github.com/onosproject/onos-api/go@v0.10.32/onos/config/v2/transaction.pb.go (about) 1 // Code generated by protoc-gen-gogo. DO NOT EDIT. 2 // source: onos/config/v2/transaction.proto 3 4 package v2 5 6 import ( 7 fmt "fmt" 8 _ "github.com/gogo/protobuf/gogoproto" 9 proto "github.com/gogo/protobuf/proto" 10 _ "github.com/gogo/protobuf/types" 11 github_com_gogo_protobuf_types "github.com/gogo/protobuf/types" 12 io "io" 13 math "math" 14 math_bits "math/bits" 15 time "time" 16 ) 17 18 // Reference imports to suppress errors if they are not otherwise used. 19 var _ = proto.Marshal 20 var _ = fmt.Errorf 21 var _ = math.Inf 22 var _ = time.Kitchen 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 TransactionStrategy_Synchronicity int32 31 32 const ( 33 TransactionStrategy_ASYNCHRONOUS TransactionStrategy_Synchronicity = 0 34 TransactionStrategy_SYNCHRONOUS TransactionStrategy_Synchronicity = 1 35 ) 36 37 var TransactionStrategy_Synchronicity_name = map[int32]string{ 38 0: "ASYNCHRONOUS", 39 1: "SYNCHRONOUS", 40 } 41 42 var TransactionStrategy_Synchronicity_value = map[string]int32{ 43 "ASYNCHRONOUS": 0, 44 "SYNCHRONOUS": 1, 45 } 46 47 func (x TransactionStrategy_Synchronicity) String() string { 48 return proto.EnumName(TransactionStrategy_Synchronicity_name, int32(x)) 49 } 50 51 func (TransactionStrategy_Synchronicity) EnumDescriptor() ([]byte, []int) { 52 return fileDescriptor_c3a2d73bdadccc35, []int{2, 0} 53 } 54 55 type TransactionStrategy_Isolation int32 56 57 const ( 58 TransactionStrategy_DEFAULT TransactionStrategy_Isolation = 0 59 TransactionStrategy_SERIALIZABLE TransactionStrategy_Isolation = 1 60 ) 61 62 var TransactionStrategy_Isolation_name = map[int32]string{ 63 0: "DEFAULT", 64 1: "SERIALIZABLE", 65 } 66 67 var TransactionStrategy_Isolation_value = map[string]int32{ 68 "DEFAULT": 0, 69 "SERIALIZABLE": 1, 70 } 71 72 func (x TransactionStrategy_Isolation) String() string { 73 return proto.EnumName(TransactionStrategy_Isolation_name, int32(x)) 74 } 75 76 func (TransactionStrategy_Isolation) EnumDescriptor() ([]byte, []int) { 77 return fileDescriptor_c3a2d73bdadccc35, []int{2, 1} 78 } 79 80 type TransactionStatus_State int32 81 82 const ( 83 TransactionStatus_PENDING TransactionStatus_State = 0 84 TransactionStatus_VALIDATED TransactionStatus_State = 1 85 TransactionStatus_COMMITTED TransactionStatus_State = 2 86 TransactionStatus_APPLIED TransactionStatus_State = 3 87 TransactionStatus_FAILED TransactionStatus_State = 4 88 ) 89 90 var TransactionStatus_State_name = map[int32]string{ 91 0: "PENDING", 92 1: "VALIDATED", 93 2: "COMMITTED", 94 3: "APPLIED", 95 4: "FAILED", 96 } 97 98 var TransactionStatus_State_value = map[string]int32{ 99 "PENDING": 0, 100 "VALIDATED": 1, 101 "COMMITTED": 2, 102 "APPLIED": 3, 103 "FAILED": 4, 104 } 105 106 func (x TransactionStatus_State) String() string { 107 return proto.EnumName(TransactionStatus_State_name, int32(x)) 108 } 109 110 func (TransactionStatus_State) EnumDescriptor() ([]byte, []int) { 111 return fileDescriptor_c3a2d73bdadccc35, []int{5, 0} 112 } 113 114 type TransactionInitializePhase_State int32 115 116 const ( 117 TransactionInitializePhase_INITIALIZING TransactionInitializePhase_State = 0 118 TransactionInitializePhase_INITIALIZED TransactionInitializePhase_State = 1 119 TransactionInitializePhase_FAILED TransactionInitializePhase_State = 2 120 ) 121 122 var TransactionInitializePhase_State_name = map[int32]string{ 123 0: "INITIALIZING", 124 1: "INITIALIZED", 125 2: "FAILED", 126 } 127 128 var TransactionInitializePhase_State_value = map[string]int32{ 129 "INITIALIZING": 0, 130 "INITIALIZED": 1, 131 "FAILED": 2, 132 } 133 134 func (x TransactionInitializePhase_State) String() string { 135 return proto.EnumName(TransactionInitializePhase_State_name, int32(x)) 136 } 137 138 func (TransactionInitializePhase_State) EnumDescriptor() ([]byte, []int) { 139 return fileDescriptor_c3a2d73bdadccc35, []int{8, 0} 140 } 141 142 type TransactionValidatePhase_State int32 143 144 const ( 145 TransactionValidatePhase_VALIDATING TransactionValidatePhase_State = 0 146 TransactionValidatePhase_VALIDATED TransactionValidatePhase_State = 1 147 TransactionValidatePhase_FAILED TransactionValidatePhase_State = 2 148 ) 149 150 var TransactionValidatePhase_State_name = map[int32]string{ 151 0: "VALIDATING", 152 1: "VALIDATED", 153 2: "FAILED", 154 } 155 156 var TransactionValidatePhase_State_value = map[string]int32{ 157 "VALIDATING": 0, 158 "VALIDATED": 1, 159 "FAILED": 2, 160 } 161 162 func (x TransactionValidatePhase_State) String() string { 163 return proto.EnumName(TransactionValidatePhase_State_name, int32(x)) 164 } 165 166 func (TransactionValidatePhase_State) EnumDescriptor() ([]byte, []int) { 167 return fileDescriptor_c3a2d73bdadccc35, []int{9, 0} 168 } 169 170 type TransactionCommitPhase_State int32 171 172 const ( 173 TransactionCommitPhase_COMMITTING TransactionCommitPhase_State = 0 174 TransactionCommitPhase_COMMITTED TransactionCommitPhase_State = 1 175 ) 176 177 var TransactionCommitPhase_State_name = map[int32]string{ 178 0: "COMMITTING", 179 1: "COMMITTED", 180 } 181 182 var TransactionCommitPhase_State_value = map[string]int32{ 183 "COMMITTING": 0, 184 "COMMITTED": 1, 185 } 186 187 func (x TransactionCommitPhase_State) String() string { 188 return proto.EnumName(TransactionCommitPhase_State_name, int32(x)) 189 } 190 191 func (TransactionCommitPhase_State) EnumDescriptor() ([]byte, []int) { 192 return fileDescriptor_c3a2d73bdadccc35, []int{10, 0} 193 } 194 195 type TransactionApplyPhase_State int32 196 197 const ( 198 TransactionApplyPhase_APPLYING TransactionApplyPhase_State = 0 199 TransactionApplyPhase_APPLIED TransactionApplyPhase_State = 1 200 TransactionApplyPhase_FAILED TransactionApplyPhase_State = 2 201 ) 202 203 var TransactionApplyPhase_State_name = map[int32]string{ 204 0: "APPLYING", 205 1: "APPLIED", 206 2: "FAILED", 207 } 208 209 var TransactionApplyPhase_State_value = map[string]int32{ 210 "APPLYING": 0, 211 "APPLIED": 1, 212 "FAILED": 2, 213 } 214 215 func (x TransactionApplyPhase_State) String() string { 216 return proto.EnumName(TransactionApplyPhase_State_name, int32(x)) 217 } 218 219 func (TransactionApplyPhase_State) EnumDescriptor() ([]byte, []int) { 220 return fileDescriptor_c3a2d73bdadccc35, []int{11, 0} 221 } 222 223 type TransactionAbortPhase_State int32 224 225 const ( 226 TransactionAbortPhase_ABORTING TransactionAbortPhase_State = 0 227 TransactionAbortPhase_ABORTED TransactionAbortPhase_State = 1 228 ) 229 230 var TransactionAbortPhase_State_name = map[int32]string{ 231 0: "ABORTING", 232 1: "ABORTED", 233 } 234 235 var TransactionAbortPhase_State_value = map[string]int32{ 236 "ABORTING": 0, 237 "ABORTED": 1, 238 } 239 240 func (x TransactionAbortPhase_State) String() string { 241 return proto.EnumName(TransactionAbortPhase_State_name, int32(x)) 242 } 243 244 func (TransactionAbortPhase_State) EnumDescriptor() ([]byte, []int) { 245 return fileDescriptor_c3a2d73bdadccc35, []int{12, 0} 246 } 247 248 // EventType transaction event types for transaction store 249 type TransactionEvent_EventType int32 250 251 const ( 252 TransactionEvent_UNKNOWN TransactionEvent_EventType = 0 253 TransactionEvent_CREATED TransactionEvent_EventType = 1 254 TransactionEvent_UPDATED TransactionEvent_EventType = 2 255 TransactionEvent_DELETED TransactionEvent_EventType = 3 256 TransactionEvent_REPLAYED TransactionEvent_EventType = 4 257 ) 258 259 var TransactionEvent_EventType_name = map[int32]string{ 260 0: "UNKNOWN", 261 1: "CREATED", 262 2: "UPDATED", 263 3: "DELETED", 264 4: "REPLAYED", 265 } 266 267 var TransactionEvent_EventType_value = map[string]int32{ 268 "UNKNOWN": 0, 269 "CREATED": 1, 270 "UPDATED": 2, 271 "DELETED": 3, 272 "REPLAYED": 4, 273 } 274 275 func (x TransactionEvent_EventType) String() string { 276 return proto.EnumName(TransactionEvent_EventType_name, int32(x)) 277 } 278 279 func (TransactionEvent_EventType) EnumDescriptor() ([]byte, []int) { 280 return fileDescriptor_c3a2d73bdadccc35, []int{13, 0} 281 } 282 283 // TransactionInfo is an extension providing information about the transaction 284 // to clients in responses. 285 type TransactionInfo struct { 286 ID TransactionID `protobuf:"bytes,1,opt,name=id,proto3,casttype=TransactionID" json:"id,omitempty"` 287 Index Index `protobuf:"varint,2,opt,name=index,proto3,casttype=Index" json:"index,omitempty"` 288 } 289 290 func (m *TransactionInfo) Reset() { *m = TransactionInfo{} } 291 func (m *TransactionInfo) String() string { return proto.CompactTextString(m) } 292 func (*TransactionInfo) ProtoMessage() {} 293 func (*TransactionInfo) Descriptor() ([]byte, []int) { 294 return fileDescriptor_c3a2d73bdadccc35, []int{0} 295 } 296 func (m *TransactionInfo) XXX_Unmarshal(b []byte) error { 297 return m.Unmarshal(b) 298 } 299 func (m *TransactionInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 300 if deterministic { 301 return xxx_messageInfo_TransactionInfo.Marshal(b, m, deterministic) 302 } else { 303 b = b[:cap(b)] 304 n, err := m.MarshalToSizedBuffer(b) 305 if err != nil { 306 return nil, err 307 } 308 return b[:n], nil 309 } 310 } 311 func (m *TransactionInfo) XXX_Merge(src proto.Message) { 312 xxx_messageInfo_TransactionInfo.Merge(m, src) 313 } 314 func (m *TransactionInfo) XXX_Size() int { 315 return m.Size() 316 } 317 func (m *TransactionInfo) XXX_DiscardUnknown() { 318 xxx_messageInfo_TransactionInfo.DiscardUnknown(m) 319 } 320 321 var xxx_messageInfo_TransactionInfo proto.InternalMessageInfo 322 323 func (m *TransactionInfo) GetID() TransactionID { 324 if m != nil { 325 return m.ID 326 } 327 return "" 328 } 329 330 func (m *TransactionInfo) GetIndex() Index { 331 if m != nil { 332 return m.Index 333 } 334 return 0 335 } 336 337 // Transaction refers to a transaction change or transaction rollback 338 type Transaction struct { 339 ObjectMeta `protobuf:"bytes,1,opt,name=meta,proto3,embedded=meta" json:"meta"` 340 // 'id' is the unique identifier of the transaction 341 // This field should be set prior to persisting the object. 342 ID TransactionID `protobuf:"bytes,2,opt,name=id,proto3,casttype=TransactionID" json:"id,omitempty"` 343 // 'index' is a monotonically increasing, globally unique index of the change 344 // The index is provided by the store, is static and unique for each unique change identifier, 345 // and should not be modified by client code. 346 Index Index `protobuf:"varint,3,opt,name=index,proto3,casttype=Index" json:"index,omitempty"` 347 // 'username' is the name of the user that made the transaction 348 Username string `protobuf:"bytes,4,opt,name=username,proto3" json:"username,omitempty"` 349 // 'strategy' is the transaction strategy 350 TransactionStrategy `protobuf:"bytes,5,opt,name=strategy,proto3,embedded=strategy" json:"strategy"` 351 // 'details' is the transaction details 352 // 353 // Types that are valid to be assigned to Details: 354 // *Transaction_Change 355 // *Transaction_Rollback 356 Details isTransaction_Details `protobuf_oneof:"details"` 357 // 'status' is the current lifecycle status of the transaction 358 Status TransactionStatus `protobuf:"bytes,8,opt,name=status,proto3" json:"status"` 359 // Optional target type/version overrides. 360 *TargetVersionOverrides `protobuf:"bytes,9,opt,name=version_overrides,json=versionOverrides,proto3,embedded=version_overrides" json:"version_overrides,omitempty"` 361 } 362 363 func (m *Transaction) Reset() { *m = Transaction{} } 364 func (m *Transaction) String() string { return proto.CompactTextString(m) } 365 func (*Transaction) ProtoMessage() {} 366 func (*Transaction) Descriptor() ([]byte, []int) { 367 return fileDescriptor_c3a2d73bdadccc35, []int{1} 368 } 369 func (m *Transaction) XXX_Unmarshal(b []byte) error { 370 return m.Unmarshal(b) 371 } 372 func (m *Transaction) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 373 if deterministic { 374 return xxx_messageInfo_Transaction.Marshal(b, m, deterministic) 375 } else { 376 b = b[:cap(b)] 377 n, err := m.MarshalToSizedBuffer(b) 378 if err != nil { 379 return nil, err 380 } 381 return b[:n], nil 382 } 383 } 384 func (m *Transaction) XXX_Merge(src proto.Message) { 385 xxx_messageInfo_Transaction.Merge(m, src) 386 } 387 func (m *Transaction) XXX_Size() int { 388 return m.Size() 389 } 390 func (m *Transaction) XXX_DiscardUnknown() { 391 xxx_messageInfo_Transaction.DiscardUnknown(m) 392 } 393 394 var xxx_messageInfo_Transaction proto.InternalMessageInfo 395 396 type isTransaction_Details interface { 397 isTransaction_Details() 398 MarshalTo([]byte) (int, error) 399 Size() int 400 } 401 402 type Transaction_Change struct { 403 Change *ChangeTransaction `protobuf:"bytes,6,opt,name=change,proto3,oneof" json:"change,omitempty"` 404 } 405 type Transaction_Rollback struct { 406 Rollback *RollbackTransaction `protobuf:"bytes,7,opt,name=rollback,proto3,oneof" json:"rollback,omitempty"` 407 } 408 409 func (*Transaction_Change) isTransaction_Details() {} 410 func (*Transaction_Rollback) isTransaction_Details() {} 411 412 func (m *Transaction) GetDetails() isTransaction_Details { 413 if m != nil { 414 return m.Details 415 } 416 return nil 417 } 418 419 func (m *Transaction) GetID() TransactionID { 420 if m != nil { 421 return m.ID 422 } 423 return "" 424 } 425 426 func (m *Transaction) GetIndex() Index { 427 if m != nil { 428 return m.Index 429 } 430 return 0 431 } 432 433 func (m *Transaction) GetUsername() string { 434 if m != nil { 435 return m.Username 436 } 437 return "" 438 } 439 440 func (m *Transaction) GetChange() *ChangeTransaction { 441 if x, ok := m.GetDetails().(*Transaction_Change); ok { 442 return x.Change 443 } 444 return nil 445 } 446 447 func (m *Transaction) GetRollback() *RollbackTransaction { 448 if x, ok := m.GetDetails().(*Transaction_Rollback); ok { 449 return x.Rollback 450 } 451 return nil 452 } 453 454 func (m *Transaction) GetStatus() TransactionStatus { 455 if m != nil { 456 return m.Status 457 } 458 return TransactionStatus{} 459 } 460 461 // XXX_OneofWrappers is for the internal use of the proto package. 462 func (*Transaction) XXX_OneofWrappers() []interface{} { 463 return []interface{}{ 464 (*Transaction_Change)(nil), 465 (*Transaction_Rollback)(nil), 466 } 467 } 468 469 type TransactionStrategy struct { 470 // 'synchronicity' indicates the transaction synchronicity level 471 Synchronicity TransactionStrategy_Synchronicity `protobuf:"varint,1,opt,name=synchronicity,proto3,enum=onos.config.v2.TransactionStrategy_Synchronicity" json:"synchronicity,omitempty"` 472 // 'isolation' indicates the transaction isolation level 473 Isolation TransactionStrategy_Isolation `protobuf:"varint,2,opt,name=isolation,proto3,enum=onos.config.v2.TransactionStrategy_Isolation" json:"isolation,omitempty"` 474 } 475 476 func (m *TransactionStrategy) Reset() { *m = TransactionStrategy{} } 477 func (m *TransactionStrategy) String() string { return proto.CompactTextString(m) } 478 func (*TransactionStrategy) ProtoMessage() {} 479 func (*TransactionStrategy) Descriptor() ([]byte, []int) { 480 return fileDescriptor_c3a2d73bdadccc35, []int{2} 481 } 482 func (m *TransactionStrategy) XXX_Unmarshal(b []byte) error { 483 return m.Unmarshal(b) 484 } 485 func (m *TransactionStrategy) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 486 if deterministic { 487 return xxx_messageInfo_TransactionStrategy.Marshal(b, m, deterministic) 488 } else { 489 b = b[:cap(b)] 490 n, err := m.MarshalToSizedBuffer(b) 491 if err != nil { 492 return nil, err 493 } 494 return b[:n], nil 495 } 496 } 497 func (m *TransactionStrategy) XXX_Merge(src proto.Message) { 498 xxx_messageInfo_TransactionStrategy.Merge(m, src) 499 } 500 func (m *TransactionStrategy) XXX_Size() int { 501 return m.Size() 502 } 503 func (m *TransactionStrategy) XXX_DiscardUnknown() { 504 xxx_messageInfo_TransactionStrategy.DiscardUnknown(m) 505 } 506 507 var xxx_messageInfo_TransactionStrategy proto.InternalMessageInfo 508 509 func (m *TransactionStrategy) GetSynchronicity() TransactionStrategy_Synchronicity { 510 if m != nil { 511 return m.Synchronicity 512 } 513 return TransactionStrategy_ASYNCHRONOUS 514 } 515 516 func (m *TransactionStrategy) GetIsolation() TransactionStrategy_Isolation { 517 if m != nil { 518 return m.Isolation 519 } 520 return TransactionStrategy_DEFAULT 521 } 522 523 type ChangeTransaction struct { 524 // 'values' is a set of changes to apply to targets 525 Values map[TargetID]*PathValues `protobuf:"bytes,1,rep,name=values,proto3,castkey=TargetID" json:"values,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` 526 } 527 528 func (m *ChangeTransaction) Reset() { *m = ChangeTransaction{} } 529 func (m *ChangeTransaction) String() string { return proto.CompactTextString(m) } 530 func (*ChangeTransaction) ProtoMessage() {} 531 func (*ChangeTransaction) Descriptor() ([]byte, []int) { 532 return fileDescriptor_c3a2d73bdadccc35, []int{3} 533 } 534 func (m *ChangeTransaction) XXX_Unmarshal(b []byte) error { 535 return m.Unmarshal(b) 536 } 537 func (m *ChangeTransaction) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 538 if deterministic { 539 return xxx_messageInfo_ChangeTransaction.Marshal(b, m, deterministic) 540 } else { 541 b = b[:cap(b)] 542 n, err := m.MarshalToSizedBuffer(b) 543 if err != nil { 544 return nil, err 545 } 546 return b[:n], nil 547 } 548 } 549 func (m *ChangeTransaction) XXX_Merge(src proto.Message) { 550 xxx_messageInfo_ChangeTransaction.Merge(m, src) 551 } 552 func (m *ChangeTransaction) XXX_Size() int { 553 return m.Size() 554 } 555 func (m *ChangeTransaction) XXX_DiscardUnknown() { 556 xxx_messageInfo_ChangeTransaction.DiscardUnknown(m) 557 } 558 559 var xxx_messageInfo_ChangeTransaction proto.InternalMessageInfo 560 561 func (m *ChangeTransaction) GetValues() map[TargetID]*PathValues { 562 if m != nil { 563 return m.Values 564 } 565 return nil 566 } 567 568 type RollbackTransaction struct { 569 // 'rollback_index' is the index of the transaction to roll back 570 RollbackIndex Index `protobuf:"varint,1,opt,name=rollback_index,json=rollbackIndex,proto3,casttype=Index" json:"rollback_index,omitempty"` 571 } 572 573 func (m *RollbackTransaction) Reset() { *m = RollbackTransaction{} } 574 func (m *RollbackTransaction) String() string { return proto.CompactTextString(m) } 575 func (*RollbackTransaction) ProtoMessage() {} 576 func (*RollbackTransaction) Descriptor() ([]byte, []int) { 577 return fileDescriptor_c3a2d73bdadccc35, []int{4} 578 } 579 func (m *RollbackTransaction) XXX_Unmarshal(b []byte) error { 580 return m.Unmarshal(b) 581 } 582 func (m *RollbackTransaction) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 583 if deterministic { 584 return xxx_messageInfo_RollbackTransaction.Marshal(b, m, deterministic) 585 } else { 586 b = b[:cap(b)] 587 n, err := m.MarshalToSizedBuffer(b) 588 if err != nil { 589 return nil, err 590 } 591 return b[:n], nil 592 } 593 } 594 func (m *RollbackTransaction) XXX_Merge(src proto.Message) { 595 xxx_messageInfo_RollbackTransaction.Merge(m, src) 596 } 597 func (m *RollbackTransaction) XXX_Size() int { 598 return m.Size() 599 } 600 func (m *RollbackTransaction) XXX_DiscardUnknown() { 601 xxx_messageInfo_RollbackTransaction.DiscardUnknown(m) 602 } 603 604 var xxx_messageInfo_RollbackTransaction proto.InternalMessageInfo 605 606 func (m *RollbackTransaction) GetRollbackIndex() Index { 607 if m != nil { 608 return m.RollbackIndex 609 } 610 return 0 611 } 612 613 type TransactionStatus struct { 614 // 'phases' is the transaction phases 615 Phases TransactionPhases `protobuf:"bytes,1,opt,name=phases,proto3" json:"phases"` 616 // 'proposals' is the set of proposals managed by the transaction 617 Proposals []ProposalID `protobuf:"bytes,2,rep,name=proposals,proto3,casttype=ProposalID" json:"proposals,omitempty"` 618 // 'state' is the overall transaction state 619 State TransactionStatus_State `protobuf:"varint,3,opt,name=state,proto3,enum=onos.config.v2.TransactionStatus_State" json:"state,omitempty"` 620 // 'failure' is the transaction failure (if any) 621 Failure *Failure `protobuf:"bytes,4,opt,name=failure,proto3" json:"failure,omitempty"` 622 } 623 624 func (m *TransactionStatus) Reset() { *m = TransactionStatus{} } 625 func (m *TransactionStatus) String() string { return proto.CompactTextString(m) } 626 func (*TransactionStatus) ProtoMessage() {} 627 func (*TransactionStatus) Descriptor() ([]byte, []int) { 628 return fileDescriptor_c3a2d73bdadccc35, []int{5} 629 } 630 func (m *TransactionStatus) XXX_Unmarshal(b []byte) error { 631 return m.Unmarshal(b) 632 } 633 func (m *TransactionStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 634 if deterministic { 635 return xxx_messageInfo_TransactionStatus.Marshal(b, m, deterministic) 636 } else { 637 b = b[:cap(b)] 638 n, err := m.MarshalToSizedBuffer(b) 639 if err != nil { 640 return nil, err 641 } 642 return b[:n], nil 643 } 644 } 645 func (m *TransactionStatus) XXX_Merge(src proto.Message) { 646 xxx_messageInfo_TransactionStatus.Merge(m, src) 647 } 648 func (m *TransactionStatus) XXX_Size() int { 649 return m.Size() 650 } 651 func (m *TransactionStatus) XXX_DiscardUnknown() { 652 xxx_messageInfo_TransactionStatus.DiscardUnknown(m) 653 } 654 655 var xxx_messageInfo_TransactionStatus proto.InternalMessageInfo 656 657 func (m *TransactionStatus) GetPhases() TransactionPhases { 658 if m != nil { 659 return m.Phases 660 } 661 return TransactionPhases{} 662 } 663 664 func (m *TransactionStatus) GetProposals() []ProposalID { 665 if m != nil { 666 return m.Proposals 667 } 668 return nil 669 } 670 671 func (m *TransactionStatus) GetState() TransactionStatus_State { 672 if m != nil { 673 return m.State 674 } 675 return TransactionStatus_PENDING 676 } 677 678 func (m *TransactionStatus) GetFailure() *Failure { 679 if m != nil { 680 return m.Failure 681 } 682 return nil 683 } 684 685 type TransactionPhases struct { 686 // 'initialize' is the transaction initialization phase status 687 Initialize *TransactionInitializePhase `protobuf:"bytes,1,opt,name=initialize,proto3" json:"initialize,omitempty"` 688 // 'validate' is the transaction validation phase status 689 Validate *TransactionValidatePhase `protobuf:"bytes,2,opt,name=validate,proto3" json:"validate,omitempty"` 690 // 'commit' is the transaction commit phase status 691 Commit *TransactionCommitPhase `protobuf:"bytes,3,opt,name=commit,proto3" json:"commit,omitempty"` 692 // 'apply' is the transaction apply phase status 693 Apply *TransactionApplyPhase `protobuf:"bytes,4,opt,name=apply,proto3" json:"apply,omitempty"` 694 // 'abort' is the transaction abort phase status 695 Abort *TransactionAbortPhase `protobuf:"bytes,5,opt,name=abort,proto3" json:"abort,omitempty"` 696 } 697 698 func (m *TransactionPhases) Reset() { *m = TransactionPhases{} } 699 func (m *TransactionPhases) String() string { return proto.CompactTextString(m) } 700 func (*TransactionPhases) ProtoMessage() {} 701 func (*TransactionPhases) Descriptor() ([]byte, []int) { 702 return fileDescriptor_c3a2d73bdadccc35, []int{6} 703 } 704 func (m *TransactionPhases) XXX_Unmarshal(b []byte) error { 705 return m.Unmarshal(b) 706 } 707 func (m *TransactionPhases) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 708 if deterministic { 709 return xxx_messageInfo_TransactionPhases.Marshal(b, m, deterministic) 710 } else { 711 b = b[:cap(b)] 712 n, err := m.MarshalToSizedBuffer(b) 713 if err != nil { 714 return nil, err 715 } 716 return b[:n], nil 717 } 718 } 719 func (m *TransactionPhases) XXX_Merge(src proto.Message) { 720 xxx_messageInfo_TransactionPhases.Merge(m, src) 721 } 722 func (m *TransactionPhases) XXX_Size() int { 723 return m.Size() 724 } 725 func (m *TransactionPhases) XXX_DiscardUnknown() { 726 xxx_messageInfo_TransactionPhases.DiscardUnknown(m) 727 } 728 729 var xxx_messageInfo_TransactionPhases proto.InternalMessageInfo 730 731 func (m *TransactionPhases) GetInitialize() *TransactionInitializePhase { 732 if m != nil { 733 return m.Initialize 734 } 735 return nil 736 } 737 738 func (m *TransactionPhases) GetValidate() *TransactionValidatePhase { 739 if m != nil { 740 return m.Validate 741 } 742 return nil 743 } 744 745 func (m *TransactionPhases) GetCommit() *TransactionCommitPhase { 746 if m != nil { 747 return m.Commit 748 } 749 return nil 750 } 751 752 func (m *TransactionPhases) GetApply() *TransactionApplyPhase { 753 if m != nil { 754 return m.Apply 755 } 756 return nil 757 } 758 759 func (m *TransactionPhases) GetAbort() *TransactionAbortPhase { 760 if m != nil { 761 return m.Abort 762 } 763 return nil 764 } 765 766 type TransactionPhaseStatus struct { 767 Start *time.Time `protobuf:"bytes,1,opt,name=start,proto3,stdtime" json:"start,omitempty"` 768 End *time.Time `protobuf:"bytes,2,opt,name=end,proto3,stdtime" json:"end,omitempty"` 769 } 770 771 func (m *TransactionPhaseStatus) Reset() { *m = TransactionPhaseStatus{} } 772 func (m *TransactionPhaseStatus) String() string { return proto.CompactTextString(m) } 773 func (*TransactionPhaseStatus) ProtoMessage() {} 774 func (*TransactionPhaseStatus) Descriptor() ([]byte, []int) { 775 return fileDescriptor_c3a2d73bdadccc35, []int{7} 776 } 777 func (m *TransactionPhaseStatus) XXX_Unmarshal(b []byte) error { 778 return m.Unmarshal(b) 779 } 780 func (m *TransactionPhaseStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 781 if deterministic { 782 return xxx_messageInfo_TransactionPhaseStatus.Marshal(b, m, deterministic) 783 } else { 784 b = b[:cap(b)] 785 n, err := m.MarshalToSizedBuffer(b) 786 if err != nil { 787 return nil, err 788 } 789 return b[:n], nil 790 } 791 } 792 func (m *TransactionPhaseStatus) XXX_Merge(src proto.Message) { 793 xxx_messageInfo_TransactionPhaseStatus.Merge(m, src) 794 } 795 func (m *TransactionPhaseStatus) XXX_Size() int { 796 return m.Size() 797 } 798 func (m *TransactionPhaseStatus) XXX_DiscardUnknown() { 799 xxx_messageInfo_TransactionPhaseStatus.DiscardUnknown(m) 800 } 801 802 var xxx_messageInfo_TransactionPhaseStatus proto.InternalMessageInfo 803 804 func (m *TransactionPhaseStatus) GetStart() *time.Time { 805 if m != nil { 806 return m.Start 807 } 808 return nil 809 } 810 811 func (m *TransactionPhaseStatus) GetEnd() *time.Time { 812 if m != nil { 813 return m.End 814 } 815 return nil 816 } 817 818 type TransactionInitializePhase struct { 819 TransactionPhaseStatus `protobuf:"bytes,1,opt,name=status,proto3,embedded=status" json:"status"` 820 State TransactionInitializePhase_State `protobuf:"varint,2,opt,name=state,proto3,enum=onos.config.v2.TransactionInitializePhase_State" json:"state,omitempty"` 821 Failure *Failure `protobuf:"bytes,3,opt,name=failure,proto3" json:"failure,omitempty"` 822 } 823 824 func (m *TransactionInitializePhase) Reset() { *m = TransactionInitializePhase{} } 825 func (m *TransactionInitializePhase) String() string { return proto.CompactTextString(m) } 826 func (*TransactionInitializePhase) ProtoMessage() {} 827 func (*TransactionInitializePhase) Descriptor() ([]byte, []int) { 828 return fileDescriptor_c3a2d73bdadccc35, []int{8} 829 } 830 func (m *TransactionInitializePhase) XXX_Unmarshal(b []byte) error { 831 return m.Unmarshal(b) 832 } 833 func (m *TransactionInitializePhase) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 834 if deterministic { 835 return xxx_messageInfo_TransactionInitializePhase.Marshal(b, m, deterministic) 836 } else { 837 b = b[:cap(b)] 838 n, err := m.MarshalToSizedBuffer(b) 839 if err != nil { 840 return nil, err 841 } 842 return b[:n], nil 843 } 844 } 845 func (m *TransactionInitializePhase) XXX_Merge(src proto.Message) { 846 xxx_messageInfo_TransactionInitializePhase.Merge(m, src) 847 } 848 func (m *TransactionInitializePhase) XXX_Size() int { 849 return m.Size() 850 } 851 func (m *TransactionInitializePhase) XXX_DiscardUnknown() { 852 xxx_messageInfo_TransactionInitializePhase.DiscardUnknown(m) 853 } 854 855 var xxx_messageInfo_TransactionInitializePhase proto.InternalMessageInfo 856 857 func (m *TransactionInitializePhase) GetState() TransactionInitializePhase_State { 858 if m != nil { 859 return m.State 860 } 861 return TransactionInitializePhase_INITIALIZING 862 } 863 864 func (m *TransactionInitializePhase) GetFailure() *Failure { 865 if m != nil { 866 return m.Failure 867 } 868 return nil 869 } 870 871 type TransactionValidatePhase struct { 872 TransactionPhaseStatus `protobuf:"bytes,1,opt,name=status,proto3,embedded=status" json:"status"` 873 State TransactionValidatePhase_State `protobuf:"varint,2,opt,name=state,proto3,enum=onos.config.v2.TransactionValidatePhase_State" json:"state,omitempty"` 874 Failure *Failure `protobuf:"bytes,3,opt,name=failure,proto3" json:"failure,omitempty"` 875 } 876 877 func (m *TransactionValidatePhase) Reset() { *m = TransactionValidatePhase{} } 878 func (m *TransactionValidatePhase) String() string { return proto.CompactTextString(m) } 879 func (*TransactionValidatePhase) ProtoMessage() {} 880 func (*TransactionValidatePhase) Descriptor() ([]byte, []int) { 881 return fileDescriptor_c3a2d73bdadccc35, []int{9} 882 } 883 func (m *TransactionValidatePhase) XXX_Unmarshal(b []byte) error { 884 return m.Unmarshal(b) 885 } 886 func (m *TransactionValidatePhase) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 887 if deterministic { 888 return xxx_messageInfo_TransactionValidatePhase.Marshal(b, m, deterministic) 889 } else { 890 b = b[:cap(b)] 891 n, err := m.MarshalToSizedBuffer(b) 892 if err != nil { 893 return nil, err 894 } 895 return b[:n], nil 896 } 897 } 898 func (m *TransactionValidatePhase) XXX_Merge(src proto.Message) { 899 xxx_messageInfo_TransactionValidatePhase.Merge(m, src) 900 } 901 func (m *TransactionValidatePhase) XXX_Size() int { 902 return m.Size() 903 } 904 func (m *TransactionValidatePhase) XXX_DiscardUnknown() { 905 xxx_messageInfo_TransactionValidatePhase.DiscardUnknown(m) 906 } 907 908 var xxx_messageInfo_TransactionValidatePhase proto.InternalMessageInfo 909 910 func (m *TransactionValidatePhase) GetState() TransactionValidatePhase_State { 911 if m != nil { 912 return m.State 913 } 914 return TransactionValidatePhase_VALIDATING 915 } 916 917 func (m *TransactionValidatePhase) GetFailure() *Failure { 918 if m != nil { 919 return m.Failure 920 } 921 return nil 922 } 923 924 type TransactionCommitPhase struct { 925 TransactionPhaseStatus `protobuf:"bytes,1,opt,name=status,proto3,embedded=status" json:"status"` 926 State TransactionCommitPhase_State `protobuf:"varint,2,opt,name=state,proto3,enum=onos.config.v2.TransactionCommitPhase_State" json:"state,omitempty"` 927 } 928 929 func (m *TransactionCommitPhase) Reset() { *m = TransactionCommitPhase{} } 930 func (m *TransactionCommitPhase) String() string { return proto.CompactTextString(m) } 931 func (*TransactionCommitPhase) ProtoMessage() {} 932 func (*TransactionCommitPhase) Descriptor() ([]byte, []int) { 933 return fileDescriptor_c3a2d73bdadccc35, []int{10} 934 } 935 func (m *TransactionCommitPhase) XXX_Unmarshal(b []byte) error { 936 return m.Unmarshal(b) 937 } 938 func (m *TransactionCommitPhase) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 939 if deterministic { 940 return xxx_messageInfo_TransactionCommitPhase.Marshal(b, m, deterministic) 941 } else { 942 b = b[:cap(b)] 943 n, err := m.MarshalToSizedBuffer(b) 944 if err != nil { 945 return nil, err 946 } 947 return b[:n], nil 948 } 949 } 950 func (m *TransactionCommitPhase) XXX_Merge(src proto.Message) { 951 xxx_messageInfo_TransactionCommitPhase.Merge(m, src) 952 } 953 func (m *TransactionCommitPhase) XXX_Size() int { 954 return m.Size() 955 } 956 func (m *TransactionCommitPhase) XXX_DiscardUnknown() { 957 xxx_messageInfo_TransactionCommitPhase.DiscardUnknown(m) 958 } 959 960 var xxx_messageInfo_TransactionCommitPhase proto.InternalMessageInfo 961 962 func (m *TransactionCommitPhase) GetState() TransactionCommitPhase_State { 963 if m != nil { 964 return m.State 965 } 966 return TransactionCommitPhase_COMMITTING 967 } 968 969 type TransactionApplyPhase struct { 970 TransactionPhaseStatus `protobuf:"bytes,1,opt,name=status,proto3,embedded=status" json:"status"` 971 State TransactionApplyPhase_State `protobuf:"varint,2,opt,name=state,proto3,enum=onos.config.v2.TransactionApplyPhase_State" json:"state,omitempty"` 972 Failure *Failure `protobuf:"bytes,3,opt,name=failure,proto3" json:"failure,omitempty"` 973 } 974 975 func (m *TransactionApplyPhase) Reset() { *m = TransactionApplyPhase{} } 976 func (m *TransactionApplyPhase) String() string { return proto.CompactTextString(m) } 977 func (*TransactionApplyPhase) ProtoMessage() {} 978 func (*TransactionApplyPhase) Descriptor() ([]byte, []int) { 979 return fileDescriptor_c3a2d73bdadccc35, []int{11} 980 } 981 func (m *TransactionApplyPhase) XXX_Unmarshal(b []byte) error { 982 return m.Unmarshal(b) 983 } 984 func (m *TransactionApplyPhase) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 985 if deterministic { 986 return xxx_messageInfo_TransactionApplyPhase.Marshal(b, m, deterministic) 987 } else { 988 b = b[:cap(b)] 989 n, err := m.MarshalToSizedBuffer(b) 990 if err != nil { 991 return nil, err 992 } 993 return b[:n], nil 994 } 995 } 996 func (m *TransactionApplyPhase) XXX_Merge(src proto.Message) { 997 xxx_messageInfo_TransactionApplyPhase.Merge(m, src) 998 } 999 func (m *TransactionApplyPhase) XXX_Size() int { 1000 return m.Size() 1001 } 1002 func (m *TransactionApplyPhase) XXX_DiscardUnknown() { 1003 xxx_messageInfo_TransactionApplyPhase.DiscardUnknown(m) 1004 } 1005 1006 var xxx_messageInfo_TransactionApplyPhase proto.InternalMessageInfo 1007 1008 func (m *TransactionApplyPhase) GetState() TransactionApplyPhase_State { 1009 if m != nil { 1010 return m.State 1011 } 1012 return TransactionApplyPhase_APPLYING 1013 } 1014 1015 func (m *TransactionApplyPhase) GetFailure() *Failure { 1016 if m != nil { 1017 return m.Failure 1018 } 1019 return nil 1020 } 1021 1022 type TransactionAbortPhase struct { 1023 TransactionPhaseStatus `protobuf:"bytes,1,opt,name=status,proto3,embedded=status" json:"status"` 1024 State TransactionAbortPhase_State `protobuf:"varint,2,opt,name=state,proto3,enum=onos.config.v2.TransactionAbortPhase_State" json:"state,omitempty"` 1025 } 1026 1027 func (m *TransactionAbortPhase) Reset() { *m = TransactionAbortPhase{} } 1028 func (m *TransactionAbortPhase) String() string { return proto.CompactTextString(m) } 1029 func (*TransactionAbortPhase) ProtoMessage() {} 1030 func (*TransactionAbortPhase) Descriptor() ([]byte, []int) { 1031 return fileDescriptor_c3a2d73bdadccc35, []int{12} 1032 } 1033 func (m *TransactionAbortPhase) XXX_Unmarshal(b []byte) error { 1034 return m.Unmarshal(b) 1035 } 1036 func (m *TransactionAbortPhase) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 1037 if deterministic { 1038 return xxx_messageInfo_TransactionAbortPhase.Marshal(b, m, deterministic) 1039 } else { 1040 b = b[:cap(b)] 1041 n, err := m.MarshalToSizedBuffer(b) 1042 if err != nil { 1043 return nil, err 1044 } 1045 return b[:n], nil 1046 } 1047 } 1048 func (m *TransactionAbortPhase) XXX_Merge(src proto.Message) { 1049 xxx_messageInfo_TransactionAbortPhase.Merge(m, src) 1050 } 1051 func (m *TransactionAbortPhase) XXX_Size() int { 1052 return m.Size() 1053 } 1054 func (m *TransactionAbortPhase) XXX_DiscardUnknown() { 1055 xxx_messageInfo_TransactionAbortPhase.DiscardUnknown(m) 1056 } 1057 1058 var xxx_messageInfo_TransactionAbortPhase proto.InternalMessageInfo 1059 1060 func (m *TransactionAbortPhase) GetState() TransactionAbortPhase_State { 1061 if m != nil { 1062 return m.State 1063 } 1064 return TransactionAbortPhase_ABORTING 1065 } 1066 1067 // TransactionEvent transaction store event 1068 type TransactionEvent struct { 1069 Type TransactionEvent_EventType `protobuf:"varint,1,opt,name=type,proto3,enum=onos.config.v2.TransactionEvent_EventType" json:"type,omitempty"` 1070 Transaction Transaction `protobuf:"bytes,2,opt,name=transaction,proto3" json:"transaction"` 1071 } 1072 1073 func (m *TransactionEvent) Reset() { *m = TransactionEvent{} } 1074 func (m *TransactionEvent) String() string { return proto.CompactTextString(m) } 1075 func (*TransactionEvent) ProtoMessage() {} 1076 func (*TransactionEvent) Descriptor() ([]byte, []int) { 1077 return fileDescriptor_c3a2d73bdadccc35, []int{13} 1078 } 1079 func (m *TransactionEvent) XXX_Unmarshal(b []byte) error { 1080 return m.Unmarshal(b) 1081 } 1082 func (m *TransactionEvent) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 1083 if deterministic { 1084 return xxx_messageInfo_TransactionEvent.Marshal(b, m, deterministic) 1085 } else { 1086 b = b[:cap(b)] 1087 n, err := m.MarshalToSizedBuffer(b) 1088 if err != nil { 1089 return nil, err 1090 } 1091 return b[:n], nil 1092 } 1093 } 1094 func (m *TransactionEvent) XXX_Merge(src proto.Message) { 1095 xxx_messageInfo_TransactionEvent.Merge(m, src) 1096 } 1097 func (m *TransactionEvent) XXX_Size() int { 1098 return m.Size() 1099 } 1100 func (m *TransactionEvent) XXX_DiscardUnknown() { 1101 xxx_messageInfo_TransactionEvent.DiscardUnknown(m) 1102 } 1103 1104 var xxx_messageInfo_TransactionEvent proto.InternalMessageInfo 1105 1106 func (m *TransactionEvent) GetType() TransactionEvent_EventType { 1107 if m != nil { 1108 return m.Type 1109 } 1110 return TransactionEvent_UNKNOWN 1111 } 1112 1113 func (m *TransactionEvent) GetTransaction() Transaction { 1114 if m != nil { 1115 return m.Transaction 1116 } 1117 return Transaction{} 1118 } 1119 1120 // TargetVersionOverrides carries optional mappings of targets to their model type and version overrides. 1121 type TargetVersionOverrides struct { 1122 Overrides map[string]*TargetTypeVersion `protobuf:"bytes,1,rep,name=overrides,proto3" json:"overrides,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` 1123 } 1124 1125 func (m *TargetVersionOverrides) Reset() { *m = TargetVersionOverrides{} } 1126 func (m *TargetVersionOverrides) String() string { return proto.CompactTextString(m) } 1127 func (*TargetVersionOverrides) ProtoMessage() {} 1128 func (*TargetVersionOverrides) Descriptor() ([]byte, []int) { 1129 return fileDescriptor_c3a2d73bdadccc35, []int{14} 1130 } 1131 func (m *TargetVersionOverrides) XXX_Unmarshal(b []byte) error { 1132 return m.Unmarshal(b) 1133 } 1134 func (m *TargetVersionOverrides) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 1135 if deterministic { 1136 return xxx_messageInfo_TargetVersionOverrides.Marshal(b, m, deterministic) 1137 } else { 1138 b = b[:cap(b)] 1139 n, err := m.MarshalToSizedBuffer(b) 1140 if err != nil { 1141 return nil, err 1142 } 1143 return b[:n], nil 1144 } 1145 } 1146 func (m *TargetVersionOverrides) XXX_Merge(src proto.Message) { 1147 xxx_messageInfo_TargetVersionOverrides.Merge(m, src) 1148 } 1149 func (m *TargetVersionOverrides) XXX_Size() int { 1150 return m.Size() 1151 } 1152 func (m *TargetVersionOverrides) XXX_DiscardUnknown() { 1153 xxx_messageInfo_TargetVersionOverrides.DiscardUnknown(m) 1154 } 1155 1156 var xxx_messageInfo_TargetVersionOverrides proto.InternalMessageInfo 1157 1158 func (m *TargetVersionOverrides) GetOverrides() map[string]*TargetTypeVersion { 1159 if m != nil { 1160 return m.Overrides 1161 } 1162 return nil 1163 } 1164 1165 func init() { 1166 proto.RegisterEnum("onos.config.v2.TransactionStrategy_Synchronicity", TransactionStrategy_Synchronicity_name, TransactionStrategy_Synchronicity_value) 1167 proto.RegisterEnum("onos.config.v2.TransactionStrategy_Isolation", TransactionStrategy_Isolation_name, TransactionStrategy_Isolation_value) 1168 proto.RegisterEnum("onos.config.v2.TransactionStatus_State", TransactionStatus_State_name, TransactionStatus_State_value) 1169 proto.RegisterEnum("onos.config.v2.TransactionInitializePhase_State", TransactionInitializePhase_State_name, TransactionInitializePhase_State_value) 1170 proto.RegisterEnum("onos.config.v2.TransactionValidatePhase_State", TransactionValidatePhase_State_name, TransactionValidatePhase_State_value) 1171 proto.RegisterEnum("onos.config.v2.TransactionCommitPhase_State", TransactionCommitPhase_State_name, TransactionCommitPhase_State_value) 1172 proto.RegisterEnum("onos.config.v2.TransactionApplyPhase_State", TransactionApplyPhase_State_name, TransactionApplyPhase_State_value) 1173 proto.RegisterEnum("onos.config.v2.TransactionAbortPhase_State", TransactionAbortPhase_State_name, TransactionAbortPhase_State_value) 1174 proto.RegisterEnum("onos.config.v2.TransactionEvent_EventType", TransactionEvent_EventType_name, TransactionEvent_EventType_value) 1175 proto.RegisterType((*TransactionInfo)(nil), "onos.config.v2.TransactionInfo") 1176 proto.RegisterType((*Transaction)(nil), "onos.config.v2.Transaction") 1177 proto.RegisterType((*TransactionStrategy)(nil), "onos.config.v2.TransactionStrategy") 1178 proto.RegisterType((*ChangeTransaction)(nil), "onos.config.v2.ChangeTransaction") 1179 proto.RegisterMapType((map[TargetID]*PathValues)(nil), "onos.config.v2.ChangeTransaction.ValuesEntry") 1180 proto.RegisterType((*RollbackTransaction)(nil), "onos.config.v2.RollbackTransaction") 1181 proto.RegisterType((*TransactionStatus)(nil), "onos.config.v2.TransactionStatus") 1182 proto.RegisterType((*TransactionPhases)(nil), "onos.config.v2.TransactionPhases") 1183 proto.RegisterType((*TransactionPhaseStatus)(nil), "onos.config.v2.TransactionPhaseStatus") 1184 proto.RegisterType((*TransactionInitializePhase)(nil), "onos.config.v2.TransactionInitializePhase") 1185 proto.RegisterType((*TransactionValidatePhase)(nil), "onos.config.v2.TransactionValidatePhase") 1186 proto.RegisterType((*TransactionCommitPhase)(nil), "onos.config.v2.TransactionCommitPhase") 1187 proto.RegisterType((*TransactionApplyPhase)(nil), "onos.config.v2.TransactionApplyPhase") 1188 proto.RegisterType((*TransactionAbortPhase)(nil), "onos.config.v2.TransactionAbortPhase") 1189 proto.RegisterType((*TransactionEvent)(nil), "onos.config.v2.TransactionEvent") 1190 proto.RegisterType((*TargetVersionOverrides)(nil), "onos.config.v2.TargetVersionOverrides") 1191 proto.RegisterMapType((map[string]*TargetTypeVersion)(nil), "onos.config.v2.TargetVersionOverrides.OverridesEntry") 1192 } 1193 1194 func init() { proto.RegisterFile("onos/config/v2/transaction.proto", fileDescriptor_c3a2d73bdadccc35) } 1195 1196 var fileDescriptor_c3a2d73bdadccc35 = []byte{ 1197 // 1321 bytes of a gzipped FileDescriptorProto 1198 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x57, 0xdf, 0x6f, 0xdb, 0x54, 1199 0x14, 0x8e, 0x9d, 0x1f, 0x4d, 0x4e, 0xda, 0x2c, 0xbb, 0x03, 0x16, 0x65, 0xa8, 0xe9, 0x8c, 0xd8, 1200 0xaa, 0x31, 0xdc, 0x2d, 0x88, 0x31, 0x31, 0x31, 0x94, 0xd4, 0xee, 0x66, 0x96, 0x26, 0xd1, 0x4d, 1201 0xda, 0xa9, 0xf0, 0x30, 0xb9, 0xc9, 0x6d, 0x6a, 0x96, 0xda, 0x91, 0xed, 0x46, 0x84, 0x47, 0x84, 1202 0xc4, 0xeb, 0x78, 0x44, 0x3c, 0xf0, 0xa7, 0x20, 0xde, 0xf6, 0x84, 0xf6, 0xc8, 0x53, 0x87, 0x3a, 1203 0x89, 0x3f, 0x62, 0x4f, 0xe8, 0xde, 0x6b, 0x3b, 0x76, 0xea, 0xb5, 0x41, 0xab, 0xc4, 0x4b, 0x6b, 1204 0xfb, 0x7e, 0xdf, 0x77, 0xef, 0xf9, 0xee, 0x39, 0xe7, 0xde, 0xc0, 0x8a, 0x65, 0x5a, 0xce, 0x5a, 1205 0xcf, 0x32, 0xf7, 0x8c, 0xc1, 0xda, 0xb8, 0xba, 0xe6, 0xda, 0xba, 0xe9, 0xe8, 0x3d, 0xd7, 0xb0, 1206 0x4c, 0x79, 0x64, 0x5b, 0xae, 0x85, 0x0a, 0x14, 0x21, 0x73, 0x84, 0x3c, 0xae, 0x96, 0xdf, 0x19, 1207 0x58, 0x03, 0x8b, 0x0d, 0xad, 0xd1, 0x27, 0x8e, 0x2a, 0x5f, 0x99, 0xd1, 0xb1, 0x76, 0xbf, 0x25, 1208 0x3d, 0xd7, 0x1b, 0x2c, 0xcf, 0x0c, 0x8e, 0xf5, 0xe1, 0x21, 0xf1, 0xc6, 0xde, 0x9f, 0x19, 0xdb, 1209 0xd3, 0x8d, 0xe1, 0xa1, 0xed, 0x8f, 0x56, 0x06, 0x96, 0x35, 0x18, 0x92, 0x35, 0xf6, 0xb6, 0x7b, 1210 0xb8, 0xb7, 0xe6, 0x1a, 0x07, 0xc4, 0x71, 0xf5, 0x83, 0x11, 0x07, 0x48, 0xdf, 0xc0, 0x85, 0xee, 1211 0x74, 0xc9, 0x9a, 0xb9, 0x67, 0xa1, 0xeb, 0x20, 0x1a, 0xfd, 0x92, 0xb0, 0x22, 0xac, 0xe6, 0xea, 1212 0x97, 0x8f, 0x8f, 0x2a, 0xa2, 0xa6, 0xbc, 0x3e, 0xaa, 0x2c, 0x85, 0x61, 0x0a, 0x16, 0x8d, 0x3e, 1213 0xaa, 0x40, 0xda, 0x30, 0xfb, 0xe4, 0xbb, 0x92, 0xb8, 0x22, 0xac, 0xa6, 0xea, 0xb9, 0xd7, 0x47, 1214 0x95, 0xb4, 0x46, 0x3f, 0x60, 0xfe, 0x5d, 0xfa, 0x2d, 0x05, 0xf9, 0x10, 0x0d, 0xdd, 0x85, 0xd4, 1215 0x01, 0x71, 0x75, 0xa6, 0x9d, 0xaf, 0x96, 0xe5, 0xa8, 0x33, 0x72, 0x8b, 0xc5, 0xbc, 0x49, 0x5c, 1216 0xbd, 0x9e, 0x7d, 0x7e, 0x54, 0x49, 0xbc, 0x38, 0xaa, 0x08, 0x98, 0x31, 0xbc, 0x35, 0x89, 0xff, 1217 0x61, 0x4d, 0xc9, 0xf8, 0x35, 0xa1, 0x32, 0x64, 0x0f, 0x1d, 0x62, 0x9b, 0xfa, 0x01, 0x29, 0xa5, 1218 0xa8, 0x1e, 0x0e, 0xde, 0x91, 0x06, 0x59, 0xc7, 0xb5, 0x75, 0x97, 0x0c, 0x26, 0xa5, 0x34, 0x5b, 1219 0xe3, 0x07, 0xb3, 0x6b, 0x0c, 0xcd, 0xd8, 0xf1, 0xa0, 0xa1, 0xc5, 0x06, 0x74, 0x74, 0x0f, 0x32, 1220 0xbd, 0x7d, 0xdd, 0x1c, 0x90, 0x52, 0x86, 0x09, 0x5d, 0x9d, 0x15, 0x5a, 0x67, 0xa3, 0x21, 0xb9, 1221 0x87, 0x09, 0xec, 0x51, 0x50, 0x0d, 0xb2, 0xb6, 0x35, 0x1c, 0xee, 0xea, 0xbd, 0xa7, 0xa5, 0x85, 1222 0xf8, 0x75, 0x60, 0x6f, 0x3c, 0x2a, 0x10, 0xd0, 0xd0, 0x97, 0x90, 0x71, 0x5c, 0xdd, 0x3d, 0x74, 1223 0x4a, 0xd9, 0xf8, 0xf9, 0x23, 0x81, 0x50, 0x60, 0x3d, 0x45, 0xc3, 0xc0, 0x1e, 0x0d, 0xed, 0xc0, 1224 0xc5, 0x31, 0xb1, 0x1d, 0xc3, 0x32, 0x9f, 0x58, 0x63, 0x62, 0xdb, 0x46, 0x9f, 0x38, 0xa5, 0x1c, 1225 0xd3, 0xba, 0x76, 0x42, 0x4b, 0xb7, 0x07, 0xc4, 0xdd, 0xe6, 0xf0, 0x96, 0x8f, 0xae, 0xa7, 0x98, 1226 0x27, 0xc5, 0xf1, 0xec, 0xf7, 0x1c, 0x2c, 0xf4, 0x89, 0xab, 0x1b, 0x43, 0x47, 0xfa, 0x55, 0x84, 1227 0x4b, 0x31, 0x96, 0xa2, 0xc7, 0xb0, 0xe4, 0x4c, 0xcc, 0xde, 0xbe, 0x6d, 0x99, 0x46, 0xcf, 0x70, 1228 0x27, 0x2c, 0x65, 0x0a, 0xd5, 0xdb, 0x73, 0x6c, 0x87, 0xdc, 0x09, 0x13, 0x71, 0x54, 0x07, 0x3d, 1229 0x82, 0x9c, 0xe1, 0x58, 0x43, 0x9d, 0x32, 0x58, 0x3e, 0x15, 0xaa, 0x1f, 0xcf, 0x23, 0xaa, 0xf9, 1230 0x24, 0x3c, 0xe5, 0x4b, 0x55, 0x58, 0x8a, 0x4c, 0x86, 0x8a, 0xb0, 0x58, 0xeb, 0xec, 0x34, 0xd7, 1231 0x1f, 0xe2, 0x56, 0xb3, 0xb5, 0xd5, 0x29, 0x26, 0xd0, 0x05, 0xc8, 0x87, 0x3f, 0x08, 0xd2, 0x0d, 1232 0xc8, 0x05, 0x5a, 0x28, 0x0f, 0x0b, 0x8a, 0xba, 0x51, 0xdb, 0x6a, 0x74, 0x8b, 0x09, 0x4a, 0xee, 1233 0xa8, 0x58, 0xab, 0x35, 0xb4, 0xaf, 0x6b, 0xf5, 0x86, 0x5a, 0x14, 0xa4, 0xdf, 0x05, 0xb8, 0x78, 1234 0x22, 0x4f, 0x50, 0x07, 0x32, 0xac, 0x01, 0x38, 0x25, 0x61, 0x25, 0xb9, 0x9a, 0x3f, 0xb9, 0xfe, 1235 0x13, 0x14, 0x79, 0x9b, 0xe1, 0x55, 0xd3, 0xb5, 0x27, 0xf5, 0xc5, 0x1f, 0x5e, 0x56, 0xb2, 0x7c, 1236 0xc7, 0x34, 0x05, 0x7b, 0x52, 0xe5, 0x2d, 0xc8, 0x87, 0x40, 0xa8, 0x08, 0xc9, 0xa7, 0x84, 0xbb, 1237 0x9e, 0xc3, 0xf4, 0x11, 0xdd, 0x82, 0x34, 0x83, 0x32, 0xd3, 0x62, 0x8a, 0xb7, 0xad, 0xbb, 0xfb, 1238 0x5c, 0x01, 0x73, 0xe0, 0xe7, 0xe2, 0x5d, 0x41, 0x7a, 0x00, 0x97, 0x62, 0x32, 0x15, 0xdd, 0x82, 1239 0x82, 0x9f, 0xa9, 0x4f, 0x78, 0xb9, 0x0a, 0xb3, 0xe5, 0xba, 0xe4, 0x03, 0xd8, 0xab, 0xf4, 0x87, 1240 0x08, 0x17, 0x4f, 0xa4, 0x2c, 0xcd, 0xf2, 0xd1, 0xbe, 0xee, 0x30, 0x2b, 0xce, 0xca, 0xf2, 0x36, 1241 0x03, 0xfa, 0x59, 0xce, 0x69, 0xe8, 0x26, 0xe4, 0x46, 0xb6, 0x35, 0xb2, 0x1c, 0x7d, 0xe8, 0x94, 1242 0xc4, 0x95, 0xe4, 0x6a, 0xae, 0x5e, 0x78, 0x7d, 0x54, 0x81, 0xb6, 0xf7, 0x51, 0x53, 0xf0, 0x14, 1243 0x80, 0xbe, 0x80, 0x34, 0xad, 0x0e, 0xc2, 0x9a, 0x4b, 0xa1, 0x7a, 0xfd, 0xcc, 0x9a, 0x92, 0xe9, 1244 0x3f, 0x82, 0x39, 0x0b, 0xdd, 0x86, 0x05, 0xaf, 0x3b, 0xb3, 0xce, 0x93, 0xaf, 0x5e, 0x9e, 0x15, 1245 0xd8, 0xe0, 0xc3, 0xd8, 0xc7, 0x49, 0x8f, 0x20, 0xcd, 0x24, 0x68, 0xa6, 0xb4, 0xd5, 0xa6, 0xa2, 1246 0x35, 0x1f, 0x14, 0x13, 0x68, 0x09, 0x72, 0xdb, 0xb5, 0x86, 0xa6, 0xd4, 0xba, 0xaa, 0x52, 0x14, 1247 0xe8, 0xeb, 0x7a, 0x6b, 0x73, 0x53, 0xeb, 0xd2, 0x57, 0x91, 0x42, 0x6b, 0xed, 0x76, 0x43, 0x53, 1248 0x95, 0x62, 0x12, 0x01, 0x64, 0x36, 0x6a, 0x5a, 0x43, 0x55, 0x8a, 0x29, 0xe9, 0x65, 0xd4, 0x43, 1249 0x6e, 0x08, 0xfa, 0x0a, 0xc0, 0x30, 0x0d, 0xd7, 0xd0, 0x87, 0xc6, 0xf7, 0xc4, 0xf3, 0xf1, 0xc6, 1250 0x29, 0x91, 0x69, 0x01, 0x98, 0x09, 0xe0, 0x10, 0x1b, 0x29, 0x90, 0x1d, 0xeb, 0x43, 0xa3, 0x4f, 1251 0x3d, 0xe2, 0x79, 0xb2, 0x7a, 0x8a, 0xd2, 0xb6, 0x07, 0xe5, 0x3a, 0x01, 0x13, 0xdd, 0x87, 0x4c, 1252 0xcf, 0x3a, 0x38, 0x30, 0x5c, 0xe6, 0x73, 0x5c, 0xbf, 0x99, 0x6a, 0xac, 0x33, 0x20, 0x57, 0xf0, 1253 0x58, 0xe8, 0x1e, 0xa4, 0xf5, 0xd1, 0x68, 0x38, 0xf1, 0x5c, 0xfe, 0xf0, 0x14, 0x7a, 0x8d, 0xe2, 1254 0x38, 0x9b, 0x73, 0x18, 0x79, 0xd7, 0xb2, 0x5d, 0xef, 0x00, 0x38, 0x95, 0x4c, 0x71, 0x3e, 0x99, 1255 0x3e, 0x4b, 0x3f, 0x0a, 0xf0, 0xde, 0xac, 0xc3, 0x5e, 0xaa, 0xde, 0x61, 0xb9, 0x63, 0xbb, 0xc1, 1256 0xe1, 0xc7, 0x4f, 0x66, 0xd9, 0x3f, 0x99, 0xe5, 0xae, 0x7f, 0x32, 0xd7, 0x53, 0xcf, 0x5e, 0x56, 1257 0x04, 0xcc, 0xe1, 0xa8, 0x0a, 0x49, 0x62, 0xf6, 0x83, 0xaa, 0x3b, 0x8b, 0x45, 0xc1, 0xd2, 0x2f, 1258 0x22, 0x94, 0xdf, 0xbc, 0x63, 0xe8, 0x61, 0x70, 0x36, 0x08, 0x67, 0xfa, 0x1b, 0x0a, 0x21, 0x74, 1259 0xce, 0xf9, 0x87, 0xc4, 0x86, 0x5f, 0x10, 0xbc, 0x93, 0xde, 0x9a, 0x3f, 0x6d, 0xde, 0x58, 0x19, 1260 0xc9, 0x39, 0x2b, 0xe3, 0x8e, 0x5f, 0x19, 0x45, 0x58, 0xd4, 0x9a, 0x5a, 0x97, 0xf5, 0x4d, 0x5e, 1261 0x1e, 0x17, 0x20, 0x1f, 0x7c, 0x61, 0x05, 0x32, 0x2d, 0x02, 0x51, 0xfa, 0x59, 0x84, 0xd2, 0x9b, 1262 0x72, 0xf0, 0x1c, 0x9d, 0x51, 0xa2, 0xce, 0xc8, 0xf3, 0x96, 0xc1, 0x5b, 0xfb, 0x52, 0xf5, 0x7d, 1263 0x29, 0x00, 0x78, 0x4d, 0x22, 0xb6, 0x69, 0x84, 0x3d, 0xf9, 0x33, 0x9a, 0xb6, 0xa1, 0x9a, 0x3a, 1264 0x47, 0x47, 0xea, 0x51, 0x47, 0x6e, 0xce, 0x57, 0xd4, 0x11, 0x3f, 0xa4, 0x6b, 0xa1, 0xe0, 0xbc, 1265 0x96, 0x17, 0x04, 0x37, 0x6d, 0x81, 0x82, 0xf4, 0x93, 0x08, 0xef, 0xc6, 0x56, 0xf9, 0x39, 0xc6, 1266 0x53, 0x8b, 0xc6, 0xf3, 0xd1, 0x5c, 0x5d, 0xe6, 0xad, 0xb7, 0x57, 0xf6, 0x1d, 0x58, 0x84, 0x2c, 1267 0xed, 0xf2, 0x3b, 0x3c, 0xfe, 0x50, 0xcf, 0x8f, 0x6e, 0xed, 0x73, 0x21, 0xea, 0x44, 0xd0, 0xb2, 1268 0xfe, 0x27, 0x27, 0x82, 0xf9, 0xa3, 0x1b, 0x2b, 0x85, 0xc3, 0xaa, 0xb7, 0x70, 0x77, 0x1a, 0x16, 1269 0x7d, 0x63, 0x9b, 0xfa, 0x8f, 0x00, 0xc5, 0x90, 0x94, 0x3a, 0x26, 0xa6, 0x8b, 0xee, 0x43, 0xca, 1270 0x9d, 0x8c, 0x88, 0x77, 0x3f, 0x3c, 0xed, 0xdc, 0x62, 0x78, 0x99, 0xfd, 0xed, 0x4e, 0x46, 0x04, 1271 0x33, 0x1e, 0x5a, 0x87, 0x7c, 0xe8, 0x27, 0x9b, 0xd7, 0x66, 0xaf, 0x9c, 0x22, 0xe3, 0x5d, 0x20, 1272 0xc2, 0x2c, 0x69, 0x13, 0x72, 0x81, 0x2e, 0x5d, 0xf3, 0x56, 0xf3, 0x51, 0xb3, 0xf5, 0xb8, 0xc9, 1273 0x03, 0x58, 0xc7, 0xaa, 0x57, 0x72, 0x74, 0xa4, 0xcd, 0xeb, 0x4f, 0xe4, 0x57, 0xbf, 0x86, 0xda, 1274 0x65, 0xa7, 0xf4, 0x22, 0x64, 0xb1, 0xda, 0x6e, 0xd4, 0x76, 0xd8, 0x39, 0xcd, 0xca, 0x31, 0xf6, 1275 0x4a, 0x8d, 0x3a, 0x90, 0x9b, 0xde, 0xc6, 0xf9, 0xf5, 0xef, 0xd3, 0xf9, 0x6e, 0xe3, 0x72, 0xf0, 1276 0xc4, 0x6e, 0x78, 0x78, 0xaa, 0x53, 0x7e, 0x02, 0x85, 0xe8, 0x60, 0xcc, 0xf5, 0xef, 0xb3, 0xe8, 1277 0xf5, 0xef, 0x6a, 0xfc, 0xa4, 0xd4, 0x00, 0x6f, 0xe2, 0xd0, 0x2d, 0xb0, 0x5e, 0x7a, 0x7e, 0xbc, 1278 0x2c, 0xbc, 0x38, 0x5e, 0x16, 0xfe, 0x3e, 0x5e, 0x16, 0x9e, 0xbd, 0x5a, 0x4e, 0xbc, 0x78, 0xb5, 1279 0x9c, 0xf8, 0xeb, 0xd5, 0x72, 0x62, 0x37, 0xc3, 0x0e, 0xb2, 0x4f, 0xfe, 0x0d, 0x00, 0x00, 0xff, 1280 0xff, 0xaf, 0x84, 0xd2, 0x82, 0x47, 0x0f, 0x00, 0x00, 1281 } 1282 1283 func (m *TransactionInfo) Marshal() (dAtA []byte, err error) { 1284 size := m.Size() 1285 dAtA = make([]byte, size) 1286 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1287 if err != nil { 1288 return nil, err 1289 } 1290 return dAtA[:n], nil 1291 } 1292 1293 func (m *TransactionInfo) MarshalTo(dAtA []byte) (int, error) { 1294 size := m.Size() 1295 return m.MarshalToSizedBuffer(dAtA[:size]) 1296 } 1297 1298 func (m *TransactionInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1299 i := len(dAtA) 1300 _ = i 1301 var l int 1302 _ = l 1303 if m.Index != 0 { 1304 i = encodeVarintTransaction(dAtA, i, uint64(m.Index)) 1305 i-- 1306 dAtA[i] = 0x10 1307 } 1308 if len(m.ID) > 0 { 1309 i -= len(m.ID) 1310 copy(dAtA[i:], m.ID) 1311 i = encodeVarintTransaction(dAtA, i, uint64(len(m.ID))) 1312 i-- 1313 dAtA[i] = 0xa 1314 } 1315 return len(dAtA) - i, nil 1316 } 1317 1318 func (m *Transaction) Marshal() (dAtA []byte, err error) { 1319 size := m.Size() 1320 dAtA = make([]byte, size) 1321 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1322 if err != nil { 1323 return nil, err 1324 } 1325 return dAtA[:n], nil 1326 } 1327 1328 func (m *Transaction) MarshalTo(dAtA []byte) (int, error) { 1329 size := m.Size() 1330 return m.MarshalToSizedBuffer(dAtA[:size]) 1331 } 1332 1333 func (m *Transaction) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1334 i := len(dAtA) 1335 _ = i 1336 var l int 1337 _ = l 1338 if m.TargetVersionOverrides != nil { 1339 { 1340 size, err := m.TargetVersionOverrides.MarshalToSizedBuffer(dAtA[:i]) 1341 if err != nil { 1342 return 0, err 1343 } 1344 i -= size 1345 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1346 } 1347 i-- 1348 dAtA[i] = 0x4a 1349 } 1350 { 1351 size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) 1352 if err != nil { 1353 return 0, err 1354 } 1355 i -= size 1356 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1357 } 1358 i-- 1359 dAtA[i] = 0x42 1360 if m.Details != nil { 1361 { 1362 size := m.Details.Size() 1363 i -= size 1364 if _, err := m.Details.MarshalTo(dAtA[i:]); err != nil { 1365 return 0, err 1366 } 1367 } 1368 } 1369 { 1370 size, err := m.TransactionStrategy.MarshalToSizedBuffer(dAtA[:i]) 1371 if err != nil { 1372 return 0, err 1373 } 1374 i -= size 1375 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1376 } 1377 i-- 1378 dAtA[i] = 0x2a 1379 if len(m.Username) > 0 { 1380 i -= len(m.Username) 1381 copy(dAtA[i:], m.Username) 1382 i = encodeVarintTransaction(dAtA, i, uint64(len(m.Username))) 1383 i-- 1384 dAtA[i] = 0x22 1385 } 1386 if m.Index != 0 { 1387 i = encodeVarintTransaction(dAtA, i, uint64(m.Index)) 1388 i-- 1389 dAtA[i] = 0x18 1390 } 1391 if len(m.ID) > 0 { 1392 i -= len(m.ID) 1393 copy(dAtA[i:], m.ID) 1394 i = encodeVarintTransaction(dAtA, i, uint64(len(m.ID))) 1395 i-- 1396 dAtA[i] = 0x12 1397 } 1398 { 1399 size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) 1400 if err != nil { 1401 return 0, err 1402 } 1403 i -= size 1404 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1405 } 1406 i-- 1407 dAtA[i] = 0xa 1408 return len(dAtA) - i, nil 1409 } 1410 1411 func (m *Transaction_Change) MarshalTo(dAtA []byte) (int, error) { 1412 size := m.Size() 1413 return m.MarshalToSizedBuffer(dAtA[:size]) 1414 } 1415 1416 func (m *Transaction_Change) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1417 i := len(dAtA) 1418 if m.Change != nil { 1419 { 1420 size, err := m.Change.MarshalToSizedBuffer(dAtA[:i]) 1421 if err != nil { 1422 return 0, err 1423 } 1424 i -= size 1425 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1426 } 1427 i-- 1428 dAtA[i] = 0x32 1429 } 1430 return len(dAtA) - i, nil 1431 } 1432 func (m *Transaction_Rollback) MarshalTo(dAtA []byte) (int, error) { 1433 size := m.Size() 1434 return m.MarshalToSizedBuffer(dAtA[:size]) 1435 } 1436 1437 func (m *Transaction_Rollback) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1438 i := len(dAtA) 1439 if m.Rollback != nil { 1440 { 1441 size, err := m.Rollback.MarshalToSizedBuffer(dAtA[:i]) 1442 if err != nil { 1443 return 0, err 1444 } 1445 i -= size 1446 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1447 } 1448 i-- 1449 dAtA[i] = 0x3a 1450 } 1451 return len(dAtA) - i, nil 1452 } 1453 func (m *TransactionStrategy) Marshal() (dAtA []byte, err error) { 1454 size := m.Size() 1455 dAtA = make([]byte, size) 1456 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1457 if err != nil { 1458 return nil, err 1459 } 1460 return dAtA[:n], nil 1461 } 1462 1463 func (m *TransactionStrategy) MarshalTo(dAtA []byte) (int, error) { 1464 size := m.Size() 1465 return m.MarshalToSizedBuffer(dAtA[:size]) 1466 } 1467 1468 func (m *TransactionStrategy) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1469 i := len(dAtA) 1470 _ = i 1471 var l int 1472 _ = l 1473 if m.Isolation != 0 { 1474 i = encodeVarintTransaction(dAtA, i, uint64(m.Isolation)) 1475 i-- 1476 dAtA[i] = 0x10 1477 } 1478 if m.Synchronicity != 0 { 1479 i = encodeVarintTransaction(dAtA, i, uint64(m.Synchronicity)) 1480 i-- 1481 dAtA[i] = 0x8 1482 } 1483 return len(dAtA) - i, nil 1484 } 1485 1486 func (m *ChangeTransaction) Marshal() (dAtA []byte, err error) { 1487 size := m.Size() 1488 dAtA = make([]byte, size) 1489 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1490 if err != nil { 1491 return nil, err 1492 } 1493 return dAtA[:n], nil 1494 } 1495 1496 func (m *ChangeTransaction) MarshalTo(dAtA []byte) (int, error) { 1497 size := m.Size() 1498 return m.MarshalToSizedBuffer(dAtA[:size]) 1499 } 1500 1501 func (m *ChangeTransaction) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1502 i := len(dAtA) 1503 _ = i 1504 var l int 1505 _ = l 1506 if len(m.Values) > 0 { 1507 for k := range m.Values { 1508 v := m.Values[k] 1509 baseI := i 1510 if v != nil { 1511 { 1512 size, err := v.MarshalToSizedBuffer(dAtA[:i]) 1513 if err != nil { 1514 return 0, err 1515 } 1516 i -= size 1517 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1518 } 1519 i-- 1520 dAtA[i] = 0x12 1521 } 1522 i -= len(k) 1523 copy(dAtA[i:], k) 1524 i = encodeVarintTransaction(dAtA, i, uint64(len(k))) 1525 i-- 1526 dAtA[i] = 0xa 1527 i = encodeVarintTransaction(dAtA, i, uint64(baseI-i)) 1528 i-- 1529 dAtA[i] = 0xa 1530 } 1531 } 1532 return len(dAtA) - i, nil 1533 } 1534 1535 func (m *RollbackTransaction) Marshal() (dAtA []byte, err error) { 1536 size := m.Size() 1537 dAtA = make([]byte, size) 1538 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1539 if err != nil { 1540 return nil, err 1541 } 1542 return dAtA[:n], nil 1543 } 1544 1545 func (m *RollbackTransaction) MarshalTo(dAtA []byte) (int, error) { 1546 size := m.Size() 1547 return m.MarshalToSizedBuffer(dAtA[:size]) 1548 } 1549 1550 func (m *RollbackTransaction) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1551 i := len(dAtA) 1552 _ = i 1553 var l int 1554 _ = l 1555 if m.RollbackIndex != 0 { 1556 i = encodeVarintTransaction(dAtA, i, uint64(m.RollbackIndex)) 1557 i-- 1558 dAtA[i] = 0x8 1559 } 1560 return len(dAtA) - i, nil 1561 } 1562 1563 func (m *TransactionStatus) Marshal() (dAtA []byte, err error) { 1564 size := m.Size() 1565 dAtA = make([]byte, size) 1566 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1567 if err != nil { 1568 return nil, err 1569 } 1570 return dAtA[:n], nil 1571 } 1572 1573 func (m *TransactionStatus) MarshalTo(dAtA []byte) (int, error) { 1574 size := m.Size() 1575 return m.MarshalToSizedBuffer(dAtA[:size]) 1576 } 1577 1578 func (m *TransactionStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1579 i := len(dAtA) 1580 _ = i 1581 var l int 1582 _ = l 1583 if m.Failure != nil { 1584 { 1585 size, err := m.Failure.MarshalToSizedBuffer(dAtA[:i]) 1586 if err != nil { 1587 return 0, err 1588 } 1589 i -= size 1590 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1591 } 1592 i-- 1593 dAtA[i] = 0x22 1594 } 1595 if m.State != 0 { 1596 i = encodeVarintTransaction(dAtA, i, uint64(m.State)) 1597 i-- 1598 dAtA[i] = 0x18 1599 } 1600 if len(m.Proposals) > 0 { 1601 for iNdEx := len(m.Proposals) - 1; iNdEx >= 0; iNdEx-- { 1602 i -= len(m.Proposals[iNdEx]) 1603 copy(dAtA[i:], m.Proposals[iNdEx]) 1604 i = encodeVarintTransaction(dAtA, i, uint64(len(m.Proposals[iNdEx]))) 1605 i-- 1606 dAtA[i] = 0x12 1607 } 1608 } 1609 { 1610 size, err := m.Phases.MarshalToSizedBuffer(dAtA[:i]) 1611 if err != nil { 1612 return 0, err 1613 } 1614 i -= size 1615 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1616 } 1617 i-- 1618 dAtA[i] = 0xa 1619 return len(dAtA) - i, nil 1620 } 1621 1622 func (m *TransactionPhases) Marshal() (dAtA []byte, err error) { 1623 size := m.Size() 1624 dAtA = make([]byte, size) 1625 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1626 if err != nil { 1627 return nil, err 1628 } 1629 return dAtA[:n], nil 1630 } 1631 1632 func (m *TransactionPhases) MarshalTo(dAtA []byte) (int, error) { 1633 size := m.Size() 1634 return m.MarshalToSizedBuffer(dAtA[:size]) 1635 } 1636 1637 func (m *TransactionPhases) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1638 i := len(dAtA) 1639 _ = i 1640 var l int 1641 _ = l 1642 if m.Abort != nil { 1643 { 1644 size, err := m.Abort.MarshalToSizedBuffer(dAtA[:i]) 1645 if err != nil { 1646 return 0, err 1647 } 1648 i -= size 1649 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1650 } 1651 i-- 1652 dAtA[i] = 0x2a 1653 } 1654 if m.Apply != nil { 1655 { 1656 size, err := m.Apply.MarshalToSizedBuffer(dAtA[:i]) 1657 if err != nil { 1658 return 0, err 1659 } 1660 i -= size 1661 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1662 } 1663 i-- 1664 dAtA[i] = 0x22 1665 } 1666 if m.Commit != nil { 1667 { 1668 size, err := m.Commit.MarshalToSizedBuffer(dAtA[:i]) 1669 if err != nil { 1670 return 0, err 1671 } 1672 i -= size 1673 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1674 } 1675 i-- 1676 dAtA[i] = 0x1a 1677 } 1678 if m.Validate != nil { 1679 { 1680 size, err := m.Validate.MarshalToSizedBuffer(dAtA[:i]) 1681 if err != nil { 1682 return 0, err 1683 } 1684 i -= size 1685 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1686 } 1687 i-- 1688 dAtA[i] = 0x12 1689 } 1690 if m.Initialize != nil { 1691 { 1692 size, err := m.Initialize.MarshalToSizedBuffer(dAtA[:i]) 1693 if err != nil { 1694 return 0, err 1695 } 1696 i -= size 1697 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1698 } 1699 i-- 1700 dAtA[i] = 0xa 1701 } 1702 return len(dAtA) - i, nil 1703 } 1704 1705 func (m *TransactionPhaseStatus) Marshal() (dAtA []byte, err error) { 1706 size := m.Size() 1707 dAtA = make([]byte, size) 1708 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1709 if err != nil { 1710 return nil, err 1711 } 1712 return dAtA[:n], nil 1713 } 1714 1715 func (m *TransactionPhaseStatus) MarshalTo(dAtA []byte) (int, error) { 1716 size := m.Size() 1717 return m.MarshalToSizedBuffer(dAtA[:size]) 1718 } 1719 1720 func (m *TransactionPhaseStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1721 i := len(dAtA) 1722 _ = i 1723 var l int 1724 _ = l 1725 if m.End != nil { 1726 n15, err15 := github_com_gogo_protobuf_types.StdTimeMarshalTo(*m.End, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(*m.End):]) 1727 if err15 != nil { 1728 return 0, err15 1729 } 1730 i -= n15 1731 i = encodeVarintTransaction(dAtA, i, uint64(n15)) 1732 i-- 1733 dAtA[i] = 0x12 1734 } 1735 if m.Start != nil { 1736 n16, err16 := github_com_gogo_protobuf_types.StdTimeMarshalTo(*m.Start, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(*m.Start):]) 1737 if err16 != nil { 1738 return 0, err16 1739 } 1740 i -= n16 1741 i = encodeVarintTransaction(dAtA, i, uint64(n16)) 1742 i-- 1743 dAtA[i] = 0xa 1744 } 1745 return len(dAtA) - i, nil 1746 } 1747 1748 func (m *TransactionInitializePhase) Marshal() (dAtA []byte, err error) { 1749 size := m.Size() 1750 dAtA = make([]byte, size) 1751 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1752 if err != nil { 1753 return nil, err 1754 } 1755 return dAtA[:n], nil 1756 } 1757 1758 func (m *TransactionInitializePhase) MarshalTo(dAtA []byte) (int, error) { 1759 size := m.Size() 1760 return m.MarshalToSizedBuffer(dAtA[:size]) 1761 } 1762 1763 func (m *TransactionInitializePhase) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1764 i := len(dAtA) 1765 _ = i 1766 var l int 1767 _ = l 1768 if m.Failure != nil { 1769 { 1770 size, err := m.Failure.MarshalToSizedBuffer(dAtA[:i]) 1771 if err != nil { 1772 return 0, err 1773 } 1774 i -= size 1775 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1776 } 1777 i-- 1778 dAtA[i] = 0x1a 1779 } 1780 if m.State != 0 { 1781 i = encodeVarintTransaction(dAtA, i, uint64(m.State)) 1782 i-- 1783 dAtA[i] = 0x10 1784 } 1785 { 1786 size, err := m.TransactionPhaseStatus.MarshalToSizedBuffer(dAtA[:i]) 1787 if err != nil { 1788 return 0, err 1789 } 1790 i -= size 1791 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1792 } 1793 i-- 1794 dAtA[i] = 0xa 1795 return len(dAtA) - i, nil 1796 } 1797 1798 func (m *TransactionValidatePhase) Marshal() (dAtA []byte, err error) { 1799 size := m.Size() 1800 dAtA = make([]byte, size) 1801 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1802 if err != nil { 1803 return nil, err 1804 } 1805 return dAtA[:n], nil 1806 } 1807 1808 func (m *TransactionValidatePhase) MarshalTo(dAtA []byte) (int, error) { 1809 size := m.Size() 1810 return m.MarshalToSizedBuffer(dAtA[:size]) 1811 } 1812 1813 func (m *TransactionValidatePhase) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1814 i := len(dAtA) 1815 _ = i 1816 var l int 1817 _ = l 1818 if m.Failure != nil { 1819 { 1820 size, err := m.Failure.MarshalToSizedBuffer(dAtA[:i]) 1821 if err != nil { 1822 return 0, err 1823 } 1824 i -= size 1825 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1826 } 1827 i-- 1828 dAtA[i] = 0x1a 1829 } 1830 if m.State != 0 { 1831 i = encodeVarintTransaction(dAtA, i, uint64(m.State)) 1832 i-- 1833 dAtA[i] = 0x10 1834 } 1835 { 1836 size, err := m.TransactionPhaseStatus.MarshalToSizedBuffer(dAtA[:i]) 1837 if err != nil { 1838 return 0, err 1839 } 1840 i -= size 1841 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1842 } 1843 i-- 1844 dAtA[i] = 0xa 1845 return len(dAtA) - i, nil 1846 } 1847 1848 func (m *TransactionCommitPhase) Marshal() (dAtA []byte, err error) { 1849 size := m.Size() 1850 dAtA = make([]byte, size) 1851 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1852 if err != nil { 1853 return nil, err 1854 } 1855 return dAtA[:n], nil 1856 } 1857 1858 func (m *TransactionCommitPhase) MarshalTo(dAtA []byte) (int, error) { 1859 size := m.Size() 1860 return m.MarshalToSizedBuffer(dAtA[:size]) 1861 } 1862 1863 func (m *TransactionCommitPhase) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1864 i := len(dAtA) 1865 _ = i 1866 var l int 1867 _ = l 1868 if m.State != 0 { 1869 i = encodeVarintTransaction(dAtA, i, uint64(m.State)) 1870 i-- 1871 dAtA[i] = 0x10 1872 } 1873 { 1874 size, err := m.TransactionPhaseStatus.MarshalToSizedBuffer(dAtA[:i]) 1875 if err != nil { 1876 return 0, err 1877 } 1878 i -= size 1879 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1880 } 1881 i-- 1882 dAtA[i] = 0xa 1883 return len(dAtA) - i, nil 1884 } 1885 1886 func (m *TransactionApplyPhase) Marshal() (dAtA []byte, err error) { 1887 size := m.Size() 1888 dAtA = make([]byte, size) 1889 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1890 if err != nil { 1891 return nil, err 1892 } 1893 return dAtA[:n], nil 1894 } 1895 1896 func (m *TransactionApplyPhase) MarshalTo(dAtA []byte) (int, error) { 1897 size := m.Size() 1898 return m.MarshalToSizedBuffer(dAtA[:size]) 1899 } 1900 1901 func (m *TransactionApplyPhase) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1902 i := len(dAtA) 1903 _ = i 1904 var l int 1905 _ = l 1906 if m.Failure != nil { 1907 { 1908 size, err := m.Failure.MarshalToSizedBuffer(dAtA[:i]) 1909 if err != nil { 1910 return 0, err 1911 } 1912 i -= size 1913 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1914 } 1915 i-- 1916 dAtA[i] = 0x1a 1917 } 1918 if m.State != 0 { 1919 i = encodeVarintTransaction(dAtA, i, uint64(m.State)) 1920 i-- 1921 dAtA[i] = 0x10 1922 } 1923 { 1924 size, err := m.TransactionPhaseStatus.MarshalToSizedBuffer(dAtA[:i]) 1925 if err != nil { 1926 return 0, err 1927 } 1928 i -= size 1929 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1930 } 1931 i-- 1932 dAtA[i] = 0xa 1933 return len(dAtA) - i, nil 1934 } 1935 1936 func (m *TransactionAbortPhase) Marshal() (dAtA []byte, err error) { 1937 size := m.Size() 1938 dAtA = make([]byte, size) 1939 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1940 if err != nil { 1941 return nil, err 1942 } 1943 return dAtA[:n], nil 1944 } 1945 1946 func (m *TransactionAbortPhase) MarshalTo(dAtA []byte) (int, error) { 1947 size := m.Size() 1948 return m.MarshalToSizedBuffer(dAtA[:size]) 1949 } 1950 1951 func (m *TransactionAbortPhase) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1952 i := len(dAtA) 1953 _ = i 1954 var l int 1955 _ = l 1956 if m.State != 0 { 1957 i = encodeVarintTransaction(dAtA, i, uint64(m.State)) 1958 i-- 1959 dAtA[i] = 0x10 1960 } 1961 { 1962 size, err := m.TransactionPhaseStatus.MarshalToSizedBuffer(dAtA[:i]) 1963 if err != nil { 1964 return 0, err 1965 } 1966 i -= size 1967 i = encodeVarintTransaction(dAtA, i, uint64(size)) 1968 } 1969 i-- 1970 dAtA[i] = 0xa 1971 return len(dAtA) - i, nil 1972 } 1973 1974 func (m *TransactionEvent) Marshal() (dAtA []byte, err error) { 1975 size := m.Size() 1976 dAtA = make([]byte, size) 1977 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 1978 if err != nil { 1979 return nil, err 1980 } 1981 return dAtA[:n], nil 1982 } 1983 1984 func (m *TransactionEvent) MarshalTo(dAtA []byte) (int, error) { 1985 size := m.Size() 1986 return m.MarshalToSizedBuffer(dAtA[:size]) 1987 } 1988 1989 func (m *TransactionEvent) MarshalToSizedBuffer(dAtA []byte) (int, error) { 1990 i := len(dAtA) 1991 _ = i 1992 var l int 1993 _ = l 1994 { 1995 size, err := m.Transaction.MarshalToSizedBuffer(dAtA[:i]) 1996 if err != nil { 1997 return 0, err 1998 } 1999 i -= size 2000 i = encodeVarintTransaction(dAtA, i, uint64(size)) 2001 } 2002 i-- 2003 dAtA[i] = 0x12 2004 if m.Type != 0 { 2005 i = encodeVarintTransaction(dAtA, i, uint64(m.Type)) 2006 i-- 2007 dAtA[i] = 0x8 2008 } 2009 return len(dAtA) - i, nil 2010 } 2011 2012 func (m *TargetVersionOverrides) Marshal() (dAtA []byte, err error) { 2013 size := m.Size() 2014 dAtA = make([]byte, size) 2015 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 2016 if err != nil { 2017 return nil, err 2018 } 2019 return dAtA[:n], nil 2020 } 2021 2022 func (m *TargetVersionOverrides) MarshalTo(dAtA []byte) (int, error) { 2023 size := m.Size() 2024 return m.MarshalToSizedBuffer(dAtA[:size]) 2025 } 2026 2027 func (m *TargetVersionOverrides) MarshalToSizedBuffer(dAtA []byte) (int, error) { 2028 i := len(dAtA) 2029 _ = i 2030 var l int 2031 _ = l 2032 if len(m.Overrides) > 0 { 2033 for k := range m.Overrides { 2034 v := m.Overrides[k] 2035 baseI := i 2036 if v != nil { 2037 { 2038 size, err := v.MarshalToSizedBuffer(dAtA[:i]) 2039 if err != nil { 2040 return 0, err 2041 } 2042 i -= size 2043 i = encodeVarintTransaction(dAtA, i, uint64(size)) 2044 } 2045 i-- 2046 dAtA[i] = 0x12 2047 } 2048 i -= len(k) 2049 copy(dAtA[i:], k) 2050 i = encodeVarintTransaction(dAtA, i, uint64(len(k))) 2051 i-- 2052 dAtA[i] = 0xa 2053 i = encodeVarintTransaction(dAtA, i, uint64(baseI-i)) 2054 i-- 2055 dAtA[i] = 0xa 2056 } 2057 } 2058 return len(dAtA) - i, nil 2059 } 2060 2061 func encodeVarintTransaction(dAtA []byte, offset int, v uint64) int { 2062 offset -= sovTransaction(v) 2063 base := offset 2064 for v >= 1<<7 { 2065 dAtA[offset] = uint8(v&0x7f | 0x80) 2066 v >>= 7 2067 offset++ 2068 } 2069 dAtA[offset] = uint8(v) 2070 return base 2071 } 2072 func (m *TransactionInfo) Size() (n int) { 2073 if m == nil { 2074 return 0 2075 } 2076 var l int 2077 _ = l 2078 l = len(m.ID) 2079 if l > 0 { 2080 n += 1 + l + sovTransaction(uint64(l)) 2081 } 2082 if m.Index != 0 { 2083 n += 1 + sovTransaction(uint64(m.Index)) 2084 } 2085 return n 2086 } 2087 2088 func (m *Transaction) Size() (n int) { 2089 if m == nil { 2090 return 0 2091 } 2092 var l int 2093 _ = l 2094 l = m.ObjectMeta.Size() 2095 n += 1 + l + sovTransaction(uint64(l)) 2096 l = len(m.ID) 2097 if l > 0 { 2098 n += 1 + l + sovTransaction(uint64(l)) 2099 } 2100 if m.Index != 0 { 2101 n += 1 + sovTransaction(uint64(m.Index)) 2102 } 2103 l = len(m.Username) 2104 if l > 0 { 2105 n += 1 + l + sovTransaction(uint64(l)) 2106 } 2107 l = m.TransactionStrategy.Size() 2108 n += 1 + l + sovTransaction(uint64(l)) 2109 if m.Details != nil { 2110 n += m.Details.Size() 2111 } 2112 l = m.Status.Size() 2113 n += 1 + l + sovTransaction(uint64(l)) 2114 if m.TargetVersionOverrides != nil { 2115 l = m.TargetVersionOverrides.Size() 2116 n += 1 + l + sovTransaction(uint64(l)) 2117 } 2118 return n 2119 } 2120 2121 func (m *Transaction_Change) Size() (n int) { 2122 if m == nil { 2123 return 0 2124 } 2125 var l int 2126 _ = l 2127 if m.Change != nil { 2128 l = m.Change.Size() 2129 n += 1 + l + sovTransaction(uint64(l)) 2130 } 2131 return n 2132 } 2133 func (m *Transaction_Rollback) Size() (n int) { 2134 if m == nil { 2135 return 0 2136 } 2137 var l int 2138 _ = l 2139 if m.Rollback != nil { 2140 l = m.Rollback.Size() 2141 n += 1 + l + sovTransaction(uint64(l)) 2142 } 2143 return n 2144 } 2145 func (m *TransactionStrategy) Size() (n int) { 2146 if m == nil { 2147 return 0 2148 } 2149 var l int 2150 _ = l 2151 if m.Synchronicity != 0 { 2152 n += 1 + sovTransaction(uint64(m.Synchronicity)) 2153 } 2154 if m.Isolation != 0 { 2155 n += 1 + sovTransaction(uint64(m.Isolation)) 2156 } 2157 return n 2158 } 2159 2160 func (m *ChangeTransaction) Size() (n int) { 2161 if m == nil { 2162 return 0 2163 } 2164 var l int 2165 _ = l 2166 if len(m.Values) > 0 { 2167 for k, v := range m.Values { 2168 _ = k 2169 _ = v 2170 l = 0 2171 if v != nil { 2172 l = v.Size() 2173 l += 1 + sovTransaction(uint64(l)) 2174 } 2175 mapEntrySize := 1 + len(k) + sovTransaction(uint64(len(k))) + l 2176 n += mapEntrySize + 1 + sovTransaction(uint64(mapEntrySize)) 2177 } 2178 } 2179 return n 2180 } 2181 2182 func (m *RollbackTransaction) Size() (n int) { 2183 if m == nil { 2184 return 0 2185 } 2186 var l int 2187 _ = l 2188 if m.RollbackIndex != 0 { 2189 n += 1 + sovTransaction(uint64(m.RollbackIndex)) 2190 } 2191 return n 2192 } 2193 2194 func (m *TransactionStatus) Size() (n int) { 2195 if m == nil { 2196 return 0 2197 } 2198 var l int 2199 _ = l 2200 l = m.Phases.Size() 2201 n += 1 + l + sovTransaction(uint64(l)) 2202 if len(m.Proposals) > 0 { 2203 for _, s := range m.Proposals { 2204 l = len(s) 2205 n += 1 + l + sovTransaction(uint64(l)) 2206 } 2207 } 2208 if m.State != 0 { 2209 n += 1 + sovTransaction(uint64(m.State)) 2210 } 2211 if m.Failure != nil { 2212 l = m.Failure.Size() 2213 n += 1 + l + sovTransaction(uint64(l)) 2214 } 2215 return n 2216 } 2217 2218 func (m *TransactionPhases) Size() (n int) { 2219 if m == nil { 2220 return 0 2221 } 2222 var l int 2223 _ = l 2224 if m.Initialize != nil { 2225 l = m.Initialize.Size() 2226 n += 1 + l + sovTransaction(uint64(l)) 2227 } 2228 if m.Validate != nil { 2229 l = m.Validate.Size() 2230 n += 1 + l + sovTransaction(uint64(l)) 2231 } 2232 if m.Commit != nil { 2233 l = m.Commit.Size() 2234 n += 1 + l + sovTransaction(uint64(l)) 2235 } 2236 if m.Apply != nil { 2237 l = m.Apply.Size() 2238 n += 1 + l + sovTransaction(uint64(l)) 2239 } 2240 if m.Abort != nil { 2241 l = m.Abort.Size() 2242 n += 1 + l + sovTransaction(uint64(l)) 2243 } 2244 return n 2245 } 2246 2247 func (m *TransactionPhaseStatus) Size() (n int) { 2248 if m == nil { 2249 return 0 2250 } 2251 var l int 2252 _ = l 2253 if m.Start != nil { 2254 l = github_com_gogo_protobuf_types.SizeOfStdTime(*m.Start) 2255 n += 1 + l + sovTransaction(uint64(l)) 2256 } 2257 if m.End != nil { 2258 l = github_com_gogo_protobuf_types.SizeOfStdTime(*m.End) 2259 n += 1 + l + sovTransaction(uint64(l)) 2260 } 2261 return n 2262 } 2263 2264 func (m *TransactionInitializePhase) Size() (n int) { 2265 if m == nil { 2266 return 0 2267 } 2268 var l int 2269 _ = l 2270 l = m.TransactionPhaseStatus.Size() 2271 n += 1 + l + sovTransaction(uint64(l)) 2272 if m.State != 0 { 2273 n += 1 + sovTransaction(uint64(m.State)) 2274 } 2275 if m.Failure != nil { 2276 l = m.Failure.Size() 2277 n += 1 + l + sovTransaction(uint64(l)) 2278 } 2279 return n 2280 } 2281 2282 func (m *TransactionValidatePhase) Size() (n int) { 2283 if m == nil { 2284 return 0 2285 } 2286 var l int 2287 _ = l 2288 l = m.TransactionPhaseStatus.Size() 2289 n += 1 + l + sovTransaction(uint64(l)) 2290 if m.State != 0 { 2291 n += 1 + sovTransaction(uint64(m.State)) 2292 } 2293 if m.Failure != nil { 2294 l = m.Failure.Size() 2295 n += 1 + l + sovTransaction(uint64(l)) 2296 } 2297 return n 2298 } 2299 2300 func (m *TransactionCommitPhase) Size() (n int) { 2301 if m == nil { 2302 return 0 2303 } 2304 var l int 2305 _ = l 2306 l = m.TransactionPhaseStatus.Size() 2307 n += 1 + l + sovTransaction(uint64(l)) 2308 if m.State != 0 { 2309 n += 1 + sovTransaction(uint64(m.State)) 2310 } 2311 return n 2312 } 2313 2314 func (m *TransactionApplyPhase) Size() (n int) { 2315 if m == nil { 2316 return 0 2317 } 2318 var l int 2319 _ = l 2320 l = m.TransactionPhaseStatus.Size() 2321 n += 1 + l + sovTransaction(uint64(l)) 2322 if m.State != 0 { 2323 n += 1 + sovTransaction(uint64(m.State)) 2324 } 2325 if m.Failure != nil { 2326 l = m.Failure.Size() 2327 n += 1 + l + sovTransaction(uint64(l)) 2328 } 2329 return n 2330 } 2331 2332 func (m *TransactionAbortPhase) Size() (n int) { 2333 if m == nil { 2334 return 0 2335 } 2336 var l int 2337 _ = l 2338 l = m.TransactionPhaseStatus.Size() 2339 n += 1 + l + sovTransaction(uint64(l)) 2340 if m.State != 0 { 2341 n += 1 + sovTransaction(uint64(m.State)) 2342 } 2343 return n 2344 } 2345 2346 func (m *TransactionEvent) Size() (n int) { 2347 if m == nil { 2348 return 0 2349 } 2350 var l int 2351 _ = l 2352 if m.Type != 0 { 2353 n += 1 + sovTransaction(uint64(m.Type)) 2354 } 2355 l = m.Transaction.Size() 2356 n += 1 + l + sovTransaction(uint64(l)) 2357 return n 2358 } 2359 2360 func (m *TargetVersionOverrides) Size() (n int) { 2361 if m == nil { 2362 return 0 2363 } 2364 var l int 2365 _ = l 2366 if len(m.Overrides) > 0 { 2367 for k, v := range m.Overrides { 2368 _ = k 2369 _ = v 2370 l = 0 2371 if v != nil { 2372 l = v.Size() 2373 l += 1 + sovTransaction(uint64(l)) 2374 } 2375 mapEntrySize := 1 + len(k) + sovTransaction(uint64(len(k))) + l 2376 n += mapEntrySize + 1 + sovTransaction(uint64(mapEntrySize)) 2377 } 2378 } 2379 return n 2380 } 2381 2382 func sovTransaction(x uint64) (n int) { 2383 return (math_bits.Len64(x|1) + 6) / 7 2384 } 2385 func sozTransaction(x uint64) (n int) { 2386 return sovTransaction(uint64((x << 1) ^ uint64((int64(x) >> 63)))) 2387 } 2388 func (m *TransactionInfo) Unmarshal(dAtA []byte) error { 2389 l := len(dAtA) 2390 iNdEx := 0 2391 for iNdEx < l { 2392 preIndex := iNdEx 2393 var wire uint64 2394 for shift := uint(0); ; shift += 7 { 2395 if shift >= 64 { 2396 return ErrIntOverflowTransaction 2397 } 2398 if iNdEx >= l { 2399 return io.ErrUnexpectedEOF 2400 } 2401 b := dAtA[iNdEx] 2402 iNdEx++ 2403 wire |= uint64(b&0x7F) << shift 2404 if b < 0x80 { 2405 break 2406 } 2407 } 2408 fieldNum := int32(wire >> 3) 2409 wireType := int(wire & 0x7) 2410 if wireType == 4 { 2411 return fmt.Errorf("proto: TransactionInfo: wiretype end group for non-group") 2412 } 2413 if fieldNum <= 0 { 2414 return fmt.Errorf("proto: TransactionInfo: illegal tag %d (wire type %d)", fieldNum, wire) 2415 } 2416 switch fieldNum { 2417 case 1: 2418 if wireType != 2 { 2419 return fmt.Errorf("proto: wrong wireType = %d for field ID", wireType) 2420 } 2421 var stringLen uint64 2422 for shift := uint(0); ; shift += 7 { 2423 if shift >= 64 { 2424 return ErrIntOverflowTransaction 2425 } 2426 if iNdEx >= l { 2427 return io.ErrUnexpectedEOF 2428 } 2429 b := dAtA[iNdEx] 2430 iNdEx++ 2431 stringLen |= uint64(b&0x7F) << shift 2432 if b < 0x80 { 2433 break 2434 } 2435 } 2436 intStringLen := int(stringLen) 2437 if intStringLen < 0 { 2438 return ErrInvalidLengthTransaction 2439 } 2440 postIndex := iNdEx + intStringLen 2441 if postIndex < 0 { 2442 return ErrInvalidLengthTransaction 2443 } 2444 if postIndex > l { 2445 return io.ErrUnexpectedEOF 2446 } 2447 m.ID = TransactionID(dAtA[iNdEx:postIndex]) 2448 iNdEx = postIndex 2449 case 2: 2450 if wireType != 0 { 2451 return fmt.Errorf("proto: wrong wireType = %d for field Index", wireType) 2452 } 2453 m.Index = 0 2454 for shift := uint(0); ; shift += 7 { 2455 if shift >= 64 { 2456 return ErrIntOverflowTransaction 2457 } 2458 if iNdEx >= l { 2459 return io.ErrUnexpectedEOF 2460 } 2461 b := dAtA[iNdEx] 2462 iNdEx++ 2463 m.Index |= Index(b&0x7F) << shift 2464 if b < 0x80 { 2465 break 2466 } 2467 } 2468 default: 2469 iNdEx = preIndex 2470 skippy, err := skipTransaction(dAtA[iNdEx:]) 2471 if err != nil { 2472 return err 2473 } 2474 if (skippy < 0) || (iNdEx+skippy) < 0 { 2475 return ErrInvalidLengthTransaction 2476 } 2477 if (iNdEx + skippy) > l { 2478 return io.ErrUnexpectedEOF 2479 } 2480 iNdEx += skippy 2481 } 2482 } 2483 2484 if iNdEx > l { 2485 return io.ErrUnexpectedEOF 2486 } 2487 return nil 2488 } 2489 func (m *Transaction) Unmarshal(dAtA []byte) error { 2490 l := len(dAtA) 2491 iNdEx := 0 2492 for iNdEx < l { 2493 preIndex := iNdEx 2494 var wire uint64 2495 for shift := uint(0); ; shift += 7 { 2496 if shift >= 64 { 2497 return ErrIntOverflowTransaction 2498 } 2499 if iNdEx >= l { 2500 return io.ErrUnexpectedEOF 2501 } 2502 b := dAtA[iNdEx] 2503 iNdEx++ 2504 wire |= uint64(b&0x7F) << shift 2505 if b < 0x80 { 2506 break 2507 } 2508 } 2509 fieldNum := int32(wire >> 3) 2510 wireType := int(wire & 0x7) 2511 if wireType == 4 { 2512 return fmt.Errorf("proto: Transaction: wiretype end group for non-group") 2513 } 2514 if fieldNum <= 0 { 2515 return fmt.Errorf("proto: Transaction: illegal tag %d (wire type %d)", fieldNum, wire) 2516 } 2517 switch fieldNum { 2518 case 1: 2519 if wireType != 2 { 2520 return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) 2521 } 2522 var msglen int 2523 for shift := uint(0); ; shift += 7 { 2524 if shift >= 64 { 2525 return ErrIntOverflowTransaction 2526 } 2527 if iNdEx >= l { 2528 return io.ErrUnexpectedEOF 2529 } 2530 b := dAtA[iNdEx] 2531 iNdEx++ 2532 msglen |= int(b&0x7F) << shift 2533 if b < 0x80 { 2534 break 2535 } 2536 } 2537 if msglen < 0 { 2538 return ErrInvalidLengthTransaction 2539 } 2540 postIndex := iNdEx + msglen 2541 if postIndex < 0 { 2542 return ErrInvalidLengthTransaction 2543 } 2544 if postIndex > l { 2545 return io.ErrUnexpectedEOF 2546 } 2547 if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 2548 return err 2549 } 2550 iNdEx = postIndex 2551 case 2: 2552 if wireType != 2 { 2553 return fmt.Errorf("proto: wrong wireType = %d for field ID", wireType) 2554 } 2555 var stringLen uint64 2556 for shift := uint(0); ; shift += 7 { 2557 if shift >= 64 { 2558 return ErrIntOverflowTransaction 2559 } 2560 if iNdEx >= l { 2561 return io.ErrUnexpectedEOF 2562 } 2563 b := dAtA[iNdEx] 2564 iNdEx++ 2565 stringLen |= uint64(b&0x7F) << shift 2566 if b < 0x80 { 2567 break 2568 } 2569 } 2570 intStringLen := int(stringLen) 2571 if intStringLen < 0 { 2572 return ErrInvalidLengthTransaction 2573 } 2574 postIndex := iNdEx + intStringLen 2575 if postIndex < 0 { 2576 return ErrInvalidLengthTransaction 2577 } 2578 if postIndex > l { 2579 return io.ErrUnexpectedEOF 2580 } 2581 m.ID = TransactionID(dAtA[iNdEx:postIndex]) 2582 iNdEx = postIndex 2583 case 3: 2584 if wireType != 0 { 2585 return fmt.Errorf("proto: wrong wireType = %d for field Index", wireType) 2586 } 2587 m.Index = 0 2588 for shift := uint(0); ; shift += 7 { 2589 if shift >= 64 { 2590 return ErrIntOverflowTransaction 2591 } 2592 if iNdEx >= l { 2593 return io.ErrUnexpectedEOF 2594 } 2595 b := dAtA[iNdEx] 2596 iNdEx++ 2597 m.Index |= Index(b&0x7F) << shift 2598 if b < 0x80 { 2599 break 2600 } 2601 } 2602 case 4: 2603 if wireType != 2 { 2604 return fmt.Errorf("proto: wrong wireType = %d for field Username", wireType) 2605 } 2606 var stringLen uint64 2607 for shift := uint(0); ; shift += 7 { 2608 if shift >= 64 { 2609 return ErrIntOverflowTransaction 2610 } 2611 if iNdEx >= l { 2612 return io.ErrUnexpectedEOF 2613 } 2614 b := dAtA[iNdEx] 2615 iNdEx++ 2616 stringLen |= uint64(b&0x7F) << shift 2617 if b < 0x80 { 2618 break 2619 } 2620 } 2621 intStringLen := int(stringLen) 2622 if intStringLen < 0 { 2623 return ErrInvalidLengthTransaction 2624 } 2625 postIndex := iNdEx + intStringLen 2626 if postIndex < 0 { 2627 return ErrInvalidLengthTransaction 2628 } 2629 if postIndex > l { 2630 return io.ErrUnexpectedEOF 2631 } 2632 m.Username = string(dAtA[iNdEx:postIndex]) 2633 iNdEx = postIndex 2634 case 5: 2635 if wireType != 2 { 2636 return fmt.Errorf("proto: wrong wireType = %d for field TransactionStrategy", wireType) 2637 } 2638 var msglen int 2639 for shift := uint(0); ; shift += 7 { 2640 if shift >= 64 { 2641 return ErrIntOverflowTransaction 2642 } 2643 if iNdEx >= l { 2644 return io.ErrUnexpectedEOF 2645 } 2646 b := dAtA[iNdEx] 2647 iNdEx++ 2648 msglen |= int(b&0x7F) << shift 2649 if b < 0x80 { 2650 break 2651 } 2652 } 2653 if msglen < 0 { 2654 return ErrInvalidLengthTransaction 2655 } 2656 postIndex := iNdEx + msglen 2657 if postIndex < 0 { 2658 return ErrInvalidLengthTransaction 2659 } 2660 if postIndex > l { 2661 return io.ErrUnexpectedEOF 2662 } 2663 if err := m.TransactionStrategy.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 2664 return err 2665 } 2666 iNdEx = postIndex 2667 case 6: 2668 if wireType != 2 { 2669 return fmt.Errorf("proto: wrong wireType = %d for field Change", wireType) 2670 } 2671 var msglen int 2672 for shift := uint(0); ; shift += 7 { 2673 if shift >= 64 { 2674 return ErrIntOverflowTransaction 2675 } 2676 if iNdEx >= l { 2677 return io.ErrUnexpectedEOF 2678 } 2679 b := dAtA[iNdEx] 2680 iNdEx++ 2681 msglen |= int(b&0x7F) << shift 2682 if b < 0x80 { 2683 break 2684 } 2685 } 2686 if msglen < 0 { 2687 return ErrInvalidLengthTransaction 2688 } 2689 postIndex := iNdEx + msglen 2690 if postIndex < 0 { 2691 return ErrInvalidLengthTransaction 2692 } 2693 if postIndex > l { 2694 return io.ErrUnexpectedEOF 2695 } 2696 v := &ChangeTransaction{} 2697 if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 2698 return err 2699 } 2700 m.Details = &Transaction_Change{v} 2701 iNdEx = postIndex 2702 case 7: 2703 if wireType != 2 { 2704 return fmt.Errorf("proto: wrong wireType = %d for field Rollback", wireType) 2705 } 2706 var msglen int 2707 for shift := uint(0); ; shift += 7 { 2708 if shift >= 64 { 2709 return ErrIntOverflowTransaction 2710 } 2711 if iNdEx >= l { 2712 return io.ErrUnexpectedEOF 2713 } 2714 b := dAtA[iNdEx] 2715 iNdEx++ 2716 msglen |= int(b&0x7F) << shift 2717 if b < 0x80 { 2718 break 2719 } 2720 } 2721 if msglen < 0 { 2722 return ErrInvalidLengthTransaction 2723 } 2724 postIndex := iNdEx + msglen 2725 if postIndex < 0 { 2726 return ErrInvalidLengthTransaction 2727 } 2728 if postIndex > l { 2729 return io.ErrUnexpectedEOF 2730 } 2731 v := &RollbackTransaction{} 2732 if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 2733 return err 2734 } 2735 m.Details = &Transaction_Rollback{v} 2736 iNdEx = postIndex 2737 case 8: 2738 if wireType != 2 { 2739 return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) 2740 } 2741 var msglen int 2742 for shift := uint(0); ; shift += 7 { 2743 if shift >= 64 { 2744 return ErrIntOverflowTransaction 2745 } 2746 if iNdEx >= l { 2747 return io.ErrUnexpectedEOF 2748 } 2749 b := dAtA[iNdEx] 2750 iNdEx++ 2751 msglen |= int(b&0x7F) << shift 2752 if b < 0x80 { 2753 break 2754 } 2755 } 2756 if msglen < 0 { 2757 return ErrInvalidLengthTransaction 2758 } 2759 postIndex := iNdEx + msglen 2760 if postIndex < 0 { 2761 return ErrInvalidLengthTransaction 2762 } 2763 if postIndex > l { 2764 return io.ErrUnexpectedEOF 2765 } 2766 if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 2767 return err 2768 } 2769 iNdEx = postIndex 2770 case 9: 2771 if wireType != 2 { 2772 return fmt.Errorf("proto: wrong wireType = %d for field TargetVersionOverrides", wireType) 2773 } 2774 var msglen int 2775 for shift := uint(0); ; shift += 7 { 2776 if shift >= 64 { 2777 return ErrIntOverflowTransaction 2778 } 2779 if iNdEx >= l { 2780 return io.ErrUnexpectedEOF 2781 } 2782 b := dAtA[iNdEx] 2783 iNdEx++ 2784 msglen |= int(b&0x7F) << shift 2785 if b < 0x80 { 2786 break 2787 } 2788 } 2789 if msglen < 0 { 2790 return ErrInvalidLengthTransaction 2791 } 2792 postIndex := iNdEx + msglen 2793 if postIndex < 0 { 2794 return ErrInvalidLengthTransaction 2795 } 2796 if postIndex > l { 2797 return io.ErrUnexpectedEOF 2798 } 2799 if m.TargetVersionOverrides == nil { 2800 m.TargetVersionOverrides = &TargetVersionOverrides{} 2801 } 2802 if err := m.TargetVersionOverrides.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 2803 return err 2804 } 2805 iNdEx = postIndex 2806 default: 2807 iNdEx = preIndex 2808 skippy, err := skipTransaction(dAtA[iNdEx:]) 2809 if err != nil { 2810 return err 2811 } 2812 if (skippy < 0) || (iNdEx+skippy) < 0 { 2813 return ErrInvalidLengthTransaction 2814 } 2815 if (iNdEx + skippy) > l { 2816 return io.ErrUnexpectedEOF 2817 } 2818 iNdEx += skippy 2819 } 2820 } 2821 2822 if iNdEx > l { 2823 return io.ErrUnexpectedEOF 2824 } 2825 return nil 2826 } 2827 func (m *TransactionStrategy) Unmarshal(dAtA []byte) error { 2828 l := len(dAtA) 2829 iNdEx := 0 2830 for iNdEx < l { 2831 preIndex := iNdEx 2832 var wire uint64 2833 for shift := uint(0); ; shift += 7 { 2834 if shift >= 64 { 2835 return ErrIntOverflowTransaction 2836 } 2837 if iNdEx >= l { 2838 return io.ErrUnexpectedEOF 2839 } 2840 b := dAtA[iNdEx] 2841 iNdEx++ 2842 wire |= uint64(b&0x7F) << shift 2843 if b < 0x80 { 2844 break 2845 } 2846 } 2847 fieldNum := int32(wire >> 3) 2848 wireType := int(wire & 0x7) 2849 if wireType == 4 { 2850 return fmt.Errorf("proto: TransactionStrategy: wiretype end group for non-group") 2851 } 2852 if fieldNum <= 0 { 2853 return fmt.Errorf("proto: TransactionStrategy: illegal tag %d (wire type %d)", fieldNum, wire) 2854 } 2855 switch fieldNum { 2856 case 1: 2857 if wireType != 0 { 2858 return fmt.Errorf("proto: wrong wireType = %d for field Synchronicity", wireType) 2859 } 2860 m.Synchronicity = 0 2861 for shift := uint(0); ; shift += 7 { 2862 if shift >= 64 { 2863 return ErrIntOverflowTransaction 2864 } 2865 if iNdEx >= l { 2866 return io.ErrUnexpectedEOF 2867 } 2868 b := dAtA[iNdEx] 2869 iNdEx++ 2870 m.Synchronicity |= TransactionStrategy_Synchronicity(b&0x7F) << shift 2871 if b < 0x80 { 2872 break 2873 } 2874 } 2875 case 2: 2876 if wireType != 0 { 2877 return fmt.Errorf("proto: wrong wireType = %d for field Isolation", wireType) 2878 } 2879 m.Isolation = 0 2880 for shift := uint(0); ; shift += 7 { 2881 if shift >= 64 { 2882 return ErrIntOverflowTransaction 2883 } 2884 if iNdEx >= l { 2885 return io.ErrUnexpectedEOF 2886 } 2887 b := dAtA[iNdEx] 2888 iNdEx++ 2889 m.Isolation |= TransactionStrategy_Isolation(b&0x7F) << shift 2890 if b < 0x80 { 2891 break 2892 } 2893 } 2894 default: 2895 iNdEx = preIndex 2896 skippy, err := skipTransaction(dAtA[iNdEx:]) 2897 if err != nil { 2898 return err 2899 } 2900 if (skippy < 0) || (iNdEx+skippy) < 0 { 2901 return ErrInvalidLengthTransaction 2902 } 2903 if (iNdEx + skippy) > l { 2904 return io.ErrUnexpectedEOF 2905 } 2906 iNdEx += skippy 2907 } 2908 } 2909 2910 if iNdEx > l { 2911 return io.ErrUnexpectedEOF 2912 } 2913 return nil 2914 } 2915 func (m *ChangeTransaction) Unmarshal(dAtA []byte) error { 2916 l := len(dAtA) 2917 iNdEx := 0 2918 for iNdEx < l { 2919 preIndex := iNdEx 2920 var wire uint64 2921 for shift := uint(0); ; shift += 7 { 2922 if shift >= 64 { 2923 return ErrIntOverflowTransaction 2924 } 2925 if iNdEx >= l { 2926 return io.ErrUnexpectedEOF 2927 } 2928 b := dAtA[iNdEx] 2929 iNdEx++ 2930 wire |= uint64(b&0x7F) << shift 2931 if b < 0x80 { 2932 break 2933 } 2934 } 2935 fieldNum := int32(wire >> 3) 2936 wireType := int(wire & 0x7) 2937 if wireType == 4 { 2938 return fmt.Errorf("proto: ChangeTransaction: wiretype end group for non-group") 2939 } 2940 if fieldNum <= 0 { 2941 return fmt.Errorf("proto: ChangeTransaction: illegal tag %d (wire type %d)", fieldNum, wire) 2942 } 2943 switch fieldNum { 2944 case 1: 2945 if wireType != 2 { 2946 return fmt.Errorf("proto: wrong wireType = %d for field Values", wireType) 2947 } 2948 var msglen int 2949 for shift := uint(0); ; shift += 7 { 2950 if shift >= 64 { 2951 return ErrIntOverflowTransaction 2952 } 2953 if iNdEx >= l { 2954 return io.ErrUnexpectedEOF 2955 } 2956 b := dAtA[iNdEx] 2957 iNdEx++ 2958 msglen |= int(b&0x7F) << shift 2959 if b < 0x80 { 2960 break 2961 } 2962 } 2963 if msglen < 0 { 2964 return ErrInvalidLengthTransaction 2965 } 2966 postIndex := iNdEx + msglen 2967 if postIndex < 0 { 2968 return ErrInvalidLengthTransaction 2969 } 2970 if postIndex > l { 2971 return io.ErrUnexpectedEOF 2972 } 2973 if m.Values == nil { 2974 m.Values = make(map[TargetID]*PathValues) 2975 } 2976 var mapkey TargetID 2977 var mapvalue *PathValues 2978 for iNdEx < postIndex { 2979 entryPreIndex := iNdEx 2980 var wire uint64 2981 for shift := uint(0); ; shift += 7 { 2982 if shift >= 64 { 2983 return ErrIntOverflowTransaction 2984 } 2985 if iNdEx >= l { 2986 return io.ErrUnexpectedEOF 2987 } 2988 b := dAtA[iNdEx] 2989 iNdEx++ 2990 wire |= uint64(b&0x7F) << shift 2991 if b < 0x80 { 2992 break 2993 } 2994 } 2995 fieldNum := int32(wire >> 3) 2996 if fieldNum == 1 { 2997 var stringLenmapkey uint64 2998 for shift := uint(0); ; shift += 7 { 2999 if shift >= 64 { 3000 return ErrIntOverflowTransaction 3001 } 3002 if iNdEx >= l { 3003 return io.ErrUnexpectedEOF 3004 } 3005 b := dAtA[iNdEx] 3006 iNdEx++ 3007 stringLenmapkey |= uint64(b&0x7F) << shift 3008 if b < 0x80 { 3009 break 3010 } 3011 } 3012 intStringLenmapkey := int(stringLenmapkey) 3013 if intStringLenmapkey < 0 { 3014 return ErrInvalidLengthTransaction 3015 } 3016 postStringIndexmapkey := iNdEx + intStringLenmapkey 3017 if postStringIndexmapkey < 0 { 3018 return ErrInvalidLengthTransaction 3019 } 3020 if postStringIndexmapkey > l { 3021 return io.ErrUnexpectedEOF 3022 } 3023 mapkey = TargetID(dAtA[iNdEx:postStringIndexmapkey]) 3024 iNdEx = postStringIndexmapkey 3025 } else if fieldNum == 2 { 3026 var mapmsglen int 3027 for shift := uint(0); ; shift += 7 { 3028 if shift >= 64 { 3029 return ErrIntOverflowTransaction 3030 } 3031 if iNdEx >= l { 3032 return io.ErrUnexpectedEOF 3033 } 3034 b := dAtA[iNdEx] 3035 iNdEx++ 3036 mapmsglen |= int(b&0x7F) << shift 3037 if b < 0x80 { 3038 break 3039 } 3040 } 3041 if mapmsglen < 0 { 3042 return ErrInvalidLengthTransaction 3043 } 3044 postmsgIndex := iNdEx + mapmsglen 3045 if postmsgIndex < 0 { 3046 return ErrInvalidLengthTransaction 3047 } 3048 if postmsgIndex > l { 3049 return io.ErrUnexpectedEOF 3050 } 3051 mapvalue = &PathValues{} 3052 if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { 3053 return err 3054 } 3055 iNdEx = postmsgIndex 3056 } else { 3057 iNdEx = entryPreIndex 3058 skippy, err := skipTransaction(dAtA[iNdEx:]) 3059 if err != nil { 3060 return err 3061 } 3062 if (skippy < 0) || (iNdEx+skippy) < 0 { 3063 return ErrInvalidLengthTransaction 3064 } 3065 if (iNdEx + skippy) > postIndex { 3066 return io.ErrUnexpectedEOF 3067 } 3068 iNdEx += skippy 3069 } 3070 } 3071 m.Values[TargetID(mapkey)] = mapvalue 3072 iNdEx = postIndex 3073 default: 3074 iNdEx = preIndex 3075 skippy, err := skipTransaction(dAtA[iNdEx:]) 3076 if err != nil { 3077 return err 3078 } 3079 if (skippy < 0) || (iNdEx+skippy) < 0 { 3080 return ErrInvalidLengthTransaction 3081 } 3082 if (iNdEx + skippy) > l { 3083 return io.ErrUnexpectedEOF 3084 } 3085 iNdEx += skippy 3086 } 3087 } 3088 3089 if iNdEx > l { 3090 return io.ErrUnexpectedEOF 3091 } 3092 return nil 3093 } 3094 func (m *RollbackTransaction) Unmarshal(dAtA []byte) error { 3095 l := len(dAtA) 3096 iNdEx := 0 3097 for iNdEx < l { 3098 preIndex := iNdEx 3099 var wire uint64 3100 for shift := uint(0); ; shift += 7 { 3101 if shift >= 64 { 3102 return ErrIntOverflowTransaction 3103 } 3104 if iNdEx >= l { 3105 return io.ErrUnexpectedEOF 3106 } 3107 b := dAtA[iNdEx] 3108 iNdEx++ 3109 wire |= uint64(b&0x7F) << shift 3110 if b < 0x80 { 3111 break 3112 } 3113 } 3114 fieldNum := int32(wire >> 3) 3115 wireType := int(wire & 0x7) 3116 if wireType == 4 { 3117 return fmt.Errorf("proto: RollbackTransaction: wiretype end group for non-group") 3118 } 3119 if fieldNum <= 0 { 3120 return fmt.Errorf("proto: RollbackTransaction: illegal tag %d (wire type %d)", fieldNum, wire) 3121 } 3122 switch fieldNum { 3123 case 1: 3124 if wireType != 0 { 3125 return fmt.Errorf("proto: wrong wireType = %d for field RollbackIndex", wireType) 3126 } 3127 m.RollbackIndex = 0 3128 for shift := uint(0); ; shift += 7 { 3129 if shift >= 64 { 3130 return ErrIntOverflowTransaction 3131 } 3132 if iNdEx >= l { 3133 return io.ErrUnexpectedEOF 3134 } 3135 b := dAtA[iNdEx] 3136 iNdEx++ 3137 m.RollbackIndex |= Index(b&0x7F) << shift 3138 if b < 0x80 { 3139 break 3140 } 3141 } 3142 default: 3143 iNdEx = preIndex 3144 skippy, err := skipTransaction(dAtA[iNdEx:]) 3145 if err != nil { 3146 return err 3147 } 3148 if (skippy < 0) || (iNdEx+skippy) < 0 { 3149 return ErrInvalidLengthTransaction 3150 } 3151 if (iNdEx + skippy) > l { 3152 return io.ErrUnexpectedEOF 3153 } 3154 iNdEx += skippy 3155 } 3156 } 3157 3158 if iNdEx > l { 3159 return io.ErrUnexpectedEOF 3160 } 3161 return nil 3162 } 3163 func (m *TransactionStatus) Unmarshal(dAtA []byte) error { 3164 l := len(dAtA) 3165 iNdEx := 0 3166 for iNdEx < l { 3167 preIndex := iNdEx 3168 var wire uint64 3169 for shift := uint(0); ; shift += 7 { 3170 if shift >= 64 { 3171 return ErrIntOverflowTransaction 3172 } 3173 if iNdEx >= l { 3174 return io.ErrUnexpectedEOF 3175 } 3176 b := dAtA[iNdEx] 3177 iNdEx++ 3178 wire |= uint64(b&0x7F) << shift 3179 if b < 0x80 { 3180 break 3181 } 3182 } 3183 fieldNum := int32(wire >> 3) 3184 wireType := int(wire & 0x7) 3185 if wireType == 4 { 3186 return fmt.Errorf("proto: TransactionStatus: wiretype end group for non-group") 3187 } 3188 if fieldNum <= 0 { 3189 return fmt.Errorf("proto: TransactionStatus: illegal tag %d (wire type %d)", fieldNum, wire) 3190 } 3191 switch fieldNum { 3192 case 1: 3193 if wireType != 2 { 3194 return fmt.Errorf("proto: wrong wireType = %d for field Phases", wireType) 3195 } 3196 var msglen int 3197 for shift := uint(0); ; shift += 7 { 3198 if shift >= 64 { 3199 return ErrIntOverflowTransaction 3200 } 3201 if iNdEx >= l { 3202 return io.ErrUnexpectedEOF 3203 } 3204 b := dAtA[iNdEx] 3205 iNdEx++ 3206 msglen |= int(b&0x7F) << shift 3207 if b < 0x80 { 3208 break 3209 } 3210 } 3211 if msglen < 0 { 3212 return ErrInvalidLengthTransaction 3213 } 3214 postIndex := iNdEx + msglen 3215 if postIndex < 0 { 3216 return ErrInvalidLengthTransaction 3217 } 3218 if postIndex > l { 3219 return io.ErrUnexpectedEOF 3220 } 3221 if err := m.Phases.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3222 return err 3223 } 3224 iNdEx = postIndex 3225 case 2: 3226 if wireType != 2 { 3227 return fmt.Errorf("proto: wrong wireType = %d for field Proposals", wireType) 3228 } 3229 var stringLen uint64 3230 for shift := uint(0); ; shift += 7 { 3231 if shift >= 64 { 3232 return ErrIntOverflowTransaction 3233 } 3234 if iNdEx >= l { 3235 return io.ErrUnexpectedEOF 3236 } 3237 b := dAtA[iNdEx] 3238 iNdEx++ 3239 stringLen |= uint64(b&0x7F) << shift 3240 if b < 0x80 { 3241 break 3242 } 3243 } 3244 intStringLen := int(stringLen) 3245 if intStringLen < 0 { 3246 return ErrInvalidLengthTransaction 3247 } 3248 postIndex := iNdEx + intStringLen 3249 if postIndex < 0 { 3250 return ErrInvalidLengthTransaction 3251 } 3252 if postIndex > l { 3253 return io.ErrUnexpectedEOF 3254 } 3255 m.Proposals = append(m.Proposals, ProposalID(dAtA[iNdEx:postIndex])) 3256 iNdEx = postIndex 3257 case 3: 3258 if wireType != 0 { 3259 return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) 3260 } 3261 m.State = 0 3262 for shift := uint(0); ; shift += 7 { 3263 if shift >= 64 { 3264 return ErrIntOverflowTransaction 3265 } 3266 if iNdEx >= l { 3267 return io.ErrUnexpectedEOF 3268 } 3269 b := dAtA[iNdEx] 3270 iNdEx++ 3271 m.State |= TransactionStatus_State(b&0x7F) << shift 3272 if b < 0x80 { 3273 break 3274 } 3275 } 3276 case 4: 3277 if wireType != 2 { 3278 return fmt.Errorf("proto: wrong wireType = %d for field Failure", wireType) 3279 } 3280 var msglen int 3281 for shift := uint(0); ; shift += 7 { 3282 if shift >= 64 { 3283 return ErrIntOverflowTransaction 3284 } 3285 if iNdEx >= l { 3286 return io.ErrUnexpectedEOF 3287 } 3288 b := dAtA[iNdEx] 3289 iNdEx++ 3290 msglen |= int(b&0x7F) << shift 3291 if b < 0x80 { 3292 break 3293 } 3294 } 3295 if msglen < 0 { 3296 return ErrInvalidLengthTransaction 3297 } 3298 postIndex := iNdEx + msglen 3299 if postIndex < 0 { 3300 return ErrInvalidLengthTransaction 3301 } 3302 if postIndex > l { 3303 return io.ErrUnexpectedEOF 3304 } 3305 if m.Failure == nil { 3306 m.Failure = &Failure{} 3307 } 3308 if err := m.Failure.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3309 return err 3310 } 3311 iNdEx = postIndex 3312 default: 3313 iNdEx = preIndex 3314 skippy, err := skipTransaction(dAtA[iNdEx:]) 3315 if err != nil { 3316 return err 3317 } 3318 if (skippy < 0) || (iNdEx+skippy) < 0 { 3319 return ErrInvalidLengthTransaction 3320 } 3321 if (iNdEx + skippy) > l { 3322 return io.ErrUnexpectedEOF 3323 } 3324 iNdEx += skippy 3325 } 3326 } 3327 3328 if iNdEx > l { 3329 return io.ErrUnexpectedEOF 3330 } 3331 return nil 3332 } 3333 func (m *TransactionPhases) Unmarshal(dAtA []byte) error { 3334 l := len(dAtA) 3335 iNdEx := 0 3336 for iNdEx < l { 3337 preIndex := iNdEx 3338 var wire uint64 3339 for shift := uint(0); ; shift += 7 { 3340 if shift >= 64 { 3341 return ErrIntOverflowTransaction 3342 } 3343 if iNdEx >= l { 3344 return io.ErrUnexpectedEOF 3345 } 3346 b := dAtA[iNdEx] 3347 iNdEx++ 3348 wire |= uint64(b&0x7F) << shift 3349 if b < 0x80 { 3350 break 3351 } 3352 } 3353 fieldNum := int32(wire >> 3) 3354 wireType := int(wire & 0x7) 3355 if wireType == 4 { 3356 return fmt.Errorf("proto: TransactionPhases: wiretype end group for non-group") 3357 } 3358 if fieldNum <= 0 { 3359 return fmt.Errorf("proto: TransactionPhases: illegal tag %d (wire type %d)", fieldNum, wire) 3360 } 3361 switch fieldNum { 3362 case 1: 3363 if wireType != 2 { 3364 return fmt.Errorf("proto: wrong wireType = %d for field Initialize", wireType) 3365 } 3366 var msglen int 3367 for shift := uint(0); ; shift += 7 { 3368 if shift >= 64 { 3369 return ErrIntOverflowTransaction 3370 } 3371 if iNdEx >= l { 3372 return io.ErrUnexpectedEOF 3373 } 3374 b := dAtA[iNdEx] 3375 iNdEx++ 3376 msglen |= int(b&0x7F) << shift 3377 if b < 0x80 { 3378 break 3379 } 3380 } 3381 if msglen < 0 { 3382 return ErrInvalidLengthTransaction 3383 } 3384 postIndex := iNdEx + msglen 3385 if postIndex < 0 { 3386 return ErrInvalidLengthTransaction 3387 } 3388 if postIndex > l { 3389 return io.ErrUnexpectedEOF 3390 } 3391 if m.Initialize == nil { 3392 m.Initialize = &TransactionInitializePhase{} 3393 } 3394 if err := m.Initialize.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3395 return err 3396 } 3397 iNdEx = postIndex 3398 case 2: 3399 if wireType != 2 { 3400 return fmt.Errorf("proto: wrong wireType = %d for field Validate", wireType) 3401 } 3402 var msglen int 3403 for shift := uint(0); ; shift += 7 { 3404 if shift >= 64 { 3405 return ErrIntOverflowTransaction 3406 } 3407 if iNdEx >= l { 3408 return io.ErrUnexpectedEOF 3409 } 3410 b := dAtA[iNdEx] 3411 iNdEx++ 3412 msglen |= int(b&0x7F) << shift 3413 if b < 0x80 { 3414 break 3415 } 3416 } 3417 if msglen < 0 { 3418 return ErrInvalidLengthTransaction 3419 } 3420 postIndex := iNdEx + msglen 3421 if postIndex < 0 { 3422 return ErrInvalidLengthTransaction 3423 } 3424 if postIndex > l { 3425 return io.ErrUnexpectedEOF 3426 } 3427 if m.Validate == nil { 3428 m.Validate = &TransactionValidatePhase{} 3429 } 3430 if err := m.Validate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3431 return err 3432 } 3433 iNdEx = postIndex 3434 case 3: 3435 if wireType != 2 { 3436 return fmt.Errorf("proto: wrong wireType = %d for field Commit", wireType) 3437 } 3438 var msglen int 3439 for shift := uint(0); ; shift += 7 { 3440 if shift >= 64 { 3441 return ErrIntOverflowTransaction 3442 } 3443 if iNdEx >= l { 3444 return io.ErrUnexpectedEOF 3445 } 3446 b := dAtA[iNdEx] 3447 iNdEx++ 3448 msglen |= int(b&0x7F) << shift 3449 if b < 0x80 { 3450 break 3451 } 3452 } 3453 if msglen < 0 { 3454 return ErrInvalidLengthTransaction 3455 } 3456 postIndex := iNdEx + msglen 3457 if postIndex < 0 { 3458 return ErrInvalidLengthTransaction 3459 } 3460 if postIndex > l { 3461 return io.ErrUnexpectedEOF 3462 } 3463 if m.Commit == nil { 3464 m.Commit = &TransactionCommitPhase{} 3465 } 3466 if err := m.Commit.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3467 return err 3468 } 3469 iNdEx = postIndex 3470 case 4: 3471 if wireType != 2 { 3472 return fmt.Errorf("proto: wrong wireType = %d for field Apply", wireType) 3473 } 3474 var msglen int 3475 for shift := uint(0); ; shift += 7 { 3476 if shift >= 64 { 3477 return ErrIntOverflowTransaction 3478 } 3479 if iNdEx >= l { 3480 return io.ErrUnexpectedEOF 3481 } 3482 b := dAtA[iNdEx] 3483 iNdEx++ 3484 msglen |= int(b&0x7F) << shift 3485 if b < 0x80 { 3486 break 3487 } 3488 } 3489 if msglen < 0 { 3490 return ErrInvalidLengthTransaction 3491 } 3492 postIndex := iNdEx + msglen 3493 if postIndex < 0 { 3494 return ErrInvalidLengthTransaction 3495 } 3496 if postIndex > l { 3497 return io.ErrUnexpectedEOF 3498 } 3499 if m.Apply == nil { 3500 m.Apply = &TransactionApplyPhase{} 3501 } 3502 if err := m.Apply.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3503 return err 3504 } 3505 iNdEx = postIndex 3506 case 5: 3507 if wireType != 2 { 3508 return fmt.Errorf("proto: wrong wireType = %d for field Abort", wireType) 3509 } 3510 var msglen int 3511 for shift := uint(0); ; shift += 7 { 3512 if shift >= 64 { 3513 return ErrIntOverflowTransaction 3514 } 3515 if iNdEx >= l { 3516 return io.ErrUnexpectedEOF 3517 } 3518 b := dAtA[iNdEx] 3519 iNdEx++ 3520 msglen |= int(b&0x7F) << shift 3521 if b < 0x80 { 3522 break 3523 } 3524 } 3525 if msglen < 0 { 3526 return ErrInvalidLengthTransaction 3527 } 3528 postIndex := iNdEx + msglen 3529 if postIndex < 0 { 3530 return ErrInvalidLengthTransaction 3531 } 3532 if postIndex > l { 3533 return io.ErrUnexpectedEOF 3534 } 3535 if m.Abort == nil { 3536 m.Abort = &TransactionAbortPhase{} 3537 } 3538 if err := m.Abort.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3539 return err 3540 } 3541 iNdEx = postIndex 3542 default: 3543 iNdEx = preIndex 3544 skippy, err := skipTransaction(dAtA[iNdEx:]) 3545 if err != nil { 3546 return err 3547 } 3548 if (skippy < 0) || (iNdEx+skippy) < 0 { 3549 return ErrInvalidLengthTransaction 3550 } 3551 if (iNdEx + skippy) > l { 3552 return io.ErrUnexpectedEOF 3553 } 3554 iNdEx += skippy 3555 } 3556 } 3557 3558 if iNdEx > l { 3559 return io.ErrUnexpectedEOF 3560 } 3561 return nil 3562 } 3563 func (m *TransactionPhaseStatus) Unmarshal(dAtA []byte) error { 3564 l := len(dAtA) 3565 iNdEx := 0 3566 for iNdEx < l { 3567 preIndex := iNdEx 3568 var wire uint64 3569 for shift := uint(0); ; shift += 7 { 3570 if shift >= 64 { 3571 return ErrIntOverflowTransaction 3572 } 3573 if iNdEx >= l { 3574 return io.ErrUnexpectedEOF 3575 } 3576 b := dAtA[iNdEx] 3577 iNdEx++ 3578 wire |= uint64(b&0x7F) << shift 3579 if b < 0x80 { 3580 break 3581 } 3582 } 3583 fieldNum := int32(wire >> 3) 3584 wireType := int(wire & 0x7) 3585 if wireType == 4 { 3586 return fmt.Errorf("proto: TransactionPhaseStatus: wiretype end group for non-group") 3587 } 3588 if fieldNum <= 0 { 3589 return fmt.Errorf("proto: TransactionPhaseStatus: illegal tag %d (wire type %d)", fieldNum, wire) 3590 } 3591 switch fieldNum { 3592 case 1: 3593 if wireType != 2 { 3594 return fmt.Errorf("proto: wrong wireType = %d for field Start", wireType) 3595 } 3596 var msglen int 3597 for shift := uint(0); ; shift += 7 { 3598 if shift >= 64 { 3599 return ErrIntOverflowTransaction 3600 } 3601 if iNdEx >= l { 3602 return io.ErrUnexpectedEOF 3603 } 3604 b := dAtA[iNdEx] 3605 iNdEx++ 3606 msglen |= int(b&0x7F) << shift 3607 if b < 0x80 { 3608 break 3609 } 3610 } 3611 if msglen < 0 { 3612 return ErrInvalidLengthTransaction 3613 } 3614 postIndex := iNdEx + msglen 3615 if postIndex < 0 { 3616 return ErrInvalidLengthTransaction 3617 } 3618 if postIndex > l { 3619 return io.ErrUnexpectedEOF 3620 } 3621 if m.Start == nil { 3622 m.Start = new(time.Time) 3623 } 3624 if err := github_com_gogo_protobuf_types.StdTimeUnmarshal(m.Start, dAtA[iNdEx:postIndex]); err != nil { 3625 return err 3626 } 3627 iNdEx = postIndex 3628 case 2: 3629 if wireType != 2 { 3630 return fmt.Errorf("proto: wrong wireType = %d for field End", wireType) 3631 } 3632 var msglen int 3633 for shift := uint(0); ; shift += 7 { 3634 if shift >= 64 { 3635 return ErrIntOverflowTransaction 3636 } 3637 if iNdEx >= l { 3638 return io.ErrUnexpectedEOF 3639 } 3640 b := dAtA[iNdEx] 3641 iNdEx++ 3642 msglen |= int(b&0x7F) << shift 3643 if b < 0x80 { 3644 break 3645 } 3646 } 3647 if msglen < 0 { 3648 return ErrInvalidLengthTransaction 3649 } 3650 postIndex := iNdEx + msglen 3651 if postIndex < 0 { 3652 return ErrInvalidLengthTransaction 3653 } 3654 if postIndex > l { 3655 return io.ErrUnexpectedEOF 3656 } 3657 if m.End == nil { 3658 m.End = new(time.Time) 3659 } 3660 if err := github_com_gogo_protobuf_types.StdTimeUnmarshal(m.End, dAtA[iNdEx:postIndex]); err != nil { 3661 return err 3662 } 3663 iNdEx = postIndex 3664 default: 3665 iNdEx = preIndex 3666 skippy, err := skipTransaction(dAtA[iNdEx:]) 3667 if err != nil { 3668 return err 3669 } 3670 if (skippy < 0) || (iNdEx+skippy) < 0 { 3671 return ErrInvalidLengthTransaction 3672 } 3673 if (iNdEx + skippy) > l { 3674 return io.ErrUnexpectedEOF 3675 } 3676 iNdEx += skippy 3677 } 3678 } 3679 3680 if iNdEx > l { 3681 return io.ErrUnexpectedEOF 3682 } 3683 return nil 3684 } 3685 func (m *TransactionInitializePhase) Unmarshal(dAtA []byte) error { 3686 l := len(dAtA) 3687 iNdEx := 0 3688 for iNdEx < l { 3689 preIndex := iNdEx 3690 var wire uint64 3691 for shift := uint(0); ; shift += 7 { 3692 if shift >= 64 { 3693 return ErrIntOverflowTransaction 3694 } 3695 if iNdEx >= l { 3696 return io.ErrUnexpectedEOF 3697 } 3698 b := dAtA[iNdEx] 3699 iNdEx++ 3700 wire |= uint64(b&0x7F) << shift 3701 if b < 0x80 { 3702 break 3703 } 3704 } 3705 fieldNum := int32(wire >> 3) 3706 wireType := int(wire & 0x7) 3707 if wireType == 4 { 3708 return fmt.Errorf("proto: TransactionInitializePhase: wiretype end group for non-group") 3709 } 3710 if fieldNum <= 0 { 3711 return fmt.Errorf("proto: TransactionInitializePhase: illegal tag %d (wire type %d)", fieldNum, wire) 3712 } 3713 switch fieldNum { 3714 case 1: 3715 if wireType != 2 { 3716 return fmt.Errorf("proto: wrong wireType = %d for field TransactionPhaseStatus", wireType) 3717 } 3718 var msglen int 3719 for shift := uint(0); ; shift += 7 { 3720 if shift >= 64 { 3721 return ErrIntOverflowTransaction 3722 } 3723 if iNdEx >= l { 3724 return io.ErrUnexpectedEOF 3725 } 3726 b := dAtA[iNdEx] 3727 iNdEx++ 3728 msglen |= int(b&0x7F) << shift 3729 if b < 0x80 { 3730 break 3731 } 3732 } 3733 if msglen < 0 { 3734 return ErrInvalidLengthTransaction 3735 } 3736 postIndex := iNdEx + msglen 3737 if postIndex < 0 { 3738 return ErrInvalidLengthTransaction 3739 } 3740 if postIndex > l { 3741 return io.ErrUnexpectedEOF 3742 } 3743 if err := m.TransactionPhaseStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3744 return err 3745 } 3746 iNdEx = postIndex 3747 case 2: 3748 if wireType != 0 { 3749 return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) 3750 } 3751 m.State = 0 3752 for shift := uint(0); ; shift += 7 { 3753 if shift >= 64 { 3754 return ErrIntOverflowTransaction 3755 } 3756 if iNdEx >= l { 3757 return io.ErrUnexpectedEOF 3758 } 3759 b := dAtA[iNdEx] 3760 iNdEx++ 3761 m.State |= TransactionInitializePhase_State(b&0x7F) << shift 3762 if b < 0x80 { 3763 break 3764 } 3765 } 3766 case 3: 3767 if wireType != 2 { 3768 return fmt.Errorf("proto: wrong wireType = %d for field Failure", wireType) 3769 } 3770 var msglen int 3771 for shift := uint(0); ; shift += 7 { 3772 if shift >= 64 { 3773 return ErrIntOverflowTransaction 3774 } 3775 if iNdEx >= l { 3776 return io.ErrUnexpectedEOF 3777 } 3778 b := dAtA[iNdEx] 3779 iNdEx++ 3780 msglen |= int(b&0x7F) << shift 3781 if b < 0x80 { 3782 break 3783 } 3784 } 3785 if msglen < 0 { 3786 return ErrInvalidLengthTransaction 3787 } 3788 postIndex := iNdEx + msglen 3789 if postIndex < 0 { 3790 return ErrInvalidLengthTransaction 3791 } 3792 if postIndex > l { 3793 return io.ErrUnexpectedEOF 3794 } 3795 if m.Failure == nil { 3796 m.Failure = &Failure{} 3797 } 3798 if err := m.Failure.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3799 return err 3800 } 3801 iNdEx = postIndex 3802 default: 3803 iNdEx = preIndex 3804 skippy, err := skipTransaction(dAtA[iNdEx:]) 3805 if err != nil { 3806 return err 3807 } 3808 if (skippy < 0) || (iNdEx+skippy) < 0 { 3809 return ErrInvalidLengthTransaction 3810 } 3811 if (iNdEx + skippy) > l { 3812 return io.ErrUnexpectedEOF 3813 } 3814 iNdEx += skippy 3815 } 3816 } 3817 3818 if iNdEx > l { 3819 return io.ErrUnexpectedEOF 3820 } 3821 return nil 3822 } 3823 func (m *TransactionValidatePhase) Unmarshal(dAtA []byte) error { 3824 l := len(dAtA) 3825 iNdEx := 0 3826 for iNdEx < l { 3827 preIndex := iNdEx 3828 var wire uint64 3829 for shift := uint(0); ; shift += 7 { 3830 if shift >= 64 { 3831 return ErrIntOverflowTransaction 3832 } 3833 if iNdEx >= l { 3834 return io.ErrUnexpectedEOF 3835 } 3836 b := dAtA[iNdEx] 3837 iNdEx++ 3838 wire |= uint64(b&0x7F) << shift 3839 if b < 0x80 { 3840 break 3841 } 3842 } 3843 fieldNum := int32(wire >> 3) 3844 wireType := int(wire & 0x7) 3845 if wireType == 4 { 3846 return fmt.Errorf("proto: TransactionValidatePhase: wiretype end group for non-group") 3847 } 3848 if fieldNum <= 0 { 3849 return fmt.Errorf("proto: TransactionValidatePhase: illegal tag %d (wire type %d)", fieldNum, wire) 3850 } 3851 switch fieldNum { 3852 case 1: 3853 if wireType != 2 { 3854 return fmt.Errorf("proto: wrong wireType = %d for field TransactionPhaseStatus", wireType) 3855 } 3856 var msglen int 3857 for shift := uint(0); ; shift += 7 { 3858 if shift >= 64 { 3859 return ErrIntOverflowTransaction 3860 } 3861 if iNdEx >= l { 3862 return io.ErrUnexpectedEOF 3863 } 3864 b := dAtA[iNdEx] 3865 iNdEx++ 3866 msglen |= int(b&0x7F) << shift 3867 if b < 0x80 { 3868 break 3869 } 3870 } 3871 if msglen < 0 { 3872 return ErrInvalidLengthTransaction 3873 } 3874 postIndex := iNdEx + msglen 3875 if postIndex < 0 { 3876 return ErrInvalidLengthTransaction 3877 } 3878 if postIndex > l { 3879 return io.ErrUnexpectedEOF 3880 } 3881 if err := m.TransactionPhaseStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3882 return err 3883 } 3884 iNdEx = postIndex 3885 case 2: 3886 if wireType != 0 { 3887 return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) 3888 } 3889 m.State = 0 3890 for shift := uint(0); ; shift += 7 { 3891 if shift >= 64 { 3892 return ErrIntOverflowTransaction 3893 } 3894 if iNdEx >= l { 3895 return io.ErrUnexpectedEOF 3896 } 3897 b := dAtA[iNdEx] 3898 iNdEx++ 3899 m.State |= TransactionValidatePhase_State(b&0x7F) << shift 3900 if b < 0x80 { 3901 break 3902 } 3903 } 3904 case 3: 3905 if wireType != 2 { 3906 return fmt.Errorf("proto: wrong wireType = %d for field Failure", wireType) 3907 } 3908 var msglen int 3909 for shift := uint(0); ; shift += 7 { 3910 if shift >= 64 { 3911 return ErrIntOverflowTransaction 3912 } 3913 if iNdEx >= l { 3914 return io.ErrUnexpectedEOF 3915 } 3916 b := dAtA[iNdEx] 3917 iNdEx++ 3918 msglen |= int(b&0x7F) << shift 3919 if b < 0x80 { 3920 break 3921 } 3922 } 3923 if msglen < 0 { 3924 return ErrInvalidLengthTransaction 3925 } 3926 postIndex := iNdEx + msglen 3927 if postIndex < 0 { 3928 return ErrInvalidLengthTransaction 3929 } 3930 if postIndex > l { 3931 return io.ErrUnexpectedEOF 3932 } 3933 if m.Failure == nil { 3934 m.Failure = &Failure{} 3935 } 3936 if err := m.Failure.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 3937 return err 3938 } 3939 iNdEx = postIndex 3940 default: 3941 iNdEx = preIndex 3942 skippy, err := skipTransaction(dAtA[iNdEx:]) 3943 if err != nil { 3944 return err 3945 } 3946 if (skippy < 0) || (iNdEx+skippy) < 0 { 3947 return ErrInvalidLengthTransaction 3948 } 3949 if (iNdEx + skippy) > l { 3950 return io.ErrUnexpectedEOF 3951 } 3952 iNdEx += skippy 3953 } 3954 } 3955 3956 if iNdEx > l { 3957 return io.ErrUnexpectedEOF 3958 } 3959 return nil 3960 } 3961 func (m *TransactionCommitPhase) Unmarshal(dAtA []byte) error { 3962 l := len(dAtA) 3963 iNdEx := 0 3964 for iNdEx < l { 3965 preIndex := iNdEx 3966 var wire uint64 3967 for shift := uint(0); ; shift += 7 { 3968 if shift >= 64 { 3969 return ErrIntOverflowTransaction 3970 } 3971 if iNdEx >= l { 3972 return io.ErrUnexpectedEOF 3973 } 3974 b := dAtA[iNdEx] 3975 iNdEx++ 3976 wire |= uint64(b&0x7F) << shift 3977 if b < 0x80 { 3978 break 3979 } 3980 } 3981 fieldNum := int32(wire >> 3) 3982 wireType := int(wire & 0x7) 3983 if wireType == 4 { 3984 return fmt.Errorf("proto: TransactionCommitPhase: wiretype end group for non-group") 3985 } 3986 if fieldNum <= 0 { 3987 return fmt.Errorf("proto: TransactionCommitPhase: illegal tag %d (wire type %d)", fieldNum, wire) 3988 } 3989 switch fieldNum { 3990 case 1: 3991 if wireType != 2 { 3992 return fmt.Errorf("proto: wrong wireType = %d for field TransactionPhaseStatus", wireType) 3993 } 3994 var msglen int 3995 for shift := uint(0); ; shift += 7 { 3996 if shift >= 64 { 3997 return ErrIntOverflowTransaction 3998 } 3999 if iNdEx >= l { 4000 return io.ErrUnexpectedEOF 4001 } 4002 b := dAtA[iNdEx] 4003 iNdEx++ 4004 msglen |= int(b&0x7F) << shift 4005 if b < 0x80 { 4006 break 4007 } 4008 } 4009 if msglen < 0 { 4010 return ErrInvalidLengthTransaction 4011 } 4012 postIndex := iNdEx + msglen 4013 if postIndex < 0 { 4014 return ErrInvalidLengthTransaction 4015 } 4016 if postIndex > l { 4017 return io.ErrUnexpectedEOF 4018 } 4019 if err := m.TransactionPhaseStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 4020 return err 4021 } 4022 iNdEx = postIndex 4023 case 2: 4024 if wireType != 0 { 4025 return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) 4026 } 4027 m.State = 0 4028 for shift := uint(0); ; shift += 7 { 4029 if shift >= 64 { 4030 return ErrIntOverflowTransaction 4031 } 4032 if iNdEx >= l { 4033 return io.ErrUnexpectedEOF 4034 } 4035 b := dAtA[iNdEx] 4036 iNdEx++ 4037 m.State |= TransactionCommitPhase_State(b&0x7F) << shift 4038 if b < 0x80 { 4039 break 4040 } 4041 } 4042 default: 4043 iNdEx = preIndex 4044 skippy, err := skipTransaction(dAtA[iNdEx:]) 4045 if err != nil { 4046 return err 4047 } 4048 if (skippy < 0) || (iNdEx+skippy) < 0 { 4049 return ErrInvalidLengthTransaction 4050 } 4051 if (iNdEx + skippy) > l { 4052 return io.ErrUnexpectedEOF 4053 } 4054 iNdEx += skippy 4055 } 4056 } 4057 4058 if iNdEx > l { 4059 return io.ErrUnexpectedEOF 4060 } 4061 return nil 4062 } 4063 func (m *TransactionApplyPhase) Unmarshal(dAtA []byte) error { 4064 l := len(dAtA) 4065 iNdEx := 0 4066 for iNdEx < l { 4067 preIndex := iNdEx 4068 var wire uint64 4069 for shift := uint(0); ; shift += 7 { 4070 if shift >= 64 { 4071 return ErrIntOverflowTransaction 4072 } 4073 if iNdEx >= l { 4074 return io.ErrUnexpectedEOF 4075 } 4076 b := dAtA[iNdEx] 4077 iNdEx++ 4078 wire |= uint64(b&0x7F) << shift 4079 if b < 0x80 { 4080 break 4081 } 4082 } 4083 fieldNum := int32(wire >> 3) 4084 wireType := int(wire & 0x7) 4085 if wireType == 4 { 4086 return fmt.Errorf("proto: TransactionApplyPhase: wiretype end group for non-group") 4087 } 4088 if fieldNum <= 0 { 4089 return fmt.Errorf("proto: TransactionApplyPhase: illegal tag %d (wire type %d)", fieldNum, wire) 4090 } 4091 switch fieldNum { 4092 case 1: 4093 if wireType != 2 { 4094 return fmt.Errorf("proto: wrong wireType = %d for field TransactionPhaseStatus", wireType) 4095 } 4096 var msglen int 4097 for shift := uint(0); ; shift += 7 { 4098 if shift >= 64 { 4099 return ErrIntOverflowTransaction 4100 } 4101 if iNdEx >= l { 4102 return io.ErrUnexpectedEOF 4103 } 4104 b := dAtA[iNdEx] 4105 iNdEx++ 4106 msglen |= int(b&0x7F) << shift 4107 if b < 0x80 { 4108 break 4109 } 4110 } 4111 if msglen < 0 { 4112 return ErrInvalidLengthTransaction 4113 } 4114 postIndex := iNdEx + msglen 4115 if postIndex < 0 { 4116 return ErrInvalidLengthTransaction 4117 } 4118 if postIndex > l { 4119 return io.ErrUnexpectedEOF 4120 } 4121 if err := m.TransactionPhaseStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 4122 return err 4123 } 4124 iNdEx = postIndex 4125 case 2: 4126 if wireType != 0 { 4127 return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) 4128 } 4129 m.State = 0 4130 for shift := uint(0); ; shift += 7 { 4131 if shift >= 64 { 4132 return ErrIntOverflowTransaction 4133 } 4134 if iNdEx >= l { 4135 return io.ErrUnexpectedEOF 4136 } 4137 b := dAtA[iNdEx] 4138 iNdEx++ 4139 m.State |= TransactionApplyPhase_State(b&0x7F) << shift 4140 if b < 0x80 { 4141 break 4142 } 4143 } 4144 case 3: 4145 if wireType != 2 { 4146 return fmt.Errorf("proto: wrong wireType = %d for field Failure", wireType) 4147 } 4148 var msglen int 4149 for shift := uint(0); ; shift += 7 { 4150 if shift >= 64 { 4151 return ErrIntOverflowTransaction 4152 } 4153 if iNdEx >= l { 4154 return io.ErrUnexpectedEOF 4155 } 4156 b := dAtA[iNdEx] 4157 iNdEx++ 4158 msglen |= int(b&0x7F) << shift 4159 if b < 0x80 { 4160 break 4161 } 4162 } 4163 if msglen < 0 { 4164 return ErrInvalidLengthTransaction 4165 } 4166 postIndex := iNdEx + msglen 4167 if postIndex < 0 { 4168 return ErrInvalidLengthTransaction 4169 } 4170 if postIndex > l { 4171 return io.ErrUnexpectedEOF 4172 } 4173 if m.Failure == nil { 4174 m.Failure = &Failure{} 4175 } 4176 if err := m.Failure.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 4177 return err 4178 } 4179 iNdEx = postIndex 4180 default: 4181 iNdEx = preIndex 4182 skippy, err := skipTransaction(dAtA[iNdEx:]) 4183 if err != nil { 4184 return err 4185 } 4186 if (skippy < 0) || (iNdEx+skippy) < 0 { 4187 return ErrInvalidLengthTransaction 4188 } 4189 if (iNdEx + skippy) > l { 4190 return io.ErrUnexpectedEOF 4191 } 4192 iNdEx += skippy 4193 } 4194 } 4195 4196 if iNdEx > l { 4197 return io.ErrUnexpectedEOF 4198 } 4199 return nil 4200 } 4201 func (m *TransactionAbortPhase) Unmarshal(dAtA []byte) error { 4202 l := len(dAtA) 4203 iNdEx := 0 4204 for iNdEx < l { 4205 preIndex := iNdEx 4206 var wire uint64 4207 for shift := uint(0); ; shift += 7 { 4208 if shift >= 64 { 4209 return ErrIntOverflowTransaction 4210 } 4211 if iNdEx >= l { 4212 return io.ErrUnexpectedEOF 4213 } 4214 b := dAtA[iNdEx] 4215 iNdEx++ 4216 wire |= uint64(b&0x7F) << shift 4217 if b < 0x80 { 4218 break 4219 } 4220 } 4221 fieldNum := int32(wire >> 3) 4222 wireType := int(wire & 0x7) 4223 if wireType == 4 { 4224 return fmt.Errorf("proto: TransactionAbortPhase: wiretype end group for non-group") 4225 } 4226 if fieldNum <= 0 { 4227 return fmt.Errorf("proto: TransactionAbortPhase: illegal tag %d (wire type %d)", fieldNum, wire) 4228 } 4229 switch fieldNum { 4230 case 1: 4231 if wireType != 2 { 4232 return fmt.Errorf("proto: wrong wireType = %d for field TransactionPhaseStatus", wireType) 4233 } 4234 var msglen int 4235 for shift := uint(0); ; shift += 7 { 4236 if shift >= 64 { 4237 return ErrIntOverflowTransaction 4238 } 4239 if iNdEx >= l { 4240 return io.ErrUnexpectedEOF 4241 } 4242 b := dAtA[iNdEx] 4243 iNdEx++ 4244 msglen |= int(b&0x7F) << shift 4245 if b < 0x80 { 4246 break 4247 } 4248 } 4249 if msglen < 0 { 4250 return ErrInvalidLengthTransaction 4251 } 4252 postIndex := iNdEx + msglen 4253 if postIndex < 0 { 4254 return ErrInvalidLengthTransaction 4255 } 4256 if postIndex > l { 4257 return io.ErrUnexpectedEOF 4258 } 4259 if err := m.TransactionPhaseStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 4260 return err 4261 } 4262 iNdEx = postIndex 4263 case 2: 4264 if wireType != 0 { 4265 return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) 4266 } 4267 m.State = 0 4268 for shift := uint(0); ; shift += 7 { 4269 if shift >= 64 { 4270 return ErrIntOverflowTransaction 4271 } 4272 if iNdEx >= l { 4273 return io.ErrUnexpectedEOF 4274 } 4275 b := dAtA[iNdEx] 4276 iNdEx++ 4277 m.State |= TransactionAbortPhase_State(b&0x7F) << shift 4278 if b < 0x80 { 4279 break 4280 } 4281 } 4282 default: 4283 iNdEx = preIndex 4284 skippy, err := skipTransaction(dAtA[iNdEx:]) 4285 if err != nil { 4286 return err 4287 } 4288 if (skippy < 0) || (iNdEx+skippy) < 0 { 4289 return ErrInvalidLengthTransaction 4290 } 4291 if (iNdEx + skippy) > l { 4292 return io.ErrUnexpectedEOF 4293 } 4294 iNdEx += skippy 4295 } 4296 } 4297 4298 if iNdEx > l { 4299 return io.ErrUnexpectedEOF 4300 } 4301 return nil 4302 } 4303 func (m *TransactionEvent) Unmarshal(dAtA []byte) error { 4304 l := len(dAtA) 4305 iNdEx := 0 4306 for iNdEx < l { 4307 preIndex := iNdEx 4308 var wire uint64 4309 for shift := uint(0); ; shift += 7 { 4310 if shift >= 64 { 4311 return ErrIntOverflowTransaction 4312 } 4313 if iNdEx >= l { 4314 return io.ErrUnexpectedEOF 4315 } 4316 b := dAtA[iNdEx] 4317 iNdEx++ 4318 wire |= uint64(b&0x7F) << shift 4319 if b < 0x80 { 4320 break 4321 } 4322 } 4323 fieldNum := int32(wire >> 3) 4324 wireType := int(wire & 0x7) 4325 if wireType == 4 { 4326 return fmt.Errorf("proto: TransactionEvent: wiretype end group for non-group") 4327 } 4328 if fieldNum <= 0 { 4329 return fmt.Errorf("proto: TransactionEvent: illegal tag %d (wire type %d)", fieldNum, wire) 4330 } 4331 switch fieldNum { 4332 case 1: 4333 if wireType != 0 { 4334 return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) 4335 } 4336 m.Type = 0 4337 for shift := uint(0); ; shift += 7 { 4338 if shift >= 64 { 4339 return ErrIntOverflowTransaction 4340 } 4341 if iNdEx >= l { 4342 return io.ErrUnexpectedEOF 4343 } 4344 b := dAtA[iNdEx] 4345 iNdEx++ 4346 m.Type |= TransactionEvent_EventType(b&0x7F) << shift 4347 if b < 0x80 { 4348 break 4349 } 4350 } 4351 case 2: 4352 if wireType != 2 { 4353 return fmt.Errorf("proto: wrong wireType = %d for field Transaction", wireType) 4354 } 4355 var msglen int 4356 for shift := uint(0); ; shift += 7 { 4357 if shift >= 64 { 4358 return ErrIntOverflowTransaction 4359 } 4360 if iNdEx >= l { 4361 return io.ErrUnexpectedEOF 4362 } 4363 b := dAtA[iNdEx] 4364 iNdEx++ 4365 msglen |= int(b&0x7F) << shift 4366 if b < 0x80 { 4367 break 4368 } 4369 } 4370 if msglen < 0 { 4371 return ErrInvalidLengthTransaction 4372 } 4373 postIndex := iNdEx + msglen 4374 if postIndex < 0 { 4375 return ErrInvalidLengthTransaction 4376 } 4377 if postIndex > l { 4378 return io.ErrUnexpectedEOF 4379 } 4380 if err := m.Transaction.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 4381 return err 4382 } 4383 iNdEx = postIndex 4384 default: 4385 iNdEx = preIndex 4386 skippy, err := skipTransaction(dAtA[iNdEx:]) 4387 if err != nil { 4388 return err 4389 } 4390 if (skippy < 0) || (iNdEx+skippy) < 0 { 4391 return ErrInvalidLengthTransaction 4392 } 4393 if (iNdEx + skippy) > l { 4394 return io.ErrUnexpectedEOF 4395 } 4396 iNdEx += skippy 4397 } 4398 } 4399 4400 if iNdEx > l { 4401 return io.ErrUnexpectedEOF 4402 } 4403 return nil 4404 } 4405 func (m *TargetVersionOverrides) Unmarshal(dAtA []byte) error { 4406 l := len(dAtA) 4407 iNdEx := 0 4408 for iNdEx < l { 4409 preIndex := iNdEx 4410 var wire uint64 4411 for shift := uint(0); ; shift += 7 { 4412 if shift >= 64 { 4413 return ErrIntOverflowTransaction 4414 } 4415 if iNdEx >= l { 4416 return io.ErrUnexpectedEOF 4417 } 4418 b := dAtA[iNdEx] 4419 iNdEx++ 4420 wire |= uint64(b&0x7F) << shift 4421 if b < 0x80 { 4422 break 4423 } 4424 } 4425 fieldNum := int32(wire >> 3) 4426 wireType := int(wire & 0x7) 4427 if wireType == 4 { 4428 return fmt.Errorf("proto: TargetVersionOverrides: wiretype end group for non-group") 4429 } 4430 if fieldNum <= 0 { 4431 return fmt.Errorf("proto: TargetVersionOverrides: illegal tag %d (wire type %d)", fieldNum, wire) 4432 } 4433 switch fieldNum { 4434 case 1: 4435 if wireType != 2 { 4436 return fmt.Errorf("proto: wrong wireType = %d for field Overrides", wireType) 4437 } 4438 var msglen int 4439 for shift := uint(0); ; shift += 7 { 4440 if shift >= 64 { 4441 return ErrIntOverflowTransaction 4442 } 4443 if iNdEx >= l { 4444 return io.ErrUnexpectedEOF 4445 } 4446 b := dAtA[iNdEx] 4447 iNdEx++ 4448 msglen |= int(b&0x7F) << shift 4449 if b < 0x80 { 4450 break 4451 } 4452 } 4453 if msglen < 0 { 4454 return ErrInvalidLengthTransaction 4455 } 4456 postIndex := iNdEx + msglen 4457 if postIndex < 0 { 4458 return ErrInvalidLengthTransaction 4459 } 4460 if postIndex > l { 4461 return io.ErrUnexpectedEOF 4462 } 4463 if m.Overrides == nil { 4464 m.Overrides = make(map[string]*TargetTypeVersion) 4465 } 4466 var mapkey string 4467 var mapvalue *TargetTypeVersion 4468 for iNdEx < postIndex { 4469 entryPreIndex := iNdEx 4470 var wire uint64 4471 for shift := uint(0); ; shift += 7 { 4472 if shift >= 64 { 4473 return ErrIntOverflowTransaction 4474 } 4475 if iNdEx >= l { 4476 return io.ErrUnexpectedEOF 4477 } 4478 b := dAtA[iNdEx] 4479 iNdEx++ 4480 wire |= uint64(b&0x7F) << shift 4481 if b < 0x80 { 4482 break 4483 } 4484 } 4485 fieldNum := int32(wire >> 3) 4486 if fieldNum == 1 { 4487 var stringLenmapkey uint64 4488 for shift := uint(0); ; shift += 7 { 4489 if shift >= 64 { 4490 return ErrIntOverflowTransaction 4491 } 4492 if iNdEx >= l { 4493 return io.ErrUnexpectedEOF 4494 } 4495 b := dAtA[iNdEx] 4496 iNdEx++ 4497 stringLenmapkey |= uint64(b&0x7F) << shift 4498 if b < 0x80 { 4499 break 4500 } 4501 } 4502 intStringLenmapkey := int(stringLenmapkey) 4503 if intStringLenmapkey < 0 { 4504 return ErrInvalidLengthTransaction 4505 } 4506 postStringIndexmapkey := iNdEx + intStringLenmapkey 4507 if postStringIndexmapkey < 0 { 4508 return ErrInvalidLengthTransaction 4509 } 4510 if postStringIndexmapkey > l { 4511 return io.ErrUnexpectedEOF 4512 } 4513 mapkey = string(dAtA[iNdEx:postStringIndexmapkey]) 4514 iNdEx = postStringIndexmapkey 4515 } else if fieldNum == 2 { 4516 var mapmsglen int 4517 for shift := uint(0); ; shift += 7 { 4518 if shift >= 64 { 4519 return ErrIntOverflowTransaction 4520 } 4521 if iNdEx >= l { 4522 return io.ErrUnexpectedEOF 4523 } 4524 b := dAtA[iNdEx] 4525 iNdEx++ 4526 mapmsglen |= int(b&0x7F) << shift 4527 if b < 0x80 { 4528 break 4529 } 4530 } 4531 if mapmsglen < 0 { 4532 return ErrInvalidLengthTransaction 4533 } 4534 postmsgIndex := iNdEx + mapmsglen 4535 if postmsgIndex < 0 { 4536 return ErrInvalidLengthTransaction 4537 } 4538 if postmsgIndex > l { 4539 return io.ErrUnexpectedEOF 4540 } 4541 mapvalue = &TargetTypeVersion{} 4542 if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { 4543 return err 4544 } 4545 iNdEx = postmsgIndex 4546 } else { 4547 iNdEx = entryPreIndex 4548 skippy, err := skipTransaction(dAtA[iNdEx:]) 4549 if err != nil { 4550 return err 4551 } 4552 if (skippy < 0) || (iNdEx+skippy) < 0 { 4553 return ErrInvalidLengthTransaction 4554 } 4555 if (iNdEx + skippy) > postIndex { 4556 return io.ErrUnexpectedEOF 4557 } 4558 iNdEx += skippy 4559 } 4560 } 4561 m.Overrides[mapkey] = mapvalue 4562 iNdEx = postIndex 4563 default: 4564 iNdEx = preIndex 4565 skippy, err := skipTransaction(dAtA[iNdEx:]) 4566 if err != nil { 4567 return err 4568 } 4569 if (skippy < 0) || (iNdEx+skippy) < 0 { 4570 return ErrInvalidLengthTransaction 4571 } 4572 if (iNdEx + skippy) > l { 4573 return io.ErrUnexpectedEOF 4574 } 4575 iNdEx += skippy 4576 } 4577 } 4578 4579 if iNdEx > l { 4580 return io.ErrUnexpectedEOF 4581 } 4582 return nil 4583 } 4584 func skipTransaction(dAtA []byte) (n int, err error) { 4585 l := len(dAtA) 4586 iNdEx := 0 4587 depth := 0 4588 for iNdEx < l { 4589 var wire uint64 4590 for shift := uint(0); ; shift += 7 { 4591 if shift >= 64 { 4592 return 0, ErrIntOverflowTransaction 4593 } 4594 if iNdEx >= l { 4595 return 0, io.ErrUnexpectedEOF 4596 } 4597 b := dAtA[iNdEx] 4598 iNdEx++ 4599 wire |= (uint64(b) & 0x7F) << shift 4600 if b < 0x80 { 4601 break 4602 } 4603 } 4604 wireType := int(wire & 0x7) 4605 switch wireType { 4606 case 0: 4607 for shift := uint(0); ; shift += 7 { 4608 if shift >= 64 { 4609 return 0, ErrIntOverflowTransaction 4610 } 4611 if iNdEx >= l { 4612 return 0, io.ErrUnexpectedEOF 4613 } 4614 iNdEx++ 4615 if dAtA[iNdEx-1] < 0x80 { 4616 break 4617 } 4618 } 4619 case 1: 4620 iNdEx += 8 4621 case 2: 4622 var length int 4623 for shift := uint(0); ; shift += 7 { 4624 if shift >= 64 { 4625 return 0, ErrIntOverflowTransaction 4626 } 4627 if iNdEx >= l { 4628 return 0, io.ErrUnexpectedEOF 4629 } 4630 b := dAtA[iNdEx] 4631 iNdEx++ 4632 length |= (int(b) & 0x7F) << shift 4633 if b < 0x80 { 4634 break 4635 } 4636 } 4637 if length < 0 { 4638 return 0, ErrInvalidLengthTransaction 4639 } 4640 iNdEx += length 4641 case 3: 4642 depth++ 4643 case 4: 4644 if depth == 0 { 4645 return 0, ErrUnexpectedEndOfGroupTransaction 4646 } 4647 depth-- 4648 case 5: 4649 iNdEx += 4 4650 default: 4651 return 0, fmt.Errorf("proto: illegal wireType %d", wireType) 4652 } 4653 if iNdEx < 0 { 4654 return 0, ErrInvalidLengthTransaction 4655 } 4656 if depth == 0 { 4657 return iNdEx, nil 4658 } 4659 } 4660 return 0, io.ErrUnexpectedEOF 4661 } 4662 4663 var ( 4664 ErrInvalidLengthTransaction = fmt.Errorf("proto: negative length found during unmarshaling") 4665 ErrIntOverflowTransaction = fmt.Errorf("proto: integer overflow") 4666 ErrUnexpectedEndOfGroupTransaction = fmt.Errorf("proto: unexpected end of group") 4667 )