github.com/minio/minio@v0.0.0-20240328213742-3f72439b8a27/cmd/storage-datatypes_gen.go (about) 1 package cmd 2 3 // Code generated by github.com/tinylib/msgp DO NOT EDIT. 4 5 import ( 6 "github.com/tinylib/msgp/msgp" 7 ) 8 9 // DecodeMsg implements msgp.Decodable 10 func (z *BaseOptions) DecodeMsg(dc *msgp.Reader) (err error) { 11 var field []byte 12 _ = field 13 var zb0001 uint32 14 zb0001, err = dc.ReadMapHeader() 15 if err != nil { 16 err = msgp.WrapError(err) 17 return 18 } 19 for zb0001 > 0 { 20 zb0001-- 21 field, err = dc.ReadMapKeyPtr() 22 if err != nil { 23 err = msgp.WrapError(err) 24 return 25 } 26 switch msgp.UnsafeString(field) { 27 default: 28 err = dc.Skip() 29 if err != nil { 30 err = msgp.WrapError(err) 31 return 32 } 33 } 34 } 35 return 36 } 37 38 // EncodeMsg implements msgp.Encodable 39 func (z BaseOptions) EncodeMsg(en *msgp.Writer) (err error) { 40 // map header, size 0 41 _ = z 42 err = en.Append(0x80) 43 if err != nil { 44 return 45 } 46 return 47 } 48 49 // MarshalMsg implements msgp.Marshaler 50 func (z BaseOptions) MarshalMsg(b []byte) (o []byte, err error) { 51 o = msgp.Require(b, z.Msgsize()) 52 // map header, size 0 53 _ = z 54 o = append(o, 0x80) 55 return 56 } 57 58 // UnmarshalMsg implements msgp.Unmarshaler 59 func (z *BaseOptions) UnmarshalMsg(bts []byte) (o []byte, err error) { 60 var field []byte 61 _ = field 62 var zb0001 uint32 63 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 64 if err != nil { 65 err = msgp.WrapError(err) 66 return 67 } 68 for zb0001 > 0 { 69 zb0001-- 70 field, bts, err = msgp.ReadMapKeyZC(bts) 71 if err != nil { 72 err = msgp.WrapError(err) 73 return 74 } 75 switch msgp.UnsafeString(field) { 76 default: 77 bts, err = msgp.Skip(bts) 78 if err != nil { 79 err = msgp.WrapError(err) 80 return 81 } 82 } 83 } 84 o = bts 85 return 86 } 87 88 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 89 func (z BaseOptions) Msgsize() (s int) { 90 s = 1 91 return 92 } 93 94 // DecodeMsg implements msgp.Decodable 95 func (z *CheckPartsHandlerParams) DecodeMsg(dc *msgp.Reader) (err error) { 96 var field []byte 97 _ = field 98 var zb0001 uint32 99 zb0001, err = dc.ReadMapHeader() 100 if err != nil { 101 err = msgp.WrapError(err) 102 return 103 } 104 for zb0001 > 0 { 105 zb0001-- 106 field, err = dc.ReadMapKeyPtr() 107 if err != nil { 108 err = msgp.WrapError(err) 109 return 110 } 111 switch msgp.UnsafeString(field) { 112 case "id": 113 z.DiskID, err = dc.ReadString() 114 if err != nil { 115 err = msgp.WrapError(err, "DiskID") 116 return 117 } 118 case "v": 119 z.Volume, err = dc.ReadString() 120 if err != nil { 121 err = msgp.WrapError(err, "Volume") 122 return 123 } 124 case "fp": 125 z.FilePath, err = dc.ReadString() 126 if err != nil { 127 err = msgp.WrapError(err, "FilePath") 128 return 129 } 130 case "fi": 131 err = z.FI.DecodeMsg(dc) 132 if err != nil { 133 err = msgp.WrapError(err, "FI") 134 return 135 } 136 default: 137 err = dc.Skip() 138 if err != nil { 139 err = msgp.WrapError(err) 140 return 141 } 142 } 143 } 144 return 145 } 146 147 // EncodeMsg implements msgp.Encodable 148 func (z *CheckPartsHandlerParams) EncodeMsg(en *msgp.Writer) (err error) { 149 // map header, size 4 150 // write "id" 151 err = en.Append(0x84, 0xa2, 0x69, 0x64) 152 if err != nil { 153 return 154 } 155 err = en.WriteString(z.DiskID) 156 if err != nil { 157 err = msgp.WrapError(err, "DiskID") 158 return 159 } 160 // write "v" 161 err = en.Append(0xa1, 0x76) 162 if err != nil { 163 return 164 } 165 err = en.WriteString(z.Volume) 166 if err != nil { 167 err = msgp.WrapError(err, "Volume") 168 return 169 } 170 // write "fp" 171 err = en.Append(0xa2, 0x66, 0x70) 172 if err != nil { 173 return 174 } 175 err = en.WriteString(z.FilePath) 176 if err != nil { 177 err = msgp.WrapError(err, "FilePath") 178 return 179 } 180 // write "fi" 181 err = en.Append(0xa2, 0x66, 0x69) 182 if err != nil { 183 return 184 } 185 err = z.FI.EncodeMsg(en) 186 if err != nil { 187 err = msgp.WrapError(err, "FI") 188 return 189 } 190 return 191 } 192 193 // MarshalMsg implements msgp.Marshaler 194 func (z *CheckPartsHandlerParams) MarshalMsg(b []byte) (o []byte, err error) { 195 o = msgp.Require(b, z.Msgsize()) 196 // map header, size 4 197 // string "id" 198 o = append(o, 0x84, 0xa2, 0x69, 0x64) 199 o = msgp.AppendString(o, z.DiskID) 200 // string "v" 201 o = append(o, 0xa1, 0x76) 202 o = msgp.AppendString(o, z.Volume) 203 // string "fp" 204 o = append(o, 0xa2, 0x66, 0x70) 205 o = msgp.AppendString(o, z.FilePath) 206 // string "fi" 207 o = append(o, 0xa2, 0x66, 0x69) 208 o, err = z.FI.MarshalMsg(o) 209 if err != nil { 210 err = msgp.WrapError(err, "FI") 211 return 212 } 213 return 214 } 215 216 // UnmarshalMsg implements msgp.Unmarshaler 217 func (z *CheckPartsHandlerParams) UnmarshalMsg(bts []byte) (o []byte, err error) { 218 var field []byte 219 _ = field 220 var zb0001 uint32 221 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 222 if err != nil { 223 err = msgp.WrapError(err) 224 return 225 } 226 for zb0001 > 0 { 227 zb0001-- 228 field, bts, err = msgp.ReadMapKeyZC(bts) 229 if err != nil { 230 err = msgp.WrapError(err) 231 return 232 } 233 switch msgp.UnsafeString(field) { 234 case "id": 235 z.DiskID, bts, err = msgp.ReadStringBytes(bts) 236 if err != nil { 237 err = msgp.WrapError(err, "DiskID") 238 return 239 } 240 case "v": 241 z.Volume, bts, err = msgp.ReadStringBytes(bts) 242 if err != nil { 243 err = msgp.WrapError(err, "Volume") 244 return 245 } 246 case "fp": 247 z.FilePath, bts, err = msgp.ReadStringBytes(bts) 248 if err != nil { 249 err = msgp.WrapError(err, "FilePath") 250 return 251 } 252 case "fi": 253 bts, err = z.FI.UnmarshalMsg(bts) 254 if err != nil { 255 err = msgp.WrapError(err, "FI") 256 return 257 } 258 default: 259 bts, err = msgp.Skip(bts) 260 if err != nil { 261 err = msgp.WrapError(err) 262 return 263 } 264 } 265 } 266 o = bts 267 return 268 } 269 270 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 271 func (z *CheckPartsHandlerParams) Msgsize() (s int) { 272 s = 1 + 3 + msgp.StringPrefixSize + len(z.DiskID) + 2 + msgp.StringPrefixSize + len(z.Volume) + 3 + msgp.StringPrefixSize + len(z.FilePath) + 3 + z.FI.Msgsize() 273 return 274 } 275 276 // DecodeMsg implements msgp.Decodable 277 func (z *DeleteFileHandlerParams) DecodeMsg(dc *msgp.Reader) (err error) { 278 var field []byte 279 _ = field 280 var zb0001 uint32 281 zb0001, err = dc.ReadMapHeader() 282 if err != nil { 283 err = msgp.WrapError(err) 284 return 285 } 286 for zb0001 > 0 { 287 zb0001-- 288 field, err = dc.ReadMapKeyPtr() 289 if err != nil { 290 err = msgp.WrapError(err) 291 return 292 } 293 switch msgp.UnsafeString(field) { 294 case "id": 295 z.DiskID, err = dc.ReadString() 296 if err != nil { 297 err = msgp.WrapError(err, "DiskID") 298 return 299 } 300 case "v": 301 z.Volume, err = dc.ReadString() 302 if err != nil { 303 err = msgp.WrapError(err, "Volume") 304 return 305 } 306 case "fp": 307 z.FilePath, err = dc.ReadString() 308 if err != nil { 309 err = msgp.WrapError(err, "FilePath") 310 return 311 } 312 case "do": 313 err = z.Opts.DecodeMsg(dc) 314 if err != nil { 315 err = msgp.WrapError(err, "Opts") 316 return 317 } 318 default: 319 err = dc.Skip() 320 if err != nil { 321 err = msgp.WrapError(err) 322 return 323 } 324 } 325 } 326 return 327 } 328 329 // EncodeMsg implements msgp.Encodable 330 func (z *DeleteFileHandlerParams) EncodeMsg(en *msgp.Writer) (err error) { 331 // map header, size 4 332 // write "id" 333 err = en.Append(0x84, 0xa2, 0x69, 0x64) 334 if err != nil { 335 return 336 } 337 err = en.WriteString(z.DiskID) 338 if err != nil { 339 err = msgp.WrapError(err, "DiskID") 340 return 341 } 342 // write "v" 343 err = en.Append(0xa1, 0x76) 344 if err != nil { 345 return 346 } 347 err = en.WriteString(z.Volume) 348 if err != nil { 349 err = msgp.WrapError(err, "Volume") 350 return 351 } 352 // write "fp" 353 err = en.Append(0xa2, 0x66, 0x70) 354 if err != nil { 355 return 356 } 357 err = en.WriteString(z.FilePath) 358 if err != nil { 359 err = msgp.WrapError(err, "FilePath") 360 return 361 } 362 // write "do" 363 err = en.Append(0xa2, 0x64, 0x6f) 364 if err != nil { 365 return 366 } 367 err = z.Opts.EncodeMsg(en) 368 if err != nil { 369 err = msgp.WrapError(err, "Opts") 370 return 371 } 372 return 373 } 374 375 // MarshalMsg implements msgp.Marshaler 376 func (z *DeleteFileHandlerParams) MarshalMsg(b []byte) (o []byte, err error) { 377 o = msgp.Require(b, z.Msgsize()) 378 // map header, size 4 379 // string "id" 380 o = append(o, 0x84, 0xa2, 0x69, 0x64) 381 o = msgp.AppendString(o, z.DiskID) 382 // string "v" 383 o = append(o, 0xa1, 0x76) 384 o = msgp.AppendString(o, z.Volume) 385 // string "fp" 386 o = append(o, 0xa2, 0x66, 0x70) 387 o = msgp.AppendString(o, z.FilePath) 388 // string "do" 389 o = append(o, 0xa2, 0x64, 0x6f) 390 o, err = z.Opts.MarshalMsg(o) 391 if err != nil { 392 err = msgp.WrapError(err, "Opts") 393 return 394 } 395 return 396 } 397 398 // UnmarshalMsg implements msgp.Unmarshaler 399 func (z *DeleteFileHandlerParams) UnmarshalMsg(bts []byte) (o []byte, err error) { 400 var field []byte 401 _ = field 402 var zb0001 uint32 403 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 404 if err != nil { 405 err = msgp.WrapError(err) 406 return 407 } 408 for zb0001 > 0 { 409 zb0001-- 410 field, bts, err = msgp.ReadMapKeyZC(bts) 411 if err != nil { 412 err = msgp.WrapError(err) 413 return 414 } 415 switch msgp.UnsafeString(field) { 416 case "id": 417 z.DiskID, bts, err = msgp.ReadStringBytes(bts) 418 if err != nil { 419 err = msgp.WrapError(err, "DiskID") 420 return 421 } 422 case "v": 423 z.Volume, bts, err = msgp.ReadStringBytes(bts) 424 if err != nil { 425 err = msgp.WrapError(err, "Volume") 426 return 427 } 428 case "fp": 429 z.FilePath, bts, err = msgp.ReadStringBytes(bts) 430 if err != nil { 431 err = msgp.WrapError(err, "FilePath") 432 return 433 } 434 case "do": 435 bts, err = z.Opts.UnmarshalMsg(bts) 436 if err != nil { 437 err = msgp.WrapError(err, "Opts") 438 return 439 } 440 default: 441 bts, err = msgp.Skip(bts) 442 if err != nil { 443 err = msgp.WrapError(err) 444 return 445 } 446 } 447 } 448 o = bts 449 return 450 } 451 452 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 453 func (z *DeleteFileHandlerParams) Msgsize() (s int) { 454 s = 1 + 3 + msgp.StringPrefixSize + len(z.DiskID) + 2 + msgp.StringPrefixSize + len(z.Volume) + 3 + msgp.StringPrefixSize + len(z.FilePath) + 3 + z.Opts.Msgsize() 455 return 456 } 457 458 // DecodeMsg implements msgp.Decodable 459 func (z *DeleteOptions) DecodeMsg(dc *msgp.Reader) (err error) { 460 var field []byte 461 _ = field 462 var zb0001 uint32 463 zb0001, err = dc.ReadMapHeader() 464 if err != nil { 465 err = msgp.WrapError(err) 466 return 467 } 468 for zb0001 > 0 { 469 zb0001-- 470 field, err = dc.ReadMapKeyPtr() 471 if err != nil { 472 err = msgp.WrapError(err) 473 return 474 } 475 switch msgp.UnsafeString(field) { 476 case "BaseOptions": 477 var zb0002 uint32 478 zb0002, err = dc.ReadMapHeader() 479 if err != nil { 480 err = msgp.WrapError(err, "BaseOptions") 481 return 482 } 483 for zb0002 > 0 { 484 zb0002-- 485 field, err = dc.ReadMapKeyPtr() 486 if err != nil { 487 err = msgp.WrapError(err, "BaseOptions") 488 return 489 } 490 switch msgp.UnsafeString(field) { 491 default: 492 err = dc.Skip() 493 if err != nil { 494 err = msgp.WrapError(err, "BaseOptions") 495 return 496 } 497 } 498 } 499 case "r": 500 z.Recursive, err = dc.ReadBool() 501 if err != nil { 502 err = msgp.WrapError(err, "Recursive") 503 return 504 } 505 case "i": 506 z.Immediate, err = dc.ReadBool() 507 if err != nil { 508 err = msgp.WrapError(err, "Immediate") 509 return 510 } 511 case "u": 512 z.UndoWrite, err = dc.ReadBool() 513 if err != nil { 514 err = msgp.WrapError(err, "UndoWrite") 515 return 516 } 517 default: 518 err = dc.Skip() 519 if err != nil { 520 err = msgp.WrapError(err) 521 return 522 } 523 } 524 } 525 return 526 } 527 528 // EncodeMsg implements msgp.Encodable 529 func (z *DeleteOptions) EncodeMsg(en *msgp.Writer) (err error) { 530 // map header, size 4 531 // write "BaseOptions" 532 err = en.Append(0x84, 0xab, 0x42, 0x61, 0x73, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73) 533 if err != nil { 534 return 535 } 536 // map header, size 0 537 _ = z.BaseOptions 538 err = en.Append(0x80) 539 if err != nil { 540 return 541 } 542 // write "r" 543 err = en.Append(0xa1, 0x72) 544 if err != nil { 545 return 546 } 547 err = en.WriteBool(z.Recursive) 548 if err != nil { 549 err = msgp.WrapError(err, "Recursive") 550 return 551 } 552 // write "i" 553 err = en.Append(0xa1, 0x69) 554 if err != nil { 555 return 556 } 557 err = en.WriteBool(z.Immediate) 558 if err != nil { 559 err = msgp.WrapError(err, "Immediate") 560 return 561 } 562 // write "u" 563 err = en.Append(0xa1, 0x75) 564 if err != nil { 565 return 566 } 567 err = en.WriteBool(z.UndoWrite) 568 if err != nil { 569 err = msgp.WrapError(err, "UndoWrite") 570 return 571 } 572 return 573 } 574 575 // MarshalMsg implements msgp.Marshaler 576 func (z *DeleteOptions) MarshalMsg(b []byte) (o []byte, err error) { 577 o = msgp.Require(b, z.Msgsize()) 578 // map header, size 4 579 // string "BaseOptions" 580 o = append(o, 0x84, 0xab, 0x42, 0x61, 0x73, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73) 581 // map header, size 0 582 _ = z.BaseOptions 583 o = append(o, 0x80) 584 // string "r" 585 o = append(o, 0xa1, 0x72) 586 o = msgp.AppendBool(o, z.Recursive) 587 // string "i" 588 o = append(o, 0xa1, 0x69) 589 o = msgp.AppendBool(o, z.Immediate) 590 // string "u" 591 o = append(o, 0xa1, 0x75) 592 o = msgp.AppendBool(o, z.UndoWrite) 593 return 594 } 595 596 // UnmarshalMsg implements msgp.Unmarshaler 597 func (z *DeleteOptions) UnmarshalMsg(bts []byte) (o []byte, err error) { 598 var field []byte 599 _ = field 600 var zb0001 uint32 601 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 602 if err != nil { 603 err = msgp.WrapError(err) 604 return 605 } 606 for zb0001 > 0 { 607 zb0001-- 608 field, bts, err = msgp.ReadMapKeyZC(bts) 609 if err != nil { 610 err = msgp.WrapError(err) 611 return 612 } 613 switch msgp.UnsafeString(field) { 614 case "BaseOptions": 615 var zb0002 uint32 616 zb0002, bts, err = msgp.ReadMapHeaderBytes(bts) 617 if err != nil { 618 err = msgp.WrapError(err, "BaseOptions") 619 return 620 } 621 for zb0002 > 0 { 622 zb0002-- 623 field, bts, err = msgp.ReadMapKeyZC(bts) 624 if err != nil { 625 err = msgp.WrapError(err, "BaseOptions") 626 return 627 } 628 switch msgp.UnsafeString(field) { 629 default: 630 bts, err = msgp.Skip(bts) 631 if err != nil { 632 err = msgp.WrapError(err, "BaseOptions") 633 return 634 } 635 } 636 } 637 case "r": 638 z.Recursive, bts, err = msgp.ReadBoolBytes(bts) 639 if err != nil { 640 err = msgp.WrapError(err, "Recursive") 641 return 642 } 643 case "i": 644 z.Immediate, bts, err = msgp.ReadBoolBytes(bts) 645 if err != nil { 646 err = msgp.WrapError(err, "Immediate") 647 return 648 } 649 case "u": 650 z.UndoWrite, bts, err = msgp.ReadBoolBytes(bts) 651 if err != nil { 652 err = msgp.WrapError(err, "UndoWrite") 653 return 654 } 655 default: 656 bts, err = msgp.Skip(bts) 657 if err != nil { 658 err = msgp.WrapError(err) 659 return 660 } 661 } 662 } 663 o = bts 664 return 665 } 666 667 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 668 func (z *DeleteOptions) Msgsize() (s int) { 669 s = 1 + 12 + 1 + 2 + msgp.BoolSize + 2 + msgp.BoolSize + 2 + msgp.BoolSize 670 return 671 } 672 673 // DecodeMsg implements msgp.Decodable 674 func (z *DeleteVersionHandlerParams) DecodeMsg(dc *msgp.Reader) (err error) { 675 var field []byte 676 _ = field 677 var zb0001 uint32 678 zb0001, err = dc.ReadMapHeader() 679 if err != nil { 680 err = msgp.WrapError(err) 681 return 682 } 683 for zb0001 > 0 { 684 zb0001-- 685 field, err = dc.ReadMapKeyPtr() 686 if err != nil { 687 err = msgp.WrapError(err) 688 return 689 } 690 switch msgp.UnsafeString(field) { 691 case "id": 692 z.DiskID, err = dc.ReadString() 693 if err != nil { 694 err = msgp.WrapError(err, "DiskID") 695 return 696 } 697 case "v": 698 z.Volume, err = dc.ReadString() 699 if err != nil { 700 err = msgp.WrapError(err, "Volume") 701 return 702 } 703 case "fp": 704 z.FilePath, err = dc.ReadString() 705 if err != nil { 706 err = msgp.WrapError(err, "FilePath") 707 return 708 } 709 case "fdm": 710 z.ForceDelMarker, err = dc.ReadBool() 711 if err != nil { 712 err = msgp.WrapError(err, "ForceDelMarker") 713 return 714 } 715 case "do": 716 err = z.Opts.DecodeMsg(dc) 717 if err != nil { 718 err = msgp.WrapError(err, "Opts") 719 return 720 } 721 case "fi": 722 err = z.FI.DecodeMsg(dc) 723 if err != nil { 724 err = msgp.WrapError(err, "FI") 725 return 726 } 727 default: 728 err = dc.Skip() 729 if err != nil { 730 err = msgp.WrapError(err) 731 return 732 } 733 } 734 } 735 return 736 } 737 738 // EncodeMsg implements msgp.Encodable 739 func (z *DeleteVersionHandlerParams) EncodeMsg(en *msgp.Writer) (err error) { 740 // map header, size 6 741 // write "id" 742 err = en.Append(0x86, 0xa2, 0x69, 0x64) 743 if err != nil { 744 return 745 } 746 err = en.WriteString(z.DiskID) 747 if err != nil { 748 err = msgp.WrapError(err, "DiskID") 749 return 750 } 751 // write "v" 752 err = en.Append(0xa1, 0x76) 753 if err != nil { 754 return 755 } 756 err = en.WriteString(z.Volume) 757 if err != nil { 758 err = msgp.WrapError(err, "Volume") 759 return 760 } 761 // write "fp" 762 err = en.Append(0xa2, 0x66, 0x70) 763 if err != nil { 764 return 765 } 766 err = en.WriteString(z.FilePath) 767 if err != nil { 768 err = msgp.WrapError(err, "FilePath") 769 return 770 } 771 // write "fdm" 772 err = en.Append(0xa3, 0x66, 0x64, 0x6d) 773 if err != nil { 774 return 775 } 776 err = en.WriteBool(z.ForceDelMarker) 777 if err != nil { 778 err = msgp.WrapError(err, "ForceDelMarker") 779 return 780 } 781 // write "do" 782 err = en.Append(0xa2, 0x64, 0x6f) 783 if err != nil { 784 return 785 } 786 err = z.Opts.EncodeMsg(en) 787 if err != nil { 788 err = msgp.WrapError(err, "Opts") 789 return 790 } 791 // write "fi" 792 err = en.Append(0xa2, 0x66, 0x69) 793 if err != nil { 794 return 795 } 796 err = z.FI.EncodeMsg(en) 797 if err != nil { 798 err = msgp.WrapError(err, "FI") 799 return 800 } 801 return 802 } 803 804 // MarshalMsg implements msgp.Marshaler 805 func (z *DeleteVersionHandlerParams) MarshalMsg(b []byte) (o []byte, err error) { 806 o = msgp.Require(b, z.Msgsize()) 807 // map header, size 6 808 // string "id" 809 o = append(o, 0x86, 0xa2, 0x69, 0x64) 810 o = msgp.AppendString(o, z.DiskID) 811 // string "v" 812 o = append(o, 0xa1, 0x76) 813 o = msgp.AppendString(o, z.Volume) 814 // string "fp" 815 o = append(o, 0xa2, 0x66, 0x70) 816 o = msgp.AppendString(o, z.FilePath) 817 // string "fdm" 818 o = append(o, 0xa3, 0x66, 0x64, 0x6d) 819 o = msgp.AppendBool(o, z.ForceDelMarker) 820 // string "do" 821 o = append(o, 0xa2, 0x64, 0x6f) 822 o, err = z.Opts.MarshalMsg(o) 823 if err != nil { 824 err = msgp.WrapError(err, "Opts") 825 return 826 } 827 // string "fi" 828 o = append(o, 0xa2, 0x66, 0x69) 829 o, err = z.FI.MarshalMsg(o) 830 if err != nil { 831 err = msgp.WrapError(err, "FI") 832 return 833 } 834 return 835 } 836 837 // UnmarshalMsg implements msgp.Unmarshaler 838 func (z *DeleteVersionHandlerParams) UnmarshalMsg(bts []byte) (o []byte, err error) { 839 var field []byte 840 _ = field 841 var zb0001 uint32 842 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 843 if err != nil { 844 err = msgp.WrapError(err) 845 return 846 } 847 for zb0001 > 0 { 848 zb0001-- 849 field, bts, err = msgp.ReadMapKeyZC(bts) 850 if err != nil { 851 err = msgp.WrapError(err) 852 return 853 } 854 switch msgp.UnsafeString(field) { 855 case "id": 856 z.DiskID, bts, err = msgp.ReadStringBytes(bts) 857 if err != nil { 858 err = msgp.WrapError(err, "DiskID") 859 return 860 } 861 case "v": 862 z.Volume, bts, err = msgp.ReadStringBytes(bts) 863 if err != nil { 864 err = msgp.WrapError(err, "Volume") 865 return 866 } 867 case "fp": 868 z.FilePath, bts, err = msgp.ReadStringBytes(bts) 869 if err != nil { 870 err = msgp.WrapError(err, "FilePath") 871 return 872 } 873 case "fdm": 874 z.ForceDelMarker, bts, err = msgp.ReadBoolBytes(bts) 875 if err != nil { 876 err = msgp.WrapError(err, "ForceDelMarker") 877 return 878 } 879 case "do": 880 bts, err = z.Opts.UnmarshalMsg(bts) 881 if err != nil { 882 err = msgp.WrapError(err, "Opts") 883 return 884 } 885 case "fi": 886 bts, err = z.FI.UnmarshalMsg(bts) 887 if err != nil { 888 err = msgp.WrapError(err, "FI") 889 return 890 } 891 default: 892 bts, err = msgp.Skip(bts) 893 if err != nil { 894 err = msgp.WrapError(err) 895 return 896 } 897 } 898 } 899 o = bts 900 return 901 } 902 903 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 904 func (z *DeleteVersionHandlerParams) Msgsize() (s int) { 905 s = 1 + 3 + msgp.StringPrefixSize + len(z.DiskID) + 2 + msgp.StringPrefixSize + len(z.Volume) + 3 + msgp.StringPrefixSize + len(z.FilePath) + 4 + msgp.BoolSize + 3 + z.Opts.Msgsize() + 3 + z.FI.Msgsize() 906 return 907 } 908 909 // DecodeMsg implements msgp.Decodable 910 func (z *DiskInfo) DecodeMsg(dc *msgp.Reader) (err error) { 911 var zb0001 uint32 912 zb0001, err = dc.ReadArrayHeader() 913 if err != nil { 914 err = msgp.WrapError(err) 915 return 916 } 917 if zb0001 != 18 { 918 err = msgp.ArrayError{Wanted: 18, Got: zb0001} 919 return 920 } 921 z.Total, err = dc.ReadUint64() 922 if err != nil { 923 err = msgp.WrapError(err, "Total") 924 return 925 } 926 z.Free, err = dc.ReadUint64() 927 if err != nil { 928 err = msgp.WrapError(err, "Free") 929 return 930 } 931 z.Used, err = dc.ReadUint64() 932 if err != nil { 933 err = msgp.WrapError(err, "Used") 934 return 935 } 936 z.UsedInodes, err = dc.ReadUint64() 937 if err != nil { 938 err = msgp.WrapError(err, "UsedInodes") 939 return 940 } 941 z.FreeInodes, err = dc.ReadUint64() 942 if err != nil { 943 err = msgp.WrapError(err, "FreeInodes") 944 return 945 } 946 z.Major, err = dc.ReadUint32() 947 if err != nil { 948 err = msgp.WrapError(err, "Major") 949 return 950 } 951 z.Minor, err = dc.ReadUint32() 952 if err != nil { 953 err = msgp.WrapError(err, "Minor") 954 return 955 } 956 z.NRRequests, err = dc.ReadUint64() 957 if err != nil { 958 err = msgp.WrapError(err, "NRRequests") 959 return 960 } 961 z.FSType, err = dc.ReadString() 962 if err != nil { 963 err = msgp.WrapError(err, "FSType") 964 return 965 } 966 z.RootDisk, err = dc.ReadBool() 967 if err != nil { 968 err = msgp.WrapError(err, "RootDisk") 969 return 970 } 971 z.Healing, err = dc.ReadBool() 972 if err != nil { 973 err = msgp.WrapError(err, "Healing") 974 return 975 } 976 z.Scanning, err = dc.ReadBool() 977 if err != nil { 978 err = msgp.WrapError(err, "Scanning") 979 return 980 } 981 z.Endpoint, err = dc.ReadString() 982 if err != nil { 983 err = msgp.WrapError(err, "Endpoint") 984 return 985 } 986 z.MountPath, err = dc.ReadString() 987 if err != nil { 988 err = msgp.WrapError(err, "MountPath") 989 return 990 } 991 z.ID, err = dc.ReadString() 992 if err != nil { 993 err = msgp.WrapError(err, "ID") 994 return 995 } 996 z.Rotational, err = dc.ReadBool() 997 if err != nil { 998 err = msgp.WrapError(err, "Rotational") 999 return 1000 } 1001 err = z.Metrics.DecodeMsg(dc) 1002 if err != nil { 1003 err = msgp.WrapError(err, "Metrics") 1004 return 1005 } 1006 z.Error, err = dc.ReadString() 1007 if err != nil { 1008 err = msgp.WrapError(err, "Error") 1009 return 1010 } 1011 return 1012 } 1013 1014 // EncodeMsg implements msgp.Encodable 1015 func (z *DiskInfo) EncodeMsg(en *msgp.Writer) (err error) { 1016 // array header, size 18 1017 err = en.Append(0xdc, 0x0, 0x12) 1018 if err != nil { 1019 return 1020 } 1021 err = en.WriteUint64(z.Total) 1022 if err != nil { 1023 err = msgp.WrapError(err, "Total") 1024 return 1025 } 1026 err = en.WriteUint64(z.Free) 1027 if err != nil { 1028 err = msgp.WrapError(err, "Free") 1029 return 1030 } 1031 err = en.WriteUint64(z.Used) 1032 if err != nil { 1033 err = msgp.WrapError(err, "Used") 1034 return 1035 } 1036 err = en.WriteUint64(z.UsedInodes) 1037 if err != nil { 1038 err = msgp.WrapError(err, "UsedInodes") 1039 return 1040 } 1041 err = en.WriteUint64(z.FreeInodes) 1042 if err != nil { 1043 err = msgp.WrapError(err, "FreeInodes") 1044 return 1045 } 1046 err = en.WriteUint32(z.Major) 1047 if err != nil { 1048 err = msgp.WrapError(err, "Major") 1049 return 1050 } 1051 err = en.WriteUint32(z.Minor) 1052 if err != nil { 1053 err = msgp.WrapError(err, "Minor") 1054 return 1055 } 1056 err = en.WriteUint64(z.NRRequests) 1057 if err != nil { 1058 err = msgp.WrapError(err, "NRRequests") 1059 return 1060 } 1061 err = en.WriteString(z.FSType) 1062 if err != nil { 1063 err = msgp.WrapError(err, "FSType") 1064 return 1065 } 1066 err = en.WriteBool(z.RootDisk) 1067 if err != nil { 1068 err = msgp.WrapError(err, "RootDisk") 1069 return 1070 } 1071 err = en.WriteBool(z.Healing) 1072 if err != nil { 1073 err = msgp.WrapError(err, "Healing") 1074 return 1075 } 1076 err = en.WriteBool(z.Scanning) 1077 if err != nil { 1078 err = msgp.WrapError(err, "Scanning") 1079 return 1080 } 1081 err = en.WriteString(z.Endpoint) 1082 if err != nil { 1083 err = msgp.WrapError(err, "Endpoint") 1084 return 1085 } 1086 err = en.WriteString(z.MountPath) 1087 if err != nil { 1088 err = msgp.WrapError(err, "MountPath") 1089 return 1090 } 1091 err = en.WriteString(z.ID) 1092 if err != nil { 1093 err = msgp.WrapError(err, "ID") 1094 return 1095 } 1096 err = en.WriteBool(z.Rotational) 1097 if err != nil { 1098 err = msgp.WrapError(err, "Rotational") 1099 return 1100 } 1101 err = z.Metrics.EncodeMsg(en) 1102 if err != nil { 1103 err = msgp.WrapError(err, "Metrics") 1104 return 1105 } 1106 err = en.WriteString(z.Error) 1107 if err != nil { 1108 err = msgp.WrapError(err, "Error") 1109 return 1110 } 1111 return 1112 } 1113 1114 // MarshalMsg implements msgp.Marshaler 1115 func (z *DiskInfo) MarshalMsg(b []byte) (o []byte, err error) { 1116 o = msgp.Require(b, z.Msgsize()) 1117 // array header, size 18 1118 o = append(o, 0xdc, 0x0, 0x12) 1119 o = msgp.AppendUint64(o, z.Total) 1120 o = msgp.AppendUint64(o, z.Free) 1121 o = msgp.AppendUint64(o, z.Used) 1122 o = msgp.AppendUint64(o, z.UsedInodes) 1123 o = msgp.AppendUint64(o, z.FreeInodes) 1124 o = msgp.AppendUint32(o, z.Major) 1125 o = msgp.AppendUint32(o, z.Minor) 1126 o = msgp.AppendUint64(o, z.NRRequests) 1127 o = msgp.AppendString(o, z.FSType) 1128 o = msgp.AppendBool(o, z.RootDisk) 1129 o = msgp.AppendBool(o, z.Healing) 1130 o = msgp.AppendBool(o, z.Scanning) 1131 o = msgp.AppendString(o, z.Endpoint) 1132 o = msgp.AppendString(o, z.MountPath) 1133 o = msgp.AppendString(o, z.ID) 1134 o = msgp.AppendBool(o, z.Rotational) 1135 o, err = z.Metrics.MarshalMsg(o) 1136 if err != nil { 1137 err = msgp.WrapError(err, "Metrics") 1138 return 1139 } 1140 o = msgp.AppendString(o, z.Error) 1141 return 1142 } 1143 1144 // UnmarshalMsg implements msgp.Unmarshaler 1145 func (z *DiskInfo) UnmarshalMsg(bts []byte) (o []byte, err error) { 1146 var zb0001 uint32 1147 zb0001, bts, err = msgp.ReadArrayHeaderBytes(bts) 1148 if err != nil { 1149 err = msgp.WrapError(err) 1150 return 1151 } 1152 if zb0001 != 18 { 1153 err = msgp.ArrayError{Wanted: 18, Got: zb0001} 1154 return 1155 } 1156 z.Total, bts, err = msgp.ReadUint64Bytes(bts) 1157 if err != nil { 1158 err = msgp.WrapError(err, "Total") 1159 return 1160 } 1161 z.Free, bts, err = msgp.ReadUint64Bytes(bts) 1162 if err != nil { 1163 err = msgp.WrapError(err, "Free") 1164 return 1165 } 1166 z.Used, bts, err = msgp.ReadUint64Bytes(bts) 1167 if err != nil { 1168 err = msgp.WrapError(err, "Used") 1169 return 1170 } 1171 z.UsedInodes, bts, err = msgp.ReadUint64Bytes(bts) 1172 if err != nil { 1173 err = msgp.WrapError(err, "UsedInodes") 1174 return 1175 } 1176 z.FreeInodes, bts, err = msgp.ReadUint64Bytes(bts) 1177 if err != nil { 1178 err = msgp.WrapError(err, "FreeInodes") 1179 return 1180 } 1181 z.Major, bts, err = msgp.ReadUint32Bytes(bts) 1182 if err != nil { 1183 err = msgp.WrapError(err, "Major") 1184 return 1185 } 1186 z.Minor, bts, err = msgp.ReadUint32Bytes(bts) 1187 if err != nil { 1188 err = msgp.WrapError(err, "Minor") 1189 return 1190 } 1191 z.NRRequests, bts, err = msgp.ReadUint64Bytes(bts) 1192 if err != nil { 1193 err = msgp.WrapError(err, "NRRequests") 1194 return 1195 } 1196 z.FSType, bts, err = msgp.ReadStringBytes(bts) 1197 if err != nil { 1198 err = msgp.WrapError(err, "FSType") 1199 return 1200 } 1201 z.RootDisk, bts, err = msgp.ReadBoolBytes(bts) 1202 if err != nil { 1203 err = msgp.WrapError(err, "RootDisk") 1204 return 1205 } 1206 z.Healing, bts, err = msgp.ReadBoolBytes(bts) 1207 if err != nil { 1208 err = msgp.WrapError(err, "Healing") 1209 return 1210 } 1211 z.Scanning, bts, err = msgp.ReadBoolBytes(bts) 1212 if err != nil { 1213 err = msgp.WrapError(err, "Scanning") 1214 return 1215 } 1216 z.Endpoint, bts, err = msgp.ReadStringBytes(bts) 1217 if err != nil { 1218 err = msgp.WrapError(err, "Endpoint") 1219 return 1220 } 1221 z.MountPath, bts, err = msgp.ReadStringBytes(bts) 1222 if err != nil { 1223 err = msgp.WrapError(err, "MountPath") 1224 return 1225 } 1226 z.ID, bts, err = msgp.ReadStringBytes(bts) 1227 if err != nil { 1228 err = msgp.WrapError(err, "ID") 1229 return 1230 } 1231 z.Rotational, bts, err = msgp.ReadBoolBytes(bts) 1232 if err != nil { 1233 err = msgp.WrapError(err, "Rotational") 1234 return 1235 } 1236 bts, err = z.Metrics.UnmarshalMsg(bts) 1237 if err != nil { 1238 err = msgp.WrapError(err, "Metrics") 1239 return 1240 } 1241 z.Error, bts, err = msgp.ReadStringBytes(bts) 1242 if err != nil { 1243 err = msgp.WrapError(err, "Error") 1244 return 1245 } 1246 o = bts 1247 return 1248 } 1249 1250 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 1251 func (z *DiskInfo) Msgsize() (s int) { 1252 s = 3 + msgp.Uint64Size + msgp.Uint64Size + msgp.Uint64Size + msgp.Uint64Size + msgp.Uint64Size + msgp.Uint32Size + msgp.Uint32Size + msgp.Uint64Size + msgp.StringPrefixSize + len(z.FSType) + msgp.BoolSize + msgp.BoolSize + msgp.BoolSize + msgp.StringPrefixSize + len(z.Endpoint) + msgp.StringPrefixSize + len(z.MountPath) + msgp.StringPrefixSize + len(z.ID) + msgp.BoolSize + z.Metrics.Msgsize() + msgp.StringPrefixSize + len(z.Error) 1253 return 1254 } 1255 1256 // DecodeMsg implements msgp.Decodable 1257 func (z *DiskInfoOptions) DecodeMsg(dc *msgp.Reader) (err error) { 1258 var field []byte 1259 _ = field 1260 var zb0001 uint32 1261 zb0001, err = dc.ReadMapHeader() 1262 if err != nil { 1263 err = msgp.WrapError(err) 1264 return 1265 } 1266 for zb0001 > 0 { 1267 zb0001-- 1268 field, err = dc.ReadMapKeyPtr() 1269 if err != nil { 1270 err = msgp.WrapError(err) 1271 return 1272 } 1273 switch msgp.UnsafeString(field) { 1274 case "id": 1275 z.DiskID, err = dc.ReadString() 1276 if err != nil { 1277 err = msgp.WrapError(err, "DiskID") 1278 return 1279 } 1280 case "m": 1281 z.Metrics, err = dc.ReadBool() 1282 if err != nil { 1283 err = msgp.WrapError(err, "Metrics") 1284 return 1285 } 1286 case "np": 1287 z.NoOp, err = dc.ReadBool() 1288 if err != nil { 1289 err = msgp.WrapError(err, "NoOp") 1290 return 1291 } 1292 default: 1293 err = dc.Skip() 1294 if err != nil { 1295 err = msgp.WrapError(err) 1296 return 1297 } 1298 } 1299 } 1300 return 1301 } 1302 1303 // EncodeMsg implements msgp.Encodable 1304 func (z DiskInfoOptions) EncodeMsg(en *msgp.Writer) (err error) { 1305 // map header, size 3 1306 // write "id" 1307 err = en.Append(0x83, 0xa2, 0x69, 0x64) 1308 if err != nil { 1309 return 1310 } 1311 err = en.WriteString(z.DiskID) 1312 if err != nil { 1313 err = msgp.WrapError(err, "DiskID") 1314 return 1315 } 1316 // write "m" 1317 err = en.Append(0xa1, 0x6d) 1318 if err != nil { 1319 return 1320 } 1321 err = en.WriteBool(z.Metrics) 1322 if err != nil { 1323 err = msgp.WrapError(err, "Metrics") 1324 return 1325 } 1326 // write "np" 1327 err = en.Append(0xa2, 0x6e, 0x70) 1328 if err != nil { 1329 return 1330 } 1331 err = en.WriteBool(z.NoOp) 1332 if err != nil { 1333 err = msgp.WrapError(err, "NoOp") 1334 return 1335 } 1336 return 1337 } 1338 1339 // MarshalMsg implements msgp.Marshaler 1340 func (z DiskInfoOptions) MarshalMsg(b []byte) (o []byte, err error) { 1341 o = msgp.Require(b, z.Msgsize()) 1342 // map header, size 3 1343 // string "id" 1344 o = append(o, 0x83, 0xa2, 0x69, 0x64) 1345 o = msgp.AppendString(o, z.DiskID) 1346 // string "m" 1347 o = append(o, 0xa1, 0x6d) 1348 o = msgp.AppendBool(o, z.Metrics) 1349 // string "np" 1350 o = append(o, 0xa2, 0x6e, 0x70) 1351 o = msgp.AppendBool(o, z.NoOp) 1352 return 1353 } 1354 1355 // UnmarshalMsg implements msgp.Unmarshaler 1356 func (z *DiskInfoOptions) UnmarshalMsg(bts []byte) (o []byte, err error) { 1357 var field []byte 1358 _ = field 1359 var zb0001 uint32 1360 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 1361 if err != nil { 1362 err = msgp.WrapError(err) 1363 return 1364 } 1365 for zb0001 > 0 { 1366 zb0001-- 1367 field, bts, err = msgp.ReadMapKeyZC(bts) 1368 if err != nil { 1369 err = msgp.WrapError(err) 1370 return 1371 } 1372 switch msgp.UnsafeString(field) { 1373 case "id": 1374 z.DiskID, bts, err = msgp.ReadStringBytes(bts) 1375 if err != nil { 1376 err = msgp.WrapError(err, "DiskID") 1377 return 1378 } 1379 case "m": 1380 z.Metrics, bts, err = msgp.ReadBoolBytes(bts) 1381 if err != nil { 1382 err = msgp.WrapError(err, "Metrics") 1383 return 1384 } 1385 case "np": 1386 z.NoOp, bts, err = msgp.ReadBoolBytes(bts) 1387 if err != nil { 1388 err = msgp.WrapError(err, "NoOp") 1389 return 1390 } 1391 default: 1392 bts, err = msgp.Skip(bts) 1393 if err != nil { 1394 err = msgp.WrapError(err) 1395 return 1396 } 1397 } 1398 } 1399 o = bts 1400 return 1401 } 1402 1403 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 1404 func (z DiskInfoOptions) Msgsize() (s int) { 1405 s = 1 + 3 + msgp.StringPrefixSize + len(z.DiskID) + 2 + msgp.BoolSize + 3 + msgp.BoolSize 1406 return 1407 } 1408 1409 // DecodeMsg implements msgp.Decodable 1410 func (z *DiskMetrics) DecodeMsg(dc *msgp.Reader) (err error) { 1411 var field []byte 1412 _ = field 1413 var zb0001 uint32 1414 zb0001, err = dc.ReadMapHeader() 1415 if err != nil { 1416 err = msgp.WrapError(err) 1417 return 1418 } 1419 for zb0001 > 0 { 1420 zb0001-- 1421 field, err = dc.ReadMapKeyPtr() 1422 if err != nil { 1423 err = msgp.WrapError(err) 1424 return 1425 } 1426 switch msgp.UnsafeString(field) { 1427 case "LastMinute": 1428 var zb0002 uint32 1429 zb0002, err = dc.ReadMapHeader() 1430 if err != nil { 1431 err = msgp.WrapError(err, "LastMinute") 1432 return 1433 } 1434 if z.LastMinute == nil { 1435 z.LastMinute = make(map[string]AccElem, zb0002) 1436 } else if len(z.LastMinute) > 0 { 1437 for key := range z.LastMinute { 1438 delete(z.LastMinute, key) 1439 } 1440 } 1441 for zb0002 > 0 { 1442 zb0002-- 1443 var za0001 string 1444 var za0002 AccElem 1445 za0001, err = dc.ReadString() 1446 if err != nil { 1447 err = msgp.WrapError(err, "LastMinute") 1448 return 1449 } 1450 err = za0002.DecodeMsg(dc) 1451 if err != nil { 1452 err = msgp.WrapError(err, "LastMinute", za0001) 1453 return 1454 } 1455 z.LastMinute[za0001] = za0002 1456 } 1457 case "APICalls": 1458 var zb0003 uint32 1459 zb0003, err = dc.ReadMapHeader() 1460 if err != nil { 1461 err = msgp.WrapError(err, "APICalls") 1462 return 1463 } 1464 if z.APICalls == nil { 1465 z.APICalls = make(map[string]uint64, zb0003) 1466 } else if len(z.APICalls) > 0 { 1467 for key := range z.APICalls { 1468 delete(z.APICalls, key) 1469 } 1470 } 1471 for zb0003 > 0 { 1472 zb0003-- 1473 var za0003 string 1474 var za0004 uint64 1475 za0003, err = dc.ReadString() 1476 if err != nil { 1477 err = msgp.WrapError(err, "APICalls") 1478 return 1479 } 1480 za0004, err = dc.ReadUint64() 1481 if err != nil { 1482 err = msgp.WrapError(err, "APICalls", za0003) 1483 return 1484 } 1485 z.APICalls[za0003] = za0004 1486 } 1487 case "TotalWaiting": 1488 z.TotalWaiting, err = dc.ReadUint32() 1489 if err != nil { 1490 err = msgp.WrapError(err, "TotalWaiting") 1491 return 1492 } 1493 case "TotalErrorsAvailability": 1494 z.TotalErrorsAvailability, err = dc.ReadUint64() 1495 if err != nil { 1496 err = msgp.WrapError(err, "TotalErrorsAvailability") 1497 return 1498 } 1499 case "TotalErrorsTimeout": 1500 z.TotalErrorsTimeout, err = dc.ReadUint64() 1501 if err != nil { 1502 err = msgp.WrapError(err, "TotalErrorsTimeout") 1503 return 1504 } 1505 case "TotalWrites": 1506 z.TotalWrites, err = dc.ReadUint64() 1507 if err != nil { 1508 err = msgp.WrapError(err, "TotalWrites") 1509 return 1510 } 1511 case "TotalDeletes": 1512 z.TotalDeletes, err = dc.ReadUint64() 1513 if err != nil { 1514 err = msgp.WrapError(err, "TotalDeletes") 1515 return 1516 } 1517 default: 1518 err = dc.Skip() 1519 if err != nil { 1520 err = msgp.WrapError(err) 1521 return 1522 } 1523 } 1524 } 1525 return 1526 } 1527 1528 // EncodeMsg implements msgp.Encodable 1529 func (z *DiskMetrics) EncodeMsg(en *msgp.Writer) (err error) { 1530 // map header, size 7 1531 // write "LastMinute" 1532 err = en.Append(0x87, 0xaa, 0x4c, 0x61, 0x73, 0x74, 0x4d, 0x69, 0x6e, 0x75, 0x74, 0x65) 1533 if err != nil { 1534 return 1535 } 1536 err = en.WriteMapHeader(uint32(len(z.LastMinute))) 1537 if err != nil { 1538 err = msgp.WrapError(err, "LastMinute") 1539 return 1540 } 1541 for za0001, za0002 := range z.LastMinute { 1542 err = en.WriteString(za0001) 1543 if err != nil { 1544 err = msgp.WrapError(err, "LastMinute") 1545 return 1546 } 1547 err = za0002.EncodeMsg(en) 1548 if err != nil { 1549 err = msgp.WrapError(err, "LastMinute", za0001) 1550 return 1551 } 1552 } 1553 // write "APICalls" 1554 err = en.Append(0xa8, 0x41, 0x50, 0x49, 0x43, 0x61, 0x6c, 0x6c, 0x73) 1555 if err != nil { 1556 return 1557 } 1558 err = en.WriteMapHeader(uint32(len(z.APICalls))) 1559 if err != nil { 1560 err = msgp.WrapError(err, "APICalls") 1561 return 1562 } 1563 for za0003, za0004 := range z.APICalls { 1564 err = en.WriteString(za0003) 1565 if err != nil { 1566 err = msgp.WrapError(err, "APICalls") 1567 return 1568 } 1569 err = en.WriteUint64(za0004) 1570 if err != nil { 1571 err = msgp.WrapError(err, "APICalls", za0003) 1572 return 1573 } 1574 } 1575 // write "TotalWaiting" 1576 err = en.Append(0xac, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x57, 0x61, 0x69, 0x74, 0x69, 0x6e, 0x67) 1577 if err != nil { 1578 return 1579 } 1580 err = en.WriteUint32(z.TotalWaiting) 1581 if err != nil { 1582 err = msgp.WrapError(err, "TotalWaiting") 1583 return 1584 } 1585 // write "TotalErrorsAvailability" 1586 err = en.Append(0xb7, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x41, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x69, 0x6c, 0x69, 0x74, 0x79) 1587 if err != nil { 1588 return 1589 } 1590 err = en.WriteUint64(z.TotalErrorsAvailability) 1591 if err != nil { 1592 err = msgp.WrapError(err, "TotalErrorsAvailability") 1593 return 1594 } 1595 // write "TotalErrorsTimeout" 1596 err = en.Append(0xb2, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x54, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74) 1597 if err != nil { 1598 return 1599 } 1600 err = en.WriteUint64(z.TotalErrorsTimeout) 1601 if err != nil { 1602 err = msgp.WrapError(err, "TotalErrorsTimeout") 1603 return 1604 } 1605 // write "TotalWrites" 1606 err = en.Append(0xab, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x57, 0x72, 0x69, 0x74, 0x65, 0x73) 1607 if err != nil { 1608 return 1609 } 1610 err = en.WriteUint64(z.TotalWrites) 1611 if err != nil { 1612 err = msgp.WrapError(err, "TotalWrites") 1613 return 1614 } 1615 // write "TotalDeletes" 1616 err = en.Append(0xac, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x73) 1617 if err != nil { 1618 return 1619 } 1620 err = en.WriteUint64(z.TotalDeletes) 1621 if err != nil { 1622 err = msgp.WrapError(err, "TotalDeletes") 1623 return 1624 } 1625 return 1626 } 1627 1628 // MarshalMsg implements msgp.Marshaler 1629 func (z *DiskMetrics) MarshalMsg(b []byte) (o []byte, err error) { 1630 o = msgp.Require(b, z.Msgsize()) 1631 // map header, size 7 1632 // string "LastMinute" 1633 o = append(o, 0x87, 0xaa, 0x4c, 0x61, 0x73, 0x74, 0x4d, 0x69, 0x6e, 0x75, 0x74, 0x65) 1634 o = msgp.AppendMapHeader(o, uint32(len(z.LastMinute))) 1635 for za0001, za0002 := range z.LastMinute { 1636 o = msgp.AppendString(o, za0001) 1637 o, err = za0002.MarshalMsg(o) 1638 if err != nil { 1639 err = msgp.WrapError(err, "LastMinute", za0001) 1640 return 1641 } 1642 } 1643 // string "APICalls" 1644 o = append(o, 0xa8, 0x41, 0x50, 0x49, 0x43, 0x61, 0x6c, 0x6c, 0x73) 1645 o = msgp.AppendMapHeader(o, uint32(len(z.APICalls))) 1646 for za0003, za0004 := range z.APICalls { 1647 o = msgp.AppendString(o, za0003) 1648 o = msgp.AppendUint64(o, za0004) 1649 } 1650 // string "TotalWaiting" 1651 o = append(o, 0xac, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x57, 0x61, 0x69, 0x74, 0x69, 0x6e, 0x67) 1652 o = msgp.AppendUint32(o, z.TotalWaiting) 1653 // string "TotalErrorsAvailability" 1654 o = append(o, 0xb7, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x41, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x69, 0x6c, 0x69, 0x74, 0x79) 1655 o = msgp.AppendUint64(o, z.TotalErrorsAvailability) 1656 // string "TotalErrorsTimeout" 1657 o = append(o, 0xb2, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x54, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74) 1658 o = msgp.AppendUint64(o, z.TotalErrorsTimeout) 1659 // string "TotalWrites" 1660 o = append(o, 0xab, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x57, 0x72, 0x69, 0x74, 0x65, 0x73) 1661 o = msgp.AppendUint64(o, z.TotalWrites) 1662 // string "TotalDeletes" 1663 o = append(o, 0xac, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x73) 1664 o = msgp.AppendUint64(o, z.TotalDeletes) 1665 return 1666 } 1667 1668 // UnmarshalMsg implements msgp.Unmarshaler 1669 func (z *DiskMetrics) UnmarshalMsg(bts []byte) (o []byte, err error) { 1670 var field []byte 1671 _ = field 1672 var zb0001 uint32 1673 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 1674 if err != nil { 1675 err = msgp.WrapError(err) 1676 return 1677 } 1678 for zb0001 > 0 { 1679 zb0001-- 1680 field, bts, err = msgp.ReadMapKeyZC(bts) 1681 if err != nil { 1682 err = msgp.WrapError(err) 1683 return 1684 } 1685 switch msgp.UnsafeString(field) { 1686 case "LastMinute": 1687 var zb0002 uint32 1688 zb0002, bts, err = msgp.ReadMapHeaderBytes(bts) 1689 if err != nil { 1690 err = msgp.WrapError(err, "LastMinute") 1691 return 1692 } 1693 if z.LastMinute == nil { 1694 z.LastMinute = make(map[string]AccElem, zb0002) 1695 } else if len(z.LastMinute) > 0 { 1696 for key := range z.LastMinute { 1697 delete(z.LastMinute, key) 1698 } 1699 } 1700 for zb0002 > 0 { 1701 var za0001 string 1702 var za0002 AccElem 1703 zb0002-- 1704 za0001, bts, err = msgp.ReadStringBytes(bts) 1705 if err != nil { 1706 err = msgp.WrapError(err, "LastMinute") 1707 return 1708 } 1709 bts, err = za0002.UnmarshalMsg(bts) 1710 if err != nil { 1711 err = msgp.WrapError(err, "LastMinute", za0001) 1712 return 1713 } 1714 z.LastMinute[za0001] = za0002 1715 } 1716 case "APICalls": 1717 var zb0003 uint32 1718 zb0003, bts, err = msgp.ReadMapHeaderBytes(bts) 1719 if err != nil { 1720 err = msgp.WrapError(err, "APICalls") 1721 return 1722 } 1723 if z.APICalls == nil { 1724 z.APICalls = make(map[string]uint64, zb0003) 1725 } else if len(z.APICalls) > 0 { 1726 for key := range z.APICalls { 1727 delete(z.APICalls, key) 1728 } 1729 } 1730 for zb0003 > 0 { 1731 var za0003 string 1732 var za0004 uint64 1733 zb0003-- 1734 za0003, bts, err = msgp.ReadStringBytes(bts) 1735 if err != nil { 1736 err = msgp.WrapError(err, "APICalls") 1737 return 1738 } 1739 za0004, bts, err = msgp.ReadUint64Bytes(bts) 1740 if err != nil { 1741 err = msgp.WrapError(err, "APICalls", za0003) 1742 return 1743 } 1744 z.APICalls[za0003] = za0004 1745 } 1746 case "TotalWaiting": 1747 z.TotalWaiting, bts, err = msgp.ReadUint32Bytes(bts) 1748 if err != nil { 1749 err = msgp.WrapError(err, "TotalWaiting") 1750 return 1751 } 1752 case "TotalErrorsAvailability": 1753 z.TotalErrorsAvailability, bts, err = msgp.ReadUint64Bytes(bts) 1754 if err != nil { 1755 err = msgp.WrapError(err, "TotalErrorsAvailability") 1756 return 1757 } 1758 case "TotalErrorsTimeout": 1759 z.TotalErrorsTimeout, bts, err = msgp.ReadUint64Bytes(bts) 1760 if err != nil { 1761 err = msgp.WrapError(err, "TotalErrorsTimeout") 1762 return 1763 } 1764 case "TotalWrites": 1765 z.TotalWrites, bts, err = msgp.ReadUint64Bytes(bts) 1766 if err != nil { 1767 err = msgp.WrapError(err, "TotalWrites") 1768 return 1769 } 1770 case "TotalDeletes": 1771 z.TotalDeletes, bts, err = msgp.ReadUint64Bytes(bts) 1772 if err != nil { 1773 err = msgp.WrapError(err, "TotalDeletes") 1774 return 1775 } 1776 default: 1777 bts, err = msgp.Skip(bts) 1778 if err != nil { 1779 err = msgp.WrapError(err) 1780 return 1781 } 1782 } 1783 } 1784 o = bts 1785 return 1786 } 1787 1788 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 1789 func (z *DiskMetrics) Msgsize() (s int) { 1790 s = 1 + 11 + msgp.MapHeaderSize 1791 if z.LastMinute != nil { 1792 for za0001, za0002 := range z.LastMinute { 1793 _ = za0002 1794 s += msgp.StringPrefixSize + len(za0001) + za0002.Msgsize() 1795 } 1796 } 1797 s += 9 + msgp.MapHeaderSize 1798 if z.APICalls != nil { 1799 for za0003, za0004 := range z.APICalls { 1800 _ = za0004 1801 s += msgp.StringPrefixSize + len(za0003) + msgp.Uint64Size 1802 } 1803 } 1804 s += 13 + msgp.Uint32Size + 24 + msgp.Uint64Size + 19 + msgp.Uint64Size + 12 + msgp.Uint64Size + 13 + msgp.Uint64Size 1805 return 1806 } 1807 1808 // DecodeMsg implements msgp.Decodable 1809 func (z *FileInfo) DecodeMsg(dc *msgp.Reader) (err error) { 1810 var zb0001 uint32 1811 zb0001, err = dc.ReadArrayHeader() 1812 if err != nil { 1813 err = msgp.WrapError(err) 1814 return 1815 } 1816 if zb0001 != 28 { 1817 err = msgp.ArrayError{Wanted: 28, Got: zb0001} 1818 return 1819 } 1820 z.Volume, err = dc.ReadString() 1821 if err != nil { 1822 err = msgp.WrapError(err, "Volume") 1823 return 1824 } 1825 z.Name, err = dc.ReadString() 1826 if err != nil { 1827 err = msgp.WrapError(err, "Name") 1828 return 1829 } 1830 z.VersionID, err = dc.ReadString() 1831 if err != nil { 1832 err = msgp.WrapError(err, "VersionID") 1833 return 1834 } 1835 z.IsLatest, err = dc.ReadBool() 1836 if err != nil { 1837 err = msgp.WrapError(err, "IsLatest") 1838 return 1839 } 1840 z.Deleted, err = dc.ReadBool() 1841 if err != nil { 1842 err = msgp.WrapError(err, "Deleted") 1843 return 1844 } 1845 z.TransitionStatus, err = dc.ReadString() 1846 if err != nil { 1847 err = msgp.WrapError(err, "TransitionStatus") 1848 return 1849 } 1850 z.TransitionedObjName, err = dc.ReadString() 1851 if err != nil { 1852 err = msgp.WrapError(err, "TransitionedObjName") 1853 return 1854 } 1855 z.TransitionTier, err = dc.ReadString() 1856 if err != nil { 1857 err = msgp.WrapError(err, "TransitionTier") 1858 return 1859 } 1860 z.TransitionVersionID, err = dc.ReadString() 1861 if err != nil { 1862 err = msgp.WrapError(err, "TransitionVersionID") 1863 return 1864 } 1865 z.ExpireRestored, err = dc.ReadBool() 1866 if err != nil { 1867 err = msgp.WrapError(err, "ExpireRestored") 1868 return 1869 } 1870 z.DataDir, err = dc.ReadString() 1871 if err != nil { 1872 err = msgp.WrapError(err, "DataDir") 1873 return 1874 } 1875 z.XLV1, err = dc.ReadBool() 1876 if err != nil { 1877 err = msgp.WrapError(err, "XLV1") 1878 return 1879 } 1880 z.ModTime, err = dc.ReadTime() 1881 if err != nil { 1882 err = msgp.WrapError(err, "ModTime") 1883 return 1884 } 1885 z.Size, err = dc.ReadInt64() 1886 if err != nil { 1887 err = msgp.WrapError(err, "Size") 1888 return 1889 } 1890 z.Mode, err = dc.ReadUint32() 1891 if err != nil { 1892 err = msgp.WrapError(err, "Mode") 1893 return 1894 } 1895 z.WrittenByVersion, err = dc.ReadUint64() 1896 if err != nil { 1897 err = msgp.WrapError(err, "WrittenByVersion") 1898 return 1899 } 1900 var zb0002 uint32 1901 zb0002, err = dc.ReadMapHeader() 1902 if err != nil { 1903 err = msgp.WrapError(err, "Metadata") 1904 return 1905 } 1906 if z.Metadata == nil { 1907 z.Metadata = make(map[string]string, zb0002) 1908 } else if len(z.Metadata) > 0 { 1909 for key := range z.Metadata { 1910 delete(z.Metadata, key) 1911 } 1912 } 1913 var field []byte 1914 _ = field 1915 for zb0002 > 0 { 1916 zb0002-- 1917 var za0001 string 1918 var za0002 string 1919 za0001, err = dc.ReadString() 1920 if err != nil { 1921 err = msgp.WrapError(err, "Metadata") 1922 return 1923 } 1924 za0002, err = dc.ReadString() 1925 if err != nil { 1926 err = msgp.WrapError(err, "Metadata", za0001) 1927 return 1928 } 1929 z.Metadata[za0001] = za0002 1930 } 1931 var zb0003 uint32 1932 zb0003, err = dc.ReadArrayHeader() 1933 if err != nil { 1934 err = msgp.WrapError(err, "Parts") 1935 return 1936 } 1937 if cap(z.Parts) >= int(zb0003) { 1938 z.Parts = (z.Parts)[:zb0003] 1939 } else { 1940 z.Parts = make([]ObjectPartInfo, zb0003) 1941 } 1942 for za0003 := range z.Parts { 1943 err = z.Parts[za0003].DecodeMsg(dc) 1944 if err != nil { 1945 err = msgp.WrapError(err, "Parts", za0003) 1946 return 1947 } 1948 } 1949 err = z.Erasure.DecodeMsg(dc) 1950 if err != nil { 1951 err = msgp.WrapError(err, "Erasure") 1952 return 1953 } 1954 z.MarkDeleted, err = dc.ReadBool() 1955 if err != nil { 1956 err = msgp.WrapError(err, "MarkDeleted") 1957 return 1958 } 1959 err = z.ReplicationState.DecodeMsg(dc) 1960 if err != nil { 1961 err = msgp.WrapError(err, "ReplicationState") 1962 return 1963 } 1964 if dc.IsNil() { 1965 err = dc.ReadNil() 1966 if err != nil { 1967 err = msgp.WrapError(err) 1968 return 1969 } 1970 z.Data = nil 1971 } else { 1972 z.Data, err = dc.ReadBytes(z.Data) 1973 if err != nil { 1974 err = msgp.WrapError(err, "Data") 1975 return 1976 } 1977 } 1978 z.NumVersions, err = dc.ReadInt() 1979 if err != nil { 1980 err = msgp.WrapError(err, "NumVersions") 1981 return 1982 } 1983 z.SuccessorModTime, err = dc.ReadTime() 1984 if err != nil { 1985 err = msgp.WrapError(err, "SuccessorModTime") 1986 return 1987 } 1988 z.Fresh, err = dc.ReadBool() 1989 if err != nil { 1990 err = msgp.WrapError(err, "Fresh") 1991 return 1992 } 1993 z.Idx, err = dc.ReadInt() 1994 if err != nil { 1995 err = msgp.WrapError(err, "Idx") 1996 return 1997 } 1998 if dc.IsNil() { 1999 err = dc.ReadNil() 2000 if err != nil { 2001 err = msgp.WrapError(err) 2002 return 2003 } 2004 z.Checksum = nil 2005 } else { 2006 z.Checksum, err = dc.ReadBytes(z.Checksum) 2007 if err != nil { 2008 err = msgp.WrapError(err, "Checksum") 2009 return 2010 } 2011 } 2012 z.Versioned, err = dc.ReadBool() 2013 if err != nil { 2014 err = msgp.WrapError(err, "Versioned") 2015 return 2016 } 2017 return 2018 } 2019 2020 // EncodeMsg implements msgp.Encodable 2021 func (z *FileInfo) EncodeMsg(en *msgp.Writer) (err error) { 2022 // array header, size 28 2023 err = en.Append(0xdc, 0x0, 0x1c) 2024 if err != nil { 2025 return 2026 } 2027 err = en.WriteString(z.Volume) 2028 if err != nil { 2029 err = msgp.WrapError(err, "Volume") 2030 return 2031 } 2032 err = en.WriteString(z.Name) 2033 if err != nil { 2034 err = msgp.WrapError(err, "Name") 2035 return 2036 } 2037 err = en.WriteString(z.VersionID) 2038 if err != nil { 2039 err = msgp.WrapError(err, "VersionID") 2040 return 2041 } 2042 err = en.WriteBool(z.IsLatest) 2043 if err != nil { 2044 err = msgp.WrapError(err, "IsLatest") 2045 return 2046 } 2047 err = en.WriteBool(z.Deleted) 2048 if err != nil { 2049 err = msgp.WrapError(err, "Deleted") 2050 return 2051 } 2052 err = en.WriteString(z.TransitionStatus) 2053 if err != nil { 2054 err = msgp.WrapError(err, "TransitionStatus") 2055 return 2056 } 2057 err = en.WriteString(z.TransitionedObjName) 2058 if err != nil { 2059 err = msgp.WrapError(err, "TransitionedObjName") 2060 return 2061 } 2062 err = en.WriteString(z.TransitionTier) 2063 if err != nil { 2064 err = msgp.WrapError(err, "TransitionTier") 2065 return 2066 } 2067 err = en.WriteString(z.TransitionVersionID) 2068 if err != nil { 2069 err = msgp.WrapError(err, "TransitionVersionID") 2070 return 2071 } 2072 err = en.WriteBool(z.ExpireRestored) 2073 if err != nil { 2074 err = msgp.WrapError(err, "ExpireRestored") 2075 return 2076 } 2077 err = en.WriteString(z.DataDir) 2078 if err != nil { 2079 err = msgp.WrapError(err, "DataDir") 2080 return 2081 } 2082 err = en.WriteBool(z.XLV1) 2083 if err != nil { 2084 err = msgp.WrapError(err, "XLV1") 2085 return 2086 } 2087 err = en.WriteTime(z.ModTime) 2088 if err != nil { 2089 err = msgp.WrapError(err, "ModTime") 2090 return 2091 } 2092 err = en.WriteInt64(z.Size) 2093 if err != nil { 2094 err = msgp.WrapError(err, "Size") 2095 return 2096 } 2097 err = en.WriteUint32(z.Mode) 2098 if err != nil { 2099 err = msgp.WrapError(err, "Mode") 2100 return 2101 } 2102 err = en.WriteUint64(z.WrittenByVersion) 2103 if err != nil { 2104 err = msgp.WrapError(err, "WrittenByVersion") 2105 return 2106 } 2107 err = en.WriteMapHeader(uint32(len(z.Metadata))) 2108 if err != nil { 2109 err = msgp.WrapError(err, "Metadata") 2110 return 2111 } 2112 for za0001, za0002 := range z.Metadata { 2113 err = en.WriteString(za0001) 2114 if err != nil { 2115 err = msgp.WrapError(err, "Metadata") 2116 return 2117 } 2118 err = en.WriteString(za0002) 2119 if err != nil { 2120 err = msgp.WrapError(err, "Metadata", za0001) 2121 return 2122 } 2123 } 2124 err = en.WriteArrayHeader(uint32(len(z.Parts))) 2125 if err != nil { 2126 err = msgp.WrapError(err, "Parts") 2127 return 2128 } 2129 for za0003 := range z.Parts { 2130 err = z.Parts[za0003].EncodeMsg(en) 2131 if err != nil { 2132 err = msgp.WrapError(err, "Parts", za0003) 2133 return 2134 } 2135 } 2136 err = z.Erasure.EncodeMsg(en) 2137 if err != nil { 2138 err = msgp.WrapError(err, "Erasure") 2139 return 2140 } 2141 err = en.WriteBool(z.MarkDeleted) 2142 if err != nil { 2143 err = msgp.WrapError(err, "MarkDeleted") 2144 return 2145 } 2146 err = z.ReplicationState.EncodeMsg(en) 2147 if err != nil { 2148 err = msgp.WrapError(err, "ReplicationState") 2149 return 2150 } 2151 if z.Data == nil { // allownil: if nil 2152 err = en.WriteNil() 2153 if err != nil { 2154 return 2155 } 2156 } else { 2157 err = en.WriteBytes(z.Data) 2158 if err != nil { 2159 err = msgp.WrapError(err, "Data") 2160 return 2161 } 2162 } 2163 err = en.WriteInt(z.NumVersions) 2164 if err != nil { 2165 err = msgp.WrapError(err, "NumVersions") 2166 return 2167 } 2168 err = en.WriteTime(z.SuccessorModTime) 2169 if err != nil { 2170 err = msgp.WrapError(err, "SuccessorModTime") 2171 return 2172 } 2173 err = en.WriteBool(z.Fresh) 2174 if err != nil { 2175 err = msgp.WrapError(err, "Fresh") 2176 return 2177 } 2178 err = en.WriteInt(z.Idx) 2179 if err != nil { 2180 err = msgp.WrapError(err, "Idx") 2181 return 2182 } 2183 if z.Checksum == nil { // allownil: if nil 2184 err = en.WriteNil() 2185 if err != nil { 2186 return 2187 } 2188 } else { 2189 err = en.WriteBytes(z.Checksum) 2190 if err != nil { 2191 err = msgp.WrapError(err, "Checksum") 2192 return 2193 } 2194 } 2195 err = en.WriteBool(z.Versioned) 2196 if err != nil { 2197 err = msgp.WrapError(err, "Versioned") 2198 return 2199 } 2200 return 2201 } 2202 2203 // MarshalMsg implements msgp.Marshaler 2204 func (z *FileInfo) MarshalMsg(b []byte) (o []byte, err error) { 2205 o = msgp.Require(b, z.Msgsize()) 2206 // array header, size 28 2207 o = append(o, 0xdc, 0x0, 0x1c) 2208 o = msgp.AppendString(o, z.Volume) 2209 o = msgp.AppendString(o, z.Name) 2210 o = msgp.AppendString(o, z.VersionID) 2211 o = msgp.AppendBool(o, z.IsLatest) 2212 o = msgp.AppendBool(o, z.Deleted) 2213 o = msgp.AppendString(o, z.TransitionStatus) 2214 o = msgp.AppendString(o, z.TransitionedObjName) 2215 o = msgp.AppendString(o, z.TransitionTier) 2216 o = msgp.AppendString(o, z.TransitionVersionID) 2217 o = msgp.AppendBool(o, z.ExpireRestored) 2218 o = msgp.AppendString(o, z.DataDir) 2219 o = msgp.AppendBool(o, z.XLV1) 2220 o = msgp.AppendTime(o, z.ModTime) 2221 o = msgp.AppendInt64(o, z.Size) 2222 o = msgp.AppendUint32(o, z.Mode) 2223 o = msgp.AppendUint64(o, z.WrittenByVersion) 2224 o = msgp.AppendMapHeader(o, uint32(len(z.Metadata))) 2225 for za0001, za0002 := range z.Metadata { 2226 o = msgp.AppendString(o, za0001) 2227 o = msgp.AppendString(o, za0002) 2228 } 2229 o = msgp.AppendArrayHeader(o, uint32(len(z.Parts))) 2230 for za0003 := range z.Parts { 2231 o, err = z.Parts[za0003].MarshalMsg(o) 2232 if err != nil { 2233 err = msgp.WrapError(err, "Parts", za0003) 2234 return 2235 } 2236 } 2237 o, err = z.Erasure.MarshalMsg(o) 2238 if err != nil { 2239 err = msgp.WrapError(err, "Erasure") 2240 return 2241 } 2242 o = msgp.AppendBool(o, z.MarkDeleted) 2243 o, err = z.ReplicationState.MarshalMsg(o) 2244 if err != nil { 2245 err = msgp.WrapError(err, "ReplicationState") 2246 return 2247 } 2248 if z.Data == nil { // allownil: if nil 2249 o = msgp.AppendNil(o) 2250 } else { 2251 o = msgp.AppendBytes(o, z.Data) 2252 } 2253 o = msgp.AppendInt(o, z.NumVersions) 2254 o = msgp.AppendTime(o, z.SuccessorModTime) 2255 o = msgp.AppendBool(o, z.Fresh) 2256 o = msgp.AppendInt(o, z.Idx) 2257 if z.Checksum == nil { // allownil: if nil 2258 o = msgp.AppendNil(o) 2259 } else { 2260 o = msgp.AppendBytes(o, z.Checksum) 2261 } 2262 o = msgp.AppendBool(o, z.Versioned) 2263 return 2264 } 2265 2266 // UnmarshalMsg implements msgp.Unmarshaler 2267 func (z *FileInfo) UnmarshalMsg(bts []byte) (o []byte, err error) { 2268 var zb0001 uint32 2269 zb0001, bts, err = msgp.ReadArrayHeaderBytes(bts) 2270 if err != nil { 2271 err = msgp.WrapError(err) 2272 return 2273 } 2274 if zb0001 != 28 { 2275 err = msgp.ArrayError{Wanted: 28, Got: zb0001} 2276 return 2277 } 2278 z.Volume, bts, err = msgp.ReadStringBytes(bts) 2279 if err != nil { 2280 err = msgp.WrapError(err, "Volume") 2281 return 2282 } 2283 z.Name, bts, err = msgp.ReadStringBytes(bts) 2284 if err != nil { 2285 err = msgp.WrapError(err, "Name") 2286 return 2287 } 2288 z.VersionID, bts, err = msgp.ReadStringBytes(bts) 2289 if err != nil { 2290 err = msgp.WrapError(err, "VersionID") 2291 return 2292 } 2293 z.IsLatest, bts, err = msgp.ReadBoolBytes(bts) 2294 if err != nil { 2295 err = msgp.WrapError(err, "IsLatest") 2296 return 2297 } 2298 z.Deleted, bts, err = msgp.ReadBoolBytes(bts) 2299 if err != nil { 2300 err = msgp.WrapError(err, "Deleted") 2301 return 2302 } 2303 z.TransitionStatus, bts, err = msgp.ReadStringBytes(bts) 2304 if err != nil { 2305 err = msgp.WrapError(err, "TransitionStatus") 2306 return 2307 } 2308 z.TransitionedObjName, bts, err = msgp.ReadStringBytes(bts) 2309 if err != nil { 2310 err = msgp.WrapError(err, "TransitionedObjName") 2311 return 2312 } 2313 z.TransitionTier, bts, err = msgp.ReadStringBytes(bts) 2314 if err != nil { 2315 err = msgp.WrapError(err, "TransitionTier") 2316 return 2317 } 2318 z.TransitionVersionID, bts, err = msgp.ReadStringBytes(bts) 2319 if err != nil { 2320 err = msgp.WrapError(err, "TransitionVersionID") 2321 return 2322 } 2323 z.ExpireRestored, bts, err = msgp.ReadBoolBytes(bts) 2324 if err != nil { 2325 err = msgp.WrapError(err, "ExpireRestored") 2326 return 2327 } 2328 z.DataDir, bts, err = msgp.ReadStringBytes(bts) 2329 if err != nil { 2330 err = msgp.WrapError(err, "DataDir") 2331 return 2332 } 2333 z.XLV1, bts, err = msgp.ReadBoolBytes(bts) 2334 if err != nil { 2335 err = msgp.WrapError(err, "XLV1") 2336 return 2337 } 2338 z.ModTime, bts, err = msgp.ReadTimeBytes(bts) 2339 if err != nil { 2340 err = msgp.WrapError(err, "ModTime") 2341 return 2342 } 2343 z.Size, bts, err = msgp.ReadInt64Bytes(bts) 2344 if err != nil { 2345 err = msgp.WrapError(err, "Size") 2346 return 2347 } 2348 z.Mode, bts, err = msgp.ReadUint32Bytes(bts) 2349 if err != nil { 2350 err = msgp.WrapError(err, "Mode") 2351 return 2352 } 2353 z.WrittenByVersion, bts, err = msgp.ReadUint64Bytes(bts) 2354 if err != nil { 2355 err = msgp.WrapError(err, "WrittenByVersion") 2356 return 2357 } 2358 var zb0002 uint32 2359 zb0002, bts, err = msgp.ReadMapHeaderBytes(bts) 2360 if err != nil { 2361 err = msgp.WrapError(err, "Metadata") 2362 return 2363 } 2364 if z.Metadata == nil { 2365 z.Metadata = make(map[string]string, zb0002) 2366 } else if len(z.Metadata) > 0 { 2367 for key := range z.Metadata { 2368 delete(z.Metadata, key) 2369 } 2370 } 2371 var field []byte 2372 _ = field 2373 for zb0002 > 0 { 2374 var za0001 string 2375 var za0002 string 2376 zb0002-- 2377 za0001, bts, err = msgp.ReadStringBytes(bts) 2378 if err != nil { 2379 err = msgp.WrapError(err, "Metadata") 2380 return 2381 } 2382 za0002, bts, err = msgp.ReadStringBytes(bts) 2383 if err != nil { 2384 err = msgp.WrapError(err, "Metadata", za0001) 2385 return 2386 } 2387 z.Metadata[za0001] = za0002 2388 } 2389 var zb0003 uint32 2390 zb0003, bts, err = msgp.ReadArrayHeaderBytes(bts) 2391 if err != nil { 2392 err = msgp.WrapError(err, "Parts") 2393 return 2394 } 2395 if cap(z.Parts) >= int(zb0003) { 2396 z.Parts = (z.Parts)[:zb0003] 2397 } else { 2398 z.Parts = make([]ObjectPartInfo, zb0003) 2399 } 2400 for za0003 := range z.Parts { 2401 bts, err = z.Parts[za0003].UnmarshalMsg(bts) 2402 if err != nil { 2403 err = msgp.WrapError(err, "Parts", za0003) 2404 return 2405 } 2406 } 2407 bts, err = z.Erasure.UnmarshalMsg(bts) 2408 if err != nil { 2409 err = msgp.WrapError(err, "Erasure") 2410 return 2411 } 2412 z.MarkDeleted, bts, err = msgp.ReadBoolBytes(bts) 2413 if err != nil { 2414 err = msgp.WrapError(err, "MarkDeleted") 2415 return 2416 } 2417 bts, err = z.ReplicationState.UnmarshalMsg(bts) 2418 if err != nil { 2419 err = msgp.WrapError(err, "ReplicationState") 2420 return 2421 } 2422 if msgp.IsNil(bts) { 2423 bts = bts[1:] 2424 z.Data = nil 2425 } else { 2426 z.Data, bts, err = msgp.ReadBytesBytes(bts, z.Data) 2427 if err != nil { 2428 err = msgp.WrapError(err, "Data") 2429 return 2430 } 2431 } 2432 z.NumVersions, bts, err = msgp.ReadIntBytes(bts) 2433 if err != nil { 2434 err = msgp.WrapError(err, "NumVersions") 2435 return 2436 } 2437 z.SuccessorModTime, bts, err = msgp.ReadTimeBytes(bts) 2438 if err != nil { 2439 err = msgp.WrapError(err, "SuccessorModTime") 2440 return 2441 } 2442 z.Fresh, bts, err = msgp.ReadBoolBytes(bts) 2443 if err != nil { 2444 err = msgp.WrapError(err, "Fresh") 2445 return 2446 } 2447 z.Idx, bts, err = msgp.ReadIntBytes(bts) 2448 if err != nil { 2449 err = msgp.WrapError(err, "Idx") 2450 return 2451 } 2452 if msgp.IsNil(bts) { 2453 bts = bts[1:] 2454 z.Checksum = nil 2455 } else { 2456 z.Checksum, bts, err = msgp.ReadBytesBytes(bts, z.Checksum) 2457 if err != nil { 2458 err = msgp.WrapError(err, "Checksum") 2459 return 2460 } 2461 } 2462 z.Versioned, bts, err = msgp.ReadBoolBytes(bts) 2463 if err != nil { 2464 err = msgp.WrapError(err, "Versioned") 2465 return 2466 } 2467 o = bts 2468 return 2469 } 2470 2471 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 2472 func (z *FileInfo) Msgsize() (s int) { 2473 s = 3 + msgp.StringPrefixSize + len(z.Volume) + msgp.StringPrefixSize + len(z.Name) + msgp.StringPrefixSize + len(z.VersionID) + msgp.BoolSize + msgp.BoolSize + msgp.StringPrefixSize + len(z.TransitionStatus) + msgp.StringPrefixSize + len(z.TransitionedObjName) + msgp.StringPrefixSize + len(z.TransitionTier) + msgp.StringPrefixSize + len(z.TransitionVersionID) + msgp.BoolSize + msgp.StringPrefixSize + len(z.DataDir) + msgp.BoolSize + msgp.TimeSize + msgp.Int64Size + msgp.Uint32Size + msgp.Uint64Size + msgp.MapHeaderSize 2474 if z.Metadata != nil { 2475 for za0001, za0002 := range z.Metadata { 2476 _ = za0002 2477 s += msgp.StringPrefixSize + len(za0001) + msgp.StringPrefixSize + len(za0002) 2478 } 2479 } 2480 s += msgp.ArrayHeaderSize 2481 for za0003 := range z.Parts { 2482 s += z.Parts[za0003].Msgsize() 2483 } 2484 s += z.Erasure.Msgsize() + msgp.BoolSize + z.ReplicationState.Msgsize() + msgp.BytesPrefixSize + len(z.Data) + msgp.IntSize + msgp.TimeSize + msgp.BoolSize + msgp.IntSize + msgp.BytesPrefixSize + len(z.Checksum) + msgp.BoolSize 2485 return 2486 } 2487 2488 // DecodeMsg implements msgp.Decodable 2489 func (z *FileInfoVersions) DecodeMsg(dc *msgp.Reader) (err error) { 2490 var zb0001 uint32 2491 zb0001, err = dc.ReadArrayHeader() 2492 if err != nil { 2493 err = msgp.WrapError(err) 2494 return 2495 } 2496 if zb0001 != 5 { 2497 err = msgp.ArrayError{Wanted: 5, Got: zb0001} 2498 return 2499 } 2500 z.Volume, err = dc.ReadString() 2501 if err != nil { 2502 err = msgp.WrapError(err, "Volume") 2503 return 2504 } 2505 z.Name, err = dc.ReadString() 2506 if err != nil { 2507 err = msgp.WrapError(err, "Name") 2508 return 2509 } 2510 z.LatestModTime, err = dc.ReadTime() 2511 if err != nil { 2512 err = msgp.WrapError(err, "LatestModTime") 2513 return 2514 } 2515 var zb0002 uint32 2516 zb0002, err = dc.ReadArrayHeader() 2517 if err != nil { 2518 err = msgp.WrapError(err, "Versions") 2519 return 2520 } 2521 if cap(z.Versions) >= int(zb0002) { 2522 z.Versions = (z.Versions)[:zb0002] 2523 } else { 2524 z.Versions = make([]FileInfo, zb0002) 2525 } 2526 for za0001 := range z.Versions { 2527 err = z.Versions[za0001].DecodeMsg(dc) 2528 if err != nil { 2529 err = msgp.WrapError(err, "Versions", za0001) 2530 return 2531 } 2532 } 2533 var zb0003 uint32 2534 zb0003, err = dc.ReadArrayHeader() 2535 if err != nil { 2536 err = msgp.WrapError(err, "FreeVersions") 2537 return 2538 } 2539 if cap(z.FreeVersions) >= int(zb0003) { 2540 z.FreeVersions = (z.FreeVersions)[:zb0003] 2541 } else { 2542 z.FreeVersions = make([]FileInfo, zb0003) 2543 } 2544 for za0002 := range z.FreeVersions { 2545 err = z.FreeVersions[za0002].DecodeMsg(dc) 2546 if err != nil { 2547 err = msgp.WrapError(err, "FreeVersions", za0002) 2548 return 2549 } 2550 } 2551 return 2552 } 2553 2554 // EncodeMsg implements msgp.Encodable 2555 func (z *FileInfoVersions) EncodeMsg(en *msgp.Writer) (err error) { 2556 // array header, size 5 2557 err = en.Append(0x95) 2558 if err != nil { 2559 return 2560 } 2561 err = en.WriteString(z.Volume) 2562 if err != nil { 2563 err = msgp.WrapError(err, "Volume") 2564 return 2565 } 2566 err = en.WriteString(z.Name) 2567 if err != nil { 2568 err = msgp.WrapError(err, "Name") 2569 return 2570 } 2571 err = en.WriteTime(z.LatestModTime) 2572 if err != nil { 2573 err = msgp.WrapError(err, "LatestModTime") 2574 return 2575 } 2576 err = en.WriteArrayHeader(uint32(len(z.Versions))) 2577 if err != nil { 2578 err = msgp.WrapError(err, "Versions") 2579 return 2580 } 2581 for za0001 := range z.Versions { 2582 err = z.Versions[za0001].EncodeMsg(en) 2583 if err != nil { 2584 err = msgp.WrapError(err, "Versions", za0001) 2585 return 2586 } 2587 } 2588 err = en.WriteArrayHeader(uint32(len(z.FreeVersions))) 2589 if err != nil { 2590 err = msgp.WrapError(err, "FreeVersions") 2591 return 2592 } 2593 for za0002 := range z.FreeVersions { 2594 err = z.FreeVersions[za0002].EncodeMsg(en) 2595 if err != nil { 2596 err = msgp.WrapError(err, "FreeVersions", za0002) 2597 return 2598 } 2599 } 2600 return 2601 } 2602 2603 // MarshalMsg implements msgp.Marshaler 2604 func (z *FileInfoVersions) MarshalMsg(b []byte) (o []byte, err error) { 2605 o = msgp.Require(b, z.Msgsize()) 2606 // array header, size 5 2607 o = append(o, 0x95) 2608 o = msgp.AppendString(o, z.Volume) 2609 o = msgp.AppendString(o, z.Name) 2610 o = msgp.AppendTime(o, z.LatestModTime) 2611 o = msgp.AppendArrayHeader(o, uint32(len(z.Versions))) 2612 for za0001 := range z.Versions { 2613 o, err = z.Versions[za0001].MarshalMsg(o) 2614 if err != nil { 2615 err = msgp.WrapError(err, "Versions", za0001) 2616 return 2617 } 2618 } 2619 o = msgp.AppendArrayHeader(o, uint32(len(z.FreeVersions))) 2620 for za0002 := range z.FreeVersions { 2621 o, err = z.FreeVersions[za0002].MarshalMsg(o) 2622 if err != nil { 2623 err = msgp.WrapError(err, "FreeVersions", za0002) 2624 return 2625 } 2626 } 2627 return 2628 } 2629 2630 // UnmarshalMsg implements msgp.Unmarshaler 2631 func (z *FileInfoVersions) UnmarshalMsg(bts []byte) (o []byte, err error) { 2632 var zb0001 uint32 2633 zb0001, bts, err = msgp.ReadArrayHeaderBytes(bts) 2634 if err != nil { 2635 err = msgp.WrapError(err) 2636 return 2637 } 2638 if zb0001 != 5 { 2639 err = msgp.ArrayError{Wanted: 5, Got: zb0001} 2640 return 2641 } 2642 z.Volume, bts, err = msgp.ReadStringBytes(bts) 2643 if err != nil { 2644 err = msgp.WrapError(err, "Volume") 2645 return 2646 } 2647 z.Name, bts, err = msgp.ReadStringBytes(bts) 2648 if err != nil { 2649 err = msgp.WrapError(err, "Name") 2650 return 2651 } 2652 z.LatestModTime, bts, err = msgp.ReadTimeBytes(bts) 2653 if err != nil { 2654 err = msgp.WrapError(err, "LatestModTime") 2655 return 2656 } 2657 var zb0002 uint32 2658 zb0002, bts, err = msgp.ReadArrayHeaderBytes(bts) 2659 if err != nil { 2660 err = msgp.WrapError(err, "Versions") 2661 return 2662 } 2663 if cap(z.Versions) >= int(zb0002) { 2664 z.Versions = (z.Versions)[:zb0002] 2665 } else { 2666 z.Versions = make([]FileInfo, zb0002) 2667 } 2668 for za0001 := range z.Versions { 2669 bts, err = z.Versions[za0001].UnmarshalMsg(bts) 2670 if err != nil { 2671 err = msgp.WrapError(err, "Versions", za0001) 2672 return 2673 } 2674 } 2675 var zb0003 uint32 2676 zb0003, bts, err = msgp.ReadArrayHeaderBytes(bts) 2677 if err != nil { 2678 err = msgp.WrapError(err, "FreeVersions") 2679 return 2680 } 2681 if cap(z.FreeVersions) >= int(zb0003) { 2682 z.FreeVersions = (z.FreeVersions)[:zb0003] 2683 } else { 2684 z.FreeVersions = make([]FileInfo, zb0003) 2685 } 2686 for za0002 := range z.FreeVersions { 2687 bts, err = z.FreeVersions[za0002].UnmarshalMsg(bts) 2688 if err != nil { 2689 err = msgp.WrapError(err, "FreeVersions", za0002) 2690 return 2691 } 2692 } 2693 o = bts 2694 return 2695 } 2696 2697 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 2698 func (z *FileInfoVersions) Msgsize() (s int) { 2699 s = 1 + msgp.StringPrefixSize + len(z.Volume) + msgp.StringPrefixSize + len(z.Name) + msgp.TimeSize + msgp.ArrayHeaderSize 2700 for za0001 := range z.Versions { 2701 s += z.Versions[za0001].Msgsize() 2702 } 2703 s += msgp.ArrayHeaderSize 2704 for za0002 := range z.FreeVersions { 2705 s += z.FreeVersions[za0002].Msgsize() 2706 } 2707 return 2708 } 2709 2710 // DecodeMsg implements msgp.Decodable 2711 func (z *FilesInfo) DecodeMsg(dc *msgp.Reader) (err error) { 2712 var field []byte 2713 _ = field 2714 var zb0001 uint32 2715 zb0001, err = dc.ReadMapHeader() 2716 if err != nil { 2717 err = msgp.WrapError(err) 2718 return 2719 } 2720 for zb0001 > 0 { 2721 zb0001-- 2722 field, err = dc.ReadMapKeyPtr() 2723 if err != nil { 2724 err = msgp.WrapError(err) 2725 return 2726 } 2727 switch msgp.UnsafeString(field) { 2728 case "Files": 2729 var zb0002 uint32 2730 zb0002, err = dc.ReadArrayHeader() 2731 if err != nil { 2732 err = msgp.WrapError(err, "Files") 2733 return 2734 } 2735 if cap(z.Files) >= int(zb0002) { 2736 z.Files = (z.Files)[:zb0002] 2737 } else { 2738 z.Files = make([]FileInfo, zb0002) 2739 } 2740 for za0001 := range z.Files { 2741 err = z.Files[za0001].DecodeMsg(dc) 2742 if err != nil { 2743 err = msgp.WrapError(err, "Files", za0001) 2744 return 2745 } 2746 } 2747 case "IsTruncated": 2748 z.IsTruncated, err = dc.ReadBool() 2749 if err != nil { 2750 err = msgp.WrapError(err, "IsTruncated") 2751 return 2752 } 2753 default: 2754 err = dc.Skip() 2755 if err != nil { 2756 err = msgp.WrapError(err) 2757 return 2758 } 2759 } 2760 } 2761 return 2762 } 2763 2764 // EncodeMsg implements msgp.Encodable 2765 func (z *FilesInfo) EncodeMsg(en *msgp.Writer) (err error) { 2766 // map header, size 2 2767 // write "Files" 2768 err = en.Append(0x82, 0xa5, 0x46, 0x69, 0x6c, 0x65, 0x73) 2769 if err != nil { 2770 return 2771 } 2772 err = en.WriteArrayHeader(uint32(len(z.Files))) 2773 if err != nil { 2774 err = msgp.WrapError(err, "Files") 2775 return 2776 } 2777 for za0001 := range z.Files { 2778 err = z.Files[za0001].EncodeMsg(en) 2779 if err != nil { 2780 err = msgp.WrapError(err, "Files", za0001) 2781 return 2782 } 2783 } 2784 // write "IsTruncated" 2785 err = en.Append(0xab, 0x49, 0x73, 0x54, 0x72, 0x75, 0x6e, 0x63, 0x61, 0x74, 0x65, 0x64) 2786 if err != nil { 2787 return 2788 } 2789 err = en.WriteBool(z.IsTruncated) 2790 if err != nil { 2791 err = msgp.WrapError(err, "IsTruncated") 2792 return 2793 } 2794 return 2795 } 2796 2797 // MarshalMsg implements msgp.Marshaler 2798 func (z *FilesInfo) MarshalMsg(b []byte) (o []byte, err error) { 2799 o = msgp.Require(b, z.Msgsize()) 2800 // map header, size 2 2801 // string "Files" 2802 o = append(o, 0x82, 0xa5, 0x46, 0x69, 0x6c, 0x65, 0x73) 2803 o = msgp.AppendArrayHeader(o, uint32(len(z.Files))) 2804 for za0001 := range z.Files { 2805 o, err = z.Files[za0001].MarshalMsg(o) 2806 if err != nil { 2807 err = msgp.WrapError(err, "Files", za0001) 2808 return 2809 } 2810 } 2811 // string "IsTruncated" 2812 o = append(o, 0xab, 0x49, 0x73, 0x54, 0x72, 0x75, 0x6e, 0x63, 0x61, 0x74, 0x65, 0x64) 2813 o = msgp.AppendBool(o, z.IsTruncated) 2814 return 2815 } 2816 2817 // UnmarshalMsg implements msgp.Unmarshaler 2818 func (z *FilesInfo) UnmarshalMsg(bts []byte) (o []byte, err error) { 2819 var field []byte 2820 _ = field 2821 var zb0001 uint32 2822 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 2823 if err != nil { 2824 err = msgp.WrapError(err) 2825 return 2826 } 2827 for zb0001 > 0 { 2828 zb0001-- 2829 field, bts, err = msgp.ReadMapKeyZC(bts) 2830 if err != nil { 2831 err = msgp.WrapError(err) 2832 return 2833 } 2834 switch msgp.UnsafeString(field) { 2835 case "Files": 2836 var zb0002 uint32 2837 zb0002, bts, err = msgp.ReadArrayHeaderBytes(bts) 2838 if err != nil { 2839 err = msgp.WrapError(err, "Files") 2840 return 2841 } 2842 if cap(z.Files) >= int(zb0002) { 2843 z.Files = (z.Files)[:zb0002] 2844 } else { 2845 z.Files = make([]FileInfo, zb0002) 2846 } 2847 for za0001 := range z.Files { 2848 bts, err = z.Files[za0001].UnmarshalMsg(bts) 2849 if err != nil { 2850 err = msgp.WrapError(err, "Files", za0001) 2851 return 2852 } 2853 } 2854 case "IsTruncated": 2855 z.IsTruncated, bts, err = msgp.ReadBoolBytes(bts) 2856 if err != nil { 2857 err = msgp.WrapError(err, "IsTruncated") 2858 return 2859 } 2860 default: 2861 bts, err = msgp.Skip(bts) 2862 if err != nil { 2863 err = msgp.WrapError(err) 2864 return 2865 } 2866 } 2867 } 2868 o = bts 2869 return 2870 } 2871 2872 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 2873 func (z *FilesInfo) Msgsize() (s int) { 2874 s = 1 + 6 + msgp.ArrayHeaderSize 2875 for za0001 := range z.Files { 2876 s += z.Files[za0001].Msgsize() 2877 } 2878 s += 12 + msgp.BoolSize 2879 return 2880 } 2881 2882 // DecodeMsg implements msgp.Decodable 2883 func (z *ListDirResult) DecodeMsg(dc *msgp.Reader) (err error) { 2884 var field []byte 2885 _ = field 2886 var zb0001 uint32 2887 zb0001, err = dc.ReadMapHeader() 2888 if err != nil { 2889 err = msgp.WrapError(err) 2890 return 2891 } 2892 for zb0001 > 0 { 2893 zb0001-- 2894 field, err = dc.ReadMapKeyPtr() 2895 if err != nil { 2896 err = msgp.WrapError(err) 2897 return 2898 } 2899 switch msgp.UnsafeString(field) { 2900 case "e": 2901 var zb0002 uint32 2902 zb0002, err = dc.ReadArrayHeader() 2903 if err != nil { 2904 err = msgp.WrapError(err, "Entries") 2905 return 2906 } 2907 if cap(z.Entries) >= int(zb0002) { 2908 z.Entries = (z.Entries)[:zb0002] 2909 } else { 2910 z.Entries = make([]string, zb0002) 2911 } 2912 for za0001 := range z.Entries { 2913 z.Entries[za0001], err = dc.ReadString() 2914 if err != nil { 2915 err = msgp.WrapError(err, "Entries", za0001) 2916 return 2917 } 2918 } 2919 default: 2920 err = dc.Skip() 2921 if err != nil { 2922 err = msgp.WrapError(err) 2923 return 2924 } 2925 } 2926 } 2927 return 2928 } 2929 2930 // EncodeMsg implements msgp.Encodable 2931 func (z *ListDirResult) EncodeMsg(en *msgp.Writer) (err error) { 2932 // map header, size 1 2933 // write "e" 2934 err = en.Append(0x81, 0xa1, 0x65) 2935 if err != nil { 2936 return 2937 } 2938 err = en.WriteArrayHeader(uint32(len(z.Entries))) 2939 if err != nil { 2940 err = msgp.WrapError(err, "Entries") 2941 return 2942 } 2943 for za0001 := range z.Entries { 2944 err = en.WriteString(z.Entries[za0001]) 2945 if err != nil { 2946 err = msgp.WrapError(err, "Entries", za0001) 2947 return 2948 } 2949 } 2950 return 2951 } 2952 2953 // MarshalMsg implements msgp.Marshaler 2954 func (z *ListDirResult) MarshalMsg(b []byte) (o []byte, err error) { 2955 o = msgp.Require(b, z.Msgsize()) 2956 // map header, size 1 2957 // string "e" 2958 o = append(o, 0x81, 0xa1, 0x65) 2959 o = msgp.AppendArrayHeader(o, uint32(len(z.Entries))) 2960 for za0001 := range z.Entries { 2961 o = msgp.AppendString(o, z.Entries[za0001]) 2962 } 2963 return 2964 } 2965 2966 // UnmarshalMsg implements msgp.Unmarshaler 2967 func (z *ListDirResult) UnmarshalMsg(bts []byte) (o []byte, err error) { 2968 var field []byte 2969 _ = field 2970 var zb0001 uint32 2971 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 2972 if err != nil { 2973 err = msgp.WrapError(err) 2974 return 2975 } 2976 for zb0001 > 0 { 2977 zb0001-- 2978 field, bts, err = msgp.ReadMapKeyZC(bts) 2979 if err != nil { 2980 err = msgp.WrapError(err) 2981 return 2982 } 2983 switch msgp.UnsafeString(field) { 2984 case "e": 2985 var zb0002 uint32 2986 zb0002, bts, err = msgp.ReadArrayHeaderBytes(bts) 2987 if err != nil { 2988 err = msgp.WrapError(err, "Entries") 2989 return 2990 } 2991 if cap(z.Entries) >= int(zb0002) { 2992 z.Entries = (z.Entries)[:zb0002] 2993 } else { 2994 z.Entries = make([]string, zb0002) 2995 } 2996 for za0001 := range z.Entries { 2997 z.Entries[za0001], bts, err = msgp.ReadStringBytes(bts) 2998 if err != nil { 2999 err = msgp.WrapError(err, "Entries", za0001) 3000 return 3001 } 3002 } 3003 default: 3004 bts, err = msgp.Skip(bts) 3005 if err != nil { 3006 err = msgp.WrapError(err) 3007 return 3008 } 3009 } 3010 } 3011 o = bts 3012 return 3013 } 3014 3015 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 3016 func (z *ListDirResult) Msgsize() (s int) { 3017 s = 1 + 2 + msgp.ArrayHeaderSize 3018 for za0001 := range z.Entries { 3019 s += msgp.StringPrefixSize + len(z.Entries[za0001]) 3020 } 3021 return 3022 } 3023 3024 // DecodeMsg implements msgp.Decodable 3025 func (z *LocalDiskIDs) DecodeMsg(dc *msgp.Reader) (err error) { 3026 var field []byte 3027 _ = field 3028 var zb0001 uint32 3029 zb0001, err = dc.ReadMapHeader() 3030 if err != nil { 3031 err = msgp.WrapError(err) 3032 return 3033 } 3034 for zb0001 > 0 { 3035 zb0001-- 3036 field, err = dc.ReadMapKeyPtr() 3037 if err != nil { 3038 err = msgp.WrapError(err) 3039 return 3040 } 3041 switch msgp.UnsafeString(field) { 3042 case "IDs": 3043 var zb0002 uint32 3044 zb0002, err = dc.ReadArrayHeader() 3045 if err != nil { 3046 err = msgp.WrapError(err, "IDs") 3047 return 3048 } 3049 if cap(z.IDs) >= int(zb0002) { 3050 z.IDs = (z.IDs)[:zb0002] 3051 } else { 3052 z.IDs = make([]string, zb0002) 3053 } 3054 for za0001 := range z.IDs { 3055 z.IDs[za0001], err = dc.ReadString() 3056 if err != nil { 3057 err = msgp.WrapError(err, "IDs", za0001) 3058 return 3059 } 3060 } 3061 default: 3062 err = dc.Skip() 3063 if err != nil { 3064 err = msgp.WrapError(err) 3065 return 3066 } 3067 } 3068 } 3069 return 3070 } 3071 3072 // EncodeMsg implements msgp.Encodable 3073 func (z *LocalDiskIDs) EncodeMsg(en *msgp.Writer) (err error) { 3074 // map header, size 1 3075 // write "IDs" 3076 err = en.Append(0x81, 0xa3, 0x49, 0x44, 0x73) 3077 if err != nil { 3078 return 3079 } 3080 err = en.WriteArrayHeader(uint32(len(z.IDs))) 3081 if err != nil { 3082 err = msgp.WrapError(err, "IDs") 3083 return 3084 } 3085 for za0001 := range z.IDs { 3086 err = en.WriteString(z.IDs[za0001]) 3087 if err != nil { 3088 err = msgp.WrapError(err, "IDs", za0001) 3089 return 3090 } 3091 } 3092 return 3093 } 3094 3095 // MarshalMsg implements msgp.Marshaler 3096 func (z *LocalDiskIDs) MarshalMsg(b []byte) (o []byte, err error) { 3097 o = msgp.Require(b, z.Msgsize()) 3098 // map header, size 1 3099 // string "IDs" 3100 o = append(o, 0x81, 0xa3, 0x49, 0x44, 0x73) 3101 o = msgp.AppendArrayHeader(o, uint32(len(z.IDs))) 3102 for za0001 := range z.IDs { 3103 o = msgp.AppendString(o, z.IDs[za0001]) 3104 } 3105 return 3106 } 3107 3108 // UnmarshalMsg implements msgp.Unmarshaler 3109 func (z *LocalDiskIDs) UnmarshalMsg(bts []byte) (o []byte, err error) { 3110 var field []byte 3111 _ = field 3112 var zb0001 uint32 3113 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 3114 if err != nil { 3115 err = msgp.WrapError(err) 3116 return 3117 } 3118 for zb0001 > 0 { 3119 zb0001-- 3120 field, bts, err = msgp.ReadMapKeyZC(bts) 3121 if err != nil { 3122 err = msgp.WrapError(err) 3123 return 3124 } 3125 switch msgp.UnsafeString(field) { 3126 case "IDs": 3127 var zb0002 uint32 3128 zb0002, bts, err = msgp.ReadArrayHeaderBytes(bts) 3129 if err != nil { 3130 err = msgp.WrapError(err, "IDs") 3131 return 3132 } 3133 if cap(z.IDs) >= int(zb0002) { 3134 z.IDs = (z.IDs)[:zb0002] 3135 } else { 3136 z.IDs = make([]string, zb0002) 3137 } 3138 for za0001 := range z.IDs { 3139 z.IDs[za0001], bts, err = msgp.ReadStringBytes(bts) 3140 if err != nil { 3141 err = msgp.WrapError(err, "IDs", za0001) 3142 return 3143 } 3144 } 3145 default: 3146 bts, err = msgp.Skip(bts) 3147 if err != nil { 3148 err = msgp.WrapError(err) 3149 return 3150 } 3151 } 3152 } 3153 o = bts 3154 return 3155 } 3156 3157 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 3158 func (z *LocalDiskIDs) Msgsize() (s int) { 3159 s = 1 + 4 + msgp.ArrayHeaderSize 3160 for za0001 := range z.IDs { 3161 s += msgp.StringPrefixSize + len(z.IDs[za0001]) 3162 } 3163 return 3164 } 3165 3166 // DecodeMsg implements msgp.Decodable 3167 func (z *MetadataHandlerParams) DecodeMsg(dc *msgp.Reader) (err error) { 3168 var field []byte 3169 _ = field 3170 var zb0001 uint32 3171 zb0001, err = dc.ReadMapHeader() 3172 if err != nil { 3173 err = msgp.WrapError(err) 3174 return 3175 } 3176 for zb0001 > 0 { 3177 zb0001-- 3178 field, err = dc.ReadMapKeyPtr() 3179 if err != nil { 3180 err = msgp.WrapError(err) 3181 return 3182 } 3183 switch msgp.UnsafeString(field) { 3184 case "id": 3185 z.DiskID, err = dc.ReadString() 3186 if err != nil { 3187 err = msgp.WrapError(err, "DiskID") 3188 return 3189 } 3190 case "v": 3191 z.Volume, err = dc.ReadString() 3192 if err != nil { 3193 err = msgp.WrapError(err, "Volume") 3194 return 3195 } 3196 case "ov": 3197 z.OrigVolume, err = dc.ReadString() 3198 if err != nil { 3199 err = msgp.WrapError(err, "OrigVolume") 3200 return 3201 } 3202 case "fp": 3203 z.FilePath, err = dc.ReadString() 3204 if err != nil { 3205 err = msgp.WrapError(err, "FilePath") 3206 return 3207 } 3208 case "uo": 3209 var zb0002 uint32 3210 zb0002, err = dc.ReadMapHeader() 3211 if err != nil { 3212 err = msgp.WrapError(err, "UpdateOpts") 3213 return 3214 } 3215 for zb0002 > 0 { 3216 zb0002-- 3217 field, err = dc.ReadMapKeyPtr() 3218 if err != nil { 3219 err = msgp.WrapError(err, "UpdateOpts") 3220 return 3221 } 3222 switch msgp.UnsafeString(field) { 3223 case "np": 3224 z.UpdateOpts.NoPersistence, err = dc.ReadBool() 3225 if err != nil { 3226 err = msgp.WrapError(err, "UpdateOpts", "NoPersistence") 3227 return 3228 } 3229 default: 3230 err = dc.Skip() 3231 if err != nil { 3232 err = msgp.WrapError(err, "UpdateOpts") 3233 return 3234 } 3235 } 3236 } 3237 case "fi": 3238 err = z.FI.DecodeMsg(dc) 3239 if err != nil { 3240 err = msgp.WrapError(err, "FI") 3241 return 3242 } 3243 default: 3244 err = dc.Skip() 3245 if err != nil { 3246 err = msgp.WrapError(err) 3247 return 3248 } 3249 } 3250 } 3251 return 3252 } 3253 3254 // EncodeMsg implements msgp.Encodable 3255 func (z *MetadataHandlerParams) EncodeMsg(en *msgp.Writer) (err error) { 3256 // map header, size 6 3257 // write "id" 3258 err = en.Append(0x86, 0xa2, 0x69, 0x64) 3259 if err != nil { 3260 return 3261 } 3262 err = en.WriteString(z.DiskID) 3263 if err != nil { 3264 err = msgp.WrapError(err, "DiskID") 3265 return 3266 } 3267 // write "v" 3268 err = en.Append(0xa1, 0x76) 3269 if err != nil { 3270 return 3271 } 3272 err = en.WriteString(z.Volume) 3273 if err != nil { 3274 err = msgp.WrapError(err, "Volume") 3275 return 3276 } 3277 // write "ov" 3278 err = en.Append(0xa2, 0x6f, 0x76) 3279 if err != nil { 3280 return 3281 } 3282 err = en.WriteString(z.OrigVolume) 3283 if err != nil { 3284 err = msgp.WrapError(err, "OrigVolume") 3285 return 3286 } 3287 // write "fp" 3288 err = en.Append(0xa2, 0x66, 0x70) 3289 if err != nil { 3290 return 3291 } 3292 err = en.WriteString(z.FilePath) 3293 if err != nil { 3294 err = msgp.WrapError(err, "FilePath") 3295 return 3296 } 3297 // write "uo" 3298 err = en.Append(0xa2, 0x75, 0x6f) 3299 if err != nil { 3300 return 3301 } 3302 // map header, size 1 3303 // write "np" 3304 err = en.Append(0x81, 0xa2, 0x6e, 0x70) 3305 if err != nil { 3306 return 3307 } 3308 err = en.WriteBool(z.UpdateOpts.NoPersistence) 3309 if err != nil { 3310 err = msgp.WrapError(err, "UpdateOpts", "NoPersistence") 3311 return 3312 } 3313 // write "fi" 3314 err = en.Append(0xa2, 0x66, 0x69) 3315 if err != nil { 3316 return 3317 } 3318 err = z.FI.EncodeMsg(en) 3319 if err != nil { 3320 err = msgp.WrapError(err, "FI") 3321 return 3322 } 3323 return 3324 } 3325 3326 // MarshalMsg implements msgp.Marshaler 3327 func (z *MetadataHandlerParams) MarshalMsg(b []byte) (o []byte, err error) { 3328 o = msgp.Require(b, z.Msgsize()) 3329 // map header, size 6 3330 // string "id" 3331 o = append(o, 0x86, 0xa2, 0x69, 0x64) 3332 o = msgp.AppendString(o, z.DiskID) 3333 // string "v" 3334 o = append(o, 0xa1, 0x76) 3335 o = msgp.AppendString(o, z.Volume) 3336 // string "ov" 3337 o = append(o, 0xa2, 0x6f, 0x76) 3338 o = msgp.AppendString(o, z.OrigVolume) 3339 // string "fp" 3340 o = append(o, 0xa2, 0x66, 0x70) 3341 o = msgp.AppendString(o, z.FilePath) 3342 // string "uo" 3343 o = append(o, 0xa2, 0x75, 0x6f) 3344 // map header, size 1 3345 // string "np" 3346 o = append(o, 0x81, 0xa2, 0x6e, 0x70) 3347 o = msgp.AppendBool(o, z.UpdateOpts.NoPersistence) 3348 // string "fi" 3349 o = append(o, 0xa2, 0x66, 0x69) 3350 o, err = z.FI.MarshalMsg(o) 3351 if err != nil { 3352 err = msgp.WrapError(err, "FI") 3353 return 3354 } 3355 return 3356 } 3357 3358 // UnmarshalMsg implements msgp.Unmarshaler 3359 func (z *MetadataHandlerParams) UnmarshalMsg(bts []byte) (o []byte, err error) { 3360 var field []byte 3361 _ = field 3362 var zb0001 uint32 3363 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 3364 if err != nil { 3365 err = msgp.WrapError(err) 3366 return 3367 } 3368 for zb0001 > 0 { 3369 zb0001-- 3370 field, bts, err = msgp.ReadMapKeyZC(bts) 3371 if err != nil { 3372 err = msgp.WrapError(err) 3373 return 3374 } 3375 switch msgp.UnsafeString(field) { 3376 case "id": 3377 z.DiskID, bts, err = msgp.ReadStringBytes(bts) 3378 if err != nil { 3379 err = msgp.WrapError(err, "DiskID") 3380 return 3381 } 3382 case "v": 3383 z.Volume, bts, err = msgp.ReadStringBytes(bts) 3384 if err != nil { 3385 err = msgp.WrapError(err, "Volume") 3386 return 3387 } 3388 case "ov": 3389 z.OrigVolume, bts, err = msgp.ReadStringBytes(bts) 3390 if err != nil { 3391 err = msgp.WrapError(err, "OrigVolume") 3392 return 3393 } 3394 case "fp": 3395 z.FilePath, bts, err = msgp.ReadStringBytes(bts) 3396 if err != nil { 3397 err = msgp.WrapError(err, "FilePath") 3398 return 3399 } 3400 case "uo": 3401 var zb0002 uint32 3402 zb0002, bts, err = msgp.ReadMapHeaderBytes(bts) 3403 if err != nil { 3404 err = msgp.WrapError(err, "UpdateOpts") 3405 return 3406 } 3407 for zb0002 > 0 { 3408 zb0002-- 3409 field, bts, err = msgp.ReadMapKeyZC(bts) 3410 if err != nil { 3411 err = msgp.WrapError(err, "UpdateOpts") 3412 return 3413 } 3414 switch msgp.UnsafeString(field) { 3415 case "np": 3416 z.UpdateOpts.NoPersistence, bts, err = msgp.ReadBoolBytes(bts) 3417 if err != nil { 3418 err = msgp.WrapError(err, "UpdateOpts", "NoPersistence") 3419 return 3420 } 3421 default: 3422 bts, err = msgp.Skip(bts) 3423 if err != nil { 3424 err = msgp.WrapError(err, "UpdateOpts") 3425 return 3426 } 3427 } 3428 } 3429 case "fi": 3430 bts, err = z.FI.UnmarshalMsg(bts) 3431 if err != nil { 3432 err = msgp.WrapError(err, "FI") 3433 return 3434 } 3435 default: 3436 bts, err = msgp.Skip(bts) 3437 if err != nil { 3438 err = msgp.WrapError(err) 3439 return 3440 } 3441 } 3442 } 3443 o = bts 3444 return 3445 } 3446 3447 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 3448 func (z *MetadataHandlerParams) Msgsize() (s int) { 3449 s = 1 + 3 + msgp.StringPrefixSize + len(z.DiskID) + 2 + msgp.StringPrefixSize + len(z.Volume) + 3 + msgp.StringPrefixSize + len(z.OrigVolume) + 3 + msgp.StringPrefixSize + len(z.FilePath) + 3 + 1 + 3 + msgp.BoolSize + 3 + z.FI.Msgsize() 3450 return 3451 } 3452 3453 // DecodeMsg implements msgp.Decodable 3454 func (z *RawFileInfo) DecodeMsg(dc *msgp.Reader) (err error) { 3455 var field []byte 3456 _ = field 3457 var zb0001 uint32 3458 zb0001, err = dc.ReadMapHeader() 3459 if err != nil { 3460 err = msgp.WrapError(err) 3461 return 3462 } 3463 for zb0001 > 0 { 3464 zb0001-- 3465 field, err = dc.ReadMapKeyPtr() 3466 if err != nil { 3467 err = msgp.WrapError(err) 3468 return 3469 } 3470 switch msgp.UnsafeString(field) { 3471 case "b": 3472 if dc.IsNil() { 3473 err = dc.ReadNil() 3474 if err != nil { 3475 err = msgp.WrapError(err, "Buf") 3476 return 3477 } 3478 z.Buf = nil 3479 } else { 3480 z.Buf, err = dc.ReadBytes(z.Buf) 3481 if err != nil { 3482 err = msgp.WrapError(err, "Buf") 3483 return 3484 } 3485 } 3486 default: 3487 err = dc.Skip() 3488 if err != nil { 3489 err = msgp.WrapError(err) 3490 return 3491 } 3492 } 3493 } 3494 return 3495 } 3496 3497 // EncodeMsg implements msgp.Encodable 3498 func (z *RawFileInfo) EncodeMsg(en *msgp.Writer) (err error) { 3499 // map header, size 1 3500 // write "b" 3501 err = en.Append(0x81, 0xa1, 0x62) 3502 if err != nil { 3503 return 3504 } 3505 if z.Buf == nil { // allownil: if nil 3506 err = en.WriteNil() 3507 if err != nil { 3508 return 3509 } 3510 } else { 3511 err = en.WriteBytes(z.Buf) 3512 if err != nil { 3513 err = msgp.WrapError(err, "Buf") 3514 return 3515 } 3516 } 3517 return 3518 } 3519 3520 // MarshalMsg implements msgp.Marshaler 3521 func (z *RawFileInfo) MarshalMsg(b []byte) (o []byte, err error) { 3522 o = msgp.Require(b, z.Msgsize()) 3523 // map header, size 1 3524 // string "b" 3525 o = append(o, 0x81, 0xa1, 0x62) 3526 if z.Buf == nil { // allownil: if nil 3527 o = msgp.AppendNil(o) 3528 } else { 3529 o = msgp.AppendBytes(o, z.Buf) 3530 } 3531 return 3532 } 3533 3534 // UnmarshalMsg implements msgp.Unmarshaler 3535 func (z *RawFileInfo) UnmarshalMsg(bts []byte) (o []byte, err error) { 3536 var field []byte 3537 _ = field 3538 var zb0001 uint32 3539 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 3540 if err != nil { 3541 err = msgp.WrapError(err) 3542 return 3543 } 3544 for zb0001 > 0 { 3545 zb0001-- 3546 field, bts, err = msgp.ReadMapKeyZC(bts) 3547 if err != nil { 3548 err = msgp.WrapError(err) 3549 return 3550 } 3551 switch msgp.UnsafeString(field) { 3552 case "b": 3553 if msgp.IsNil(bts) { 3554 bts = bts[1:] 3555 z.Buf = nil 3556 } else { 3557 z.Buf, bts, err = msgp.ReadBytesBytes(bts, z.Buf) 3558 if err != nil { 3559 err = msgp.WrapError(err, "Buf") 3560 return 3561 } 3562 } 3563 default: 3564 bts, err = msgp.Skip(bts) 3565 if err != nil { 3566 err = msgp.WrapError(err) 3567 return 3568 } 3569 } 3570 } 3571 o = bts 3572 return 3573 } 3574 3575 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 3576 func (z *RawFileInfo) Msgsize() (s int) { 3577 s = 1 + 2 + msgp.BytesPrefixSize + len(z.Buf) 3578 return 3579 } 3580 3581 // DecodeMsg implements msgp.Decodable 3582 func (z *ReadAllHandlerParams) DecodeMsg(dc *msgp.Reader) (err error) { 3583 var field []byte 3584 _ = field 3585 var zb0001 uint32 3586 zb0001, err = dc.ReadMapHeader() 3587 if err != nil { 3588 err = msgp.WrapError(err) 3589 return 3590 } 3591 for zb0001 > 0 { 3592 zb0001-- 3593 field, err = dc.ReadMapKeyPtr() 3594 if err != nil { 3595 err = msgp.WrapError(err) 3596 return 3597 } 3598 switch msgp.UnsafeString(field) { 3599 case "id": 3600 z.DiskID, err = dc.ReadString() 3601 if err != nil { 3602 err = msgp.WrapError(err, "DiskID") 3603 return 3604 } 3605 case "v": 3606 z.Volume, err = dc.ReadString() 3607 if err != nil { 3608 err = msgp.WrapError(err, "Volume") 3609 return 3610 } 3611 case "fp": 3612 z.FilePath, err = dc.ReadString() 3613 if err != nil { 3614 err = msgp.WrapError(err, "FilePath") 3615 return 3616 } 3617 default: 3618 err = dc.Skip() 3619 if err != nil { 3620 err = msgp.WrapError(err) 3621 return 3622 } 3623 } 3624 } 3625 return 3626 } 3627 3628 // EncodeMsg implements msgp.Encodable 3629 func (z ReadAllHandlerParams) EncodeMsg(en *msgp.Writer) (err error) { 3630 // map header, size 3 3631 // write "id" 3632 err = en.Append(0x83, 0xa2, 0x69, 0x64) 3633 if err != nil { 3634 return 3635 } 3636 err = en.WriteString(z.DiskID) 3637 if err != nil { 3638 err = msgp.WrapError(err, "DiskID") 3639 return 3640 } 3641 // write "v" 3642 err = en.Append(0xa1, 0x76) 3643 if err != nil { 3644 return 3645 } 3646 err = en.WriteString(z.Volume) 3647 if err != nil { 3648 err = msgp.WrapError(err, "Volume") 3649 return 3650 } 3651 // write "fp" 3652 err = en.Append(0xa2, 0x66, 0x70) 3653 if err != nil { 3654 return 3655 } 3656 err = en.WriteString(z.FilePath) 3657 if err != nil { 3658 err = msgp.WrapError(err, "FilePath") 3659 return 3660 } 3661 return 3662 } 3663 3664 // MarshalMsg implements msgp.Marshaler 3665 func (z ReadAllHandlerParams) MarshalMsg(b []byte) (o []byte, err error) { 3666 o = msgp.Require(b, z.Msgsize()) 3667 // map header, size 3 3668 // string "id" 3669 o = append(o, 0x83, 0xa2, 0x69, 0x64) 3670 o = msgp.AppendString(o, z.DiskID) 3671 // string "v" 3672 o = append(o, 0xa1, 0x76) 3673 o = msgp.AppendString(o, z.Volume) 3674 // string "fp" 3675 o = append(o, 0xa2, 0x66, 0x70) 3676 o = msgp.AppendString(o, z.FilePath) 3677 return 3678 } 3679 3680 // UnmarshalMsg implements msgp.Unmarshaler 3681 func (z *ReadAllHandlerParams) UnmarshalMsg(bts []byte) (o []byte, err error) { 3682 var field []byte 3683 _ = field 3684 var zb0001 uint32 3685 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 3686 if err != nil { 3687 err = msgp.WrapError(err) 3688 return 3689 } 3690 for zb0001 > 0 { 3691 zb0001-- 3692 field, bts, err = msgp.ReadMapKeyZC(bts) 3693 if err != nil { 3694 err = msgp.WrapError(err) 3695 return 3696 } 3697 switch msgp.UnsafeString(field) { 3698 case "id": 3699 z.DiskID, bts, err = msgp.ReadStringBytes(bts) 3700 if err != nil { 3701 err = msgp.WrapError(err, "DiskID") 3702 return 3703 } 3704 case "v": 3705 z.Volume, bts, err = msgp.ReadStringBytes(bts) 3706 if err != nil { 3707 err = msgp.WrapError(err, "Volume") 3708 return 3709 } 3710 case "fp": 3711 z.FilePath, bts, err = msgp.ReadStringBytes(bts) 3712 if err != nil { 3713 err = msgp.WrapError(err, "FilePath") 3714 return 3715 } 3716 default: 3717 bts, err = msgp.Skip(bts) 3718 if err != nil { 3719 err = msgp.WrapError(err) 3720 return 3721 } 3722 } 3723 } 3724 o = bts 3725 return 3726 } 3727 3728 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 3729 func (z ReadAllHandlerParams) Msgsize() (s int) { 3730 s = 1 + 3 + msgp.StringPrefixSize + len(z.DiskID) + 2 + msgp.StringPrefixSize + len(z.Volume) + 3 + msgp.StringPrefixSize + len(z.FilePath) 3731 return 3732 } 3733 3734 // DecodeMsg implements msgp.Decodable 3735 func (z *ReadMultipleReq) DecodeMsg(dc *msgp.Reader) (err error) { 3736 var field []byte 3737 _ = field 3738 var zb0001 uint32 3739 zb0001, err = dc.ReadMapHeader() 3740 if err != nil { 3741 err = msgp.WrapError(err) 3742 return 3743 } 3744 for zb0001 > 0 { 3745 zb0001-- 3746 field, err = dc.ReadMapKeyPtr() 3747 if err != nil { 3748 err = msgp.WrapError(err) 3749 return 3750 } 3751 switch msgp.UnsafeString(field) { 3752 case "Bucket": 3753 z.Bucket, err = dc.ReadString() 3754 if err != nil { 3755 err = msgp.WrapError(err, "Bucket") 3756 return 3757 } 3758 case "Prefix": 3759 z.Prefix, err = dc.ReadString() 3760 if err != nil { 3761 err = msgp.WrapError(err, "Prefix") 3762 return 3763 } 3764 case "Files": 3765 var zb0002 uint32 3766 zb0002, err = dc.ReadArrayHeader() 3767 if err != nil { 3768 err = msgp.WrapError(err, "Files") 3769 return 3770 } 3771 if cap(z.Files) >= int(zb0002) { 3772 z.Files = (z.Files)[:zb0002] 3773 } else { 3774 z.Files = make([]string, zb0002) 3775 } 3776 for za0001 := range z.Files { 3777 z.Files[za0001], err = dc.ReadString() 3778 if err != nil { 3779 err = msgp.WrapError(err, "Files", za0001) 3780 return 3781 } 3782 } 3783 case "MaxSize": 3784 z.MaxSize, err = dc.ReadInt64() 3785 if err != nil { 3786 err = msgp.WrapError(err, "MaxSize") 3787 return 3788 } 3789 case "MetadataOnly": 3790 z.MetadataOnly, err = dc.ReadBool() 3791 if err != nil { 3792 err = msgp.WrapError(err, "MetadataOnly") 3793 return 3794 } 3795 case "AbortOn404": 3796 z.AbortOn404, err = dc.ReadBool() 3797 if err != nil { 3798 err = msgp.WrapError(err, "AbortOn404") 3799 return 3800 } 3801 case "MaxResults": 3802 z.MaxResults, err = dc.ReadInt() 3803 if err != nil { 3804 err = msgp.WrapError(err, "MaxResults") 3805 return 3806 } 3807 default: 3808 err = dc.Skip() 3809 if err != nil { 3810 err = msgp.WrapError(err) 3811 return 3812 } 3813 } 3814 } 3815 return 3816 } 3817 3818 // EncodeMsg implements msgp.Encodable 3819 func (z *ReadMultipleReq) EncodeMsg(en *msgp.Writer) (err error) { 3820 // map header, size 7 3821 // write "Bucket" 3822 err = en.Append(0x87, 0xa6, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74) 3823 if err != nil { 3824 return 3825 } 3826 err = en.WriteString(z.Bucket) 3827 if err != nil { 3828 err = msgp.WrapError(err, "Bucket") 3829 return 3830 } 3831 // write "Prefix" 3832 err = en.Append(0xa6, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78) 3833 if err != nil { 3834 return 3835 } 3836 err = en.WriteString(z.Prefix) 3837 if err != nil { 3838 err = msgp.WrapError(err, "Prefix") 3839 return 3840 } 3841 // write "Files" 3842 err = en.Append(0xa5, 0x46, 0x69, 0x6c, 0x65, 0x73) 3843 if err != nil { 3844 return 3845 } 3846 err = en.WriteArrayHeader(uint32(len(z.Files))) 3847 if err != nil { 3848 err = msgp.WrapError(err, "Files") 3849 return 3850 } 3851 for za0001 := range z.Files { 3852 err = en.WriteString(z.Files[za0001]) 3853 if err != nil { 3854 err = msgp.WrapError(err, "Files", za0001) 3855 return 3856 } 3857 } 3858 // write "MaxSize" 3859 err = en.Append(0xa7, 0x4d, 0x61, 0x78, 0x53, 0x69, 0x7a, 0x65) 3860 if err != nil { 3861 return 3862 } 3863 err = en.WriteInt64(z.MaxSize) 3864 if err != nil { 3865 err = msgp.WrapError(err, "MaxSize") 3866 return 3867 } 3868 // write "MetadataOnly" 3869 err = en.Append(0xac, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x4f, 0x6e, 0x6c, 0x79) 3870 if err != nil { 3871 return 3872 } 3873 err = en.WriteBool(z.MetadataOnly) 3874 if err != nil { 3875 err = msgp.WrapError(err, "MetadataOnly") 3876 return 3877 } 3878 // write "AbortOn404" 3879 err = en.Append(0xaa, 0x41, 0x62, 0x6f, 0x72, 0x74, 0x4f, 0x6e, 0x34, 0x30, 0x34) 3880 if err != nil { 3881 return 3882 } 3883 err = en.WriteBool(z.AbortOn404) 3884 if err != nil { 3885 err = msgp.WrapError(err, "AbortOn404") 3886 return 3887 } 3888 // write "MaxResults" 3889 err = en.Append(0xaa, 0x4d, 0x61, 0x78, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73) 3890 if err != nil { 3891 return 3892 } 3893 err = en.WriteInt(z.MaxResults) 3894 if err != nil { 3895 err = msgp.WrapError(err, "MaxResults") 3896 return 3897 } 3898 return 3899 } 3900 3901 // MarshalMsg implements msgp.Marshaler 3902 func (z *ReadMultipleReq) MarshalMsg(b []byte) (o []byte, err error) { 3903 o = msgp.Require(b, z.Msgsize()) 3904 // map header, size 7 3905 // string "Bucket" 3906 o = append(o, 0x87, 0xa6, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74) 3907 o = msgp.AppendString(o, z.Bucket) 3908 // string "Prefix" 3909 o = append(o, 0xa6, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78) 3910 o = msgp.AppendString(o, z.Prefix) 3911 // string "Files" 3912 o = append(o, 0xa5, 0x46, 0x69, 0x6c, 0x65, 0x73) 3913 o = msgp.AppendArrayHeader(o, uint32(len(z.Files))) 3914 for za0001 := range z.Files { 3915 o = msgp.AppendString(o, z.Files[za0001]) 3916 } 3917 // string "MaxSize" 3918 o = append(o, 0xa7, 0x4d, 0x61, 0x78, 0x53, 0x69, 0x7a, 0x65) 3919 o = msgp.AppendInt64(o, z.MaxSize) 3920 // string "MetadataOnly" 3921 o = append(o, 0xac, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x4f, 0x6e, 0x6c, 0x79) 3922 o = msgp.AppendBool(o, z.MetadataOnly) 3923 // string "AbortOn404" 3924 o = append(o, 0xaa, 0x41, 0x62, 0x6f, 0x72, 0x74, 0x4f, 0x6e, 0x34, 0x30, 0x34) 3925 o = msgp.AppendBool(o, z.AbortOn404) 3926 // string "MaxResults" 3927 o = append(o, 0xaa, 0x4d, 0x61, 0x78, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73) 3928 o = msgp.AppendInt(o, z.MaxResults) 3929 return 3930 } 3931 3932 // UnmarshalMsg implements msgp.Unmarshaler 3933 func (z *ReadMultipleReq) UnmarshalMsg(bts []byte) (o []byte, err error) { 3934 var field []byte 3935 _ = field 3936 var zb0001 uint32 3937 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 3938 if err != nil { 3939 err = msgp.WrapError(err) 3940 return 3941 } 3942 for zb0001 > 0 { 3943 zb0001-- 3944 field, bts, err = msgp.ReadMapKeyZC(bts) 3945 if err != nil { 3946 err = msgp.WrapError(err) 3947 return 3948 } 3949 switch msgp.UnsafeString(field) { 3950 case "Bucket": 3951 z.Bucket, bts, err = msgp.ReadStringBytes(bts) 3952 if err != nil { 3953 err = msgp.WrapError(err, "Bucket") 3954 return 3955 } 3956 case "Prefix": 3957 z.Prefix, bts, err = msgp.ReadStringBytes(bts) 3958 if err != nil { 3959 err = msgp.WrapError(err, "Prefix") 3960 return 3961 } 3962 case "Files": 3963 var zb0002 uint32 3964 zb0002, bts, err = msgp.ReadArrayHeaderBytes(bts) 3965 if err != nil { 3966 err = msgp.WrapError(err, "Files") 3967 return 3968 } 3969 if cap(z.Files) >= int(zb0002) { 3970 z.Files = (z.Files)[:zb0002] 3971 } else { 3972 z.Files = make([]string, zb0002) 3973 } 3974 for za0001 := range z.Files { 3975 z.Files[za0001], bts, err = msgp.ReadStringBytes(bts) 3976 if err != nil { 3977 err = msgp.WrapError(err, "Files", za0001) 3978 return 3979 } 3980 } 3981 case "MaxSize": 3982 z.MaxSize, bts, err = msgp.ReadInt64Bytes(bts) 3983 if err != nil { 3984 err = msgp.WrapError(err, "MaxSize") 3985 return 3986 } 3987 case "MetadataOnly": 3988 z.MetadataOnly, bts, err = msgp.ReadBoolBytes(bts) 3989 if err != nil { 3990 err = msgp.WrapError(err, "MetadataOnly") 3991 return 3992 } 3993 case "AbortOn404": 3994 z.AbortOn404, bts, err = msgp.ReadBoolBytes(bts) 3995 if err != nil { 3996 err = msgp.WrapError(err, "AbortOn404") 3997 return 3998 } 3999 case "MaxResults": 4000 z.MaxResults, bts, err = msgp.ReadIntBytes(bts) 4001 if err != nil { 4002 err = msgp.WrapError(err, "MaxResults") 4003 return 4004 } 4005 default: 4006 bts, err = msgp.Skip(bts) 4007 if err != nil { 4008 err = msgp.WrapError(err) 4009 return 4010 } 4011 } 4012 } 4013 o = bts 4014 return 4015 } 4016 4017 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 4018 func (z *ReadMultipleReq) Msgsize() (s int) { 4019 s = 1 + 7 + msgp.StringPrefixSize + len(z.Bucket) + 7 + msgp.StringPrefixSize + len(z.Prefix) + 6 + msgp.ArrayHeaderSize 4020 for za0001 := range z.Files { 4021 s += msgp.StringPrefixSize + len(z.Files[za0001]) 4022 } 4023 s += 8 + msgp.Int64Size + 13 + msgp.BoolSize + 11 + msgp.BoolSize + 11 + msgp.IntSize 4024 return 4025 } 4026 4027 // DecodeMsg implements msgp.Decodable 4028 func (z *ReadMultipleResp) DecodeMsg(dc *msgp.Reader) (err error) { 4029 var field []byte 4030 _ = field 4031 var zb0001 uint32 4032 zb0001, err = dc.ReadMapHeader() 4033 if err != nil { 4034 err = msgp.WrapError(err) 4035 return 4036 } 4037 for zb0001 > 0 { 4038 zb0001-- 4039 field, err = dc.ReadMapKeyPtr() 4040 if err != nil { 4041 err = msgp.WrapError(err) 4042 return 4043 } 4044 switch msgp.UnsafeString(field) { 4045 case "Bucket": 4046 z.Bucket, err = dc.ReadString() 4047 if err != nil { 4048 err = msgp.WrapError(err, "Bucket") 4049 return 4050 } 4051 case "Prefix": 4052 z.Prefix, err = dc.ReadString() 4053 if err != nil { 4054 err = msgp.WrapError(err, "Prefix") 4055 return 4056 } 4057 case "File": 4058 z.File, err = dc.ReadString() 4059 if err != nil { 4060 err = msgp.WrapError(err, "File") 4061 return 4062 } 4063 case "Exists": 4064 z.Exists, err = dc.ReadBool() 4065 if err != nil { 4066 err = msgp.WrapError(err, "Exists") 4067 return 4068 } 4069 case "Error": 4070 z.Error, err = dc.ReadString() 4071 if err != nil { 4072 err = msgp.WrapError(err, "Error") 4073 return 4074 } 4075 case "Data": 4076 z.Data, err = dc.ReadBytes(z.Data) 4077 if err != nil { 4078 err = msgp.WrapError(err, "Data") 4079 return 4080 } 4081 case "Modtime": 4082 z.Modtime, err = dc.ReadTime() 4083 if err != nil { 4084 err = msgp.WrapError(err, "Modtime") 4085 return 4086 } 4087 default: 4088 err = dc.Skip() 4089 if err != nil { 4090 err = msgp.WrapError(err) 4091 return 4092 } 4093 } 4094 } 4095 return 4096 } 4097 4098 // EncodeMsg implements msgp.Encodable 4099 func (z *ReadMultipleResp) EncodeMsg(en *msgp.Writer) (err error) { 4100 // map header, size 7 4101 // write "Bucket" 4102 err = en.Append(0x87, 0xa6, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74) 4103 if err != nil { 4104 return 4105 } 4106 err = en.WriteString(z.Bucket) 4107 if err != nil { 4108 err = msgp.WrapError(err, "Bucket") 4109 return 4110 } 4111 // write "Prefix" 4112 err = en.Append(0xa6, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78) 4113 if err != nil { 4114 return 4115 } 4116 err = en.WriteString(z.Prefix) 4117 if err != nil { 4118 err = msgp.WrapError(err, "Prefix") 4119 return 4120 } 4121 // write "File" 4122 err = en.Append(0xa4, 0x46, 0x69, 0x6c, 0x65) 4123 if err != nil { 4124 return 4125 } 4126 err = en.WriteString(z.File) 4127 if err != nil { 4128 err = msgp.WrapError(err, "File") 4129 return 4130 } 4131 // write "Exists" 4132 err = en.Append(0xa6, 0x45, 0x78, 0x69, 0x73, 0x74, 0x73) 4133 if err != nil { 4134 return 4135 } 4136 err = en.WriteBool(z.Exists) 4137 if err != nil { 4138 err = msgp.WrapError(err, "Exists") 4139 return 4140 } 4141 // write "Error" 4142 err = en.Append(0xa5, 0x45, 0x72, 0x72, 0x6f, 0x72) 4143 if err != nil { 4144 return 4145 } 4146 err = en.WriteString(z.Error) 4147 if err != nil { 4148 err = msgp.WrapError(err, "Error") 4149 return 4150 } 4151 // write "Data" 4152 err = en.Append(0xa4, 0x44, 0x61, 0x74, 0x61) 4153 if err != nil { 4154 return 4155 } 4156 err = en.WriteBytes(z.Data) 4157 if err != nil { 4158 err = msgp.WrapError(err, "Data") 4159 return 4160 } 4161 // write "Modtime" 4162 err = en.Append(0xa7, 0x4d, 0x6f, 0x64, 0x74, 0x69, 0x6d, 0x65) 4163 if err != nil { 4164 return 4165 } 4166 err = en.WriteTime(z.Modtime) 4167 if err != nil { 4168 err = msgp.WrapError(err, "Modtime") 4169 return 4170 } 4171 return 4172 } 4173 4174 // MarshalMsg implements msgp.Marshaler 4175 func (z *ReadMultipleResp) MarshalMsg(b []byte) (o []byte, err error) { 4176 o = msgp.Require(b, z.Msgsize()) 4177 // map header, size 7 4178 // string "Bucket" 4179 o = append(o, 0x87, 0xa6, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74) 4180 o = msgp.AppendString(o, z.Bucket) 4181 // string "Prefix" 4182 o = append(o, 0xa6, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78) 4183 o = msgp.AppendString(o, z.Prefix) 4184 // string "File" 4185 o = append(o, 0xa4, 0x46, 0x69, 0x6c, 0x65) 4186 o = msgp.AppendString(o, z.File) 4187 // string "Exists" 4188 o = append(o, 0xa6, 0x45, 0x78, 0x69, 0x73, 0x74, 0x73) 4189 o = msgp.AppendBool(o, z.Exists) 4190 // string "Error" 4191 o = append(o, 0xa5, 0x45, 0x72, 0x72, 0x6f, 0x72) 4192 o = msgp.AppendString(o, z.Error) 4193 // string "Data" 4194 o = append(o, 0xa4, 0x44, 0x61, 0x74, 0x61) 4195 o = msgp.AppendBytes(o, z.Data) 4196 // string "Modtime" 4197 o = append(o, 0xa7, 0x4d, 0x6f, 0x64, 0x74, 0x69, 0x6d, 0x65) 4198 o = msgp.AppendTime(o, z.Modtime) 4199 return 4200 } 4201 4202 // UnmarshalMsg implements msgp.Unmarshaler 4203 func (z *ReadMultipleResp) UnmarshalMsg(bts []byte) (o []byte, err error) { 4204 var field []byte 4205 _ = field 4206 var zb0001 uint32 4207 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 4208 if err != nil { 4209 err = msgp.WrapError(err) 4210 return 4211 } 4212 for zb0001 > 0 { 4213 zb0001-- 4214 field, bts, err = msgp.ReadMapKeyZC(bts) 4215 if err != nil { 4216 err = msgp.WrapError(err) 4217 return 4218 } 4219 switch msgp.UnsafeString(field) { 4220 case "Bucket": 4221 z.Bucket, bts, err = msgp.ReadStringBytes(bts) 4222 if err != nil { 4223 err = msgp.WrapError(err, "Bucket") 4224 return 4225 } 4226 case "Prefix": 4227 z.Prefix, bts, err = msgp.ReadStringBytes(bts) 4228 if err != nil { 4229 err = msgp.WrapError(err, "Prefix") 4230 return 4231 } 4232 case "File": 4233 z.File, bts, err = msgp.ReadStringBytes(bts) 4234 if err != nil { 4235 err = msgp.WrapError(err, "File") 4236 return 4237 } 4238 case "Exists": 4239 z.Exists, bts, err = msgp.ReadBoolBytes(bts) 4240 if err != nil { 4241 err = msgp.WrapError(err, "Exists") 4242 return 4243 } 4244 case "Error": 4245 z.Error, bts, err = msgp.ReadStringBytes(bts) 4246 if err != nil { 4247 err = msgp.WrapError(err, "Error") 4248 return 4249 } 4250 case "Data": 4251 z.Data, bts, err = msgp.ReadBytesBytes(bts, z.Data) 4252 if err != nil { 4253 err = msgp.WrapError(err, "Data") 4254 return 4255 } 4256 case "Modtime": 4257 z.Modtime, bts, err = msgp.ReadTimeBytes(bts) 4258 if err != nil { 4259 err = msgp.WrapError(err, "Modtime") 4260 return 4261 } 4262 default: 4263 bts, err = msgp.Skip(bts) 4264 if err != nil { 4265 err = msgp.WrapError(err) 4266 return 4267 } 4268 } 4269 } 4270 o = bts 4271 return 4272 } 4273 4274 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 4275 func (z *ReadMultipleResp) Msgsize() (s int) { 4276 s = 1 + 7 + msgp.StringPrefixSize + len(z.Bucket) + 7 + msgp.StringPrefixSize + len(z.Prefix) + 5 + msgp.StringPrefixSize + len(z.File) + 7 + msgp.BoolSize + 6 + msgp.StringPrefixSize + len(z.Error) + 5 + msgp.BytesPrefixSize + len(z.Data) + 8 + msgp.TimeSize 4277 return 4278 } 4279 4280 // DecodeMsg implements msgp.Decodable 4281 func (z *RenameDataHandlerParams) DecodeMsg(dc *msgp.Reader) (err error) { 4282 var field []byte 4283 _ = field 4284 var zb0001 uint32 4285 zb0001, err = dc.ReadMapHeader() 4286 if err != nil { 4287 err = msgp.WrapError(err) 4288 return 4289 } 4290 for zb0001 > 0 { 4291 zb0001-- 4292 field, err = dc.ReadMapKeyPtr() 4293 if err != nil { 4294 err = msgp.WrapError(err) 4295 return 4296 } 4297 switch msgp.UnsafeString(field) { 4298 case "id": 4299 z.DiskID, err = dc.ReadString() 4300 if err != nil { 4301 err = msgp.WrapError(err, "DiskID") 4302 return 4303 } 4304 case "sv": 4305 z.SrcVolume, err = dc.ReadString() 4306 if err != nil { 4307 err = msgp.WrapError(err, "SrcVolume") 4308 return 4309 } 4310 case "sp": 4311 z.SrcPath, err = dc.ReadString() 4312 if err != nil { 4313 err = msgp.WrapError(err, "SrcPath") 4314 return 4315 } 4316 case "dv": 4317 z.DstVolume, err = dc.ReadString() 4318 if err != nil { 4319 err = msgp.WrapError(err, "DstVolume") 4320 return 4321 } 4322 case "dp": 4323 z.DstPath, err = dc.ReadString() 4324 if err != nil { 4325 err = msgp.WrapError(err, "DstPath") 4326 return 4327 } 4328 case "fi": 4329 err = z.FI.DecodeMsg(dc) 4330 if err != nil { 4331 err = msgp.WrapError(err, "FI") 4332 return 4333 } 4334 case "ro": 4335 var zb0002 uint32 4336 zb0002, err = dc.ReadMapHeader() 4337 if err != nil { 4338 err = msgp.WrapError(err, "Opts") 4339 return 4340 } 4341 for zb0002 > 0 { 4342 zb0002-- 4343 field, err = dc.ReadMapKeyPtr() 4344 if err != nil { 4345 err = msgp.WrapError(err, "Opts") 4346 return 4347 } 4348 switch msgp.UnsafeString(field) { 4349 case "BaseOptions": 4350 var zb0003 uint32 4351 zb0003, err = dc.ReadMapHeader() 4352 if err != nil { 4353 err = msgp.WrapError(err, "Opts", "BaseOptions") 4354 return 4355 } 4356 for zb0003 > 0 { 4357 zb0003-- 4358 field, err = dc.ReadMapKeyPtr() 4359 if err != nil { 4360 err = msgp.WrapError(err, "Opts", "BaseOptions") 4361 return 4362 } 4363 switch msgp.UnsafeString(field) { 4364 default: 4365 err = dc.Skip() 4366 if err != nil { 4367 err = msgp.WrapError(err, "Opts", "BaseOptions") 4368 return 4369 } 4370 } 4371 } 4372 default: 4373 err = dc.Skip() 4374 if err != nil { 4375 err = msgp.WrapError(err, "Opts") 4376 return 4377 } 4378 } 4379 } 4380 default: 4381 err = dc.Skip() 4382 if err != nil { 4383 err = msgp.WrapError(err) 4384 return 4385 } 4386 } 4387 } 4388 return 4389 } 4390 4391 // EncodeMsg implements msgp.Encodable 4392 func (z *RenameDataHandlerParams) EncodeMsg(en *msgp.Writer) (err error) { 4393 // map header, size 7 4394 // write "id" 4395 err = en.Append(0x87, 0xa2, 0x69, 0x64) 4396 if err != nil { 4397 return 4398 } 4399 err = en.WriteString(z.DiskID) 4400 if err != nil { 4401 err = msgp.WrapError(err, "DiskID") 4402 return 4403 } 4404 // write "sv" 4405 err = en.Append(0xa2, 0x73, 0x76) 4406 if err != nil { 4407 return 4408 } 4409 err = en.WriteString(z.SrcVolume) 4410 if err != nil { 4411 err = msgp.WrapError(err, "SrcVolume") 4412 return 4413 } 4414 // write "sp" 4415 err = en.Append(0xa2, 0x73, 0x70) 4416 if err != nil { 4417 return 4418 } 4419 err = en.WriteString(z.SrcPath) 4420 if err != nil { 4421 err = msgp.WrapError(err, "SrcPath") 4422 return 4423 } 4424 // write "dv" 4425 err = en.Append(0xa2, 0x64, 0x76) 4426 if err != nil { 4427 return 4428 } 4429 err = en.WriteString(z.DstVolume) 4430 if err != nil { 4431 err = msgp.WrapError(err, "DstVolume") 4432 return 4433 } 4434 // write "dp" 4435 err = en.Append(0xa2, 0x64, 0x70) 4436 if err != nil { 4437 return 4438 } 4439 err = en.WriteString(z.DstPath) 4440 if err != nil { 4441 err = msgp.WrapError(err, "DstPath") 4442 return 4443 } 4444 // write "fi" 4445 err = en.Append(0xa2, 0x66, 0x69) 4446 if err != nil { 4447 return 4448 } 4449 err = z.FI.EncodeMsg(en) 4450 if err != nil { 4451 err = msgp.WrapError(err, "FI") 4452 return 4453 } 4454 // write "ro" 4455 err = en.Append(0xa2, 0x72, 0x6f) 4456 if err != nil { 4457 return 4458 } 4459 // map header, size 1 4460 // write "BaseOptions" 4461 err = en.Append(0x81, 0xab, 0x42, 0x61, 0x73, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73) 4462 if err != nil { 4463 return 4464 } 4465 // map header, size 0 4466 _ = z.Opts.BaseOptions 4467 err = en.Append(0x80) 4468 if err != nil { 4469 return 4470 } 4471 return 4472 } 4473 4474 // MarshalMsg implements msgp.Marshaler 4475 func (z *RenameDataHandlerParams) MarshalMsg(b []byte) (o []byte, err error) { 4476 o = msgp.Require(b, z.Msgsize()) 4477 // map header, size 7 4478 // string "id" 4479 o = append(o, 0x87, 0xa2, 0x69, 0x64) 4480 o = msgp.AppendString(o, z.DiskID) 4481 // string "sv" 4482 o = append(o, 0xa2, 0x73, 0x76) 4483 o = msgp.AppendString(o, z.SrcVolume) 4484 // string "sp" 4485 o = append(o, 0xa2, 0x73, 0x70) 4486 o = msgp.AppendString(o, z.SrcPath) 4487 // string "dv" 4488 o = append(o, 0xa2, 0x64, 0x76) 4489 o = msgp.AppendString(o, z.DstVolume) 4490 // string "dp" 4491 o = append(o, 0xa2, 0x64, 0x70) 4492 o = msgp.AppendString(o, z.DstPath) 4493 // string "fi" 4494 o = append(o, 0xa2, 0x66, 0x69) 4495 o, err = z.FI.MarshalMsg(o) 4496 if err != nil { 4497 err = msgp.WrapError(err, "FI") 4498 return 4499 } 4500 // string "ro" 4501 o = append(o, 0xa2, 0x72, 0x6f) 4502 // map header, size 1 4503 // string "BaseOptions" 4504 o = append(o, 0x81, 0xab, 0x42, 0x61, 0x73, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73) 4505 // map header, size 0 4506 _ = z.Opts.BaseOptions 4507 o = append(o, 0x80) 4508 return 4509 } 4510 4511 // UnmarshalMsg implements msgp.Unmarshaler 4512 func (z *RenameDataHandlerParams) UnmarshalMsg(bts []byte) (o []byte, err error) { 4513 var field []byte 4514 _ = field 4515 var zb0001 uint32 4516 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 4517 if err != nil { 4518 err = msgp.WrapError(err) 4519 return 4520 } 4521 for zb0001 > 0 { 4522 zb0001-- 4523 field, bts, err = msgp.ReadMapKeyZC(bts) 4524 if err != nil { 4525 err = msgp.WrapError(err) 4526 return 4527 } 4528 switch msgp.UnsafeString(field) { 4529 case "id": 4530 z.DiskID, bts, err = msgp.ReadStringBytes(bts) 4531 if err != nil { 4532 err = msgp.WrapError(err, "DiskID") 4533 return 4534 } 4535 case "sv": 4536 z.SrcVolume, bts, err = msgp.ReadStringBytes(bts) 4537 if err != nil { 4538 err = msgp.WrapError(err, "SrcVolume") 4539 return 4540 } 4541 case "sp": 4542 z.SrcPath, bts, err = msgp.ReadStringBytes(bts) 4543 if err != nil { 4544 err = msgp.WrapError(err, "SrcPath") 4545 return 4546 } 4547 case "dv": 4548 z.DstVolume, bts, err = msgp.ReadStringBytes(bts) 4549 if err != nil { 4550 err = msgp.WrapError(err, "DstVolume") 4551 return 4552 } 4553 case "dp": 4554 z.DstPath, bts, err = msgp.ReadStringBytes(bts) 4555 if err != nil { 4556 err = msgp.WrapError(err, "DstPath") 4557 return 4558 } 4559 case "fi": 4560 bts, err = z.FI.UnmarshalMsg(bts) 4561 if err != nil { 4562 err = msgp.WrapError(err, "FI") 4563 return 4564 } 4565 case "ro": 4566 var zb0002 uint32 4567 zb0002, bts, err = msgp.ReadMapHeaderBytes(bts) 4568 if err != nil { 4569 err = msgp.WrapError(err, "Opts") 4570 return 4571 } 4572 for zb0002 > 0 { 4573 zb0002-- 4574 field, bts, err = msgp.ReadMapKeyZC(bts) 4575 if err != nil { 4576 err = msgp.WrapError(err, "Opts") 4577 return 4578 } 4579 switch msgp.UnsafeString(field) { 4580 case "BaseOptions": 4581 var zb0003 uint32 4582 zb0003, bts, err = msgp.ReadMapHeaderBytes(bts) 4583 if err != nil { 4584 err = msgp.WrapError(err, "Opts", "BaseOptions") 4585 return 4586 } 4587 for zb0003 > 0 { 4588 zb0003-- 4589 field, bts, err = msgp.ReadMapKeyZC(bts) 4590 if err != nil { 4591 err = msgp.WrapError(err, "Opts", "BaseOptions") 4592 return 4593 } 4594 switch msgp.UnsafeString(field) { 4595 default: 4596 bts, err = msgp.Skip(bts) 4597 if err != nil { 4598 err = msgp.WrapError(err, "Opts", "BaseOptions") 4599 return 4600 } 4601 } 4602 } 4603 default: 4604 bts, err = msgp.Skip(bts) 4605 if err != nil { 4606 err = msgp.WrapError(err, "Opts") 4607 return 4608 } 4609 } 4610 } 4611 default: 4612 bts, err = msgp.Skip(bts) 4613 if err != nil { 4614 err = msgp.WrapError(err) 4615 return 4616 } 4617 } 4618 } 4619 o = bts 4620 return 4621 } 4622 4623 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 4624 func (z *RenameDataHandlerParams) Msgsize() (s int) { 4625 s = 1 + 3 + msgp.StringPrefixSize + len(z.DiskID) + 3 + msgp.StringPrefixSize + len(z.SrcVolume) + 3 + msgp.StringPrefixSize + len(z.SrcPath) + 3 + msgp.StringPrefixSize + len(z.DstVolume) + 3 + msgp.StringPrefixSize + len(z.DstPath) + 3 + z.FI.Msgsize() + 3 + 1 + 12 + 1 4626 return 4627 } 4628 4629 // DecodeMsg implements msgp.Decodable 4630 func (z *RenameDataResp) DecodeMsg(dc *msgp.Reader) (err error) { 4631 var field []byte 4632 _ = field 4633 var zb0001 uint32 4634 zb0001, err = dc.ReadMapHeader() 4635 if err != nil { 4636 err = msgp.WrapError(err) 4637 return 4638 } 4639 for zb0001 > 0 { 4640 zb0001-- 4641 field, err = dc.ReadMapKeyPtr() 4642 if err != nil { 4643 err = msgp.WrapError(err) 4644 return 4645 } 4646 switch msgp.UnsafeString(field) { 4647 case "sig": 4648 z.Signature, err = dc.ReadUint64() 4649 if err != nil { 4650 err = msgp.WrapError(err, "Signature") 4651 return 4652 } 4653 default: 4654 err = dc.Skip() 4655 if err != nil { 4656 err = msgp.WrapError(err) 4657 return 4658 } 4659 } 4660 } 4661 return 4662 } 4663 4664 // EncodeMsg implements msgp.Encodable 4665 func (z RenameDataResp) EncodeMsg(en *msgp.Writer) (err error) { 4666 // map header, size 1 4667 // write "sig" 4668 err = en.Append(0x81, 0xa3, 0x73, 0x69, 0x67) 4669 if err != nil { 4670 return 4671 } 4672 err = en.WriteUint64(z.Signature) 4673 if err != nil { 4674 err = msgp.WrapError(err, "Signature") 4675 return 4676 } 4677 return 4678 } 4679 4680 // MarshalMsg implements msgp.Marshaler 4681 func (z RenameDataResp) MarshalMsg(b []byte) (o []byte, err error) { 4682 o = msgp.Require(b, z.Msgsize()) 4683 // map header, size 1 4684 // string "sig" 4685 o = append(o, 0x81, 0xa3, 0x73, 0x69, 0x67) 4686 o = msgp.AppendUint64(o, z.Signature) 4687 return 4688 } 4689 4690 // UnmarshalMsg implements msgp.Unmarshaler 4691 func (z *RenameDataResp) UnmarshalMsg(bts []byte) (o []byte, err error) { 4692 var field []byte 4693 _ = field 4694 var zb0001 uint32 4695 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 4696 if err != nil { 4697 err = msgp.WrapError(err) 4698 return 4699 } 4700 for zb0001 > 0 { 4701 zb0001-- 4702 field, bts, err = msgp.ReadMapKeyZC(bts) 4703 if err != nil { 4704 err = msgp.WrapError(err) 4705 return 4706 } 4707 switch msgp.UnsafeString(field) { 4708 case "sig": 4709 z.Signature, bts, err = msgp.ReadUint64Bytes(bts) 4710 if err != nil { 4711 err = msgp.WrapError(err, "Signature") 4712 return 4713 } 4714 default: 4715 bts, err = msgp.Skip(bts) 4716 if err != nil { 4717 err = msgp.WrapError(err) 4718 return 4719 } 4720 } 4721 } 4722 o = bts 4723 return 4724 } 4725 4726 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 4727 func (z RenameDataResp) Msgsize() (s int) { 4728 s = 1 + 4 + msgp.Uint64Size 4729 return 4730 } 4731 4732 // DecodeMsg implements msgp.Decodable 4733 func (z *RenameFileHandlerParams) DecodeMsg(dc *msgp.Reader) (err error) { 4734 var field []byte 4735 _ = field 4736 var zb0001 uint32 4737 zb0001, err = dc.ReadMapHeader() 4738 if err != nil { 4739 err = msgp.WrapError(err) 4740 return 4741 } 4742 for zb0001 > 0 { 4743 zb0001-- 4744 field, err = dc.ReadMapKeyPtr() 4745 if err != nil { 4746 err = msgp.WrapError(err) 4747 return 4748 } 4749 switch msgp.UnsafeString(field) { 4750 case "id": 4751 z.DiskID, err = dc.ReadString() 4752 if err != nil { 4753 err = msgp.WrapError(err, "DiskID") 4754 return 4755 } 4756 case "sv": 4757 z.SrcVolume, err = dc.ReadString() 4758 if err != nil { 4759 err = msgp.WrapError(err, "SrcVolume") 4760 return 4761 } 4762 case "sp": 4763 z.SrcFilePath, err = dc.ReadString() 4764 if err != nil { 4765 err = msgp.WrapError(err, "SrcFilePath") 4766 return 4767 } 4768 case "dv": 4769 z.DstVolume, err = dc.ReadString() 4770 if err != nil { 4771 err = msgp.WrapError(err, "DstVolume") 4772 return 4773 } 4774 case "dp": 4775 z.DstFilePath, err = dc.ReadString() 4776 if err != nil { 4777 err = msgp.WrapError(err, "DstFilePath") 4778 return 4779 } 4780 default: 4781 err = dc.Skip() 4782 if err != nil { 4783 err = msgp.WrapError(err) 4784 return 4785 } 4786 } 4787 } 4788 return 4789 } 4790 4791 // EncodeMsg implements msgp.Encodable 4792 func (z *RenameFileHandlerParams) EncodeMsg(en *msgp.Writer) (err error) { 4793 // map header, size 5 4794 // write "id" 4795 err = en.Append(0x85, 0xa2, 0x69, 0x64) 4796 if err != nil { 4797 return 4798 } 4799 err = en.WriteString(z.DiskID) 4800 if err != nil { 4801 err = msgp.WrapError(err, "DiskID") 4802 return 4803 } 4804 // write "sv" 4805 err = en.Append(0xa2, 0x73, 0x76) 4806 if err != nil { 4807 return 4808 } 4809 err = en.WriteString(z.SrcVolume) 4810 if err != nil { 4811 err = msgp.WrapError(err, "SrcVolume") 4812 return 4813 } 4814 // write "sp" 4815 err = en.Append(0xa2, 0x73, 0x70) 4816 if err != nil { 4817 return 4818 } 4819 err = en.WriteString(z.SrcFilePath) 4820 if err != nil { 4821 err = msgp.WrapError(err, "SrcFilePath") 4822 return 4823 } 4824 // write "dv" 4825 err = en.Append(0xa2, 0x64, 0x76) 4826 if err != nil { 4827 return 4828 } 4829 err = en.WriteString(z.DstVolume) 4830 if err != nil { 4831 err = msgp.WrapError(err, "DstVolume") 4832 return 4833 } 4834 // write "dp" 4835 err = en.Append(0xa2, 0x64, 0x70) 4836 if err != nil { 4837 return 4838 } 4839 err = en.WriteString(z.DstFilePath) 4840 if err != nil { 4841 err = msgp.WrapError(err, "DstFilePath") 4842 return 4843 } 4844 return 4845 } 4846 4847 // MarshalMsg implements msgp.Marshaler 4848 func (z *RenameFileHandlerParams) MarshalMsg(b []byte) (o []byte, err error) { 4849 o = msgp.Require(b, z.Msgsize()) 4850 // map header, size 5 4851 // string "id" 4852 o = append(o, 0x85, 0xa2, 0x69, 0x64) 4853 o = msgp.AppendString(o, z.DiskID) 4854 // string "sv" 4855 o = append(o, 0xa2, 0x73, 0x76) 4856 o = msgp.AppendString(o, z.SrcVolume) 4857 // string "sp" 4858 o = append(o, 0xa2, 0x73, 0x70) 4859 o = msgp.AppendString(o, z.SrcFilePath) 4860 // string "dv" 4861 o = append(o, 0xa2, 0x64, 0x76) 4862 o = msgp.AppendString(o, z.DstVolume) 4863 // string "dp" 4864 o = append(o, 0xa2, 0x64, 0x70) 4865 o = msgp.AppendString(o, z.DstFilePath) 4866 return 4867 } 4868 4869 // UnmarshalMsg implements msgp.Unmarshaler 4870 func (z *RenameFileHandlerParams) UnmarshalMsg(bts []byte) (o []byte, err error) { 4871 var field []byte 4872 _ = field 4873 var zb0001 uint32 4874 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 4875 if err != nil { 4876 err = msgp.WrapError(err) 4877 return 4878 } 4879 for zb0001 > 0 { 4880 zb0001-- 4881 field, bts, err = msgp.ReadMapKeyZC(bts) 4882 if err != nil { 4883 err = msgp.WrapError(err) 4884 return 4885 } 4886 switch msgp.UnsafeString(field) { 4887 case "id": 4888 z.DiskID, bts, err = msgp.ReadStringBytes(bts) 4889 if err != nil { 4890 err = msgp.WrapError(err, "DiskID") 4891 return 4892 } 4893 case "sv": 4894 z.SrcVolume, bts, err = msgp.ReadStringBytes(bts) 4895 if err != nil { 4896 err = msgp.WrapError(err, "SrcVolume") 4897 return 4898 } 4899 case "sp": 4900 z.SrcFilePath, bts, err = msgp.ReadStringBytes(bts) 4901 if err != nil { 4902 err = msgp.WrapError(err, "SrcFilePath") 4903 return 4904 } 4905 case "dv": 4906 z.DstVolume, bts, err = msgp.ReadStringBytes(bts) 4907 if err != nil { 4908 err = msgp.WrapError(err, "DstVolume") 4909 return 4910 } 4911 case "dp": 4912 z.DstFilePath, bts, err = msgp.ReadStringBytes(bts) 4913 if err != nil { 4914 err = msgp.WrapError(err, "DstFilePath") 4915 return 4916 } 4917 default: 4918 bts, err = msgp.Skip(bts) 4919 if err != nil { 4920 err = msgp.WrapError(err) 4921 return 4922 } 4923 } 4924 } 4925 o = bts 4926 return 4927 } 4928 4929 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 4930 func (z *RenameFileHandlerParams) Msgsize() (s int) { 4931 s = 1 + 3 + msgp.StringPrefixSize + len(z.DiskID) + 3 + msgp.StringPrefixSize + len(z.SrcVolume) + 3 + msgp.StringPrefixSize + len(z.SrcFilePath) + 3 + msgp.StringPrefixSize + len(z.DstVolume) + 3 + msgp.StringPrefixSize + len(z.DstFilePath) 4932 return 4933 } 4934 4935 // DecodeMsg implements msgp.Decodable 4936 func (z *RenameOptions) DecodeMsg(dc *msgp.Reader) (err error) { 4937 var field []byte 4938 _ = field 4939 var zb0001 uint32 4940 zb0001, err = dc.ReadMapHeader() 4941 if err != nil { 4942 err = msgp.WrapError(err) 4943 return 4944 } 4945 for zb0001 > 0 { 4946 zb0001-- 4947 field, err = dc.ReadMapKeyPtr() 4948 if err != nil { 4949 err = msgp.WrapError(err) 4950 return 4951 } 4952 switch msgp.UnsafeString(field) { 4953 case "BaseOptions": 4954 var zb0002 uint32 4955 zb0002, err = dc.ReadMapHeader() 4956 if err != nil { 4957 err = msgp.WrapError(err, "BaseOptions") 4958 return 4959 } 4960 for zb0002 > 0 { 4961 zb0002-- 4962 field, err = dc.ReadMapKeyPtr() 4963 if err != nil { 4964 err = msgp.WrapError(err, "BaseOptions") 4965 return 4966 } 4967 switch msgp.UnsafeString(field) { 4968 default: 4969 err = dc.Skip() 4970 if err != nil { 4971 err = msgp.WrapError(err, "BaseOptions") 4972 return 4973 } 4974 } 4975 } 4976 default: 4977 err = dc.Skip() 4978 if err != nil { 4979 err = msgp.WrapError(err) 4980 return 4981 } 4982 } 4983 } 4984 return 4985 } 4986 4987 // EncodeMsg implements msgp.Encodable 4988 func (z *RenameOptions) EncodeMsg(en *msgp.Writer) (err error) { 4989 // map header, size 1 4990 // write "BaseOptions" 4991 err = en.Append(0x81, 0xab, 0x42, 0x61, 0x73, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73) 4992 if err != nil { 4993 return 4994 } 4995 // map header, size 0 4996 _ = z.BaseOptions 4997 err = en.Append(0x80) 4998 if err != nil { 4999 return 5000 } 5001 return 5002 } 5003 5004 // MarshalMsg implements msgp.Marshaler 5005 func (z *RenameOptions) MarshalMsg(b []byte) (o []byte, err error) { 5006 o = msgp.Require(b, z.Msgsize()) 5007 // map header, size 1 5008 // string "BaseOptions" 5009 o = append(o, 0x81, 0xab, 0x42, 0x61, 0x73, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73) 5010 // map header, size 0 5011 _ = z.BaseOptions 5012 o = append(o, 0x80) 5013 return 5014 } 5015 5016 // UnmarshalMsg implements msgp.Unmarshaler 5017 func (z *RenameOptions) UnmarshalMsg(bts []byte) (o []byte, err error) { 5018 var field []byte 5019 _ = field 5020 var zb0001 uint32 5021 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 5022 if err != nil { 5023 err = msgp.WrapError(err) 5024 return 5025 } 5026 for zb0001 > 0 { 5027 zb0001-- 5028 field, bts, err = msgp.ReadMapKeyZC(bts) 5029 if err != nil { 5030 err = msgp.WrapError(err) 5031 return 5032 } 5033 switch msgp.UnsafeString(field) { 5034 case "BaseOptions": 5035 var zb0002 uint32 5036 zb0002, bts, err = msgp.ReadMapHeaderBytes(bts) 5037 if err != nil { 5038 err = msgp.WrapError(err, "BaseOptions") 5039 return 5040 } 5041 for zb0002 > 0 { 5042 zb0002-- 5043 field, bts, err = msgp.ReadMapKeyZC(bts) 5044 if err != nil { 5045 err = msgp.WrapError(err, "BaseOptions") 5046 return 5047 } 5048 switch msgp.UnsafeString(field) { 5049 default: 5050 bts, err = msgp.Skip(bts) 5051 if err != nil { 5052 err = msgp.WrapError(err, "BaseOptions") 5053 return 5054 } 5055 } 5056 } 5057 default: 5058 bts, err = msgp.Skip(bts) 5059 if err != nil { 5060 err = msgp.WrapError(err) 5061 return 5062 } 5063 } 5064 } 5065 o = bts 5066 return 5067 } 5068 5069 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 5070 func (z *RenameOptions) Msgsize() (s int) { 5071 s = 1 + 12 + 1 5072 return 5073 } 5074 5075 // DecodeMsg implements msgp.Decodable 5076 func (z *UpdateMetadataOpts) DecodeMsg(dc *msgp.Reader) (err error) { 5077 var field []byte 5078 _ = field 5079 var zb0001 uint32 5080 zb0001, err = dc.ReadMapHeader() 5081 if err != nil { 5082 err = msgp.WrapError(err) 5083 return 5084 } 5085 for zb0001 > 0 { 5086 zb0001-- 5087 field, err = dc.ReadMapKeyPtr() 5088 if err != nil { 5089 err = msgp.WrapError(err) 5090 return 5091 } 5092 switch msgp.UnsafeString(field) { 5093 case "np": 5094 z.NoPersistence, err = dc.ReadBool() 5095 if err != nil { 5096 err = msgp.WrapError(err, "NoPersistence") 5097 return 5098 } 5099 default: 5100 err = dc.Skip() 5101 if err != nil { 5102 err = msgp.WrapError(err) 5103 return 5104 } 5105 } 5106 } 5107 return 5108 } 5109 5110 // EncodeMsg implements msgp.Encodable 5111 func (z UpdateMetadataOpts) EncodeMsg(en *msgp.Writer) (err error) { 5112 // map header, size 1 5113 // write "np" 5114 err = en.Append(0x81, 0xa2, 0x6e, 0x70) 5115 if err != nil { 5116 return 5117 } 5118 err = en.WriteBool(z.NoPersistence) 5119 if err != nil { 5120 err = msgp.WrapError(err, "NoPersistence") 5121 return 5122 } 5123 return 5124 } 5125 5126 // MarshalMsg implements msgp.Marshaler 5127 func (z UpdateMetadataOpts) MarshalMsg(b []byte) (o []byte, err error) { 5128 o = msgp.Require(b, z.Msgsize()) 5129 // map header, size 1 5130 // string "np" 5131 o = append(o, 0x81, 0xa2, 0x6e, 0x70) 5132 o = msgp.AppendBool(o, z.NoPersistence) 5133 return 5134 } 5135 5136 // UnmarshalMsg implements msgp.Unmarshaler 5137 func (z *UpdateMetadataOpts) UnmarshalMsg(bts []byte) (o []byte, err error) { 5138 var field []byte 5139 _ = field 5140 var zb0001 uint32 5141 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 5142 if err != nil { 5143 err = msgp.WrapError(err) 5144 return 5145 } 5146 for zb0001 > 0 { 5147 zb0001-- 5148 field, bts, err = msgp.ReadMapKeyZC(bts) 5149 if err != nil { 5150 err = msgp.WrapError(err) 5151 return 5152 } 5153 switch msgp.UnsafeString(field) { 5154 case "np": 5155 z.NoPersistence, bts, err = msgp.ReadBoolBytes(bts) 5156 if err != nil { 5157 err = msgp.WrapError(err, "NoPersistence") 5158 return 5159 } 5160 default: 5161 bts, err = msgp.Skip(bts) 5162 if err != nil { 5163 err = msgp.WrapError(err) 5164 return 5165 } 5166 } 5167 } 5168 o = bts 5169 return 5170 } 5171 5172 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 5173 func (z UpdateMetadataOpts) Msgsize() (s int) { 5174 s = 1 + 3 + msgp.BoolSize 5175 return 5176 } 5177 5178 // DecodeMsg implements msgp.Decodable 5179 func (z *VolInfo) DecodeMsg(dc *msgp.Reader) (err error) { 5180 var zb0001 uint32 5181 zb0001, err = dc.ReadArrayHeader() 5182 if err != nil { 5183 err = msgp.WrapError(err) 5184 return 5185 } 5186 if zb0001 != 2 { 5187 err = msgp.ArrayError{Wanted: 2, Got: zb0001} 5188 return 5189 } 5190 z.Name, err = dc.ReadString() 5191 if err != nil { 5192 err = msgp.WrapError(err, "Name") 5193 return 5194 } 5195 z.Created, err = dc.ReadTime() 5196 if err != nil { 5197 err = msgp.WrapError(err, "Created") 5198 return 5199 } 5200 return 5201 } 5202 5203 // EncodeMsg implements msgp.Encodable 5204 func (z VolInfo) EncodeMsg(en *msgp.Writer) (err error) { 5205 // array header, size 2 5206 err = en.Append(0x92) 5207 if err != nil { 5208 return 5209 } 5210 err = en.WriteString(z.Name) 5211 if err != nil { 5212 err = msgp.WrapError(err, "Name") 5213 return 5214 } 5215 err = en.WriteTime(z.Created) 5216 if err != nil { 5217 err = msgp.WrapError(err, "Created") 5218 return 5219 } 5220 return 5221 } 5222 5223 // MarshalMsg implements msgp.Marshaler 5224 func (z VolInfo) MarshalMsg(b []byte) (o []byte, err error) { 5225 o = msgp.Require(b, z.Msgsize()) 5226 // array header, size 2 5227 o = append(o, 0x92) 5228 o = msgp.AppendString(o, z.Name) 5229 o = msgp.AppendTime(o, z.Created) 5230 return 5231 } 5232 5233 // UnmarshalMsg implements msgp.Unmarshaler 5234 func (z *VolInfo) UnmarshalMsg(bts []byte) (o []byte, err error) { 5235 var zb0001 uint32 5236 zb0001, bts, err = msgp.ReadArrayHeaderBytes(bts) 5237 if err != nil { 5238 err = msgp.WrapError(err) 5239 return 5240 } 5241 if zb0001 != 2 { 5242 err = msgp.ArrayError{Wanted: 2, Got: zb0001} 5243 return 5244 } 5245 z.Name, bts, err = msgp.ReadStringBytes(bts) 5246 if err != nil { 5247 err = msgp.WrapError(err, "Name") 5248 return 5249 } 5250 z.Created, bts, err = msgp.ReadTimeBytes(bts) 5251 if err != nil { 5252 err = msgp.WrapError(err, "Created") 5253 return 5254 } 5255 o = bts 5256 return 5257 } 5258 5259 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 5260 func (z VolInfo) Msgsize() (s int) { 5261 s = 1 + msgp.StringPrefixSize + len(z.Name) + msgp.TimeSize 5262 return 5263 } 5264 5265 // DecodeMsg implements msgp.Decodable 5266 func (z *VolsInfo) DecodeMsg(dc *msgp.Reader) (err error) { 5267 var zb0002 uint32 5268 zb0002, err = dc.ReadArrayHeader() 5269 if err != nil { 5270 err = msgp.WrapError(err) 5271 return 5272 } 5273 if cap((*z)) >= int(zb0002) { 5274 (*z) = (*z)[:zb0002] 5275 } else { 5276 (*z) = make(VolsInfo, zb0002) 5277 } 5278 for zb0001 := range *z { 5279 var zb0003 uint32 5280 zb0003, err = dc.ReadArrayHeader() 5281 if err != nil { 5282 err = msgp.WrapError(err, zb0001) 5283 return 5284 } 5285 if zb0003 != 2 { 5286 err = msgp.ArrayError{Wanted: 2, Got: zb0003} 5287 return 5288 } 5289 (*z)[zb0001].Name, err = dc.ReadString() 5290 if err != nil { 5291 err = msgp.WrapError(err, zb0001, "Name") 5292 return 5293 } 5294 (*z)[zb0001].Created, err = dc.ReadTime() 5295 if err != nil { 5296 err = msgp.WrapError(err, zb0001, "Created") 5297 return 5298 } 5299 } 5300 return 5301 } 5302 5303 // EncodeMsg implements msgp.Encodable 5304 func (z VolsInfo) EncodeMsg(en *msgp.Writer) (err error) { 5305 err = en.WriteArrayHeader(uint32(len(z))) 5306 if err != nil { 5307 err = msgp.WrapError(err) 5308 return 5309 } 5310 for zb0004 := range z { 5311 // array header, size 2 5312 err = en.Append(0x92) 5313 if err != nil { 5314 return 5315 } 5316 err = en.WriteString(z[zb0004].Name) 5317 if err != nil { 5318 err = msgp.WrapError(err, zb0004, "Name") 5319 return 5320 } 5321 err = en.WriteTime(z[zb0004].Created) 5322 if err != nil { 5323 err = msgp.WrapError(err, zb0004, "Created") 5324 return 5325 } 5326 } 5327 return 5328 } 5329 5330 // MarshalMsg implements msgp.Marshaler 5331 func (z VolsInfo) MarshalMsg(b []byte) (o []byte, err error) { 5332 o = msgp.Require(b, z.Msgsize()) 5333 o = msgp.AppendArrayHeader(o, uint32(len(z))) 5334 for zb0004 := range z { 5335 // array header, size 2 5336 o = append(o, 0x92) 5337 o = msgp.AppendString(o, z[zb0004].Name) 5338 o = msgp.AppendTime(o, z[zb0004].Created) 5339 } 5340 return 5341 } 5342 5343 // UnmarshalMsg implements msgp.Unmarshaler 5344 func (z *VolsInfo) UnmarshalMsg(bts []byte) (o []byte, err error) { 5345 var zb0002 uint32 5346 zb0002, bts, err = msgp.ReadArrayHeaderBytes(bts) 5347 if err != nil { 5348 err = msgp.WrapError(err) 5349 return 5350 } 5351 if cap((*z)) >= int(zb0002) { 5352 (*z) = (*z)[:zb0002] 5353 } else { 5354 (*z) = make(VolsInfo, zb0002) 5355 } 5356 for zb0001 := range *z { 5357 var zb0003 uint32 5358 zb0003, bts, err = msgp.ReadArrayHeaderBytes(bts) 5359 if err != nil { 5360 err = msgp.WrapError(err, zb0001) 5361 return 5362 } 5363 if zb0003 != 2 { 5364 err = msgp.ArrayError{Wanted: 2, Got: zb0003} 5365 return 5366 } 5367 (*z)[zb0001].Name, bts, err = msgp.ReadStringBytes(bts) 5368 if err != nil { 5369 err = msgp.WrapError(err, zb0001, "Name") 5370 return 5371 } 5372 (*z)[zb0001].Created, bts, err = msgp.ReadTimeBytes(bts) 5373 if err != nil { 5374 err = msgp.WrapError(err, zb0001, "Created") 5375 return 5376 } 5377 } 5378 o = bts 5379 return 5380 } 5381 5382 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 5383 func (z VolsInfo) Msgsize() (s int) { 5384 s = msgp.ArrayHeaderSize 5385 for zb0004 := range z { 5386 s += 1 + msgp.StringPrefixSize + len(z[zb0004].Name) + msgp.TimeSize 5387 } 5388 return 5389 } 5390 5391 // DecodeMsg implements msgp.Decodable 5392 func (z *WriteAllHandlerParams) DecodeMsg(dc *msgp.Reader) (err error) { 5393 var field []byte 5394 _ = field 5395 var zb0001 uint32 5396 zb0001, err = dc.ReadMapHeader() 5397 if err != nil { 5398 err = msgp.WrapError(err) 5399 return 5400 } 5401 for zb0001 > 0 { 5402 zb0001-- 5403 field, err = dc.ReadMapKeyPtr() 5404 if err != nil { 5405 err = msgp.WrapError(err) 5406 return 5407 } 5408 switch msgp.UnsafeString(field) { 5409 case "id": 5410 z.DiskID, err = dc.ReadString() 5411 if err != nil { 5412 err = msgp.WrapError(err, "DiskID") 5413 return 5414 } 5415 case "v": 5416 z.Volume, err = dc.ReadString() 5417 if err != nil { 5418 err = msgp.WrapError(err, "Volume") 5419 return 5420 } 5421 case "fp": 5422 z.FilePath, err = dc.ReadString() 5423 if err != nil { 5424 err = msgp.WrapError(err, "FilePath") 5425 return 5426 } 5427 case "b": 5428 z.Buf, err = dc.ReadBytes(z.Buf) 5429 if err != nil { 5430 err = msgp.WrapError(err, "Buf") 5431 return 5432 } 5433 default: 5434 err = dc.Skip() 5435 if err != nil { 5436 err = msgp.WrapError(err) 5437 return 5438 } 5439 } 5440 } 5441 return 5442 } 5443 5444 // EncodeMsg implements msgp.Encodable 5445 func (z *WriteAllHandlerParams) EncodeMsg(en *msgp.Writer) (err error) { 5446 // map header, size 4 5447 // write "id" 5448 err = en.Append(0x84, 0xa2, 0x69, 0x64) 5449 if err != nil { 5450 return 5451 } 5452 err = en.WriteString(z.DiskID) 5453 if err != nil { 5454 err = msgp.WrapError(err, "DiskID") 5455 return 5456 } 5457 // write "v" 5458 err = en.Append(0xa1, 0x76) 5459 if err != nil { 5460 return 5461 } 5462 err = en.WriteString(z.Volume) 5463 if err != nil { 5464 err = msgp.WrapError(err, "Volume") 5465 return 5466 } 5467 // write "fp" 5468 err = en.Append(0xa2, 0x66, 0x70) 5469 if err != nil { 5470 return 5471 } 5472 err = en.WriteString(z.FilePath) 5473 if err != nil { 5474 err = msgp.WrapError(err, "FilePath") 5475 return 5476 } 5477 // write "b" 5478 err = en.Append(0xa1, 0x62) 5479 if err != nil { 5480 return 5481 } 5482 err = en.WriteBytes(z.Buf) 5483 if err != nil { 5484 err = msgp.WrapError(err, "Buf") 5485 return 5486 } 5487 return 5488 } 5489 5490 // MarshalMsg implements msgp.Marshaler 5491 func (z *WriteAllHandlerParams) MarshalMsg(b []byte) (o []byte, err error) { 5492 o = msgp.Require(b, z.Msgsize()) 5493 // map header, size 4 5494 // string "id" 5495 o = append(o, 0x84, 0xa2, 0x69, 0x64) 5496 o = msgp.AppendString(o, z.DiskID) 5497 // string "v" 5498 o = append(o, 0xa1, 0x76) 5499 o = msgp.AppendString(o, z.Volume) 5500 // string "fp" 5501 o = append(o, 0xa2, 0x66, 0x70) 5502 o = msgp.AppendString(o, z.FilePath) 5503 // string "b" 5504 o = append(o, 0xa1, 0x62) 5505 o = msgp.AppendBytes(o, z.Buf) 5506 return 5507 } 5508 5509 // UnmarshalMsg implements msgp.Unmarshaler 5510 func (z *WriteAllHandlerParams) UnmarshalMsg(bts []byte) (o []byte, err error) { 5511 var field []byte 5512 _ = field 5513 var zb0001 uint32 5514 zb0001, bts, err = msgp.ReadMapHeaderBytes(bts) 5515 if err != nil { 5516 err = msgp.WrapError(err) 5517 return 5518 } 5519 for zb0001 > 0 { 5520 zb0001-- 5521 field, bts, err = msgp.ReadMapKeyZC(bts) 5522 if err != nil { 5523 err = msgp.WrapError(err) 5524 return 5525 } 5526 switch msgp.UnsafeString(field) { 5527 case "id": 5528 z.DiskID, bts, err = msgp.ReadStringBytes(bts) 5529 if err != nil { 5530 err = msgp.WrapError(err, "DiskID") 5531 return 5532 } 5533 case "v": 5534 z.Volume, bts, err = msgp.ReadStringBytes(bts) 5535 if err != nil { 5536 err = msgp.WrapError(err, "Volume") 5537 return 5538 } 5539 case "fp": 5540 z.FilePath, bts, err = msgp.ReadStringBytes(bts) 5541 if err != nil { 5542 err = msgp.WrapError(err, "FilePath") 5543 return 5544 } 5545 case "b": 5546 z.Buf, bts, err = msgp.ReadBytesBytes(bts, z.Buf) 5547 if err != nil { 5548 err = msgp.WrapError(err, "Buf") 5549 return 5550 } 5551 default: 5552 bts, err = msgp.Skip(bts) 5553 if err != nil { 5554 err = msgp.WrapError(err) 5555 return 5556 } 5557 } 5558 } 5559 o = bts 5560 return 5561 } 5562 5563 // Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message 5564 func (z *WriteAllHandlerParams) Msgsize() (s int) { 5565 s = 1 + 3 + msgp.StringPrefixSize + len(z.DiskID) + 2 + msgp.StringPrefixSize + len(z.Volume) + 3 + msgp.StringPrefixSize + len(z.FilePath) + 2 + msgp.BytesPrefixSize + len(z.Buf) 5566 return 5567 }