Example #1
0
func (p *GetAccessableGroupResourcesArgs) ReadField3(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return fmt.Errorf("error reading field 3: %s", err)
	} else {
		temp := entity.Zone(v)
		p.Zone = temp
	}
	return nil
}
Example #2
0
func (p *HasAccessToRegionArgs) ReadField3(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return fmt.Errorf("error reading field 3: %s", err)
	} else {
		temp := entity.Zone(v)
		p.Zone = temp
	}
	return nil
}
Example #3
0
func (p *GrantUserAccessToGroupRegionArgs) ReadField3(iprot thrift.TProtocol) error {
	_, size, err := iprot.ReadListBegin()
	if err != nil {
		return fmt.Errorf("error reading list begin: %s", err)
	}
	tSlice := make([]entity.Zone, 0, size)
	p.Zones = tSlice
	for i := 0; i < size; i++ {
		var _elem454 entity.Zone
		if v, err := iprot.ReadI32(); err != nil {
			return fmt.Errorf("error reading field 0: %s", err)
		} else {
			temp := entity.Zone(v)
			_elem454 = temp
		}
		p.Zones = append(p.Zones, _elem454)
	}
	if err := iprot.ReadListEnd(); err != nil {
		return fmt.Errorf("error reading list end: %s", err)
	}
	return nil
}