예제 #1
0
 protected override void doOnReceive(byte[] bytes, int length)
 {
     _tmpDatas.Clear();
     _reader.decode(bytes, length, _tmpDatas);
     for (int i = 0; i < _tmpDatas.Count; i++)
     {
         byte[] data = _tmpDatas[i];
         if (data != null && data.Length > 0)
         {
             string        json = JCode.GetString(data, data.Length);
             StringBuilder sb   = new StringBuilder(json);
             //int cmd = 0;// int.Parse(getPT(sb));
             //MyDebug.Log(json);
             OnReceive(sb);
         }
     }
 }
예제 #2
0
 protected override void doOnReceive(byte[] bytes, int length)
 {
     _reader.decode(bytes, length, OnResponse);
 }