File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java in General and the fly likes using singleton pattern in java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "using singleton pattern in java " Watch "using singleton pattern in java " New topic
Author

using singleton pattern in java

Anand Jain
Greenhorn

Joined: Jul 27, 2009
Posts: 18
Can you give me the scenarios where Singleton pattern is used in Java?
Seetharaman Venkatasamy
Ranch Hand

Joined: Jan 28, 2008
Posts: 5575

you may need some values [which are common for the application ] from database on application startup time
Suhas Bilaye
Ranch Hand

Joined: Sep 10, 2009
Posts: 80
When huge objects like Hibernate Session Factory is to be created only once and the same object is to be used throughout the application

Thanks and Regards,
Suhas
http://www.xplore-java.blogspot.com/
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 40034
    
  28
Have a look at this thread and the links in it.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: using singleton pattern in java