Isn’t “package private” member access synonymous with the default (no-modifier) access?

Yes, it’s almost the same. The protected modifier specifies that the member can only be accessed within its own package (as with package-private) and, in addition, by a subclass of its class in another package.

Leave a Comment

tech