func (p *HealthCheckRes) Read(iprot thrift.TProtocol) error { if _, err := iprot.ReadStructBegin(); err != nil { return fmt.Errorf("%T read error: %s", p, err) } for { _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin() if err != nil { return fmt.Errorf("%T field %d read error: %s", p, fieldId, err) } if fieldTypeId == thrift.STOP { break } switch fieldId { case 1: if err := p.ReadField1(iprot); err != nil { return err } case 2: if err := p.ReadField2(iprot); err != nil { return err } default: if err := iprot.Skip(fieldTypeId); err != nil { return err } } if err := iprot.ReadFieldEnd(); err != nil { return err } } if err := iprot.ReadStructEnd(); err != nil { return fmt.Errorf("%T read struct end error: %s", p, err) } return nil }
func (p *NotAuthorized) Read(iprot thrift.TProtocol) error { if _, err := iprot.ReadStructBegin(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) } for { _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin() if err != nil { return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) } if fieldTypeId == thrift.STOP { break } if err := iprot.Skip(fieldTypeId); err != nil { return err } if err := iprot.ReadFieldEnd(); err != nil { return err } } if err := iprot.ReadStructEnd(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) } return nil }
func (p *AccountDoActionArgs) Read(iprot thrift.TProtocol) error { if _, err := iprot.ReadStructBegin(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) } for { _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin() if err != nil { return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) } if fieldTypeId == thrift.STOP { break } switch fieldId { case 1: if err := p.readField1(iprot); err != nil { return err } default: if err := iprot.Skip(fieldTypeId); err != nil { return err } } if err := iprot.ReadFieldEnd(); err != nil { return err } } if err := iprot.ReadStructEnd(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) } return nil }
func (p *FirstHealthcheckResult) Read(iprot thrift.TProtocol) error { if _, err := iprot.ReadStructBegin(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) } for { _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin() if err != nil { return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) } if fieldTypeId == thrift.STOP { break } switch fieldId { case 0: if err := p.ReadField0(iprot); err != nil { return err } default: if err := iprot.Skip(fieldTypeId); err != nil { return err } } if err := iprot.ReadFieldEnd(); err != nil { return err } } if err := iprot.ReadStructEnd(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) } return nil }
func (p *Span) Read(iprot thrift.TProtocol) error { if _, err := iprot.ReadStructBegin(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) } for { _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin() if err != nil { return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) } if fieldTypeId == thrift.STOP { break } switch fieldId { case 1: if err := p.readField1(iprot); err != nil { return err } case 2: if err := p.readField2(iprot); err != nil { return err } case 3: if err := p.readField3(iprot); err != nil { return err } case 4: if err := p.readField4(iprot); err != nil { return err } case 5: if err := p.readField5(iprot); err != nil { return err } case 6: if err := p.readField6(iprot); err != nil { return err } case 7: if err := p.readField7(iprot); err != nil { return err } case 8: if err := p.readField8(iprot); err != nil { return err } default: if err := iprot.Skip(fieldTypeId); err != nil { return err } } if err := iprot.ReadFieldEnd(); err != nil { return err } } if err := iprot.ReadStructEnd(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) } return nil }
func (p *VersionInfo) Read(iprot thrift.TProtocol) error { if _, err := iprot.ReadStructBegin(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) } var issetLanguage bool = false var issetLanguageVersion bool = false var issetVersion bool = false for { _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin() if err != nil { return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) } if fieldTypeId == thrift.STOP { break } switch fieldId { case 1: if err := p.readField1(iprot); err != nil { return err } issetLanguage = true case 2: if err := p.readField2(iprot); err != nil { return err } issetLanguageVersion = true case 3: if err := p.readField3(iprot); err != nil { return err } issetVersion = true default: if err := iprot.Skip(fieldTypeId); err != nil { return err } } if err := iprot.ReadFieldEnd(); err != nil { return err } } if err := iprot.ReadStructEnd(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) } if !issetLanguage { return thrift.NewTProtocolExceptionWithType(thrift.INVALID_DATA, fmt.Errorf("Required field Language is not set")) } if !issetLanguageVersion { return thrift.NewTProtocolExceptionWithType(thrift.INVALID_DATA, fmt.Errorf("Required field LanguageVersion is not set")) } if !issetVersion { return thrift.NewTProtocolExceptionWithType(thrift.INVALID_DATA, fmt.Errorf("Required field Version is not set")) } return nil }
func (p *BinaryAnnotation) Read(iprot thrift.TProtocol) error { if _, err := iprot.ReadStructBegin(); err != nil { return fmt.Errorf("%T read error: %s", p, err) } for { _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin() if err != nil { return fmt.Errorf("%T field %d read error: %s", p, fieldId, err) } if fieldTypeId == thrift.STOP { break } switch fieldId { case 1: if err := p.ReadField1(iprot); err != nil { return err } case 2: if err := p.ReadField2(iprot); err != nil { return err } case 3: if err := p.ReadField3(iprot); err != nil { return err } case 4: if err := p.ReadField4(iprot); err != nil { return err } case 5: if err := p.ReadField5(iprot); err != nil { return err } case 6: if err := p.ReadField6(iprot); err != nil { return err } case 7: if err := p.ReadField7(iprot); err != nil { return err } default: if err := iprot.Skip(fieldTypeId); err != nil { return err } } if err := iprot.ReadFieldEnd(); err != nil { return err } } if err := iprot.ReadStructEnd(); err != nil { return fmt.Errorf("%T read struct end error: %s", p, err) } return nil }
func (p *ThriftIDLs) Read(iprot thrift.TProtocol) error { if _, err := iprot.ReadStructBegin(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) } var issetIdls bool = false var issetEntryPoint bool = false for { _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin() if err != nil { return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) } if fieldTypeId == thrift.STOP { break } switch fieldId { case 1: if err := p.readField1(iprot); err != nil { return err } issetIdls = true case 2: if err := p.readField2(iprot); err != nil { return err } issetEntryPoint = true default: if err := iprot.Skip(fieldTypeId); err != nil { return err } } if err := iprot.ReadFieldEnd(); err != nil { return err } } if err := iprot.ReadStructEnd(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) } if !issetIdls { return thrift.NewTProtocolExceptionWithType(thrift.INVALID_DATA, fmt.Errorf("Required field Idls is not set")) } if !issetEntryPoint { return thrift.NewTProtocolExceptionWithType(thrift.INVALID_DATA, fmt.Errorf("Required field EntryPoint is not set")) } return nil }
func (p *HyperbahnDiscoverArgs) Read(iprot thrift.TProtocol) error { if _, err := iprot.ReadStructBegin(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) } var issetQuery bool = false for { _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin() if err != nil { return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) } if fieldTypeId == thrift.STOP { break } switch fieldId { case 1: if err := p.ReadField1(iprot); err != nil { return err } issetQuery = true default: if err := iprot.Skip(fieldTypeId); err != nil { return err } } if err := iprot.ReadFieldEnd(); err != nil { return err } } if err := iprot.ReadStructEnd(); err != nil { return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) } if !issetQuery { return thrift.NewTProtocolExceptionWithType(thrift.INVALID_DATA, fmt.Errorf("Required field Query is not set")) } return nil }
func (p *SimpleArgs) Read(iprot thrift.TProtocol) error { if _, err := iprot.ReadStructBegin(); err != nil { return fmt.Errorf("%T read error: %s", p, err) } for { _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin() if err != nil { return fmt.Errorf("%T field %d read error: %s", p, fieldId, err) } if fieldTypeId == thrift.STOP { break } if err := iprot.Skip(fieldTypeId); err != nil { return err } if err := iprot.ReadFieldEnd(); err != nil { return err } } if err := iprot.ReadStructEnd(); err != nil { return fmt.Errorf("%T read struct end error: %s", p, err) } return nil }