static void Main(string[] args)
        {
            Uri         uri  = new Uri(ConfigurationManager.AppSettings["addr"]);
            ServiceHost host = new ServiceHost(typeof(WbService.MainService), uri);
            WbDB        t    = new WbDB();

            host.Open();
            Console.WriteLine("채팅 서비스를 시작합니다. {0}", uri.ToString());
            Console.WriteLine("http://192.168.0.48:7555/GetService");
            Console.WriteLine("멈추시려면 엔터를 눌러주세요..");
            WbDB.Singleton.Connect();
            WbDB.Singleton.Dispose();

            Console.ReadLine();
            //서비스
            host.Abort();
            host.Close();
        }
示例#2
0
 static WbDB()
 {
     Singleton = new WbDB();
     Console.WriteLine("dusruf");
 }