C#学习之继承

基本概念 面向对象的三个特性:继承、封装、多态 继承 继承的类型:单重继承、多重继承、多层继承(C#不支持类的多重继承,但允接口的多重继承)、接口继承 实现继承 //类 class child : MyBaseClass class child : MyBaseClass,Interface1,Interface2 //接口(只能用于继承接口) public struct childStruct
相关文章
相关标签/搜索