Oct 17, 2019 in Design Patterns
Q: What is Singleton Pattern in Java?

1 Answer

0 votes
Oct 18, 2019
Singleton pattern is a creational pattern which allows only one instance of a class to be created which will be available to the whole application. The major advantage of Singleton design pattern is its saves memory because the single instance is reused again and again; there is no need to create a new object at each request. For example, in our application, we can use a single database connection shared by multiple objects, instead of creating a database connection for every request.
Click here to read more about Loan/Mortgage
Click here to read more about Insurance

Related questions

0 votes
Oct 16, 2019 in Design Patterns