摘要: extends在英文意思上看是“继承”的意思。子类是父类的拓展,例如我们要新定义一个Student类,发现Student类里的很多属性或方法在Person中都都是重复的,我们就可以让Student类继承Person类,使Student类拥有Person类的属性和方法。 话不多说,上一个demo,知识 阅读全文
posted @ 2019-03-08 23:42 codeFlyer 阅读(1329) 评论(0) 推荐(0)