github.com/digitalocean/go-netbox@v0.0.2/netbox/client/users/users_permissions_list_parameters.go (about) 1 // Code generated by go-swagger; DO NOT EDIT. 2 3 // Copyright 2020 The go-netbox Authors. 4 // 5 // Licensed under the Apache License, Version 2.0 (the "License"); 6 // you may not use this file except in compliance with the License. 7 // You may obtain a copy of the License at 8 // 9 // http://www.apache.org/licenses/LICENSE-2.0 10 // 11 // Unless required by applicable law or agreed to in writing, software 12 // distributed under the License is distributed on an "AS IS" BASIS, 13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 // See the License for the specific language governing permissions and 15 // limitations under the License. 16 // 17 18 package users 19 20 // This file was generated by the swagger tool. 21 // Editing this file might prove futile when you re-run the swagger generate command 22 23 import ( 24 "context" 25 "net/http" 26 "time" 27 28 "github.com/go-openapi/errors" 29 "github.com/go-openapi/runtime" 30 cr "github.com/go-openapi/runtime/client" 31 "github.com/go-openapi/strfmt" 32 "github.com/go-openapi/swag" 33 ) 34 35 // NewUsersPermissionsListParams creates a new UsersPermissionsListParams object, 36 // with the default timeout for this client. 37 // 38 // Default values are not hydrated, since defaults are normally applied by the API server side. 39 // 40 // To enforce default values in parameter, use SetDefaults or WithDefaults. 41 func NewUsersPermissionsListParams() *UsersPermissionsListParams { 42 return &UsersPermissionsListParams{ 43 timeout: cr.DefaultTimeout, 44 } 45 } 46 47 // NewUsersPermissionsListParamsWithTimeout creates a new UsersPermissionsListParams object 48 // with the ability to set a timeout on a request. 49 func NewUsersPermissionsListParamsWithTimeout(timeout time.Duration) *UsersPermissionsListParams { 50 return &UsersPermissionsListParams{ 51 timeout: timeout, 52 } 53 } 54 55 // NewUsersPermissionsListParamsWithContext creates a new UsersPermissionsListParams object 56 // with the ability to set a context for a request. 57 func NewUsersPermissionsListParamsWithContext(ctx context.Context) *UsersPermissionsListParams { 58 return &UsersPermissionsListParams{ 59 Context: ctx, 60 } 61 } 62 63 // NewUsersPermissionsListParamsWithHTTPClient creates a new UsersPermissionsListParams object 64 // with the ability to set a custom HTTPClient for a request. 65 func NewUsersPermissionsListParamsWithHTTPClient(client *http.Client) *UsersPermissionsListParams { 66 return &UsersPermissionsListParams{ 67 HTTPClient: client, 68 } 69 } 70 71 /* UsersPermissionsListParams contains all the parameters to send to the API endpoint 72 for the users permissions list operation. 73 74 Typically these are written to a http.Request. 75 */ 76 type UsersPermissionsListParams struct { 77 78 // Enabled. 79 Enabled *string 80 81 // Group. 82 Group *string 83 84 // Groupn. 85 Groupn *string 86 87 // GroupID. 88 GroupID *string 89 90 // GroupIDn. 91 GroupIDn *string 92 93 // ID. 94 ID *string 95 96 // IDGt. 97 IDGt *string 98 99 // IDGte. 100 IDGte *string 101 102 // IDLt. 103 IDLt *string 104 105 // IDLte. 106 IDLte *string 107 108 // IDn. 109 IDn *string 110 111 /* Limit. 112 113 Number of results to return per page. 114 */ 115 Limit *int64 116 117 // Name. 118 Name *string 119 120 // NameEmpty. 121 NameEmpty *string 122 123 // NameIc. 124 NameIc *string 125 126 // NameIe. 127 NameIe *string 128 129 // NameIew. 130 NameIew *string 131 132 // NameIsw. 133 NameIsw *string 134 135 // Namen. 136 Namen *string 137 138 // NameNic. 139 NameNic *string 140 141 // NameNie. 142 NameNie *string 143 144 // NameNiew. 145 NameNiew *string 146 147 // NameNisw. 148 NameNisw *string 149 150 // ObjectTypes. 151 ObjectTypes *string 152 153 // ObjectTypesn. 154 ObjectTypesn *string 155 156 /* Offset. 157 158 The initial index from which to return the results. 159 */ 160 Offset *int64 161 162 // User. 163 User *string 164 165 // Usern. 166 Usern *string 167 168 // UserID. 169 UserID *string 170 171 // UserIDn. 172 UserIDn *string 173 174 timeout time.Duration 175 Context context.Context 176 HTTPClient *http.Client 177 } 178 179 // WithDefaults hydrates default values in the users permissions list params (not the query body). 180 // 181 // All values with no default are reset to their zero value. 182 func (o *UsersPermissionsListParams) WithDefaults() *UsersPermissionsListParams { 183 o.SetDefaults() 184 return o 185 } 186 187 // SetDefaults hydrates default values in the users permissions list params (not the query body). 188 // 189 // All values with no default are reset to their zero value. 190 func (o *UsersPermissionsListParams) SetDefaults() { 191 // no default values defined for this parameter 192 } 193 194 // WithTimeout adds the timeout to the users permissions list params 195 func (o *UsersPermissionsListParams) WithTimeout(timeout time.Duration) *UsersPermissionsListParams { 196 o.SetTimeout(timeout) 197 return o 198 } 199 200 // SetTimeout adds the timeout to the users permissions list params 201 func (o *UsersPermissionsListParams) SetTimeout(timeout time.Duration) { 202 o.timeout = timeout 203 } 204 205 // WithContext adds the context to the users permissions list params 206 func (o *UsersPermissionsListParams) WithContext(ctx context.Context) *UsersPermissionsListParams { 207 o.SetContext(ctx) 208 return o 209 } 210 211 // SetContext adds the context to the users permissions list params 212 func (o *UsersPermissionsListParams) SetContext(ctx context.Context) { 213 o.Context = ctx 214 } 215 216 // WithHTTPClient adds the HTTPClient to the users permissions list params 217 func (o *UsersPermissionsListParams) WithHTTPClient(client *http.Client) *UsersPermissionsListParams { 218 o.SetHTTPClient(client) 219 return o 220 } 221 222 // SetHTTPClient adds the HTTPClient to the users permissions list params 223 func (o *UsersPermissionsListParams) SetHTTPClient(client *http.Client) { 224 o.HTTPClient = client 225 } 226 227 // WithEnabled adds the enabled to the users permissions list params 228 func (o *UsersPermissionsListParams) WithEnabled(enabled *string) *UsersPermissionsListParams { 229 o.SetEnabled(enabled) 230 return o 231 } 232 233 // SetEnabled adds the enabled to the users permissions list params 234 func (o *UsersPermissionsListParams) SetEnabled(enabled *string) { 235 o.Enabled = enabled 236 } 237 238 // WithGroup adds the group to the users permissions list params 239 func (o *UsersPermissionsListParams) WithGroup(group *string) *UsersPermissionsListParams { 240 o.SetGroup(group) 241 return o 242 } 243 244 // SetGroup adds the group to the users permissions list params 245 func (o *UsersPermissionsListParams) SetGroup(group *string) { 246 o.Group = group 247 } 248 249 // WithGroupn adds the groupn to the users permissions list params 250 func (o *UsersPermissionsListParams) WithGroupn(groupn *string) *UsersPermissionsListParams { 251 o.SetGroupn(groupn) 252 return o 253 } 254 255 // SetGroupn adds the groupN to the users permissions list params 256 func (o *UsersPermissionsListParams) SetGroupn(groupn *string) { 257 o.Groupn = groupn 258 } 259 260 // WithGroupID adds the groupID to the users permissions list params 261 func (o *UsersPermissionsListParams) WithGroupID(groupID *string) *UsersPermissionsListParams { 262 o.SetGroupID(groupID) 263 return o 264 } 265 266 // SetGroupID adds the groupId to the users permissions list params 267 func (o *UsersPermissionsListParams) SetGroupID(groupID *string) { 268 o.GroupID = groupID 269 } 270 271 // WithGroupIDn adds the groupIDn to the users permissions list params 272 func (o *UsersPermissionsListParams) WithGroupIDn(groupIDn *string) *UsersPermissionsListParams { 273 o.SetGroupIDn(groupIDn) 274 return o 275 } 276 277 // SetGroupIDn adds the groupIdN to the users permissions list params 278 func (o *UsersPermissionsListParams) SetGroupIDn(groupIDn *string) { 279 o.GroupIDn = groupIDn 280 } 281 282 // WithID adds the id to the users permissions list params 283 func (o *UsersPermissionsListParams) WithID(id *string) *UsersPermissionsListParams { 284 o.SetID(id) 285 return o 286 } 287 288 // SetID adds the id to the users permissions list params 289 func (o *UsersPermissionsListParams) SetID(id *string) { 290 o.ID = id 291 } 292 293 // WithIDGt adds the iDGt to the users permissions list params 294 func (o *UsersPermissionsListParams) WithIDGt(iDGt *string) *UsersPermissionsListParams { 295 o.SetIDGt(iDGt) 296 return o 297 } 298 299 // SetIDGt adds the idGt to the users permissions list params 300 func (o *UsersPermissionsListParams) SetIDGt(iDGt *string) { 301 o.IDGt = iDGt 302 } 303 304 // WithIDGte adds the iDGte to the users permissions list params 305 func (o *UsersPermissionsListParams) WithIDGte(iDGte *string) *UsersPermissionsListParams { 306 o.SetIDGte(iDGte) 307 return o 308 } 309 310 // SetIDGte adds the idGte to the users permissions list params 311 func (o *UsersPermissionsListParams) SetIDGte(iDGte *string) { 312 o.IDGte = iDGte 313 } 314 315 // WithIDLt adds the iDLt to the users permissions list params 316 func (o *UsersPermissionsListParams) WithIDLt(iDLt *string) *UsersPermissionsListParams { 317 o.SetIDLt(iDLt) 318 return o 319 } 320 321 // SetIDLt adds the idLt to the users permissions list params 322 func (o *UsersPermissionsListParams) SetIDLt(iDLt *string) { 323 o.IDLt = iDLt 324 } 325 326 // WithIDLte adds the iDLte to the users permissions list params 327 func (o *UsersPermissionsListParams) WithIDLte(iDLte *string) *UsersPermissionsListParams { 328 o.SetIDLte(iDLte) 329 return o 330 } 331 332 // SetIDLte adds the idLte to the users permissions list params 333 func (o *UsersPermissionsListParams) SetIDLte(iDLte *string) { 334 o.IDLte = iDLte 335 } 336 337 // WithIDn adds the iDn to the users permissions list params 338 func (o *UsersPermissionsListParams) WithIDn(iDn *string) *UsersPermissionsListParams { 339 o.SetIDn(iDn) 340 return o 341 } 342 343 // SetIDn adds the idN to the users permissions list params 344 func (o *UsersPermissionsListParams) SetIDn(iDn *string) { 345 o.IDn = iDn 346 } 347 348 // WithLimit adds the limit to the users permissions list params 349 func (o *UsersPermissionsListParams) WithLimit(limit *int64) *UsersPermissionsListParams { 350 o.SetLimit(limit) 351 return o 352 } 353 354 // SetLimit adds the limit to the users permissions list params 355 func (o *UsersPermissionsListParams) SetLimit(limit *int64) { 356 o.Limit = limit 357 } 358 359 // WithName adds the name to the users permissions list params 360 func (o *UsersPermissionsListParams) WithName(name *string) *UsersPermissionsListParams { 361 o.SetName(name) 362 return o 363 } 364 365 // SetName adds the name to the users permissions list params 366 func (o *UsersPermissionsListParams) SetName(name *string) { 367 o.Name = name 368 } 369 370 // WithNameEmpty adds the nameEmpty to the users permissions list params 371 func (o *UsersPermissionsListParams) WithNameEmpty(nameEmpty *string) *UsersPermissionsListParams { 372 o.SetNameEmpty(nameEmpty) 373 return o 374 } 375 376 // SetNameEmpty adds the nameEmpty to the users permissions list params 377 func (o *UsersPermissionsListParams) SetNameEmpty(nameEmpty *string) { 378 o.NameEmpty = nameEmpty 379 } 380 381 // WithNameIc adds the nameIc to the users permissions list params 382 func (o *UsersPermissionsListParams) WithNameIc(nameIc *string) *UsersPermissionsListParams { 383 o.SetNameIc(nameIc) 384 return o 385 } 386 387 // SetNameIc adds the nameIc to the users permissions list params 388 func (o *UsersPermissionsListParams) SetNameIc(nameIc *string) { 389 o.NameIc = nameIc 390 } 391 392 // WithNameIe adds the nameIe to the users permissions list params 393 func (o *UsersPermissionsListParams) WithNameIe(nameIe *string) *UsersPermissionsListParams { 394 o.SetNameIe(nameIe) 395 return o 396 } 397 398 // SetNameIe adds the nameIe to the users permissions list params 399 func (o *UsersPermissionsListParams) SetNameIe(nameIe *string) { 400 o.NameIe = nameIe 401 } 402 403 // WithNameIew adds the nameIew to the users permissions list params 404 func (o *UsersPermissionsListParams) WithNameIew(nameIew *string) *UsersPermissionsListParams { 405 o.SetNameIew(nameIew) 406 return o 407 } 408 409 // SetNameIew adds the nameIew to the users permissions list params 410 func (o *UsersPermissionsListParams) SetNameIew(nameIew *string) { 411 o.NameIew = nameIew 412 } 413 414 // WithNameIsw adds the nameIsw to the users permissions list params 415 func (o *UsersPermissionsListParams) WithNameIsw(nameIsw *string) *UsersPermissionsListParams { 416 o.SetNameIsw(nameIsw) 417 return o 418 } 419 420 // SetNameIsw adds the nameIsw to the users permissions list params 421 func (o *UsersPermissionsListParams) SetNameIsw(nameIsw *string) { 422 o.NameIsw = nameIsw 423 } 424 425 // WithNamen adds the namen to the users permissions list params 426 func (o *UsersPermissionsListParams) WithNamen(namen *string) *UsersPermissionsListParams { 427 o.SetNamen(namen) 428 return o 429 } 430 431 // SetNamen adds the nameN to the users permissions list params 432 func (o *UsersPermissionsListParams) SetNamen(namen *string) { 433 o.Namen = namen 434 } 435 436 // WithNameNic adds the nameNic to the users permissions list params 437 func (o *UsersPermissionsListParams) WithNameNic(nameNic *string) *UsersPermissionsListParams { 438 o.SetNameNic(nameNic) 439 return o 440 } 441 442 // SetNameNic adds the nameNic to the users permissions list params 443 func (o *UsersPermissionsListParams) SetNameNic(nameNic *string) { 444 o.NameNic = nameNic 445 } 446 447 // WithNameNie adds the nameNie to the users permissions list params 448 func (o *UsersPermissionsListParams) WithNameNie(nameNie *string) *UsersPermissionsListParams { 449 o.SetNameNie(nameNie) 450 return o 451 } 452 453 // SetNameNie adds the nameNie to the users permissions list params 454 func (o *UsersPermissionsListParams) SetNameNie(nameNie *string) { 455 o.NameNie = nameNie 456 } 457 458 // WithNameNiew adds the nameNiew to the users permissions list params 459 func (o *UsersPermissionsListParams) WithNameNiew(nameNiew *string) *UsersPermissionsListParams { 460 o.SetNameNiew(nameNiew) 461 return o 462 } 463 464 // SetNameNiew adds the nameNiew to the users permissions list params 465 func (o *UsersPermissionsListParams) SetNameNiew(nameNiew *string) { 466 o.NameNiew = nameNiew 467 } 468 469 // WithNameNisw adds the nameNisw to the users permissions list params 470 func (o *UsersPermissionsListParams) WithNameNisw(nameNisw *string) *UsersPermissionsListParams { 471 o.SetNameNisw(nameNisw) 472 return o 473 } 474 475 // SetNameNisw adds the nameNisw to the users permissions list params 476 func (o *UsersPermissionsListParams) SetNameNisw(nameNisw *string) { 477 o.NameNisw = nameNisw 478 } 479 480 // WithObjectTypes adds the objectTypes to the users permissions list params 481 func (o *UsersPermissionsListParams) WithObjectTypes(objectTypes *string) *UsersPermissionsListParams { 482 o.SetObjectTypes(objectTypes) 483 return o 484 } 485 486 // SetObjectTypes adds the objectTypes to the users permissions list params 487 func (o *UsersPermissionsListParams) SetObjectTypes(objectTypes *string) { 488 o.ObjectTypes = objectTypes 489 } 490 491 // WithObjectTypesn adds the objectTypesn to the users permissions list params 492 func (o *UsersPermissionsListParams) WithObjectTypesn(objectTypesn *string) *UsersPermissionsListParams { 493 o.SetObjectTypesn(objectTypesn) 494 return o 495 } 496 497 // SetObjectTypesn adds the objectTypesN to the users permissions list params 498 func (o *UsersPermissionsListParams) SetObjectTypesn(objectTypesn *string) { 499 o.ObjectTypesn = objectTypesn 500 } 501 502 // WithOffset adds the offset to the users permissions list params 503 func (o *UsersPermissionsListParams) WithOffset(offset *int64) *UsersPermissionsListParams { 504 o.SetOffset(offset) 505 return o 506 } 507 508 // SetOffset adds the offset to the users permissions list params 509 func (o *UsersPermissionsListParams) SetOffset(offset *int64) { 510 o.Offset = offset 511 } 512 513 // WithUser adds the user to the users permissions list params 514 func (o *UsersPermissionsListParams) WithUser(user *string) *UsersPermissionsListParams { 515 o.SetUser(user) 516 return o 517 } 518 519 // SetUser adds the user to the users permissions list params 520 func (o *UsersPermissionsListParams) SetUser(user *string) { 521 o.User = user 522 } 523 524 // WithUsern adds the usern to the users permissions list params 525 func (o *UsersPermissionsListParams) WithUsern(usern *string) *UsersPermissionsListParams { 526 o.SetUsern(usern) 527 return o 528 } 529 530 // SetUsern adds the userN to the users permissions list params 531 func (o *UsersPermissionsListParams) SetUsern(usern *string) { 532 o.Usern = usern 533 } 534 535 // WithUserID adds the userID to the users permissions list params 536 func (o *UsersPermissionsListParams) WithUserID(userID *string) *UsersPermissionsListParams { 537 o.SetUserID(userID) 538 return o 539 } 540 541 // SetUserID adds the userId to the users permissions list params 542 func (o *UsersPermissionsListParams) SetUserID(userID *string) { 543 o.UserID = userID 544 } 545 546 // WithUserIDn adds the userIDn to the users permissions list params 547 func (o *UsersPermissionsListParams) WithUserIDn(userIDn *string) *UsersPermissionsListParams { 548 o.SetUserIDn(userIDn) 549 return o 550 } 551 552 // SetUserIDn adds the userIdN to the users permissions list params 553 func (o *UsersPermissionsListParams) SetUserIDn(userIDn *string) { 554 o.UserIDn = userIDn 555 } 556 557 // WriteToRequest writes these params to a swagger request 558 func (o *UsersPermissionsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { 559 560 if err := r.SetTimeout(o.timeout); err != nil { 561 return err 562 } 563 var res []error 564 565 if o.Enabled != nil { 566 567 // query param enabled 568 var qrEnabled string 569 570 if o.Enabled != nil { 571 qrEnabled = *o.Enabled 572 } 573 qEnabled := qrEnabled 574 if qEnabled != "" { 575 576 if err := r.SetQueryParam("enabled", qEnabled); err != nil { 577 return err 578 } 579 } 580 } 581 582 if o.Group != nil { 583 584 // query param group 585 var qrGroup string 586 587 if o.Group != nil { 588 qrGroup = *o.Group 589 } 590 qGroup := qrGroup 591 if qGroup != "" { 592 593 if err := r.SetQueryParam("group", qGroup); err != nil { 594 return err 595 } 596 } 597 } 598 599 if o.Groupn != nil { 600 601 // query param group__n 602 var qrGroupn string 603 604 if o.Groupn != nil { 605 qrGroupn = *o.Groupn 606 } 607 qGroupn := qrGroupn 608 if qGroupn != "" { 609 610 if err := r.SetQueryParam("group__n", qGroupn); err != nil { 611 return err 612 } 613 } 614 } 615 616 if o.GroupID != nil { 617 618 // query param group_id 619 var qrGroupID string 620 621 if o.GroupID != nil { 622 qrGroupID = *o.GroupID 623 } 624 qGroupID := qrGroupID 625 if qGroupID != "" { 626 627 if err := r.SetQueryParam("group_id", qGroupID); err != nil { 628 return err 629 } 630 } 631 } 632 633 if o.GroupIDn != nil { 634 635 // query param group_id__n 636 var qrGroupIDn string 637 638 if o.GroupIDn != nil { 639 qrGroupIDn = *o.GroupIDn 640 } 641 qGroupIDn := qrGroupIDn 642 if qGroupIDn != "" { 643 644 if err := r.SetQueryParam("group_id__n", qGroupIDn); err != nil { 645 return err 646 } 647 } 648 } 649 650 if o.ID != nil { 651 652 // query param id 653 var qrID string 654 655 if o.ID != nil { 656 qrID = *o.ID 657 } 658 qID := qrID 659 if qID != "" { 660 661 if err := r.SetQueryParam("id", qID); err != nil { 662 return err 663 } 664 } 665 } 666 667 if o.IDGt != nil { 668 669 // query param id__gt 670 var qrIDGt string 671 672 if o.IDGt != nil { 673 qrIDGt = *o.IDGt 674 } 675 qIDGt := qrIDGt 676 if qIDGt != "" { 677 678 if err := r.SetQueryParam("id__gt", qIDGt); err != nil { 679 return err 680 } 681 } 682 } 683 684 if o.IDGte != nil { 685 686 // query param id__gte 687 var qrIDGte string 688 689 if o.IDGte != nil { 690 qrIDGte = *o.IDGte 691 } 692 qIDGte := qrIDGte 693 if qIDGte != "" { 694 695 if err := r.SetQueryParam("id__gte", qIDGte); err != nil { 696 return err 697 } 698 } 699 } 700 701 if o.IDLt != nil { 702 703 // query param id__lt 704 var qrIDLt string 705 706 if o.IDLt != nil { 707 qrIDLt = *o.IDLt 708 } 709 qIDLt := qrIDLt 710 if qIDLt != "" { 711 712 if err := r.SetQueryParam("id__lt", qIDLt); err != nil { 713 return err 714 } 715 } 716 } 717 718 if o.IDLte != nil { 719 720 // query param id__lte 721 var qrIDLte string 722 723 if o.IDLte != nil { 724 qrIDLte = *o.IDLte 725 } 726 qIDLte := qrIDLte 727 if qIDLte != "" { 728 729 if err := r.SetQueryParam("id__lte", qIDLte); err != nil { 730 return err 731 } 732 } 733 } 734 735 if o.IDn != nil { 736 737 // query param id__n 738 var qrIDn string 739 740 if o.IDn != nil { 741 qrIDn = *o.IDn 742 } 743 qIDn := qrIDn 744 if qIDn != "" { 745 746 if err := r.SetQueryParam("id__n", qIDn); err != nil { 747 return err 748 } 749 } 750 } 751 752 if o.Limit != nil { 753 754 // query param limit 755 var qrLimit int64 756 757 if o.Limit != nil { 758 qrLimit = *o.Limit 759 } 760 qLimit := swag.FormatInt64(qrLimit) 761 if qLimit != "" { 762 763 if err := r.SetQueryParam("limit", qLimit); err != nil { 764 return err 765 } 766 } 767 } 768 769 if o.Name != nil { 770 771 // query param name 772 var qrName string 773 774 if o.Name != nil { 775 qrName = *o.Name 776 } 777 qName := qrName 778 if qName != "" { 779 780 if err := r.SetQueryParam("name", qName); err != nil { 781 return err 782 } 783 } 784 } 785 786 if o.NameEmpty != nil { 787 788 // query param name__empty 789 var qrNameEmpty string 790 791 if o.NameEmpty != nil { 792 qrNameEmpty = *o.NameEmpty 793 } 794 qNameEmpty := qrNameEmpty 795 if qNameEmpty != "" { 796 797 if err := r.SetQueryParam("name__empty", qNameEmpty); err != nil { 798 return err 799 } 800 } 801 } 802 803 if o.NameIc != nil { 804 805 // query param name__ic 806 var qrNameIc string 807 808 if o.NameIc != nil { 809 qrNameIc = *o.NameIc 810 } 811 qNameIc := qrNameIc 812 if qNameIc != "" { 813 814 if err := r.SetQueryParam("name__ic", qNameIc); err != nil { 815 return err 816 } 817 } 818 } 819 820 if o.NameIe != nil { 821 822 // query param name__ie 823 var qrNameIe string 824 825 if o.NameIe != nil { 826 qrNameIe = *o.NameIe 827 } 828 qNameIe := qrNameIe 829 if qNameIe != "" { 830 831 if err := r.SetQueryParam("name__ie", qNameIe); err != nil { 832 return err 833 } 834 } 835 } 836 837 if o.NameIew != nil { 838 839 // query param name__iew 840 var qrNameIew string 841 842 if o.NameIew != nil { 843 qrNameIew = *o.NameIew 844 } 845 qNameIew := qrNameIew 846 if qNameIew != "" { 847 848 if err := r.SetQueryParam("name__iew", qNameIew); err != nil { 849 return err 850 } 851 } 852 } 853 854 if o.NameIsw != nil { 855 856 // query param name__isw 857 var qrNameIsw string 858 859 if o.NameIsw != nil { 860 qrNameIsw = *o.NameIsw 861 } 862 qNameIsw := qrNameIsw 863 if qNameIsw != "" { 864 865 if err := r.SetQueryParam("name__isw", qNameIsw); err != nil { 866 return err 867 } 868 } 869 } 870 871 if o.Namen != nil { 872 873 // query param name__n 874 var qrNamen string 875 876 if o.Namen != nil { 877 qrNamen = *o.Namen 878 } 879 qNamen := qrNamen 880 if qNamen != "" { 881 882 if err := r.SetQueryParam("name__n", qNamen); err != nil { 883 return err 884 } 885 } 886 } 887 888 if o.NameNic != nil { 889 890 // query param name__nic 891 var qrNameNic string 892 893 if o.NameNic != nil { 894 qrNameNic = *o.NameNic 895 } 896 qNameNic := qrNameNic 897 if qNameNic != "" { 898 899 if err := r.SetQueryParam("name__nic", qNameNic); err != nil { 900 return err 901 } 902 } 903 } 904 905 if o.NameNie != nil { 906 907 // query param name__nie 908 var qrNameNie string 909 910 if o.NameNie != nil { 911 qrNameNie = *o.NameNie 912 } 913 qNameNie := qrNameNie 914 if qNameNie != "" { 915 916 if err := r.SetQueryParam("name__nie", qNameNie); err != nil { 917 return err 918 } 919 } 920 } 921 922 if o.NameNiew != nil { 923 924 // query param name__niew 925 var qrNameNiew string 926 927 if o.NameNiew != nil { 928 qrNameNiew = *o.NameNiew 929 } 930 qNameNiew := qrNameNiew 931 if qNameNiew != "" { 932 933 if err := r.SetQueryParam("name__niew", qNameNiew); err != nil { 934 return err 935 } 936 } 937 } 938 939 if o.NameNisw != nil { 940 941 // query param name__nisw 942 var qrNameNisw string 943 944 if o.NameNisw != nil { 945 qrNameNisw = *o.NameNisw 946 } 947 qNameNisw := qrNameNisw 948 if qNameNisw != "" { 949 950 if err := r.SetQueryParam("name__nisw", qNameNisw); err != nil { 951 return err 952 } 953 } 954 } 955 956 if o.ObjectTypes != nil { 957 958 // query param object_types 959 var qrObjectTypes string 960 961 if o.ObjectTypes != nil { 962 qrObjectTypes = *o.ObjectTypes 963 } 964 qObjectTypes := qrObjectTypes 965 if qObjectTypes != "" { 966 967 if err := r.SetQueryParam("object_types", qObjectTypes); err != nil { 968 return err 969 } 970 } 971 } 972 973 if o.ObjectTypesn != nil { 974 975 // query param object_types__n 976 var qrObjectTypesn string 977 978 if o.ObjectTypesn != nil { 979 qrObjectTypesn = *o.ObjectTypesn 980 } 981 qObjectTypesn := qrObjectTypesn 982 if qObjectTypesn != "" { 983 984 if err := r.SetQueryParam("object_types__n", qObjectTypesn); err != nil { 985 return err 986 } 987 } 988 } 989 990 if o.Offset != nil { 991 992 // query param offset 993 var qrOffset int64 994 995 if o.Offset != nil { 996 qrOffset = *o.Offset 997 } 998 qOffset := swag.FormatInt64(qrOffset) 999 if qOffset != "" { 1000 1001 if err := r.SetQueryParam("offset", qOffset); err != nil { 1002 return err 1003 } 1004 } 1005 } 1006 1007 if o.User != nil { 1008 1009 // query param user 1010 var qrUser string 1011 1012 if o.User != nil { 1013 qrUser = *o.User 1014 } 1015 qUser := qrUser 1016 if qUser != "" { 1017 1018 if err := r.SetQueryParam("user", qUser); err != nil { 1019 return err 1020 } 1021 } 1022 } 1023 1024 if o.Usern != nil { 1025 1026 // query param user__n 1027 var qrUsern string 1028 1029 if o.Usern != nil { 1030 qrUsern = *o.Usern 1031 } 1032 qUsern := qrUsern 1033 if qUsern != "" { 1034 1035 if err := r.SetQueryParam("user__n", qUsern); err != nil { 1036 return err 1037 } 1038 } 1039 } 1040 1041 if o.UserID != nil { 1042 1043 // query param user_id 1044 var qrUserID string 1045 1046 if o.UserID != nil { 1047 qrUserID = *o.UserID 1048 } 1049 qUserID := qrUserID 1050 if qUserID != "" { 1051 1052 if err := r.SetQueryParam("user_id", qUserID); err != nil { 1053 return err 1054 } 1055 } 1056 } 1057 1058 if o.UserIDn != nil { 1059 1060 // query param user_id__n 1061 var qrUserIDn string 1062 1063 if o.UserIDn != nil { 1064 qrUserIDn = *o.UserIDn 1065 } 1066 qUserIDn := qrUserIDn 1067 if qUserIDn != "" { 1068 1069 if err := r.SetQueryParam("user_id__n", qUserIDn); err != nil { 1070 return err 1071 } 1072 } 1073 } 1074 1075 if len(res) > 0 { 1076 return errors.CompositeValidationError(res...) 1077 } 1078 return nil 1079 }