gump-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From leosim...@apache.org
Subject svn commit: r209306 - /gump/branches/Gump3/pygump/python/gump/plugins/introspection.py
Date Tue, 05 Jul 2005 19:14:08 GMT
Author: leosimons
Date: Tue Jul  5 12:14:03 2005
New Revision: 209306

URL: http://svn.apache.org/viewcvs?rev=209306&view=rev
Log:
Some more useful introspection.

 * pygump/python/gump/plugins/introspection.py: also look at properties for Commands.

Modified:
    gump/branches/Gump3/pygump/python/gump/plugins/introspection.py

Modified: gump/branches/Gump3/pygump/python/gump/plugins/introspection.py
URL: http://svn.apache.org/viewcvs/gump/branches/Gump3/pygump/python/gump/plugins/introspection.py?rev=209306&r1=209305&r2=209306&view=diff
==============================================================================
--- gump/branches/Gump3/pygump/python/gump/plugins/introspection.py (original)
+++ gump/branches/Gump3/pygump/python/gump/plugins/introspection.py Tue Jul  5 12:14:03 2005
@@ -56,6 +56,15 @@
         msg += "\n\nAll possible project properties:\n   "
         msg += "\n   ".join(allproperties)
 
+        allproperties = []
+        for v in workspace.projects.values():
+            for c in v.commands:
+                properties = [prop for prop in dir(c) if not prop.startswith("__") and not
prop in allproperties]
+                allproperties.extend(properties)
+        allproperties.sort()
+        msg += "\n\nAll possible command properties:\n   "
+        msg += "\n   ".join(allproperties)
+
         msg += "\n\nAll known repositories:\n"
         for k in workspace.repositories.keys():
             msg += "   %s\n" % k
@@ -81,4 +90,14 @@
         #    if callable(att):
         #        continue
         #    self.log.debug("XML-APIS attribute %s has value %s" % (prop, att))
+        
+        #bootstrapant = workspace.projects["bootstrap-ant"]
+        #for c in bootstrapant.commands:
+        #    from gump.model import Script
+        #    if isinstance(c, Script):
+        #        for p in dir(c):
+        #            att = getattr(c, p)
+        #            if callable(att):
+        #                continue
+        #            self.log.debug("BOOTSTRAP-ANT command attribute %s has value %s" % (p,
att))
         



Mime
View raw message