public static MyClientManage getInstance() { if (_instance == null) { _instance = new MyClientManage(); } return _instance; }
public static MyClientManage getInstance() { if (_instance == null) { _instance = new MyClientManage(); } return(_instance); }
public void Stop() { _currentForm.removeClientFromListView(this); isRunning = false; _socket.Close(); _threadManage.stopInstance(_idThread); MyClientManage manage = MyClientManage.getInstance(); manage.RemoveClient(this); }
private SvListenAcceptClient() { _clmanage = MyClientManage.getInstance(); }
private void Server_Load(object sender, EventArgs e) { serverSocket = new TcpListener(8888); serverSocket.Start(); _threadmanage = ServerTheadingManage.getInstance(); _myClientManage = MyClientManage.getInstance(); _myClientManage.setCurrentForm(this); _myListenAccept = SvListenAcceptClient.getInstance(serverSocket); _sthreadAcceptClient = new Thread(_myListenAccept.task); _myListenAccept.start(); _myListenAccept.setForm(this); _sthreadAcceptClient.Start(); tbPassword.Text = ""; cleanGroupQuestion(); lbServerIP.Text = GetLocalIPAddress(); this.addToReceiverText(">> Server đã khởi động xong."); }