Пример #1
0
        //后台程序监听该端口的登录情况
        private static void login(object obj)
        {
            Socket         client     = obj as Socket;
            dataProcessing listenData = new dataProcessing(client);

            listenData.receiveData();
        }
Пример #2
0
 //删除在线账号
 public static void removeDictionary(dataProcessing s)
 {
     lock (new object())
     {
         clientList.Remove(s.socket);
     }
     form.delListItem(s.userName);
 }
Пример #3
0
 //添加在线账号
 public static void addDictionary(dataProcessing dataprocessing)
 {
     lock (new object())
     {
         clientList.Add(dataprocessing.socket, dataprocessing);
     }
     form.addListItem(dataprocessing.userName);
 }