Python导入类的对象作为当前类的全局变量
摘要:
from a import A class B(): def init(self): self.a_obj = A() def b_method(self): print "calling a_method() from B..." self.a_obj.a_method() 阅读全文
posted @ 2020-11-19 15:30 小白在此 阅读(495) 评论(0) 推荐(0) 编辑