Created
September 5, 2010 17:13
-
-
Save sdiehl/566177 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def generate(icls): | |
strs = [] | |
def descend(cl): | |
for cls in cl.__subclasses__(): | |
strs.append('[%s]^[%s|%s]' % (cl.__name__,cls.__name__, ';'.join(cls.__dict__.keys()))) | |
descend(cls) | |
descend(icls) | |
for st in strs: | |
print st |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment