李昂 55801b28f5 !109 default
* add callback test
* def test(a=1, b='test') for default is ok
* getNodeAttr
2022-09-02 11:25:32 +00:00

23 lines
391 B
Python

class Demo():
def __init__(self):
print("__init__")
self.funcs = []
self.funcs.append(self.a)
self.funcs.append(self.b)
def a(self):
print('a')
def b(self):
print('b')
def get_funcs(self):
return self.funcs
demo = Demo()
funcs = demo.get_funcs()
print('----------------------------')
for func in funcs:
func()