Esempio n. 1
0
        public void InitAndConnect(IPEndPoint ip, NetworkProtocol protocol, Action connect = null)
        {
            mConnect      = new Connect(ip.Address.ToString(), ip.Port, protocol);
            SystemHandler = new _System();
            mConnect.AddCallBackHandler(_System.OperatorCode, SystemHandler);

            SystemHandler.Connect += connect;
        }
Esempio n. 2
0
 /// <summary>
 /// 加入自定義的回傳處理者
 /// </summary>
 /// <param name="base"></param>
 public void AddCallBackHandler(byte operatorCode, CallBackHandler @base)
 {
     mConnect?.AddCallBackHandler(operatorCode, @base);
 }