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); } } }
protected override void doOnReceive(byte[] bytes, int length) { _reader.decode(bytes, length, OnResponse); }