예제 #1
0
func (p *HealthStatus) writeField1(oprot thrift.TProtocol) (err error) {
	if err := oprot.WriteFieldBegin("ok", thrift.BOOL, 1); err != nil {
		return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ok: ", p), err)
	}
	if err := oprot.WriteBool(bool(p.Ok)); err != nil {
		return thrift.PrependError(fmt.Sprintf("%T.ok (1) field write error: ", p), err)
	}
	if err := oprot.WriteFieldEnd(); err != nil {
		return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ok: ", p), err)
	}
	return err
}
예제 #2
0
파일: ttypes.go 프로젝트: pengzhai/tchannel
func (p *HealthCheckRes) writeField1(oprot thrift.TProtocol) (err error) {
	if err := oprot.WriteFieldBegin("healthy", thrift.BOOL, 1); err != nil {
		return fmt.Errorf("%T write field begin error 1:healthy: %s", p, err)
	}
	if err := oprot.WriteBool(bool(p.Healthy)); err != nil {
		return fmt.Errorf("%T.healthy (1) field write error: %s", p, err)
	}
	if err := oprot.WriteFieldEnd(); err != nil {
		return fmt.Errorf("%T write field end error 1:healthy: %s", p, err)
	}
	return err
}
예제 #3
0
파일: ttypes.go 프로젝트: uber/tchannel-go
func (p *Data) writeField1(oprot thrift.TProtocol) (err error) {
	if err := oprot.WriteFieldBegin("b1", thrift.BOOL, 1); err != nil {
		return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:b1: ", p), err)
	}
	if err := oprot.WriteBool(bool(p.B1)); err != nil {
		return thrift.PrependError(fmt.Sprintf("%T.b1 (1) field write error: ", p), err)
	}
	if err := oprot.WriteFieldEnd(); err != nil {
		return thrift.PrependError(fmt.Sprintf("%T write field end error 1:b1: ", p), err)
	}
	return err
}
예제 #4
0
func (p *Response) writeField1(oprot thrift.TProtocol) (err error) {
	if err := oprot.WriteFieldBegin("ok", thrift.BOOL, 1); err != nil {
		return fmt.Errorf("%T write field begin error 1:ok: %s", p, err)
	}
	if err := oprot.WriteBool(bool(p.Ok)); err != nil {
		return fmt.Errorf("%T.ok (1) field write error: %s", p, err)
	}
	if err := oprot.WriteFieldEnd(); err != nil {
		return fmt.Errorf("%T write field end error 1:ok: %s", p, err)
	}
	return err
}
예제 #5
0
func (p *Span) writeField9(oprot thrift.TProtocol) (err error) {
	if p.IsSetDebug() {
		if err := oprot.WriteFieldBegin("debug", thrift.BOOL, 9); err != nil {
			return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:debug: ", p), err)
		}
		if err := oprot.WriteBool(bool(p.Debug)); err != nil {
			return thrift.PrependError(fmt.Sprintf("%T.debug (9) field write error: ", p), err)
		}
		if err := oprot.WriteFieldEnd(); err != nil {
			return thrift.PrependError(fmt.Sprintf("%T write field end error 9:debug: ", p), err)
		}
	}
	return err
}
예제 #6
0
func (p *BinaryAnnotation) writeField4(oprot thrift.TProtocol) (err error) {
	if p.IsSetBoolValue() {
		if err := oprot.WriteFieldBegin("boolValue", thrift.BOOL, 4); err != nil {
			return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:boolValue: ", p), err)
		}
		if err := oprot.WriteBool(bool(*p.BoolValue)); err != nil {
			return thrift.PrependError(fmt.Sprintf("%T.boolValue (4) field write error: ", p), err)
		}
		if err := oprot.WriteFieldEnd(); err != nil {
			return thrift.PrependError(fmt.Sprintf("%T write field end error 4:boolValue: ", p), err)
		}
	}
	return err
}
예제 #7
0
func (p *Span) writeField8(oprot thrift.TProtocol) (err error) {
	if p.IsSetDebug() {
		if err := oprot.WriteFieldBegin("debug", thrift.BOOL, 8); err != nil {
			return fmt.Errorf("%T write field begin error 8:debug: %s", p, err)
		}
		if err := oprot.WriteBool(bool(p.Debug)); err != nil {
			return fmt.Errorf("%T.debug (8) field write error: %s", p, err)
		}
		if err := oprot.WriteFieldEnd(); err != nil {
			return fmt.Errorf("%T write field end error 8:debug: %s", p, err)
		}
	}
	return err
}