C++:繼承訪問屬性(public/protected/private)

 

http://www.javashuo.com/article/p-pbrguerd-ga.html

•總結

父類中的訪問屬性 繼承方式 子類中的訪問屬性
private public/protected/private 不容許訪問
public public public
public protected protected
public private private
protected public protected
protected protected protected
protected private private
相關文章
相關標籤/搜索