Public, Private, and Protected 繼承
衍生類別 (Derived)
| ||||
基
礎
類
別
(Base)
|
Public繼承
|
Protected繼承
|
Private繼承
| |
Public
|
Public
Friend function
Member function
non-member function(外部函式) 可直接存取
|
Protected
Friend function
Member function
可直接存取
|
Private
Friend function
Member function
可直接存取
| |
Protected
|
Protected
Friend function
Member function
可直接存取
|
Protected
Friend function
Member function
可直接存取
|
Private
friend function
member function
可直接存取
| |
Private
|
可藉由基礎類別 的public或protect的成員函數存取 member function 及friend function
|
Hidden
可藉由基礎類別 的public或protect的成員函數存取 member function 及friend function
|
Hidden
可藉由基礎類別 的public或protect的成員函數存取 member function 及friend function
|
沒有留言:
張貼留言