private static void LazySingletonDemo() { LazySingleton obj = LazySingleton.SingleInstance; LazySingleton obj1 = LazySingleton.SingleInstance; obj.LogMessage("defect1"); obj1.LogMessage("defect2"); Console.ReadLine(); }
private static void GetLazySingletonInstance_2() { LazySingleton GetLazySingletonInstance_2 = LazySingleton.GetLazySingletonInstance; GetLazySingletonInstance_2.PrintDetails("PRINT : GetLazySingletonInstance_2"); }