Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
の線に沿って何かを探していdir()ますが、スーパークラスで定義されている非インスタンスメソッドと属性を除外したいと思います。
dir()
Python 2.xの場合:
[name for name, method in Class.__dict__.iteritems() if callable(method)]
Python 3.xの場合:
[name for name, method in Class.__dict__.items() if hasattr(method,'__call__')]
I have home object : id , FirstName, Lastname, Fees[ ]
id
FirstName
Lastname
Fees[ ]
Fees is object contain Amount description DueDate ...
home object include the Fees