Suppose we have following code defined in tester.py
class Tester( object ):
def method( self ):
print 'I am a Tester'
and we have following defined in main.py
from tester import Tester
t = Tester()
#print definition of t
is there anyway we could get the definitions of a class/function from an object in a systematic way? or we have to parse the code and extract the code definition manually then save them into a string?