best answer > Can you override a protected method in Java 2024?- QuesHub | Better Than Quora
The most authoritative answer in 2024
  • Julian Hall——Works at the International Fund for Agricultural Development, Lives in Rome, Italy.

    If a method cannot be inherited, then it cannot be overridden. A subclass within the same package as the instance's superclass can override any superclass method that is not declared private or final. A subclass in a different package can only override the non-final methods declared public or protected.read more >>
    +119962023-05-05 12:30:24

About “method、overridden、can override”,people ask:

READ MORE:

QuesHub is a place where questions meet answers, it is more authentic than Quora, but you still need to discern the answers provided by the respondents.

分享到

取消