# HG changeset patch # User John@Doomsday # Date 1331734410 14400 # Node ID ecef0cba29131cf3ca58ac03784d5652492e7659 # Parent 7bfbff27a3d7b30141eb44669d1a5b48c4cb7203 Very handy - print the public api of an object. Nice for when you get an AceGUI object (etc) and don't know what it exposes diff -r 7bfbff27a3d7 -r ecef0cba2913 Lists.lua --- a/Lists.lua Wed Mar 14 08:31:31 2012 -0400 +++ b/Lists.lua Wed Mar 14 10:13:30 2012 -0400 @@ -127,6 +127,13 @@ function bsk:PrintPersons() bsk:PrintTable(bsk.persons) end +function bsk:PrintAPI(object) + for i,v in pairs(object) do + if type(v) == "function" then + bsk:Print("function "..i.."()") + end + end +end function bsk:PrintTable(table, depth) depth = depth or "" if not table then return end