正在加载图片...
8复合与继承的比较 例 c1 ass BirthDa七e 构造的顺序是 class TelephoneNumber i.] 按指定顺序进 class Employee 行的! public Employee ( BirthDate birth;//作为Emp1oyee的成员 TelephoneNumber tel; };§复合与继承的比较  例: class BirthDate { … }; class TelephoneNumber { … }; class Employee { public: Employee() { … } BirthDate birth; // 作为 Employee 的成员 TelephoneNumber tel; … }; 构造的顺序是 按指定顺序进 行的!
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有