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 a singleton class in Java? And How to implement a singleton class?

Answer Posted / nashiinformaticssolutions

A class that can possess only one object at a time is called a singleton class. To implement a singleton class given steps are to be followed:
1. Make sure that the class has only one object
2. Give global access to that object

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How we can generate random numbers in java?

1134


Why java applets are more useful for intranets as compared to internet?

1077


What is bean? Where it can be used?

1088


What does jenkins do?

914


Which sorting algorithm is best in java?

989


What is the default size of load factor in hashing based collection?

1051


Is null an object java?

996


Does treeset use compareto?

979


What is numeric function?

1021


What are the advantages of java?

991


Explain the differences between abstraction and encapsulation?

1057


What does string [] args mean?

1019


What do you understand by the term string pool?

1013


how can you take care of mutual exclusion using java threads? : Java thread

1048


Why null value is used in string?

1051