public void Read(TProtocol iprot) { TField field; iprot.ReadStructBegin(); while (true) { field = iprot.ReadFieldBegin(); if (field.Type == TType.Stop) { break; } switch (field.ID) { case 0: if (field.Type == TType.List) { { Success = new List<KeySlice>(); TList _list109 = iprot.ReadListBegin(); for( int _i110 = 0; _i110 < _list109.Count; ++_i110) { KeySlice _elem111 = new KeySlice(); _elem111 = new KeySlice(); _elem111.Read(iprot); Success.Add(_elem111); } iprot.ReadListEnd(); } } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 1: if (field.Type == TType.Struct) { Ire = new InvalidRequestException(); Ire.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 2: if (field.Type == TType.Struct) { Ue = new UnavailableException(); Ue.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 3: if (field.Type == TType.Struct) { Te = new TimedOutException(); Te.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; default: TProtocolUtil.Skip(iprot, field.Type); break; } iprot.ReadFieldEnd(); } iprot.ReadStructEnd(); }
public void Read(TProtocol iprot) { TField field; iprot.ReadStructBegin(); while (true) { field = iprot.ReadFieldBegin(); if (field.Type == TType.Stop) { break; } switch (field.ID) { case 0: if (field.Type == TType.List) { { this.success = new List<KeySlice>(); TList _list47 = iprot.ReadListBegin(); for( int _i48 = 0; _i48 < _list47.Count; ++_i48) { KeySlice _elem49 = new KeySlice(); _elem49 = new KeySlice(); _elem49.Read(iprot); this.success.Add(_elem49); } iprot.ReadListEnd(); } this.__isset.success = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 1: if (field.Type == TType.Struct) { this.ire = new InvalidRequestException(); this.ire.Read(iprot); this.__isset.ire = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 2: if (field.Type == TType.Struct) { this.ue = new UnavailableException(); this.ue.Read(iprot); this.__isset.ue = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 3: if (field.Type == TType.Struct) { this.te = new TimedOutException(); this.te.Read(iprot); this.__isset.te = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; default: TProtocolUtil.Skip(iprot, field.Type); break; } iprot.ReadFieldEnd(); } iprot.ReadStructEnd(); }