What is the difference between a public and a non-public
class?
Answer Posted / javachi
public class is a class that can be accessed from anywhere in the package and outside the package, this public means access globaly.
there is no such non-public class in java. so we can consider private, protected, friendly classes as a non-public classes.
| Is This Answer Correct ? | 6 Yes | 1 No |
Post New Answer View All Answers
When is the finalize() called?
What is meant by data hiding/encapsulation?
What is the format specifier?
Can a class have multiple constructors?
What are the changes in java.io in java 8 ?
Is c better than java?
Can we use this () and super () in a method?
Is it possible to specify multiple jndi names when deploying an ejb?
Define immutable object?
What does @param args mean in java?
What does a method signature consist of?
Implement a stack with push (), pop() and min() in O(1) time.
What is entry in java?
What is parsing in grammar?
What type of value does sizeof return?