If a class is both a subclass of and in the same package as the class with the protected member, then the class has access to the protected member.

 
  • 如果一个类既是包含受保护成员的类的子类,又与它在同一个包中,则该类可访问受保护的成员。
今日热词
目录 附录 查词历史