Singleton Design pattern

The importance of this pattern is coming from the fact that There are many objects we only need one of, like objects that handle
preferences and registry settings, objects used for logging.
In fact, for many of these types of objects, if we are to instantiate more than one time we will run into all sorts of problems like incorrect program behavior, overuse of resources.
lets how we can constract a class that can work as Singleton . in order to write this class you need to follow these steps Continue reading “Singleton Design pattern”