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...

what is the use of private constructor in core java?

Answer Posted / rakesh

Private constructor can be used if we do not want any other
class to instantiate the class. This concept is generally
used in Singleton Design Pattern. The instantiation of such
classes is done from a static public method.

Is This Answer Correct ?    54 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is runtime polymorphism or dynamic method dispatch?

981


Why 1 is not a prime number?

983


What is final method in java?

981


What are different access specifiers in java?

961


How do you use wildcards?

994


What are the different ways of implementing thread? Which one is more advantageous?

947


What is the use of static class?

1107


Can we override the static methods?

991


Which collection is ordered in java?

941


What is class??

1180


Why we used break and continue statement in java?

1082


5 Coding best practices you learned in java?

989


Define array. Tell me about 2-D array.

1006


What is the main use of generics in java?

933


What is "this" keyword in java? Explain

1061