github.com/Finschia/finschia-sdk@v0.48.1/x/params/types/proposal/query.pb.go (about) 1 // Code generated by protoc-gen-gogo. DO NOT EDIT. 2 // source: cosmos/params/v1beta1/query.proto 3 4 package proposal 5 6 import ( 7 context "context" 8 fmt "fmt" 9 _ "github.com/gogo/protobuf/gogoproto" 10 grpc1 "github.com/gogo/protobuf/grpc" 11 proto "github.com/gogo/protobuf/proto" 12 _ "google.golang.org/genproto/googleapis/api/annotations" 13 grpc "google.golang.org/grpc" 14 codes "google.golang.org/grpc/codes" 15 status "google.golang.org/grpc/status" 16 io "io" 17 math "math" 18 math_bits "math/bits" 19 ) 20 21 // Reference imports to suppress errors if they are not otherwise used. 22 var _ = proto.Marshal 23 var _ = fmt.Errorf 24 var _ = math.Inf 25 26 // This is a compile-time assertion to ensure that this generated file 27 // is compatible with the proto package it is being compiled against. 28 // A compilation error at this line likely means your copy of the 29 // proto package needs to be updated. 30 const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package 31 32 // QueryParamsRequest is request type for the Query/Params RPC method. 33 type QueryParamsRequest struct { 34 // subspace defines the module to query the parameter for. 35 Subspace string `protobuf:"bytes,1,opt,name=subspace,proto3" json:"subspace,omitempty"` 36 // key defines the key of the parameter in the subspace. 37 Key string `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"` 38 } 39 40 func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } 41 func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } 42 func (*QueryParamsRequest) ProtoMessage() {} 43 func (*QueryParamsRequest) Descriptor() ([]byte, []int) { 44 return fileDescriptor_2b32979c1792ccc4, []int{0} 45 } 46 func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { 47 return m.Unmarshal(b) 48 } 49 func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 50 if deterministic { 51 return xxx_messageInfo_QueryParamsRequest.Marshal(b, m, deterministic) 52 } else { 53 b = b[:cap(b)] 54 n, err := m.MarshalToSizedBuffer(b) 55 if err != nil { 56 return nil, err 57 } 58 return b[:n], nil 59 } 60 } 61 func (m *QueryParamsRequest) XXX_Merge(src proto.Message) { 62 xxx_messageInfo_QueryParamsRequest.Merge(m, src) 63 } 64 func (m *QueryParamsRequest) XXX_Size() int { 65 return m.Size() 66 } 67 func (m *QueryParamsRequest) XXX_DiscardUnknown() { 68 xxx_messageInfo_QueryParamsRequest.DiscardUnknown(m) 69 } 70 71 var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo 72 73 func (m *QueryParamsRequest) GetSubspace() string { 74 if m != nil { 75 return m.Subspace 76 } 77 return "" 78 } 79 80 func (m *QueryParamsRequest) GetKey() string { 81 if m != nil { 82 return m.Key 83 } 84 return "" 85 } 86 87 // QueryParamsResponse is response type for the Query/Params RPC method. 88 type QueryParamsResponse struct { 89 // param defines the queried parameter. 90 Param ParamChange `protobuf:"bytes,1,opt,name=param,proto3" json:"param"` 91 } 92 93 func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } 94 func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } 95 func (*QueryParamsResponse) ProtoMessage() {} 96 func (*QueryParamsResponse) Descriptor() ([]byte, []int) { 97 return fileDescriptor_2b32979c1792ccc4, []int{1} 98 } 99 func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { 100 return m.Unmarshal(b) 101 } 102 func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 103 if deterministic { 104 return xxx_messageInfo_QueryParamsResponse.Marshal(b, m, deterministic) 105 } else { 106 b = b[:cap(b)] 107 n, err := m.MarshalToSizedBuffer(b) 108 if err != nil { 109 return nil, err 110 } 111 return b[:n], nil 112 } 113 } 114 func (m *QueryParamsResponse) XXX_Merge(src proto.Message) { 115 xxx_messageInfo_QueryParamsResponse.Merge(m, src) 116 } 117 func (m *QueryParamsResponse) XXX_Size() int { 118 return m.Size() 119 } 120 func (m *QueryParamsResponse) XXX_DiscardUnknown() { 121 xxx_messageInfo_QueryParamsResponse.DiscardUnknown(m) 122 } 123 124 var xxx_messageInfo_QueryParamsResponse proto.InternalMessageInfo 125 126 func (m *QueryParamsResponse) GetParam() ParamChange { 127 if m != nil { 128 return m.Param 129 } 130 return ParamChange{} 131 } 132 133 func init() { 134 proto.RegisterType((*QueryParamsRequest)(nil), "cosmos.params.v1beta1.QueryParamsRequest") 135 proto.RegisterType((*QueryParamsResponse)(nil), "cosmos.params.v1beta1.QueryParamsResponse") 136 } 137 138 func init() { proto.RegisterFile("cosmos/params/v1beta1/query.proto", fileDescriptor_2b32979c1792ccc4) } 139 140 var fileDescriptor_2b32979c1792ccc4 = []byte{ 141 // 329 bytes of a gzipped FileDescriptorProto 142 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x91, 0xb1, 0x4b, 0xfb, 0x40, 143 0x14, 0xc7, 0x73, 0xfd, 0xfd, 0x5a, 0xf4, 0x5c, 0xe4, 0x54, 0x28, 0x41, 0x53, 0x0d, 0x08, 0x2a, 144 0x98, 0xa3, 0x75, 0x71, 0x72, 0xa8, 0xe0, 0xac, 0x01, 0x17, 0xb7, 0x4b, 0x3c, 0xd3, 0xd0, 0x36, 145 0xef, 0x9a, 0x77, 0x11, 0xbb, 0x3a, 0x38, 0x17, 0xfc, 0xa7, 0x3a, 0x16, 0x5c, 0x9c, 0x44, 0x5a, 146 0xff, 0x10, 0xe9, 0x5d, 0x14, 0xc4, 0x2a, 0x6e, 0x2f, 0x2f, 0x9f, 0xf7, 0xf9, 0xde, 0xbb, 0xa3, 147 0x3b, 0x31, 0x60, 0x1f, 0x90, 0x2b, 0x91, 0x8b, 0x3e, 0xf2, 0xdb, 0x66, 0x24, 0xb5, 0x68, 0xf2, 148 0x41, 0x21, 0xf3, 0x61, 0xa0, 0x72, 0xd0, 0xc0, 0x36, 0x2c, 0x12, 0x58, 0x24, 0x28, 0x11, 0x77, 149 0x3d, 0x81, 0x04, 0x0c, 0xc1, 0xe7, 0x95, 0x85, 0xdd, 0xcd, 0x04, 0x20, 0xe9, 0x49, 0x2e, 0x54, 150 0xca, 0x45, 0x96, 0x81, 0x16, 0x3a, 0x85, 0x0c, 0xcb, 0xbf, 0xfe, 0xe2, 0xb4, 0xd2, 0x6c, 0x18, 151 0xbf, 0x4d, 0xd9, 0xc5, 0x3c, 0xfd, 0xdc, 0x34, 0x43, 0x39, 0x28, 0x24, 0x6a, 0xe6, 0xd2, 0x25, 152 0x2c, 0x22, 0x54, 0x22, 0x96, 0x75, 0xb2, 0x4d, 0xf6, 0x96, 0xc3, 0xcf, 0x6f, 0xb6, 0x4a, 0xff, 153 0x75, 0xe5, 0xb0, 0x5e, 0x31, 0xed, 0x79, 0xe9, 0x5f, 0xd2, 0xb5, 0x2f, 0x0e, 0x54, 0x90, 0xa1, 154 0x64, 0x27, 0xb4, 0x6a, 0xa2, 0x8c, 0x61, 0xa5, 0xe5, 0x07, 0x0b, 0x37, 0x0b, 0xcc, 0xd4, 0x69, 155 0x47, 0x64, 0x89, 0x6c, 0xff, 0x1f, 0xbf, 0x34, 0x9c, 0xd0, 0x8e, 0xb5, 0x46, 0x84, 0x56, 0x8d, 156 0x97, 0x3d, 0x10, 0x5a, 0xb3, 0x72, 0xb6, 0xff, 0x83, 0xe5, 0xfb, 0x12, 0xee, 0xc1, 0x5f, 0x50, 157 0x7b, 0x56, 0x7f, 0xf7, 0xfe, 0xe9, 0xed, 0xb1, 0xd2, 0x60, 0x5b, 0xfc, 0xb7, 0x3b, 0x6b, 0x87, 158 0xe3, 0xa9, 0x47, 0x26, 0x53, 0x8f, 0xbc, 0x4e, 0x3d, 0x32, 0x9a, 0x79, 0xce, 0x64, 0xe6, 0x39, 159 0xcf, 0x33, 0xcf, 0xb9, 0x3a, 0x4e, 0x52, 0xdd, 0x29, 0xa2, 0x20, 0x86, 0x3e, 0x3f, 0x4b, 0x33, 160 0x8c, 0x3b, 0xa9, 0xe0, 0x37, 0x65, 0x71, 0x88, 0xd7, 0x5d, 0x7e, 0xf7, 0xe1, 0xd4, 0x43, 0x25, 161 0x91, 0xab, 0x1c, 0x14, 0xa0, 0xe8, 0x45, 0x35, 0xf3, 0x10, 0x47, 0xef, 0x01, 0x00, 0x00, 0xff, 162 0xff, 0x00, 0xb4, 0x64, 0x2f, 0x1c, 0x02, 0x00, 0x00, 163 } 164 165 // Reference imports to suppress errors if they are not otherwise used. 166 var _ context.Context 167 var _ grpc.ClientConn 168 169 // This is a compile-time assertion to ensure that this generated file 170 // is compatible with the grpc package it is being compiled against. 171 const _ = grpc.SupportPackageIsVersion4 172 173 // QueryClient is the client API for Query service. 174 // 175 // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. 176 type QueryClient interface { 177 // Params queries a specific parameter of a module, given its subspace and 178 // key. 179 Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) 180 } 181 182 type queryClient struct { 183 cc grpc1.ClientConn 184 } 185 186 func NewQueryClient(cc grpc1.ClientConn) QueryClient { 187 return &queryClient{cc} 188 } 189 190 func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { 191 out := new(QueryParamsResponse) 192 err := c.cc.Invoke(ctx, "/cosmos.params.v1beta1.Query/Params", in, out, opts...) 193 if err != nil { 194 return nil, err 195 } 196 return out, nil 197 } 198 199 // QueryServer is the server API for Query service. 200 type QueryServer interface { 201 // Params queries a specific parameter of a module, given its subspace and 202 // key. 203 Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) 204 } 205 206 // UnimplementedQueryServer can be embedded to have forward compatible implementations. 207 type UnimplementedQueryServer struct { 208 } 209 210 func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) { 211 return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") 212 } 213 214 func RegisterQueryServer(s grpc1.Server, srv QueryServer) { 215 s.RegisterService(&_Query_serviceDesc, srv) 216 } 217 218 func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 219 in := new(QueryParamsRequest) 220 if err := dec(in); err != nil { 221 return nil, err 222 } 223 if interceptor == nil { 224 return srv.(QueryServer).Params(ctx, in) 225 } 226 info := &grpc.UnaryServerInfo{ 227 Server: srv, 228 FullMethod: "/cosmos.params.v1beta1.Query/Params", 229 } 230 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 231 return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) 232 } 233 return interceptor(ctx, in, info, handler) 234 } 235 236 var _Query_serviceDesc = grpc.ServiceDesc{ 237 ServiceName: "cosmos.params.v1beta1.Query", 238 HandlerType: (*QueryServer)(nil), 239 Methods: []grpc.MethodDesc{ 240 { 241 MethodName: "Params", 242 Handler: _Query_Params_Handler, 243 }, 244 }, 245 Streams: []grpc.StreamDesc{}, 246 Metadata: "cosmos/params/v1beta1/query.proto", 247 } 248 249 func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { 250 size := m.Size() 251 dAtA = make([]byte, size) 252 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 253 if err != nil { 254 return nil, err 255 } 256 return dAtA[:n], nil 257 } 258 259 func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error) { 260 size := m.Size() 261 return m.MarshalToSizedBuffer(dAtA[:size]) 262 } 263 264 func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { 265 i := len(dAtA) 266 _ = i 267 var l int 268 _ = l 269 if len(m.Key) > 0 { 270 i -= len(m.Key) 271 copy(dAtA[i:], m.Key) 272 i = encodeVarintQuery(dAtA, i, uint64(len(m.Key))) 273 i-- 274 dAtA[i] = 0x12 275 } 276 if len(m.Subspace) > 0 { 277 i -= len(m.Subspace) 278 copy(dAtA[i:], m.Subspace) 279 i = encodeVarintQuery(dAtA, i, uint64(len(m.Subspace))) 280 i-- 281 dAtA[i] = 0xa 282 } 283 return len(dAtA) - i, nil 284 } 285 286 func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error) { 287 size := m.Size() 288 dAtA = make([]byte, size) 289 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 290 if err != nil { 291 return nil, err 292 } 293 return dAtA[:n], nil 294 } 295 296 func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error) { 297 size := m.Size() 298 return m.MarshalToSizedBuffer(dAtA[:size]) 299 } 300 301 func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { 302 i := len(dAtA) 303 _ = i 304 var l int 305 _ = l 306 { 307 size, err := m.Param.MarshalToSizedBuffer(dAtA[:i]) 308 if err != nil { 309 return 0, err 310 } 311 i -= size 312 i = encodeVarintQuery(dAtA, i, uint64(size)) 313 } 314 i-- 315 dAtA[i] = 0xa 316 return len(dAtA) - i, nil 317 } 318 319 func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { 320 offset -= sovQuery(v) 321 base := offset 322 for v >= 1<<7 { 323 dAtA[offset] = uint8(v&0x7f | 0x80) 324 v >>= 7 325 offset++ 326 } 327 dAtA[offset] = uint8(v) 328 return base 329 } 330 func (m *QueryParamsRequest) Size() (n int) { 331 if m == nil { 332 return 0 333 } 334 var l int 335 _ = l 336 l = len(m.Subspace) 337 if l > 0 { 338 n += 1 + l + sovQuery(uint64(l)) 339 } 340 l = len(m.Key) 341 if l > 0 { 342 n += 1 + l + sovQuery(uint64(l)) 343 } 344 return n 345 } 346 347 func (m *QueryParamsResponse) Size() (n int) { 348 if m == nil { 349 return 0 350 } 351 var l int 352 _ = l 353 l = m.Param.Size() 354 n += 1 + l + sovQuery(uint64(l)) 355 return n 356 } 357 358 func sovQuery(x uint64) (n int) { 359 return (math_bits.Len64(x|1) + 6) / 7 360 } 361 func sozQuery(x uint64) (n int) { 362 return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) 363 } 364 func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error { 365 l := len(dAtA) 366 iNdEx := 0 367 for iNdEx < l { 368 preIndex := iNdEx 369 var wire uint64 370 for shift := uint(0); ; shift += 7 { 371 if shift >= 64 { 372 return ErrIntOverflowQuery 373 } 374 if iNdEx >= l { 375 return io.ErrUnexpectedEOF 376 } 377 b := dAtA[iNdEx] 378 iNdEx++ 379 wire |= uint64(b&0x7F) << shift 380 if b < 0x80 { 381 break 382 } 383 } 384 fieldNum := int32(wire >> 3) 385 wireType := int(wire & 0x7) 386 if wireType == 4 { 387 return fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") 388 } 389 if fieldNum <= 0 { 390 return fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) 391 } 392 switch fieldNum { 393 case 1: 394 if wireType != 2 { 395 return fmt.Errorf("proto: wrong wireType = %d for field Subspace", wireType) 396 } 397 var stringLen uint64 398 for shift := uint(0); ; shift += 7 { 399 if shift >= 64 { 400 return ErrIntOverflowQuery 401 } 402 if iNdEx >= l { 403 return io.ErrUnexpectedEOF 404 } 405 b := dAtA[iNdEx] 406 iNdEx++ 407 stringLen |= uint64(b&0x7F) << shift 408 if b < 0x80 { 409 break 410 } 411 } 412 intStringLen := int(stringLen) 413 if intStringLen < 0 { 414 return ErrInvalidLengthQuery 415 } 416 postIndex := iNdEx + intStringLen 417 if postIndex < 0 { 418 return ErrInvalidLengthQuery 419 } 420 if postIndex > l { 421 return io.ErrUnexpectedEOF 422 } 423 m.Subspace = string(dAtA[iNdEx:postIndex]) 424 iNdEx = postIndex 425 case 2: 426 if wireType != 2 { 427 return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) 428 } 429 var stringLen uint64 430 for shift := uint(0); ; shift += 7 { 431 if shift >= 64 { 432 return ErrIntOverflowQuery 433 } 434 if iNdEx >= l { 435 return io.ErrUnexpectedEOF 436 } 437 b := dAtA[iNdEx] 438 iNdEx++ 439 stringLen |= uint64(b&0x7F) << shift 440 if b < 0x80 { 441 break 442 } 443 } 444 intStringLen := int(stringLen) 445 if intStringLen < 0 { 446 return ErrInvalidLengthQuery 447 } 448 postIndex := iNdEx + intStringLen 449 if postIndex < 0 { 450 return ErrInvalidLengthQuery 451 } 452 if postIndex > l { 453 return io.ErrUnexpectedEOF 454 } 455 m.Key = string(dAtA[iNdEx:postIndex]) 456 iNdEx = postIndex 457 default: 458 iNdEx = preIndex 459 skippy, err := skipQuery(dAtA[iNdEx:]) 460 if err != nil { 461 return err 462 } 463 if (skippy < 0) || (iNdEx+skippy) < 0 { 464 return ErrInvalidLengthQuery 465 } 466 if (iNdEx + skippy) > l { 467 return io.ErrUnexpectedEOF 468 } 469 iNdEx += skippy 470 } 471 } 472 473 if iNdEx > l { 474 return io.ErrUnexpectedEOF 475 } 476 return nil 477 } 478 func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error { 479 l := len(dAtA) 480 iNdEx := 0 481 for iNdEx < l { 482 preIndex := iNdEx 483 var wire uint64 484 for shift := uint(0); ; shift += 7 { 485 if shift >= 64 { 486 return ErrIntOverflowQuery 487 } 488 if iNdEx >= l { 489 return io.ErrUnexpectedEOF 490 } 491 b := dAtA[iNdEx] 492 iNdEx++ 493 wire |= uint64(b&0x7F) << shift 494 if b < 0x80 { 495 break 496 } 497 } 498 fieldNum := int32(wire >> 3) 499 wireType := int(wire & 0x7) 500 if wireType == 4 { 501 return fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") 502 } 503 if fieldNum <= 0 { 504 return fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) 505 } 506 switch fieldNum { 507 case 1: 508 if wireType != 2 { 509 return fmt.Errorf("proto: wrong wireType = %d for field Param", wireType) 510 } 511 var msglen int 512 for shift := uint(0); ; shift += 7 { 513 if shift >= 64 { 514 return ErrIntOverflowQuery 515 } 516 if iNdEx >= l { 517 return io.ErrUnexpectedEOF 518 } 519 b := dAtA[iNdEx] 520 iNdEx++ 521 msglen |= int(b&0x7F) << shift 522 if b < 0x80 { 523 break 524 } 525 } 526 if msglen < 0 { 527 return ErrInvalidLengthQuery 528 } 529 postIndex := iNdEx + msglen 530 if postIndex < 0 { 531 return ErrInvalidLengthQuery 532 } 533 if postIndex > l { 534 return io.ErrUnexpectedEOF 535 } 536 if err := m.Param.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 537 return err 538 } 539 iNdEx = postIndex 540 default: 541 iNdEx = preIndex 542 skippy, err := skipQuery(dAtA[iNdEx:]) 543 if err != nil { 544 return err 545 } 546 if (skippy < 0) || (iNdEx+skippy) < 0 { 547 return ErrInvalidLengthQuery 548 } 549 if (iNdEx + skippy) > l { 550 return io.ErrUnexpectedEOF 551 } 552 iNdEx += skippy 553 } 554 } 555 556 if iNdEx > l { 557 return io.ErrUnexpectedEOF 558 } 559 return nil 560 } 561 func skipQuery(dAtA []byte) (n int, err error) { 562 l := len(dAtA) 563 iNdEx := 0 564 depth := 0 565 for iNdEx < l { 566 var wire uint64 567 for shift := uint(0); ; shift += 7 { 568 if shift >= 64 { 569 return 0, ErrIntOverflowQuery 570 } 571 if iNdEx >= l { 572 return 0, io.ErrUnexpectedEOF 573 } 574 b := dAtA[iNdEx] 575 iNdEx++ 576 wire |= (uint64(b) & 0x7F) << shift 577 if b < 0x80 { 578 break 579 } 580 } 581 wireType := int(wire & 0x7) 582 switch wireType { 583 case 0: 584 for shift := uint(0); ; shift += 7 { 585 if shift >= 64 { 586 return 0, ErrIntOverflowQuery 587 } 588 if iNdEx >= l { 589 return 0, io.ErrUnexpectedEOF 590 } 591 iNdEx++ 592 if dAtA[iNdEx-1] < 0x80 { 593 break 594 } 595 } 596 case 1: 597 iNdEx += 8 598 case 2: 599 var length int 600 for shift := uint(0); ; shift += 7 { 601 if shift >= 64 { 602 return 0, ErrIntOverflowQuery 603 } 604 if iNdEx >= l { 605 return 0, io.ErrUnexpectedEOF 606 } 607 b := dAtA[iNdEx] 608 iNdEx++ 609 length |= (int(b) & 0x7F) << shift 610 if b < 0x80 { 611 break 612 } 613 } 614 if length < 0 { 615 return 0, ErrInvalidLengthQuery 616 } 617 iNdEx += length 618 case 3: 619 depth++ 620 case 4: 621 if depth == 0 { 622 return 0, ErrUnexpectedEndOfGroupQuery 623 } 624 depth-- 625 case 5: 626 iNdEx += 4 627 default: 628 return 0, fmt.Errorf("proto: illegal wireType %d", wireType) 629 } 630 if iNdEx < 0 { 631 return 0, ErrInvalidLengthQuery 632 } 633 if depth == 0 { 634 return iNdEx, nil 635 } 636 } 637 return 0, io.ErrUnexpectedEOF 638 } 639 640 var ( 641 ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") 642 ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") 643 ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") 644 )