github.com/onosproject/onos-api/go@v0.10.32/onos/a1t/a1/a1.pb.go (about) 1 // Code generated by protoc-gen-gogo. DO NOT EDIT. 2 // source: onos/a1t/a1/a1.proto 3 4 // Package onos.a1t.a1 defines the interior gRPC interfaces for xApps to interact with A1T. 5 6 package a1 7 8 import ( 9 fmt "fmt" 10 _ "github.com/gogo/protobuf/gogoproto" 11 proto "github.com/gogo/protobuf/proto" 12 golang_proto "github.com/golang/protobuf/proto" 13 io "io" 14 math "math" 15 math_bits "math/bits" 16 ) 17 18 // Reference imports to suppress errors if they are not otherwise used. 19 var _ = proto.Marshal 20 var _ = golang_proto.Marshal 21 var _ = fmt.Errorf 22 var _ = math.Inf 23 24 // This is a compile-time assertion to ensure that this generated file 25 // is compatible with the proto package it is being compiled against. 26 // A compilation error at this line likely means your copy of the 27 // proto package needs to be updated. 28 const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package 29 30 type Encoding int32 31 32 const ( 33 Encoding_PROTO Encoding = 0 34 Encoding_JSON Encoding = 1 35 ) 36 37 var Encoding_name = map[int32]string{ 38 0: "PROTO", 39 1: "JSON", 40 } 41 42 var Encoding_value = map[string]int32{ 43 "PROTO": 0, 44 "JSON": 1, 45 } 46 47 func (x Encoding) String() string { 48 return proto.EnumName(Encoding_name, int32(x)) 49 } 50 51 func (Encoding) EnumDescriptor() ([]byte, []int) { 52 return fileDescriptor_4e28d31dd9c6e420, []int{0} 53 } 54 55 type PayloadType int32 56 57 const ( 58 PayloadType_POLICY PayloadType = 0 59 PayloadType_STATUS PayloadType = 1 60 ) 61 62 var PayloadType_name = map[int32]string{ 63 0: "POLICY", 64 1: "STATUS", 65 } 66 67 var PayloadType_value = map[string]int32{ 68 "POLICY": 0, 69 "STATUS": 1, 70 } 71 72 func (x PayloadType) String() string { 73 return proto.EnumName(PayloadType_name, int32(x)) 74 } 75 76 func (PayloadType) EnumDescriptor() ([]byte, []int) { 77 return fileDescriptor_4e28d31dd9c6e420, []int{1} 78 } 79 80 type Header struct { 81 RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` 82 AppId string `protobuf:"bytes,2,opt,name=app_id,json=appId,proto3" json:"app_id,omitempty"` 83 AppInstanceId string `protobuf:"bytes,3,opt,name=app_instance_id,json=appInstanceId,proto3" json:"app_instance_id,omitempty"` 84 A1NodeId string `protobuf:"bytes,4,opt,name=a1_node_id,json=a1NodeId,proto3" json:"a1_node_id,omitempty"` 85 Encoding Encoding `protobuf:"varint,5,opt,name=encoding,proto3,enum=onos.a1t.a1.Encoding" json:"encoding,omitempty"` 86 PayloadType PayloadType `protobuf:"varint,6,opt,name=payload_type,json=payloadType,proto3,enum=onos.a1t.a1.PayloadType" json:"payload_type,omitempty"` 87 } 88 89 func (m *Header) Reset() { *m = Header{} } 90 func (m *Header) String() string { return proto.CompactTextString(m) } 91 func (*Header) ProtoMessage() {} 92 func (*Header) Descriptor() ([]byte, []int) { 93 return fileDescriptor_4e28d31dd9c6e420, []int{0} 94 } 95 func (m *Header) XXX_Unmarshal(b []byte) error { 96 return m.Unmarshal(b) 97 } 98 func (m *Header) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 99 if deterministic { 100 return xxx_messageInfo_Header.Marshal(b, m, deterministic) 101 } else { 102 b = b[:cap(b)] 103 n, err := m.MarshalToSizedBuffer(b) 104 if err != nil { 105 return nil, err 106 } 107 return b[:n], nil 108 } 109 } 110 func (m *Header) XXX_Merge(src proto.Message) { 111 xxx_messageInfo_Header.Merge(m, src) 112 } 113 func (m *Header) XXX_Size() int { 114 return m.Size() 115 } 116 func (m *Header) XXX_DiscardUnknown() { 117 xxx_messageInfo_Header.DiscardUnknown(m) 118 } 119 120 var xxx_messageInfo_Header proto.InternalMessageInfo 121 122 func (m *Header) GetRequestId() string { 123 if m != nil { 124 return m.RequestId 125 } 126 return "" 127 } 128 129 func (m *Header) GetAppId() string { 130 if m != nil { 131 return m.AppId 132 } 133 return "" 134 } 135 136 func (m *Header) GetAppInstanceId() string { 137 if m != nil { 138 return m.AppInstanceId 139 } 140 return "" 141 } 142 143 func (m *Header) GetA1NodeId() string { 144 if m != nil { 145 return m.A1NodeId 146 } 147 return "" 148 } 149 150 func (m *Header) GetEncoding() Encoding { 151 if m != nil { 152 return m.Encoding 153 } 154 return Encoding_PROTO 155 } 156 157 func (m *Header) GetPayloadType() PayloadType { 158 if m != nil { 159 return m.PayloadType 160 } 161 return PayloadType_POLICY 162 } 163 164 type Result struct { 165 Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"` 166 Reason string `protobuf:"bytes,2,opt,name=reason,proto3" json:"reason,omitempty"` 167 } 168 169 func (m *Result) Reset() { *m = Result{} } 170 func (m *Result) String() string { return proto.CompactTextString(m) } 171 func (*Result) ProtoMessage() {} 172 func (*Result) Descriptor() ([]byte, []int) { 173 return fileDescriptor_4e28d31dd9c6e420, []int{1} 174 } 175 func (m *Result) XXX_Unmarshal(b []byte) error { 176 return m.Unmarshal(b) 177 } 178 func (m *Result) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 179 if deterministic { 180 return xxx_messageInfo_Result.Marshal(b, m, deterministic) 181 } else { 182 b = b[:cap(b)] 183 n, err := m.MarshalToSizedBuffer(b) 184 if err != nil { 185 return nil, err 186 } 187 return b[:n], nil 188 } 189 } 190 func (m *Result) XXX_Merge(src proto.Message) { 191 xxx_messageInfo_Result.Merge(m, src) 192 } 193 func (m *Result) XXX_Size() int { 194 return m.Size() 195 } 196 func (m *Result) XXX_DiscardUnknown() { 197 xxx_messageInfo_Result.DiscardUnknown(m) 198 } 199 200 var xxx_messageInfo_Result proto.InternalMessageInfo 201 202 func (m *Result) GetSuccess() bool { 203 if m != nil { 204 return m.Success 205 } 206 return false 207 } 208 209 func (m *Result) GetReason() string { 210 if m != nil { 211 return m.Reason 212 } 213 return "" 214 } 215 216 type RequestMessage struct { 217 Header *Header `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"` 218 Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` 219 } 220 221 func (m *RequestMessage) Reset() { *m = RequestMessage{} } 222 func (m *RequestMessage) String() string { return proto.CompactTextString(m) } 223 func (*RequestMessage) ProtoMessage() {} 224 func (*RequestMessage) Descriptor() ([]byte, []int) { 225 return fileDescriptor_4e28d31dd9c6e420, []int{2} 226 } 227 func (m *RequestMessage) XXX_Unmarshal(b []byte) error { 228 return m.Unmarshal(b) 229 } 230 func (m *RequestMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 231 if deterministic { 232 return xxx_messageInfo_RequestMessage.Marshal(b, m, deterministic) 233 } else { 234 b = b[:cap(b)] 235 n, err := m.MarshalToSizedBuffer(b) 236 if err != nil { 237 return nil, err 238 } 239 return b[:n], nil 240 } 241 } 242 func (m *RequestMessage) XXX_Merge(src proto.Message) { 243 xxx_messageInfo_RequestMessage.Merge(m, src) 244 } 245 func (m *RequestMessage) XXX_Size() int { 246 return m.Size() 247 } 248 func (m *RequestMessage) XXX_DiscardUnknown() { 249 xxx_messageInfo_RequestMessage.DiscardUnknown(m) 250 } 251 252 var xxx_messageInfo_RequestMessage proto.InternalMessageInfo 253 254 func (m *RequestMessage) GetHeader() *Header { 255 if m != nil { 256 return m.Header 257 } 258 return nil 259 } 260 261 func (m *RequestMessage) GetPayload() []byte { 262 if m != nil { 263 return m.Payload 264 } 265 return nil 266 } 267 268 type ResultMessage struct { 269 Header *Header `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"` 270 Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` 271 Result *Result `protobuf:"bytes,3,opt,name=result,proto3" json:"result,omitempty"` 272 } 273 274 func (m *ResultMessage) Reset() { *m = ResultMessage{} } 275 func (m *ResultMessage) String() string { return proto.CompactTextString(m) } 276 func (*ResultMessage) ProtoMessage() {} 277 func (*ResultMessage) Descriptor() ([]byte, []int) { 278 return fileDescriptor_4e28d31dd9c6e420, []int{3} 279 } 280 func (m *ResultMessage) XXX_Unmarshal(b []byte) error { 281 return m.Unmarshal(b) 282 } 283 func (m *ResultMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 284 if deterministic { 285 return xxx_messageInfo_ResultMessage.Marshal(b, m, deterministic) 286 } else { 287 b = b[:cap(b)] 288 n, err := m.MarshalToSizedBuffer(b) 289 if err != nil { 290 return nil, err 291 } 292 return b[:n], nil 293 } 294 } 295 func (m *ResultMessage) XXX_Merge(src proto.Message) { 296 xxx_messageInfo_ResultMessage.Merge(m, src) 297 } 298 func (m *ResultMessage) XXX_Size() int { 299 return m.Size() 300 } 301 func (m *ResultMessage) XXX_DiscardUnknown() { 302 xxx_messageInfo_ResultMessage.DiscardUnknown(m) 303 } 304 305 var xxx_messageInfo_ResultMessage proto.InternalMessageInfo 306 307 func (m *ResultMessage) GetHeader() *Header { 308 if m != nil { 309 return m.Header 310 } 311 return nil 312 } 313 314 func (m *ResultMessage) GetPayload() []byte { 315 if m != nil { 316 return m.Payload 317 } 318 return nil 319 } 320 321 func (m *ResultMessage) GetResult() *Result { 322 if m != nil { 323 return m.Result 324 } 325 return nil 326 } 327 328 type StatusMessage struct { 329 Header *Header `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"` 330 Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` 331 } 332 333 func (m *StatusMessage) Reset() { *m = StatusMessage{} } 334 func (m *StatusMessage) String() string { return proto.CompactTextString(m) } 335 func (*StatusMessage) ProtoMessage() {} 336 func (*StatusMessage) Descriptor() ([]byte, []int) { 337 return fileDescriptor_4e28d31dd9c6e420, []int{4} 338 } 339 func (m *StatusMessage) XXX_Unmarshal(b []byte) error { 340 return m.Unmarshal(b) 341 } 342 func (m *StatusMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 343 if deterministic { 344 return xxx_messageInfo_StatusMessage.Marshal(b, m, deterministic) 345 } else { 346 b = b[:cap(b)] 347 n, err := m.MarshalToSizedBuffer(b) 348 if err != nil { 349 return nil, err 350 } 351 return b[:n], nil 352 } 353 } 354 func (m *StatusMessage) XXX_Merge(src proto.Message) { 355 xxx_messageInfo_StatusMessage.Merge(m, src) 356 } 357 func (m *StatusMessage) XXX_Size() int { 358 return m.Size() 359 } 360 func (m *StatusMessage) XXX_DiscardUnknown() { 361 xxx_messageInfo_StatusMessage.DiscardUnknown(m) 362 } 363 364 var xxx_messageInfo_StatusMessage proto.InternalMessageInfo 365 366 func (m *StatusMessage) GetHeader() *Header { 367 if m != nil { 368 return m.Header 369 } 370 return nil 371 } 372 373 func (m *StatusMessage) GetPayload() []byte { 374 if m != nil { 375 return m.Payload 376 } 377 return nil 378 } 379 380 type AckMessage struct { 381 Header *Header `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"` 382 Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` 383 Result *Result `protobuf:"bytes,3,opt,name=result,proto3" json:"result,omitempty"` 384 } 385 386 func (m *AckMessage) Reset() { *m = AckMessage{} } 387 func (m *AckMessage) String() string { return proto.CompactTextString(m) } 388 func (*AckMessage) ProtoMessage() {} 389 func (*AckMessage) Descriptor() ([]byte, []int) { 390 return fileDescriptor_4e28d31dd9c6e420, []int{5} 391 } 392 func (m *AckMessage) XXX_Unmarshal(b []byte) error { 393 return m.Unmarshal(b) 394 } 395 func (m *AckMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 396 if deterministic { 397 return xxx_messageInfo_AckMessage.Marshal(b, m, deterministic) 398 } else { 399 b = b[:cap(b)] 400 n, err := m.MarshalToSizedBuffer(b) 401 if err != nil { 402 return nil, err 403 } 404 return b[:n], nil 405 } 406 } 407 func (m *AckMessage) XXX_Merge(src proto.Message) { 408 xxx_messageInfo_AckMessage.Merge(m, src) 409 } 410 func (m *AckMessage) XXX_Size() int { 411 return m.Size() 412 } 413 func (m *AckMessage) XXX_DiscardUnknown() { 414 xxx_messageInfo_AckMessage.DiscardUnknown(m) 415 } 416 417 var xxx_messageInfo_AckMessage proto.InternalMessageInfo 418 419 func (m *AckMessage) GetHeader() *Header { 420 if m != nil { 421 return m.Header 422 } 423 return nil 424 } 425 426 func (m *AckMessage) GetPayload() []byte { 427 if m != nil { 428 return m.Payload 429 } 430 return nil 431 } 432 433 func (m *AckMessage) GetResult() *Result { 434 if m != nil { 435 return m.Result 436 } 437 return nil 438 } 439 440 func init() { 441 proto.RegisterEnum("onos.a1t.a1.Encoding", Encoding_name, Encoding_value) 442 golang_proto.RegisterEnum("onos.a1t.a1.Encoding", Encoding_name, Encoding_value) 443 proto.RegisterEnum("onos.a1t.a1.PayloadType", PayloadType_name, PayloadType_value) 444 golang_proto.RegisterEnum("onos.a1t.a1.PayloadType", PayloadType_name, PayloadType_value) 445 proto.RegisterType((*Header)(nil), "onos.a1t.a1.Header") 446 golang_proto.RegisterType((*Header)(nil), "onos.a1t.a1.Header") 447 proto.RegisterType((*Result)(nil), "onos.a1t.a1.Result") 448 golang_proto.RegisterType((*Result)(nil), "onos.a1t.a1.Result") 449 proto.RegisterType((*RequestMessage)(nil), "onos.a1t.a1.RequestMessage") 450 golang_proto.RegisterType((*RequestMessage)(nil), "onos.a1t.a1.RequestMessage") 451 proto.RegisterType((*ResultMessage)(nil), "onos.a1t.a1.ResultMessage") 452 golang_proto.RegisterType((*ResultMessage)(nil), "onos.a1t.a1.ResultMessage") 453 proto.RegisterType((*StatusMessage)(nil), "onos.a1t.a1.StatusMessage") 454 golang_proto.RegisterType((*StatusMessage)(nil), "onos.a1t.a1.StatusMessage") 455 proto.RegisterType((*AckMessage)(nil), "onos.a1t.a1.AckMessage") 456 golang_proto.RegisterType((*AckMessage)(nil), "onos.a1t.a1.AckMessage") 457 } 458 459 func init() { proto.RegisterFile("onos/a1t/a1/a1.proto", fileDescriptor_4e28d31dd9c6e420) } 460 func init() { golang_proto.RegisterFile("onos/a1t/a1/a1.proto", fileDescriptor_4e28d31dd9c6e420) } 461 462 var fileDescriptor_4e28d31dd9c6e420 = []byte{ 463 // 444 bytes of a gzipped FileDescriptorProto 464 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x53, 0xc1, 0x6e, 0x13, 0x31, 465 0x10, 0x5d, 0x43, 0xb3, 0x6c, 0x26, 0x4d, 0x89, 0x4c, 0x8b, 0x56, 0xa8, 0x2c, 0xd5, 0x4a, 0xa0, 466 0xaa, 0x48, 0x1b, 0xb9, 0xdc, 0xe0, 0x54, 0x10, 0x12, 0x41, 0xd0, 0x44, 0x4e, 0x00, 0x71, 0x8a, 467 0x86, 0xb5, 0x15, 0x2a, 0xaa, 0xb5, 0x59, 0x3b, 0x87, 0xdc, 0x90, 0xf8, 0x01, 0x3e, 0x89, 0x23, 468 0xc7, 0x1e, 0x39, 0xa2, 0xe4, 0x17, 0xf8, 0x00, 0x64, 0xaf, 0x03, 0x2d, 0xe7, 0x4a, 0xbd, 0x79, 469 0xde, 0x7b, 0x7e, 0x9e, 0x37, 0x3b, 0x0b, 0xdb, 0xaa, 0x52, 0xa6, 0x8f, 0xcc, 0xf6, 0x91, 0xf5, 470 0x91, 0x15, 0xba, 0x56, 0x56, 0xd1, 0x8e, 0x43, 0x0b, 0x64, 0xb6, 0x40, 0x76, 0x67, 0x7b, 0xa6, 471 0x66, 0xca, 0xe3, 0x7d, 0x77, 0x6a, 0x24, 0xf9, 0x6f, 0x02, 0xf1, 0x0b, 0x89, 0x42, 0xd6, 0xf4, 472 0x2e, 0x40, 0x2d, 0x3f, 0xcf, 0xa5, 0xb1, 0xd3, 0x13, 0x91, 0x92, 0x3d, 0xb2, 0xdf, 0xe6, 0xed, 473 0x80, 0x0c, 0x04, 0xdd, 0x81, 0x18, 0xb5, 0x76, 0xd4, 0x35, 0x4f, 0xb5, 0x50, 0xeb, 0x81, 0xa0, 474 0x0f, 0xe0, 0xa6, 0x87, 0x2b, 0x63, 0xb1, 0x2a, 0xa5, 0xe3, 0xaf, 0x7b, 0xbe, 0xeb, 0xf8, 0x80, 475 0x0e, 0x04, 0xdd, 0x05, 0x40, 0x36, 0xad, 0x94, 0xf0, 0x92, 0x0d, 0x2f, 0x49, 0x90, 0x1d, 0x2b, 476 0xe1, 0x58, 0x06, 0x89, 0xac, 0x4a, 0x25, 0x4e, 0xaa, 0x59, 0xda, 0xda, 0x23, 0xfb, 0x5b, 0x87, 477 0x3b, 0xc5, 0xb9, 0xe6, 0x8b, 0xe7, 0x81, 0xe4, 0x7f, 0x65, 0xf4, 0x09, 0x6c, 0x6a, 0x5c, 0x9c, 478 0x2a, 0x14, 0x53, 0xbb, 0xd0, 0x32, 0x8d, 0xfd, 0xb5, 0xf4, 0xc2, 0xb5, 0x51, 0x23, 0x98, 0x2c, 479 0xb4, 0xe4, 0x1d, 0xfd, 0xaf, 0xc8, 0x1f, 0x43, 0xcc, 0xa5, 0x99, 0x9f, 0x5a, 0x9a, 0xc2, 0x0d, 480 0x33, 0x2f, 0x4b, 0x69, 0x8c, 0x8f, 0x9c, 0xf0, 0x75, 0x49, 0x6f, 0x43, 0x5c, 0x4b, 0x34, 0xaa, 481 0x0a, 0x81, 0x43, 0x95, 0xbf, 0x83, 0x2d, 0xde, 0x4c, 0xe5, 0xb5, 0x34, 0x06, 0x67, 0x92, 0x3e, 482 0x84, 0xf8, 0xa3, 0x9f, 0xa1, 0xb7, 0xe8, 0x1c, 0xde, 0xba, 0xd0, 0x44, 0x33, 0x5e, 0x1e, 0x24, 483 0xee, 0xc1, 0xd0, 0x89, 0xf7, 0xdd, 0xe4, 0xeb, 0x32, 0xff, 0x4a, 0xa0, 0xdb, 0x74, 0x75, 0xb9, 484 0xc6, 0xce, 0xa6, 0xf6, 0xbe, 0xfe, 0xd3, 0xfc, 0x6f, 0xd3, 0x3c, 0xc9, 0x83, 0x24, 0x7f, 0x0b, 485 0xdd, 0xb1, 0x45, 0x3b, 0x37, 0x97, 0x9c, 0xee, 0x0b, 0x01, 0x38, 0x2a, 0x3f, 0x5d, 0x61, 0xb4, 486 0x83, 0x7b, 0x90, 0xac, 0x17, 0x89, 0xb6, 0xa1, 0x35, 0xe2, 0xc3, 0xc9, 0xb0, 0x17, 0xd1, 0x04, 487 0x36, 0x5e, 0x8e, 0x87, 0xc7, 0x3d, 0x72, 0x70, 0x1f, 0x3a, 0xe7, 0x56, 0x86, 0x02, 0xc4, 0xa3, 488 0xe1, 0xab, 0xc1, 0xb3, 0xf7, 0xbd, 0xc8, 0x9d, 0xc7, 0x93, 0xa3, 0xc9, 0x9b, 0x71, 0x8f, 0x3c, 489 0xdd, 0xfd, 0xb1, 0xcc, 0xc8, 0xd9, 0x32, 0x23, 0xbf, 0x96, 0x19, 0xf9, 0xb6, 0xca, 0xa2, 0xef, 490 0xab, 0x8c, 0x9c, 0xad, 0xb2, 0xe8, 0xe7, 0x2a, 0x8b, 0x3e, 0xc4, 0xfe, 0xcf, 0x7a, 0xf4, 0x27, 491 0x00, 0x00, 0xff, 0xff, 0x76, 0xf2, 0x38, 0x1c, 0x94, 0x03, 0x00, 0x00, 492 } 493 494 func (m *Header) Marshal() (dAtA []byte, err error) { 495 size := m.Size() 496 dAtA = make([]byte, size) 497 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 498 if err != nil { 499 return nil, err 500 } 501 return dAtA[:n], nil 502 } 503 504 func (m *Header) MarshalTo(dAtA []byte) (int, error) { 505 size := m.Size() 506 return m.MarshalToSizedBuffer(dAtA[:size]) 507 } 508 509 func (m *Header) MarshalToSizedBuffer(dAtA []byte) (int, error) { 510 i := len(dAtA) 511 _ = i 512 var l int 513 _ = l 514 if m.PayloadType != 0 { 515 i = encodeVarintA1(dAtA, i, uint64(m.PayloadType)) 516 i-- 517 dAtA[i] = 0x30 518 } 519 if m.Encoding != 0 { 520 i = encodeVarintA1(dAtA, i, uint64(m.Encoding)) 521 i-- 522 dAtA[i] = 0x28 523 } 524 if len(m.A1NodeId) > 0 { 525 i -= len(m.A1NodeId) 526 copy(dAtA[i:], m.A1NodeId) 527 i = encodeVarintA1(dAtA, i, uint64(len(m.A1NodeId))) 528 i-- 529 dAtA[i] = 0x22 530 } 531 if len(m.AppInstanceId) > 0 { 532 i -= len(m.AppInstanceId) 533 copy(dAtA[i:], m.AppInstanceId) 534 i = encodeVarintA1(dAtA, i, uint64(len(m.AppInstanceId))) 535 i-- 536 dAtA[i] = 0x1a 537 } 538 if len(m.AppId) > 0 { 539 i -= len(m.AppId) 540 copy(dAtA[i:], m.AppId) 541 i = encodeVarintA1(dAtA, i, uint64(len(m.AppId))) 542 i-- 543 dAtA[i] = 0x12 544 } 545 if len(m.RequestId) > 0 { 546 i -= len(m.RequestId) 547 copy(dAtA[i:], m.RequestId) 548 i = encodeVarintA1(dAtA, i, uint64(len(m.RequestId))) 549 i-- 550 dAtA[i] = 0xa 551 } 552 return len(dAtA) - i, nil 553 } 554 555 func (m *Result) Marshal() (dAtA []byte, err error) { 556 size := m.Size() 557 dAtA = make([]byte, size) 558 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 559 if err != nil { 560 return nil, err 561 } 562 return dAtA[:n], nil 563 } 564 565 func (m *Result) MarshalTo(dAtA []byte) (int, error) { 566 size := m.Size() 567 return m.MarshalToSizedBuffer(dAtA[:size]) 568 } 569 570 func (m *Result) MarshalToSizedBuffer(dAtA []byte) (int, error) { 571 i := len(dAtA) 572 _ = i 573 var l int 574 _ = l 575 if len(m.Reason) > 0 { 576 i -= len(m.Reason) 577 copy(dAtA[i:], m.Reason) 578 i = encodeVarintA1(dAtA, i, uint64(len(m.Reason))) 579 i-- 580 dAtA[i] = 0x12 581 } 582 if m.Success { 583 i-- 584 if m.Success { 585 dAtA[i] = 1 586 } else { 587 dAtA[i] = 0 588 } 589 i-- 590 dAtA[i] = 0x8 591 } 592 return len(dAtA) - i, nil 593 } 594 595 func (m *RequestMessage) Marshal() (dAtA []byte, err error) { 596 size := m.Size() 597 dAtA = make([]byte, size) 598 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 599 if err != nil { 600 return nil, err 601 } 602 return dAtA[:n], nil 603 } 604 605 func (m *RequestMessage) MarshalTo(dAtA []byte) (int, error) { 606 size := m.Size() 607 return m.MarshalToSizedBuffer(dAtA[:size]) 608 } 609 610 func (m *RequestMessage) MarshalToSizedBuffer(dAtA []byte) (int, error) { 611 i := len(dAtA) 612 _ = i 613 var l int 614 _ = l 615 if len(m.Payload) > 0 { 616 i -= len(m.Payload) 617 copy(dAtA[i:], m.Payload) 618 i = encodeVarintA1(dAtA, i, uint64(len(m.Payload))) 619 i-- 620 dAtA[i] = 0x12 621 } 622 if m.Header != nil { 623 { 624 size, err := m.Header.MarshalToSizedBuffer(dAtA[:i]) 625 if err != nil { 626 return 0, err 627 } 628 i -= size 629 i = encodeVarintA1(dAtA, i, uint64(size)) 630 } 631 i-- 632 dAtA[i] = 0xa 633 } 634 return len(dAtA) - i, nil 635 } 636 637 func (m *ResultMessage) Marshal() (dAtA []byte, err error) { 638 size := m.Size() 639 dAtA = make([]byte, size) 640 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 641 if err != nil { 642 return nil, err 643 } 644 return dAtA[:n], nil 645 } 646 647 func (m *ResultMessage) MarshalTo(dAtA []byte) (int, error) { 648 size := m.Size() 649 return m.MarshalToSizedBuffer(dAtA[:size]) 650 } 651 652 func (m *ResultMessage) MarshalToSizedBuffer(dAtA []byte) (int, error) { 653 i := len(dAtA) 654 _ = i 655 var l int 656 _ = l 657 if m.Result != nil { 658 { 659 size, err := m.Result.MarshalToSizedBuffer(dAtA[:i]) 660 if err != nil { 661 return 0, err 662 } 663 i -= size 664 i = encodeVarintA1(dAtA, i, uint64(size)) 665 } 666 i-- 667 dAtA[i] = 0x1a 668 } 669 if len(m.Payload) > 0 { 670 i -= len(m.Payload) 671 copy(dAtA[i:], m.Payload) 672 i = encodeVarintA1(dAtA, i, uint64(len(m.Payload))) 673 i-- 674 dAtA[i] = 0x12 675 } 676 if m.Header != nil { 677 { 678 size, err := m.Header.MarshalToSizedBuffer(dAtA[:i]) 679 if err != nil { 680 return 0, err 681 } 682 i -= size 683 i = encodeVarintA1(dAtA, i, uint64(size)) 684 } 685 i-- 686 dAtA[i] = 0xa 687 } 688 return len(dAtA) - i, nil 689 } 690 691 func (m *StatusMessage) Marshal() (dAtA []byte, err error) { 692 size := m.Size() 693 dAtA = make([]byte, size) 694 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 695 if err != nil { 696 return nil, err 697 } 698 return dAtA[:n], nil 699 } 700 701 func (m *StatusMessage) MarshalTo(dAtA []byte) (int, error) { 702 size := m.Size() 703 return m.MarshalToSizedBuffer(dAtA[:size]) 704 } 705 706 func (m *StatusMessage) MarshalToSizedBuffer(dAtA []byte) (int, error) { 707 i := len(dAtA) 708 _ = i 709 var l int 710 _ = l 711 if len(m.Payload) > 0 { 712 i -= len(m.Payload) 713 copy(dAtA[i:], m.Payload) 714 i = encodeVarintA1(dAtA, i, uint64(len(m.Payload))) 715 i-- 716 dAtA[i] = 0x12 717 } 718 if m.Header != nil { 719 { 720 size, err := m.Header.MarshalToSizedBuffer(dAtA[:i]) 721 if err != nil { 722 return 0, err 723 } 724 i -= size 725 i = encodeVarintA1(dAtA, i, uint64(size)) 726 } 727 i-- 728 dAtA[i] = 0xa 729 } 730 return len(dAtA) - i, nil 731 } 732 733 func (m *AckMessage) Marshal() (dAtA []byte, err error) { 734 size := m.Size() 735 dAtA = make([]byte, size) 736 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 737 if err != nil { 738 return nil, err 739 } 740 return dAtA[:n], nil 741 } 742 743 func (m *AckMessage) MarshalTo(dAtA []byte) (int, error) { 744 size := m.Size() 745 return m.MarshalToSizedBuffer(dAtA[:size]) 746 } 747 748 func (m *AckMessage) MarshalToSizedBuffer(dAtA []byte) (int, error) { 749 i := len(dAtA) 750 _ = i 751 var l int 752 _ = l 753 if m.Result != nil { 754 { 755 size, err := m.Result.MarshalToSizedBuffer(dAtA[:i]) 756 if err != nil { 757 return 0, err 758 } 759 i -= size 760 i = encodeVarintA1(dAtA, i, uint64(size)) 761 } 762 i-- 763 dAtA[i] = 0x1a 764 } 765 if len(m.Payload) > 0 { 766 i -= len(m.Payload) 767 copy(dAtA[i:], m.Payload) 768 i = encodeVarintA1(dAtA, i, uint64(len(m.Payload))) 769 i-- 770 dAtA[i] = 0x12 771 } 772 if m.Header != nil { 773 { 774 size, err := m.Header.MarshalToSizedBuffer(dAtA[:i]) 775 if err != nil { 776 return 0, err 777 } 778 i -= size 779 i = encodeVarintA1(dAtA, i, uint64(size)) 780 } 781 i-- 782 dAtA[i] = 0xa 783 } 784 return len(dAtA) - i, nil 785 } 786 787 func encodeVarintA1(dAtA []byte, offset int, v uint64) int { 788 offset -= sovA1(v) 789 base := offset 790 for v >= 1<<7 { 791 dAtA[offset] = uint8(v&0x7f | 0x80) 792 v >>= 7 793 offset++ 794 } 795 dAtA[offset] = uint8(v) 796 return base 797 } 798 func (m *Header) Size() (n int) { 799 if m == nil { 800 return 0 801 } 802 var l int 803 _ = l 804 l = len(m.RequestId) 805 if l > 0 { 806 n += 1 + l + sovA1(uint64(l)) 807 } 808 l = len(m.AppId) 809 if l > 0 { 810 n += 1 + l + sovA1(uint64(l)) 811 } 812 l = len(m.AppInstanceId) 813 if l > 0 { 814 n += 1 + l + sovA1(uint64(l)) 815 } 816 l = len(m.A1NodeId) 817 if l > 0 { 818 n += 1 + l + sovA1(uint64(l)) 819 } 820 if m.Encoding != 0 { 821 n += 1 + sovA1(uint64(m.Encoding)) 822 } 823 if m.PayloadType != 0 { 824 n += 1 + sovA1(uint64(m.PayloadType)) 825 } 826 return n 827 } 828 829 func (m *Result) Size() (n int) { 830 if m == nil { 831 return 0 832 } 833 var l int 834 _ = l 835 if m.Success { 836 n += 2 837 } 838 l = len(m.Reason) 839 if l > 0 { 840 n += 1 + l + sovA1(uint64(l)) 841 } 842 return n 843 } 844 845 func (m *RequestMessage) Size() (n int) { 846 if m == nil { 847 return 0 848 } 849 var l int 850 _ = l 851 if m.Header != nil { 852 l = m.Header.Size() 853 n += 1 + l + sovA1(uint64(l)) 854 } 855 l = len(m.Payload) 856 if l > 0 { 857 n += 1 + l + sovA1(uint64(l)) 858 } 859 return n 860 } 861 862 func (m *ResultMessage) Size() (n int) { 863 if m == nil { 864 return 0 865 } 866 var l int 867 _ = l 868 if m.Header != nil { 869 l = m.Header.Size() 870 n += 1 + l + sovA1(uint64(l)) 871 } 872 l = len(m.Payload) 873 if l > 0 { 874 n += 1 + l + sovA1(uint64(l)) 875 } 876 if m.Result != nil { 877 l = m.Result.Size() 878 n += 1 + l + sovA1(uint64(l)) 879 } 880 return n 881 } 882 883 func (m *StatusMessage) Size() (n int) { 884 if m == nil { 885 return 0 886 } 887 var l int 888 _ = l 889 if m.Header != nil { 890 l = m.Header.Size() 891 n += 1 + l + sovA1(uint64(l)) 892 } 893 l = len(m.Payload) 894 if l > 0 { 895 n += 1 + l + sovA1(uint64(l)) 896 } 897 return n 898 } 899 900 func (m *AckMessage) Size() (n int) { 901 if m == nil { 902 return 0 903 } 904 var l int 905 _ = l 906 if m.Header != nil { 907 l = m.Header.Size() 908 n += 1 + l + sovA1(uint64(l)) 909 } 910 l = len(m.Payload) 911 if l > 0 { 912 n += 1 + l + sovA1(uint64(l)) 913 } 914 if m.Result != nil { 915 l = m.Result.Size() 916 n += 1 + l + sovA1(uint64(l)) 917 } 918 return n 919 } 920 921 func sovA1(x uint64) (n int) { 922 return (math_bits.Len64(x|1) + 6) / 7 923 } 924 func sozA1(x uint64) (n int) { 925 return sovA1(uint64((x << 1) ^ uint64((int64(x) >> 63)))) 926 } 927 func (m *Header) Unmarshal(dAtA []byte) error { 928 l := len(dAtA) 929 iNdEx := 0 930 for iNdEx < l { 931 preIndex := iNdEx 932 var wire uint64 933 for shift := uint(0); ; shift += 7 { 934 if shift >= 64 { 935 return ErrIntOverflowA1 936 } 937 if iNdEx >= l { 938 return io.ErrUnexpectedEOF 939 } 940 b := dAtA[iNdEx] 941 iNdEx++ 942 wire |= uint64(b&0x7F) << shift 943 if b < 0x80 { 944 break 945 } 946 } 947 fieldNum := int32(wire >> 3) 948 wireType := int(wire & 0x7) 949 if wireType == 4 { 950 return fmt.Errorf("proto: Header: wiretype end group for non-group") 951 } 952 if fieldNum <= 0 { 953 return fmt.Errorf("proto: Header: illegal tag %d (wire type %d)", fieldNum, wire) 954 } 955 switch fieldNum { 956 case 1: 957 if wireType != 2 { 958 return fmt.Errorf("proto: wrong wireType = %d for field RequestId", wireType) 959 } 960 var stringLen uint64 961 for shift := uint(0); ; shift += 7 { 962 if shift >= 64 { 963 return ErrIntOverflowA1 964 } 965 if iNdEx >= l { 966 return io.ErrUnexpectedEOF 967 } 968 b := dAtA[iNdEx] 969 iNdEx++ 970 stringLen |= uint64(b&0x7F) << shift 971 if b < 0x80 { 972 break 973 } 974 } 975 intStringLen := int(stringLen) 976 if intStringLen < 0 { 977 return ErrInvalidLengthA1 978 } 979 postIndex := iNdEx + intStringLen 980 if postIndex < 0 { 981 return ErrInvalidLengthA1 982 } 983 if postIndex > l { 984 return io.ErrUnexpectedEOF 985 } 986 m.RequestId = string(dAtA[iNdEx:postIndex]) 987 iNdEx = postIndex 988 case 2: 989 if wireType != 2 { 990 return fmt.Errorf("proto: wrong wireType = %d for field AppId", wireType) 991 } 992 var stringLen uint64 993 for shift := uint(0); ; shift += 7 { 994 if shift >= 64 { 995 return ErrIntOverflowA1 996 } 997 if iNdEx >= l { 998 return io.ErrUnexpectedEOF 999 } 1000 b := dAtA[iNdEx] 1001 iNdEx++ 1002 stringLen |= uint64(b&0x7F) << shift 1003 if b < 0x80 { 1004 break 1005 } 1006 } 1007 intStringLen := int(stringLen) 1008 if intStringLen < 0 { 1009 return ErrInvalidLengthA1 1010 } 1011 postIndex := iNdEx + intStringLen 1012 if postIndex < 0 { 1013 return ErrInvalidLengthA1 1014 } 1015 if postIndex > l { 1016 return io.ErrUnexpectedEOF 1017 } 1018 m.AppId = string(dAtA[iNdEx:postIndex]) 1019 iNdEx = postIndex 1020 case 3: 1021 if wireType != 2 { 1022 return fmt.Errorf("proto: wrong wireType = %d for field AppInstanceId", wireType) 1023 } 1024 var stringLen uint64 1025 for shift := uint(0); ; shift += 7 { 1026 if shift >= 64 { 1027 return ErrIntOverflowA1 1028 } 1029 if iNdEx >= l { 1030 return io.ErrUnexpectedEOF 1031 } 1032 b := dAtA[iNdEx] 1033 iNdEx++ 1034 stringLen |= uint64(b&0x7F) << shift 1035 if b < 0x80 { 1036 break 1037 } 1038 } 1039 intStringLen := int(stringLen) 1040 if intStringLen < 0 { 1041 return ErrInvalidLengthA1 1042 } 1043 postIndex := iNdEx + intStringLen 1044 if postIndex < 0 { 1045 return ErrInvalidLengthA1 1046 } 1047 if postIndex > l { 1048 return io.ErrUnexpectedEOF 1049 } 1050 m.AppInstanceId = string(dAtA[iNdEx:postIndex]) 1051 iNdEx = postIndex 1052 case 4: 1053 if wireType != 2 { 1054 return fmt.Errorf("proto: wrong wireType = %d for field A1NodeId", wireType) 1055 } 1056 var stringLen uint64 1057 for shift := uint(0); ; shift += 7 { 1058 if shift >= 64 { 1059 return ErrIntOverflowA1 1060 } 1061 if iNdEx >= l { 1062 return io.ErrUnexpectedEOF 1063 } 1064 b := dAtA[iNdEx] 1065 iNdEx++ 1066 stringLen |= uint64(b&0x7F) << shift 1067 if b < 0x80 { 1068 break 1069 } 1070 } 1071 intStringLen := int(stringLen) 1072 if intStringLen < 0 { 1073 return ErrInvalidLengthA1 1074 } 1075 postIndex := iNdEx + intStringLen 1076 if postIndex < 0 { 1077 return ErrInvalidLengthA1 1078 } 1079 if postIndex > l { 1080 return io.ErrUnexpectedEOF 1081 } 1082 m.A1NodeId = string(dAtA[iNdEx:postIndex]) 1083 iNdEx = postIndex 1084 case 5: 1085 if wireType != 0 { 1086 return fmt.Errorf("proto: wrong wireType = %d for field Encoding", wireType) 1087 } 1088 m.Encoding = 0 1089 for shift := uint(0); ; shift += 7 { 1090 if shift >= 64 { 1091 return ErrIntOverflowA1 1092 } 1093 if iNdEx >= l { 1094 return io.ErrUnexpectedEOF 1095 } 1096 b := dAtA[iNdEx] 1097 iNdEx++ 1098 m.Encoding |= Encoding(b&0x7F) << shift 1099 if b < 0x80 { 1100 break 1101 } 1102 } 1103 case 6: 1104 if wireType != 0 { 1105 return fmt.Errorf("proto: wrong wireType = %d for field PayloadType", wireType) 1106 } 1107 m.PayloadType = 0 1108 for shift := uint(0); ; shift += 7 { 1109 if shift >= 64 { 1110 return ErrIntOverflowA1 1111 } 1112 if iNdEx >= l { 1113 return io.ErrUnexpectedEOF 1114 } 1115 b := dAtA[iNdEx] 1116 iNdEx++ 1117 m.PayloadType |= PayloadType(b&0x7F) << shift 1118 if b < 0x80 { 1119 break 1120 } 1121 } 1122 default: 1123 iNdEx = preIndex 1124 skippy, err := skipA1(dAtA[iNdEx:]) 1125 if err != nil { 1126 return err 1127 } 1128 if (skippy < 0) || (iNdEx+skippy) < 0 { 1129 return ErrInvalidLengthA1 1130 } 1131 if (iNdEx + skippy) > l { 1132 return io.ErrUnexpectedEOF 1133 } 1134 iNdEx += skippy 1135 } 1136 } 1137 1138 if iNdEx > l { 1139 return io.ErrUnexpectedEOF 1140 } 1141 return nil 1142 } 1143 func (m *Result) Unmarshal(dAtA []byte) error { 1144 l := len(dAtA) 1145 iNdEx := 0 1146 for iNdEx < l { 1147 preIndex := iNdEx 1148 var wire uint64 1149 for shift := uint(0); ; shift += 7 { 1150 if shift >= 64 { 1151 return ErrIntOverflowA1 1152 } 1153 if iNdEx >= l { 1154 return io.ErrUnexpectedEOF 1155 } 1156 b := dAtA[iNdEx] 1157 iNdEx++ 1158 wire |= uint64(b&0x7F) << shift 1159 if b < 0x80 { 1160 break 1161 } 1162 } 1163 fieldNum := int32(wire >> 3) 1164 wireType := int(wire & 0x7) 1165 if wireType == 4 { 1166 return fmt.Errorf("proto: Result: wiretype end group for non-group") 1167 } 1168 if fieldNum <= 0 { 1169 return fmt.Errorf("proto: Result: illegal tag %d (wire type %d)", fieldNum, wire) 1170 } 1171 switch fieldNum { 1172 case 1: 1173 if wireType != 0 { 1174 return fmt.Errorf("proto: wrong wireType = %d for field Success", wireType) 1175 } 1176 var v int 1177 for shift := uint(0); ; shift += 7 { 1178 if shift >= 64 { 1179 return ErrIntOverflowA1 1180 } 1181 if iNdEx >= l { 1182 return io.ErrUnexpectedEOF 1183 } 1184 b := dAtA[iNdEx] 1185 iNdEx++ 1186 v |= int(b&0x7F) << shift 1187 if b < 0x80 { 1188 break 1189 } 1190 } 1191 m.Success = bool(v != 0) 1192 case 2: 1193 if wireType != 2 { 1194 return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) 1195 } 1196 var stringLen uint64 1197 for shift := uint(0); ; shift += 7 { 1198 if shift >= 64 { 1199 return ErrIntOverflowA1 1200 } 1201 if iNdEx >= l { 1202 return io.ErrUnexpectedEOF 1203 } 1204 b := dAtA[iNdEx] 1205 iNdEx++ 1206 stringLen |= uint64(b&0x7F) << shift 1207 if b < 0x80 { 1208 break 1209 } 1210 } 1211 intStringLen := int(stringLen) 1212 if intStringLen < 0 { 1213 return ErrInvalidLengthA1 1214 } 1215 postIndex := iNdEx + intStringLen 1216 if postIndex < 0 { 1217 return ErrInvalidLengthA1 1218 } 1219 if postIndex > l { 1220 return io.ErrUnexpectedEOF 1221 } 1222 m.Reason = string(dAtA[iNdEx:postIndex]) 1223 iNdEx = postIndex 1224 default: 1225 iNdEx = preIndex 1226 skippy, err := skipA1(dAtA[iNdEx:]) 1227 if err != nil { 1228 return err 1229 } 1230 if (skippy < 0) || (iNdEx+skippy) < 0 { 1231 return ErrInvalidLengthA1 1232 } 1233 if (iNdEx + skippy) > l { 1234 return io.ErrUnexpectedEOF 1235 } 1236 iNdEx += skippy 1237 } 1238 } 1239 1240 if iNdEx > l { 1241 return io.ErrUnexpectedEOF 1242 } 1243 return nil 1244 } 1245 func (m *RequestMessage) Unmarshal(dAtA []byte) error { 1246 l := len(dAtA) 1247 iNdEx := 0 1248 for iNdEx < l { 1249 preIndex := iNdEx 1250 var wire uint64 1251 for shift := uint(0); ; shift += 7 { 1252 if shift >= 64 { 1253 return ErrIntOverflowA1 1254 } 1255 if iNdEx >= l { 1256 return io.ErrUnexpectedEOF 1257 } 1258 b := dAtA[iNdEx] 1259 iNdEx++ 1260 wire |= uint64(b&0x7F) << shift 1261 if b < 0x80 { 1262 break 1263 } 1264 } 1265 fieldNum := int32(wire >> 3) 1266 wireType := int(wire & 0x7) 1267 if wireType == 4 { 1268 return fmt.Errorf("proto: RequestMessage: wiretype end group for non-group") 1269 } 1270 if fieldNum <= 0 { 1271 return fmt.Errorf("proto: RequestMessage: illegal tag %d (wire type %d)", fieldNum, wire) 1272 } 1273 switch fieldNum { 1274 case 1: 1275 if wireType != 2 { 1276 return fmt.Errorf("proto: wrong wireType = %d for field Header", wireType) 1277 } 1278 var msglen int 1279 for shift := uint(0); ; shift += 7 { 1280 if shift >= 64 { 1281 return ErrIntOverflowA1 1282 } 1283 if iNdEx >= l { 1284 return io.ErrUnexpectedEOF 1285 } 1286 b := dAtA[iNdEx] 1287 iNdEx++ 1288 msglen |= int(b&0x7F) << shift 1289 if b < 0x80 { 1290 break 1291 } 1292 } 1293 if msglen < 0 { 1294 return ErrInvalidLengthA1 1295 } 1296 postIndex := iNdEx + msglen 1297 if postIndex < 0 { 1298 return ErrInvalidLengthA1 1299 } 1300 if postIndex > l { 1301 return io.ErrUnexpectedEOF 1302 } 1303 if m.Header == nil { 1304 m.Header = &Header{} 1305 } 1306 if err := m.Header.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 1307 return err 1308 } 1309 iNdEx = postIndex 1310 case 2: 1311 if wireType != 2 { 1312 return fmt.Errorf("proto: wrong wireType = %d for field Payload", wireType) 1313 } 1314 var byteLen int 1315 for shift := uint(0); ; shift += 7 { 1316 if shift >= 64 { 1317 return ErrIntOverflowA1 1318 } 1319 if iNdEx >= l { 1320 return io.ErrUnexpectedEOF 1321 } 1322 b := dAtA[iNdEx] 1323 iNdEx++ 1324 byteLen |= int(b&0x7F) << shift 1325 if b < 0x80 { 1326 break 1327 } 1328 } 1329 if byteLen < 0 { 1330 return ErrInvalidLengthA1 1331 } 1332 postIndex := iNdEx + byteLen 1333 if postIndex < 0 { 1334 return ErrInvalidLengthA1 1335 } 1336 if postIndex > l { 1337 return io.ErrUnexpectedEOF 1338 } 1339 m.Payload = append(m.Payload[:0], dAtA[iNdEx:postIndex]...) 1340 if m.Payload == nil { 1341 m.Payload = []byte{} 1342 } 1343 iNdEx = postIndex 1344 default: 1345 iNdEx = preIndex 1346 skippy, err := skipA1(dAtA[iNdEx:]) 1347 if err != nil { 1348 return err 1349 } 1350 if (skippy < 0) || (iNdEx+skippy) < 0 { 1351 return ErrInvalidLengthA1 1352 } 1353 if (iNdEx + skippy) > l { 1354 return io.ErrUnexpectedEOF 1355 } 1356 iNdEx += skippy 1357 } 1358 } 1359 1360 if iNdEx > l { 1361 return io.ErrUnexpectedEOF 1362 } 1363 return nil 1364 } 1365 func (m *ResultMessage) Unmarshal(dAtA []byte) error { 1366 l := len(dAtA) 1367 iNdEx := 0 1368 for iNdEx < l { 1369 preIndex := iNdEx 1370 var wire uint64 1371 for shift := uint(0); ; shift += 7 { 1372 if shift >= 64 { 1373 return ErrIntOverflowA1 1374 } 1375 if iNdEx >= l { 1376 return io.ErrUnexpectedEOF 1377 } 1378 b := dAtA[iNdEx] 1379 iNdEx++ 1380 wire |= uint64(b&0x7F) << shift 1381 if b < 0x80 { 1382 break 1383 } 1384 } 1385 fieldNum := int32(wire >> 3) 1386 wireType := int(wire & 0x7) 1387 if wireType == 4 { 1388 return fmt.Errorf("proto: ResultMessage: wiretype end group for non-group") 1389 } 1390 if fieldNum <= 0 { 1391 return fmt.Errorf("proto: ResultMessage: illegal tag %d (wire type %d)", fieldNum, wire) 1392 } 1393 switch fieldNum { 1394 case 1: 1395 if wireType != 2 { 1396 return fmt.Errorf("proto: wrong wireType = %d for field Header", wireType) 1397 } 1398 var msglen int 1399 for shift := uint(0); ; shift += 7 { 1400 if shift >= 64 { 1401 return ErrIntOverflowA1 1402 } 1403 if iNdEx >= l { 1404 return io.ErrUnexpectedEOF 1405 } 1406 b := dAtA[iNdEx] 1407 iNdEx++ 1408 msglen |= int(b&0x7F) << shift 1409 if b < 0x80 { 1410 break 1411 } 1412 } 1413 if msglen < 0 { 1414 return ErrInvalidLengthA1 1415 } 1416 postIndex := iNdEx + msglen 1417 if postIndex < 0 { 1418 return ErrInvalidLengthA1 1419 } 1420 if postIndex > l { 1421 return io.ErrUnexpectedEOF 1422 } 1423 if m.Header == nil { 1424 m.Header = &Header{} 1425 } 1426 if err := m.Header.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 1427 return err 1428 } 1429 iNdEx = postIndex 1430 case 2: 1431 if wireType != 2 { 1432 return fmt.Errorf("proto: wrong wireType = %d for field Payload", wireType) 1433 } 1434 var byteLen int 1435 for shift := uint(0); ; shift += 7 { 1436 if shift >= 64 { 1437 return ErrIntOverflowA1 1438 } 1439 if iNdEx >= l { 1440 return io.ErrUnexpectedEOF 1441 } 1442 b := dAtA[iNdEx] 1443 iNdEx++ 1444 byteLen |= int(b&0x7F) << shift 1445 if b < 0x80 { 1446 break 1447 } 1448 } 1449 if byteLen < 0 { 1450 return ErrInvalidLengthA1 1451 } 1452 postIndex := iNdEx + byteLen 1453 if postIndex < 0 { 1454 return ErrInvalidLengthA1 1455 } 1456 if postIndex > l { 1457 return io.ErrUnexpectedEOF 1458 } 1459 m.Payload = append(m.Payload[:0], dAtA[iNdEx:postIndex]...) 1460 if m.Payload == nil { 1461 m.Payload = []byte{} 1462 } 1463 iNdEx = postIndex 1464 case 3: 1465 if wireType != 2 { 1466 return fmt.Errorf("proto: wrong wireType = %d for field Result", wireType) 1467 } 1468 var msglen int 1469 for shift := uint(0); ; shift += 7 { 1470 if shift >= 64 { 1471 return ErrIntOverflowA1 1472 } 1473 if iNdEx >= l { 1474 return io.ErrUnexpectedEOF 1475 } 1476 b := dAtA[iNdEx] 1477 iNdEx++ 1478 msglen |= int(b&0x7F) << shift 1479 if b < 0x80 { 1480 break 1481 } 1482 } 1483 if msglen < 0 { 1484 return ErrInvalidLengthA1 1485 } 1486 postIndex := iNdEx + msglen 1487 if postIndex < 0 { 1488 return ErrInvalidLengthA1 1489 } 1490 if postIndex > l { 1491 return io.ErrUnexpectedEOF 1492 } 1493 if m.Result == nil { 1494 m.Result = &Result{} 1495 } 1496 if err := m.Result.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 1497 return err 1498 } 1499 iNdEx = postIndex 1500 default: 1501 iNdEx = preIndex 1502 skippy, err := skipA1(dAtA[iNdEx:]) 1503 if err != nil { 1504 return err 1505 } 1506 if (skippy < 0) || (iNdEx+skippy) < 0 { 1507 return ErrInvalidLengthA1 1508 } 1509 if (iNdEx + skippy) > l { 1510 return io.ErrUnexpectedEOF 1511 } 1512 iNdEx += skippy 1513 } 1514 } 1515 1516 if iNdEx > l { 1517 return io.ErrUnexpectedEOF 1518 } 1519 return nil 1520 } 1521 func (m *StatusMessage) Unmarshal(dAtA []byte) error { 1522 l := len(dAtA) 1523 iNdEx := 0 1524 for iNdEx < l { 1525 preIndex := iNdEx 1526 var wire uint64 1527 for shift := uint(0); ; shift += 7 { 1528 if shift >= 64 { 1529 return ErrIntOverflowA1 1530 } 1531 if iNdEx >= l { 1532 return io.ErrUnexpectedEOF 1533 } 1534 b := dAtA[iNdEx] 1535 iNdEx++ 1536 wire |= uint64(b&0x7F) << shift 1537 if b < 0x80 { 1538 break 1539 } 1540 } 1541 fieldNum := int32(wire >> 3) 1542 wireType := int(wire & 0x7) 1543 if wireType == 4 { 1544 return fmt.Errorf("proto: StatusMessage: wiretype end group for non-group") 1545 } 1546 if fieldNum <= 0 { 1547 return fmt.Errorf("proto: StatusMessage: illegal tag %d (wire type %d)", fieldNum, wire) 1548 } 1549 switch fieldNum { 1550 case 1: 1551 if wireType != 2 { 1552 return fmt.Errorf("proto: wrong wireType = %d for field Header", wireType) 1553 } 1554 var msglen int 1555 for shift := uint(0); ; shift += 7 { 1556 if shift >= 64 { 1557 return ErrIntOverflowA1 1558 } 1559 if iNdEx >= l { 1560 return io.ErrUnexpectedEOF 1561 } 1562 b := dAtA[iNdEx] 1563 iNdEx++ 1564 msglen |= int(b&0x7F) << shift 1565 if b < 0x80 { 1566 break 1567 } 1568 } 1569 if msglen < 0 { 1570 return ErrInvalidLengthA1 1571 } 1572 postIndex := iNdEx + msglen 1573 if postIndex < 0 { 1574 return ErrInvalidLengthA1 1575 } 1576 if postIndex > l { 1577 return io.ErrUnexpectedEOF 1578 } 1579 if m.Header == nil { 1580 m.Header = &Header{} 1581 } 1582 if err := m.Header.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 1583 return err 1584 } 1585 iNdEx = postIndex 1586 case 2: 1587 if wireType != 2 { 1588 return fmt.Errorf("proto: wrong wireType = %d for field Payload", wireType) 1589 } 1590 var byteLen int 1591 for shift := uint(0); ; shift += 7 { 1592 if shift >= 64 { 1593 return ErrIntOverflowA1 1594 } 1595 if iNdEx >= l { 1596 return io.ErrUnexpectedEOF 1597 } 1598 b := dAtA[iNdEx] 1599 iNdEx++ 1600 byteLen |= int(b&0x7F) << shift 1601 if b < 0x80 { 1602 break 1603 } 1604 } 1605 if byteLen < 0 { 1606 return ErrInvalidLengthA1 1607 } 1608 postIndex := iNdEx + byteLen 1609 if postIndex < 0 { 1610 return ErrInvalidLengthA1 1611 } 1612 if postIndex > l { 1613 return io.ErrUnexpectedEOF 1614 } 1615 m.Payload = append(m.Payload[:0], dAtA[iNdEx:postIndex]...) 1616 if m.Payload == nil { 1617 m.Payload = []byte{} 1618 } 1619 iNdEx = postIndex 1620 default: 1621 iNdEx = preIndex 1622 skippy, err := skipA1(dAtA[iNdEx:]) 1623 if err != nil { 1624 return err 1625 } 1626 if (skippy < 0) || (iNdEx+skippy) < 0 { 1627 return ErrInvalidLengthA1 1628 } 1629 if (iNdEx + skippy) > l { 1630 return io.ErrUnexpectedEOF 1631 } 1632 iNdEx += skippy 1633 } 1634 } 1635 1636 if iNdEx > l { 1637 return io.ErrUnexpectedEOF 1638 } 1639 return nil 1640 } 1641 func (m *AckMessage) Unmarshal(dAtA []byte) error { 1642 l := len(dAtA) 1643 iNdEx := 0 1644 for iNdEx < l { 1645 preIndex := iNdEx 1646 var wire uint64 1647 for shift := uint(0); ; shift += 7 { 1648 if shift >= 64 { 1649 return ErrIntOverflowA1 1650 } 1651 if iNdEx >= l { 1652 return io.ErrUnexpectedEOF 1653 } 1654 b := dAtA[iNdEx] 1655 iNdEx++ 1656 wire |= uint64(b&0x7F) << shift 1657 if b < 0x80 { 1658 break 1659 } 1660 } 1661 fieldNum := int32(wire >> 3) 1662 wireType := int(wire & 0x7) 1663 if wireType == 4 { 1664 return fmt.Errorf("proto: AckMessage: wiretype end group for non-group") 1665 } 1666 if fieldNum <= 0 { 1667 return fmt.Errorf("proto: AckMessage: illegal tag %d (wire type %d)", fieldNum, wire) 1668 } 1669 switch fieldNum { 1670 case 1: 1671 if wireType != 2 { 1672 return fmt.Errorf("proto: wrong wireType = %d for field Header", wireType) 1673 } 1674 var msglen int 1675 for shift := uint(0); ; shift += 7 { 1676 if shift >= 64 { 1677 return ErrIntOverflowA1 1678 } 1679 if iNdEx >= l { 1680 return io.ErrUnexpectedEOF 1681 } 1682 b := dAtA[iNdEx] 1683 iNdEx++ 1684 msglen |= int(b&0x7F) << shift 1685 if b < 0x80 { 1686 break 1687 } 1688 } 1689 if msglen < 0 { 1690 return ErrInvalidLengthA1 1691 } 1692 postIndex := iNdEx + msglen 1693 if postIndex < 0 { 1694 return ErrInvalidLengthA1 1695 } 1696 if postIndex > l { 1697 return io.ErrUnexpectedEOF 1698 } 1699 if m.Header == nil { 1700 m.Header = &Header{} 1701 } 1702 if err := m.Header.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 1703 return err 1704 } 1705 iNdEx = postIndex 1706 case 2: 1707 if wireType != 2 { 1708 return fmt.Errorf("proto: wrong wireType = %d for field Payload", wireType) 1709 } 1710 var byteLen int 1711 for shift := uint(0); ; shift += 7 { 1712 if shift >= 64 { 1713 return ErrIntOverflowA1 1714 } 1715 if iNdEx >= l { 1716 return io.ErrUnexpectedEOF 1717 } 1718 b := dAtA[iNdEx] 1719 iNdEx++ 1720 byteLen |= int(b&0x7F) << shift 1721 if b < 0x80 { 1722 break 1723 } 1724 } 1725 if byteLen < 0 { 1726 return ErrInvalidLengthA1 1727 } 1728 postIndex := iNdEx + byteLen 1729 if postIndex < 0 { 1730 return ErrInvalidLengthA1 1731 } 1732 if postIndex > l { 1733 return io.ErrUnexpectedEOF 1734 } 1735 m.Payload = append(m.Payload[:0], dAtA[iNdEx:postIndex]...) 1736 if m.Payload == nil { 1737 m.Payload = []byte{} 1738 } 1739 iNdEx = postIndex 1740 case 3: 1741 if wireType != 2 { 1742 return fmt.Errorf("proto: wrong wireType = %d for field Result", wireType) 1743 } 1744 var msglen int 1745 for shift := uint(0); ; shift += 7 { 1746 if shift >= 64 { 1747 return ErrIntOverflowA1 1748 } 1749 if iNdEx >= l { 1750 return io.ErrUnexpectedEOF 1751 } 1752 b := dAtA[iNdEx] 1753 iNdEx++ 1754 msglen |= int(b&0x7F) << shift 1755 if b < 0x80 { 1756 break 1757 } 1758 } 1759 if msglen < 0 { 1760 return ErrInvalidLengthA1 1761 } 1762 postIndex := iNdEx + msglen 1763 if postIndex < 0 { 1764 return ErrInvalidLengthA1 1765 } 1766 if postIndex > l { 1767 return io.ErrUnexpectedEOF 1768 } 1769 if m.Result == nil { 1770 m.Result = &Result{} 1771 } 1772 if err := m.Result.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 1773 return err 1774 } 1775 iNdEx = postIndex 1776 default: 1777 iNdEx = preIndex 1778 skippy, err := skipA1(dAtA[iNdEx:]) 1779 if err != nil { 1780 return err 1781 } 1782 if (skippy < 0) || (iNdEx+skippy) < 0 { 1783 return ErrInvalidLengthA1 1784 } 1785 if (iNdEx + skippy) > l { 1786 return io.ErrUnexpectedEOF 1787 } 1788 iNdEx += skippy 1789 } 1790 } 1791 1792 if iNdEx > l { 1793 return io.ErrUnexpectedEOF 1794 } 1795 return nil 1796 } 1797 func skipA1(dAtA []byte) (n int, err error) { 1798 l := len(dAtA) 1799 iNdEx := 0 1800 depth := 0 1801 for iNdEx < l { 1802 var wire uint64 1803 for shift := uint(0); ; shift += 7 { 1804 if shift >= 64 { 1805 return 0, ErrIntOverflowA1 1806 } 1807 if iNdEx >= l { 1808 return 0, io.ErrUnexpectedEOF 1809 } 1810 b := dAtA[iNdEx] 1811 iNdEx++ 1812 wire |= (uint64(b) & 0x7F) << shift 1813 if b < 0x80 { 1814 break 1815 } 1816 } 1817 wireType := int(wire & 0x7) 1818 switch wireType { 1819 case 0: 1820 for shift := uint(0); ; shift += 7 { 1821 if shift >= 64 { 1822 return 0, ErrIntOverflowA1 1823 } 1824 if iNdEx >= l { 1825 return 0, io.ErrUnexpectedEOF 1826 } 1827 iNdEx++ 1828 if dAtA[iNdEx-1] < 0x80 { 1829 break 1830 } 1831 } 1832 case 1: 1833 iNdEx += 8 1834 case 2: 1835 var length int 1836 for shift := uint(0); ; shift += 7 { 1837 if shift >= 64 { 1838 return 0, ErrIntOverflowA1 1839 } 1840 if iNdEx >= l { 1841 return 0, io.ErrUnexpectedEOF 1842 } 1843 b := dAtA[iNdEx] 1844 iNdEx++ 1845 length |= (int(b) & 0x7F) << shift 1846 if b < 0x80 { 1847 break 1848 } 1849 } 1850 if length < 0 { 1851 return 0, ErrInvalidLengthA1 1852 } 1853 iNdEx += length 1854 case 3: 1855 depth++ 1856 case 4: 1857 if depth == 0 { 1858 return 0, ErrUnexpectedEndOfGroupA1 1859 } 1860 depth-- 1861 case 5: 1862 iNdEx += 4 1863 default: 1864 return 0, fmt.Errorf("proto: illegal wireType %d", wireType) 1865 } 1866 if iNdEx < 0 { 1867 return 0, ErrInvalidLengthA1 1868 } 1869 if depth == 0 { 1870 return iNdEx, nil 1871 } 1872 } 1873 return 0, io.ErrUnexpectedEOF 1874 } 1875 1876 var ( 1877 ErrInvalidLengthA1 = fmt.Errorf("proto: negative length found during unmarshaling") 1878 ErrIntOverflowA1 = fmt.Errorf("proto: integer overflow") 1879 ErrUnexpectedEndOfGroupA1 = fmt.Errorf("proto: unexpected end of group") 1880 )