How can i create only one instance of class and thus doesn't
allow creating any more instances?



How can i create only one instance of class and thus doesn't allow creating any more instances..

Answer / prayag thakkar

If a system only needs one instance of a class, and that
instance needs to be accessible in many different parts of
a system, you control both instantiation and access by
making that class a singleton.

Is This Answer Correct ?    5 Yes 0 No

Post New Answer

More Dot Net AllOther Interview Questions

how to delete the record using data reader

0 Answers   PCS,


what are constructors and destructors

1 Answers   Six Sigma,


Explain the difference between l1 and l2 cache? : .NET Architecture

0 Answers  


how to make and display a form without title bar?

1 Answers   Six Sigma,


How do I stop a thread?

0 Answers  






What is the .net class that allows the retrieval of a data element using a unique key?

0 Answers  


Different types of authentication modes in .net framework ?

0 Answers  


Explain is development of a mobile web application with asp.net is very easy? : Microsoft dot net mobile

0 Answers  


difference between Response.write,server.transfer and also which one is used when ?

0 Answers  


what is sessions and cookies take one example simple way to understand

0 Answers  


IS IT Possible to inherit the AJAX page from child class which(child) is inherit from page class.Because i should apply some security in child class

0 Answers   IBM,


Explain write back and write through caches? : .NET Architecture

0 Answers  


Categories