how many access specifiers are available in java

Answer Posted / gyana

there are four access specifier in java.they are

public - means the the properties of class is accessable
to all other classes.
private- means the the properties of class cannot
accessable to any other classes.
protected- means the properties of class will acessed only
to its subclasses,not subclasses of its subclasses.
no access - mean you can access it with in the class.

Is This Answer Correct ?    6 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between variable declaration and variable initialization?

500


Can substring create new object?

556


How does list work in java?

501


How do you know if a value is nan?

562


What is advantage of java?

538






What is an argument in java?

505


What is split return?

488


How do you convert bytes to character in java?

529


How to find the index of the largest number in an arraylist java?

512


What is the parse method in java?

559


What is sortedset in java?

567


What is parseint?

527


How to use Media tracker Class.

640


Hi friends am new to java. I read jar file means collection of java files. For executing struts application what are the necessary jar files. " struts.jar " file contains what. can u explain

1428


Which programming language is best in future?

517