Example #1
0
 public static SingleT getSingleT()
 {
     if (instancia == null)
     {
         instancia = new SingleT();
     }
     return(instancia);
 }
Example #2
0
        private static void TestSinglenton()
        {
            SingleT myConect = SingleT.getSingleT();

            //SingleT myConect2 = SingleT.getSingleT();
            myConect.conectar();
            myConect.desconectar();

            //myConect2.conectar();
            //myConect2.desconectar();

            var ret = myConect.GetType();

            Console.WriteLine(ret);
            Console.ReadKey();
        }