| 28515 | } |
| 28516 | |
| 28517 | func (p *IClientRPCServiceOpenSessionArgs) Read(ctx context.Context, iprot thrift.TProtocol) error { |
| 28518 | if _, err := iprot.ReadStructBegin(ctx); err != nil { |
| 28519 | return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) |
| 28520 | } |
| 28521 | |
| 28522 | |
| 28523 | for { |
| 28524 | _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) |
| 28525 | if err != nil { |
| 28526 | return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) |
| 28527 | } |
| 28528 | if fieldTypeId == thrift.STOP { break; } |
| 28529 | switch fieldId { |
| 28530 | case 1: |
| 28531 | if fieldTypeId == thrift.STRUCT { |
| 28532 | if err := p.ReadField1(ctx, iprot); err != nil { |
| 28533 | return err |
| 28534 | } |
| 28535 | } else { |
| 28536 | if err := iprot.Skip(ctx, fieldTypeId); err != nil { |
| 28537 | return err |
| 28538 | } |
| 28539 | } |
| 28540 | default: |
| 28541 | if err := iprot.Skip(ctx, fieldTypeId); err != nil { |
| 28542 | return err |
| 28543 | } |
| 28544 | } |
| 28545 | if err := iprot.ReadFieldEnd(ctx); err != nil { |
| 28546 | return err |
| 28547 | } |
| 28548 | } |
| 28549 | if err := iprot.ReadStructEnd(ctx); err != nil { |
| 28550 | return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) |
| 28551 | } |
| 28552 | return nil |
| 28553 | } |
| 28554 | |
| 28555 | func (p *IClientRPCServiceOpenSessionArgs) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { |
| 28556 | p.Req = &TSOpenSessionReq{ |