正在加载图片...
12.1 Introduction-类之间的关系 Shape(基类 public ls-a(继承 Inheritance protected Has-a(组合) (继承关系) private crce(派生类 声明格式: class<派生类名>:<继承方式><基类名> …} class Circle: public Shape....]; 图形 闭合图形 开放图形 多边形 椭圆形(折线)(直线(弧线 O 2018, SEt. All rights reserved. 5© 2009, SEU. All rights reserved. © 2018, SEU. All rights reserved. 5 12.1 Introduction --类之间的关系 派生类 Inheritance (继承关系) public protected private 基 类 图 形 闭合图形 开放图形 多边形 椭圆形 折线 直线 弧线 Is-a(继承) Has-a(组合) Shape Circle 声明格式:class <派生类名>:<继承方式><基类名> {……}; class Circle: public Shape{……};
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有