2017年11月20日

Python 父类调用子类方法

摘要: class father(): def call_children(self): child_method = getattr(self, 'out')# 获取子类的out()方法 child_method() # 执行子类的out()方法class children(father): def out(self): print "hehe"ch... 阅读全文

posted @ 2017-11-20 17:25 DaSunWarman 阅读(4982) 评论(0) 推荐(0) 编辑

导航