Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How to access a method that it declared as protected?

Answer Posted / ranganathkini

If a method is marked protected, only the subclass of that
class can access it. To make it accessible to other classes,
the subclass of that class can override the protected method
and the override can be marked as public making it
accessible to other classes.

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is regex used for?

937


If two threads have same priority which thread will be executed first ?

1410


What is java’s garbage collected heap?

914


Explain static nested classes ?

1041


Does java arraylist maintain insertion order?

934


What is == mean?

932


Using callable statement how can you pass out parameters, explain with example?

1163


How can you share data between two thread in Java?

895


How do you insert a line break?

854


Is java an ide?

922


How to declare an arraylist in java?

997


What does a boolean method return?

1139


Explain polymorphism citing an example.

996


What is isa relationship?

962


Can we serialize arraylist in java?

957