Introduction to OOP
Chapter 8: Inheritance and Substitution:
next
previous
audio
real
text
Private, Public and Protected
There are now three levels of visibility modifiers:
private
: accessible only within the class definition (but memory is still found in the child class, just not accessible).
public
: accessible anywhere
protected
: accessible within the class definition or within the definition of child classes.
Note: Java interprets protected to mean accessible within same package
Intro OOP,
Chapter 8
, Slide 04