if you delete the static modifier of the line1 does not compile, what is the rule ?
Rule 1: The protected member can be accessible to the classes which are declared in same package in which the class declaring the member exists or accessible to the sublclss of this class. Rule 2: protected members can be accessed by their subclassed only through inheritence. if the member is instance variable or instance methods they has to follow both the rules while for the members which can not be inherited like (static members and constructors) has to follow the rule 1 only.
~Sanjeev Singh<br />SCJP 1.5
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop