+ 2
Method overriding.
The overriding method cannot be more restrictive than the overridden method. If the superclass method is public, then the overriding subclass method can neither be private nor protected. My question is, if the superclass method is protected, can the overriding subclass method be public?
1 Réponse
+ 7
Yes it can