getting all user defined attributes of a class

Amit Gupta emailamit at gmail.com
Wed Feb 6 17:07:23 EST 2008


Hi

How do I get user defined attributes of a class? e.g

Class A(object) :
  self.x = 1
------------------

I want something like:
  for userattrib in A.getAllUserAttribute() :
    print userattrib

My question is, is there a builtin function, called
getAllUserAttributes?

Thanks



More information about the Python-list mailing list