public void Read(TProtocol iprot) { iprot.IncrementRecursionDepth(); try { TField field; iprot.ReadStructBegin(); while (true) { field = iprot.ReadFieldBegin(); if (field.Type == TType.Stop) { break; } switch (field.ID) { case 1: if (field.Type == TType.Struct) { OutputFailure = new TDDIOutputFailure(); OutputFailure.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 2: if (field.Type == TType.Struct) { InputFailure = new TDDIInputFailure(); InputFailure.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; default: TProtocolUtil.Skip(iprot, field.Type); break; } iprot.ReadFieldEnd(); } iprot.ReadStructEnd(); } finally { iprot.DecrementRecursionDepth(); } }
public void Read(TProtocol iprot) { iprot.IncrementRecursionDepth(); try { TField field; iprot.ReadStructBegin(); while (true) { field = iprot.ReadFieldBegin(); if (field.Type == TType.Stop) { break; } switch (field.ID) { case 1: if (field.Type == TType.I64) { Id = iprot.ReadI64(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 2: if (field.Type == TType.String) { Name = iprot.ReadString(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 3: if (field.Type == TType.String) { Description = iprot.ReadString(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 4: if (field.Type == TType.Bool) { IsCitation = iprot.ReadBool(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 5: if (field.Type == TType.Bool) { IsAbstract = iprot.ReadBool(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 6: if (field.Type == TType.List) { { KeyValueMaps = new List <TDDIKeyValueMapRef>(); TList _list580 = iprot.ReadListBegin(); for (int _i581 = 0; _i581 < _list580.Count; ++_i581) { TDDIKeyValueMapRef _elem582; _elem582 = new TDDIKeyValueMapRef(); _elem582.Read(iprot); KeyValueMaps.Add(_elem582); } iprot.ReadListEnd(); } } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 7: if (field.Type == TType.Struct) { CitedElement = new TDDIAbstractBaseElement(); CitedElement.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 8: if (field.Type == TType.Struct) { InputFailure = new TDDIInputFailure(); InputFailure.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; default: TProtocolUtil.Skip(iprot, field.Type); break; } iprot.ReadFieldEnd(); } iprot.ReadStructEnd(); } finally { iprot.DecrementRecursionDepth(); } }
public void Read(TProtocol iprot) { iprot.IncrementRecursionDepth(); try { TField field; iprot.ReadStructBegin(); while (true) { field = iprot.ReadFieldBegin(); if (field.Type == TType.Stop) { break; } switch (field.ID) { case 1: if (field.Type == TType.I64) { Id = iprot.ReadI64(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 2: if (field.Type == TType.String) { Name = iprot.ReadString(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 3: if (field.Type == TType.String) { Description = iprot.ReadString(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 4: if (field.Type == TType.Bool) { IsCitation = iprot.ReadBool(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 5: if (field.Type == TType.Bool) { IsAbstract = iprot.ReadBool(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 6: if (field.Type == TType.List) { { KeyValueMaps = new List <TDDIKeyValueMapRef>(); TList _list568 = iprot.ReadListBegin(); for (int _i569 = 0; _i569 < _list568.Count; ++_i569) { TDDIKeyValueMapRef _elem570; _elem570 = new TDDIKeyValueMapRef(); _elem570.Read(iprot); KeyValueMaps.Add(_elem570); } iprot.ReadListEnd(); } } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 7: if (field.Type == TType.Struct) { CitedElement = new TDDIAbstractBaseElement(); CitedElement.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 8: if (field.Type == TType.Double) { FailureRate = iprot.ReadDouble(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 9: if (field.Type == TType.Struct) { FailureMode = new TDDIFailureMode(); FailureMode.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 10: if (field.Type == TType.Struct) { ProbabilityDistribution = new TDDIProbabilityDistribution(); ProbabilityDistribution.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 11: if (field.Type == TType.Struct) { OutputFailure = new TDDIOutputFailure(); OutputFailure.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 12: if (field.Type == TType.Struct) { InputFailure = new TDDIInputFailure(); InputFailure.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; default: TProtocolUtil.Skip(iprot, field.Type); break; } iprot.ReadFieldEnd(); } iprot.ReadStructEnd(); } finally { iprot.DecrementRecursionDepth(); } }