Protected vs default access control
Differences between the protected and the default/package-private access.
Quick overview, this is a typical interview question.
- the protected access has a modifier (keyword): protected
- the default access doesn’t have any modifier.
- the default access doesn’t allow access outside of the package
The complete details (Java Language Specification 11)
JLS: Access Control