Unfortunately, the case you describe is special, and
you should not use this knowledge to think it works the same with other static methods.
The reason that main() can be private or protected is that the JVM uses this method as the starting point when it executes a
java application.
If I have a simple class...
class Foo{
public static void main(
String[] args)
{
System.out.println("I am foo");
}
}//end class Foo
and you run this by typing...
java Foo
The JVM will start a new user
thread, and begin executing the main() method. Since the main() entry point must always be accessible to the JVM, it ignores the access modifier. So even if the main() method is made private, the JVM will still be able to execute it.
Again, this is a very special exception and you should not think this applies to any other method in java.