Singleton Pattern
الغرض من هذا النوذج هو التاكد من عدم عمل اكثر من نسخة من نفس الكلاس والتاكد ايضا من نقطة دخول رئيسية وعامة للاوبجيكت والمثال الاوضح لذلك هي ايقونة عمل البرامج حيث ان بعض البرامج لا تسمح بتشغيل اكثر من نسخة في ان واحد .
مثال:
public sealed class Singleton
{
    // Private Constructor
    Singleton() { }
    // Private object instantiated with private constructor
    static readonly Singleton instance = new Singleton();
    // Public static property to get the object
    public static Singleton UniqueInstance
    {
        get { return instance; }
    }
}
 
 

 
