Answer Posted / javamasque
Public: It is the highest visibility access modifier. It makes visible the class members (variables/methods) to any classes (child/non-child) present within same or any package.
Protected: It has lesser visibility than public access modifier. It makes visible the class members (variables/methods) to sub-classes within same or different package and it also make visible in any class of same package.
Default: It has lesser visibility than protected access modifier. It makes visible the class members (variables/methods) to any classes within same package only.
Private: It has least visibility than all access modifiers. It makes visible the class members (variables/methods) within same class only.
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
How will you initialize an Applet?
When do we need to use internal iteration? When do we need to use external iteration?
What is core java called?
What does %d do in java?
How is string stored in java?
How do I write a self declaration?
Why charat is used in java?
Realized?
What is core java used for?
What is the public method modifier?
Why are arrays useful in java?
How do you convert an int to a string in java?
How is hashcode calculated in java?
Explain about method local inner classes or local inner classes in java?
Is ruby built on java?