public static TransYTJ GetInstance() { if (instance == null) { instance = new TransYTJ(); } return(instance); }
public YTJtest() { //连接服务器,创建通讯类 MsgSendReceiver msr = ServerConn.ConnServer(); if (msr == null) { Console.Out.WriteLine("连接服务器失败!"); } else { ytj = TransYTJ.GetInstance(); } }