github.com/digitalocean/go-netbox@v0.0.2/netbox/client/dcim/dcim_device_bay_templates_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 dcim 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 // NewDcimDeviceBayTemplatesListParams creates a new DcimDeviceBayTemplatesListParams 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 NewDcimDeviceBayTemplatesListParams() *DcimDeviceBayTemplatesListParams { 42 return &DcimDeviceBayTemplatesListParams{ 43 timeout: cr.DefaultTimeout, 44 } 45 } 46 47 // NewDcimDeviceBayTemplatesListParamsWithTimeout creates a new DcimDeviceBayTemplatesListParams object 48 // with the ability to set a timeout on a request. 49 func NewDcimDeviceBayTemplatesListParamsWithTimeout(timeout time.Duration) *DcimDeviceBayTemplatesListParams { 50 return &DcimDeviceBayTemplatesListParams{ 51 timeout: timeout, 52 } 53 } 54 55 // NewDcimDeviceBayTemplatesListParamsWithContext creates a new DcimDeviceBayTemplatesListParams object 56 // with the ability to set a context for a request. 57 func NewDcimDeviceBayTemplatesListParamsWithContext(ctx context.Context) *DcimDeviceBayTemplatesListParams { 58 return &DcimDeviceBayTemplatesListParams{ 59 Context: ctx, 60 } 61 } 62 63 // NewDcimDeviceBayTemplatesListParamsWithHTTPClient creates a new DcimDeviceBayTemplatesListParams object 64 // with the ability to set a custom HTTPClient for a request. 65 func NewDcimDeviceBayTemplatesListParamsWithHTTPClient(client *http.Client) *DcimDeviceBayTemplatesListParams { 66 return &DcimDeviceBayTemplatesListParams{ 67 HTTPClient: client, 68 } 69 } 70 71 /* DcimDeviceBayTemplatesListParams contains all the parameters to send to the API endpoint 72 for the dcim device bay templates list operation. 73 74 Typically these are written to a http.Request. 75 */ 76 type DcimDeviceBayTemplatesListParams struct { 77 78 // Created. 79 Created *string 80 81 // CreatedGte. 82 CreatedGte *string 83 84 // CreatedLte. 85 CreatedLte *string 86 87 // DevicetypeID. 88 DevicetypeID *string 89 90 // DevicetypeIDn. 91 DevicetypeIDn *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 // LastUpdated. 112 LastUpdated *string 113 114 // LastUpdatedGte. 115 LastUpdatedGte *string 116 117 // LastUpdatedLte. 118 LastUpdatedLte *string 119 120 /* Limit. 121 122 Number of results to return per page. 123 */ 124 Limit *int64 125 126 // Name. 127 Name *string 128 129 // NameEmpty. 130 NameEmpty *string 131 132 // NameIc. 133 NameIc *string 134 135 // NameIe. 136 NameIe *string 137 138 // NameIew. 139 NameIew *string 140 141 // NameIsw. 142 NameIsw *string 143 144 // Namen. 145 Namen *string 146 147 // NameNic. 148 NameNic *string 149 150 // NameNie. 151 NameNie *string 152 153 // NameNiew. 154 NameNiew *string 155 156 // NameNisw. 157 NameNisw *string 158 159 /* Offset. 160 161 The initial index from which to return the results. 162 */ 163 Offset *int64 164 165 timeout time.Duration 166 Context context.Context 167 HTTPClient *http.Client 168 } 169 170 // WithDefaults hydrates default values in the dcim device bay templates list params (not the query body). 171 // 172 // All values with no default are reset to their zero value. 173 func (o *DcimDeviceBayTemplatesListParams) WithDefaults() *DcimDeviceBayTemplatesListParams { 174 o.SetDefaults() 175 return o 176 } 177 178 // SetDefaults hydrates default values in the dcim device bay templates list params (not the query body). 179 // 180 // All values with no default are reset to their zero value. 181 func (o *DcimDeviceBayTemplatesListParams) SetDefaults() { 182 // no default values defined for this parameter 183 } 184 185 // WithTimeout adds the timeout to the dcim device bay templates list params 186 func (o *DcimDeviceBayTemplatesListParams) WithTimeout(timeout time.Duration) *DcimDeviceBayTemplatesListParams { 187 o.SetTimeout(timeout) 188 return o 189 } 190 191 // SetTimeout adds the timeout to the dcim device bay templates list params 192 func (o *DcimDeviceBayTemplatesListParams) SetTimeout(timeout time.Duration) { 193 o.timeout = timeout 194 } 195 196 // WithContext adds the context to the dcim device bay templates list params 197 func (o *DcimDeviceBayTemplatesListParams) WithContext(ctx context.Context) *DcimDeviceBayTemplatesListParams { 198 o.SetContext(ctx) 199 return o 200 } 201 202 // SetContext adds the context to the dcim device bay templates list params 203 func (o *DcimDeviceBayTemplatesListParams) SetContext(ctx context.Context) { 204 o.Context = ctx 205 } 206 207 // WithHTTPClient adds the HTTPClient to the dcim device bay templates list params 208 func (o *DcimDeviceBayTemplatesListParams) WithHTTPClient(client *http.Client) *DcimDeviceBayTemplatesListParams { 209 o.SetHTTPClient(client) 210 return o 211 } 212 213 // SetHTTPClient adds the HTTPClient to the dcim device bay templates list params 214 func (o *DcimDeviceBayTemplatesListParams) SetHTTPClient(client *http.Client) { 215 o.HTTPClient = client 216 } 217 218 // WithCreated adds the created to the dcim device bay templates list params 219 func (o *DcimDeviceBayTemplatesListParams) WithCreated(created *string) *DcimDeviceBayTemplatesListParams { 220 o.SetCreated(created) 221 return o 222 } 223 224 // SetCreated adds the created to the dcim device bay templates list params 225 func (o *DcimDeviceBayTemplatesListParams) SetCreated(created *string) { 226 o.Created = created 227 } 228 229 // WithCreatedGte adds the createdGte to the dcim device bay templates list params 230 func (o *DcimDeviceBayTemplatesListParams) WithCreatedGte(createdGte *string) *DcimDeviceBayTemplatesListParams { 231 o.SetCreatedGte(createdGte) 232 return o 233 } 234 235 // SetCreatedGte adds the createdGte to the dcim device bay templates list params 236 func (o *DcimDeviceBayTemplatesListParams) SetCreatedGte(createdGte *string) { 237 o.CreatedGte = createdGte 238 } 239 240 // WithCreatedLte adds the createdLte to the dcim device bay templates list params 241 func (o *DcimDeviceBayTemplatesListParams) WithCreatedLte(createdLte *string) *DcimDeviceBayTemplatesListParams { 242 o.SetCreatedLte(createdLte) 243 return o 244 } 245 246 // SetCreatedLte adds the createdLte to the dcim device bay templates list params 247 func (o *DcimDeviceBayTemplatesListParams) SetCreatedLte(createdLte *string) { 248 o.CreatedLte = createdLte 249 } 250 251 // WithDevicetypeID adds the devicetypeID to the dcim device bay templates list params 252 func (o *DcimDeviceBayTemplatesListParams) WithDevicetypeID(devicetypeID *string) *DcimDeviceBayTemplatesListParams { 253 o.SetDevicetypeID(devicetypeID) 254 return o 255 } 256 257 // SetDevicetypeID adds the devicetypeId to the dcim device bay templates list params 258 func (o *DcimDeviceBayTemplatesListParams) SetDevicetypeID(devicetypeID *string) { 259 o.DevicetypeID = devicetypeID 260 } 261 262 // WithDevicetypeIDn adds the devicetypeIDn to the dcim device bay templates list params 263 func (o *DcimDeviceBayTemplatesListParams) WithDevicetypeIDn(devicetypeIDn *string) *DcimDeviceBayTemplatesListParams { 264 o.SetDevicetypeIDn(devicetypeIDn) 265 return o 266 } 267 268 // SetDevicetypeIDn adds the devicetypeIdN to the dcim device bay templates list params 269 func (o *DcimDeviceBayTemplatesListParams) SetDevicetypeIDn(devicetypeIDn *string) { 270 o.DevicetypeIDn = devicetypeIDn 271 } 272 273 // WithID adds the id to the dcim device bay templates list params 274 func (o *DcimDeviceBayTemplatesListParams) WithID(id *string) *DcimDeviceBayTemplatesListParams { 275 o.SetID(id) 276 return o 277 } 278 279 // SetID adds the id to the dcim device bay templates list params 280 func (o *DcimDeviceBayTemplatesListParams) SetID(id *string) { 281 o.ID = id 282 } 283 284 // WithIDGt adds the iDGt to the dcim device bay templates list params 285 func (o *DcimDeviceBayTemplatesListParams) WithIDGt(iDGt *string) *DcimDeviceBayTemplatesListParams { 286 o.SetIDGt(iDGt) 287 return o 288 } 289 290 // SetIDGt adds the idGt to the dcim device bay templates list params 291 func (o *DcimDeviceBayTemplatesListParams) SetIDGt(iDGt *string) { 292 o.IDGt = iDGt 293 } 294 295 // WithIDGte adds the iDGte to the dcim device bay templates list params 296 func (o *DcimDeviceBayTemplatesListParams) WithIDGte(iDGte *string) *DcimDeviceBayTemplatesListParams { 297 o.SetIDGte(iDGte) 298 return o 299 } 300 301 // SetIDGte adds the idGte to the dcim device bay templates list params 302 func (o *DcimDeviceBayTemplatesListParams) SetIDGte(iDGte *string) { 303 o.IDGte = iDGte 304 } 305 306 // WithIDLt adds the iDLt to the dcim device bay templates list params 307 func (o *DcimDeviceBayTemplatesListParams) WithIDLt(iDLt *string) *DcimDeviceBayTemplatesListParams { 308 o.SetIDLt(iDLt) 309 return o 310 } 311 312 // SetIDLt adds the idLt to the dcim device bay templates list params 313 func (o *DcimDeviceBayTemplatesListParams) SetIDLt(iDLt *string) { 314 o.IDLt = iDLt 315 } 316 317 // WithIDLte adds the iDLte to the dcim device bay templates list params 318 func (o *DcimDeviceBayTemplatesListParams) WithIDLte(iDLte *string) *DcimDeviceBayTemplatesListParams { 319 o.SetIDLte(iDLte) 320 return o 321 } 322 323 // SetIDLte adds the idLte to the dcim device bay templates list params 324 func (o *DcimDeviceBayTemplatesListParams) SetIDLte(iDLte *string) { 325 o.IDLte = iDLte 326 } 327 328 // WithIDn adds the iDn to the dcim device bay templates list params 329 func (o *DcimDeviceBayTemplatesListParams) WithIDn(iDn *string) *DcimDeviceBayTemplatesListParams { 330 o.SetIDn(iDn) 331 return o 332 } 333 334 // SetIDn adds the idN to the dcim device bay templates list params 335 func (o *DcimDeviceBayTemplatesListParams) SetIDn(iDn *string) { 336 o.IDn = iDn 337 } 338 339 // WithLastUpdated adds the lastUpdated to the dcim device bay templates list params 340 func (o *DcimDeviceBayTemplatesListParams) WithLastUpdated(lastUpdated *string) *DcimDeviceBayTemplatesListParams { 341 o.SetLastUpdated(lastUpdated) 342 return o 343 } 344 345 // SetLastUpdated adds the lastUpdated to the dcim device bay templates list params 346 func (o *DcimDeviceBayTemplatesListParams) SetLastUpdated(lastUpdated *string) { 347 o.LastUpdated = lastUpdated 348 } 349 350 // WithLastUpdatedGte adds the lastUpdatedGte to the dcim device bay templates list params 351 func (o *DcimDeviceBayTemplatesListParams) WithLastUpdatedGte(lastUpdatedGte *string) *DcimDeviceBayTemplatesListParams { 352 o.SetLastUpdatedGte(lastUpdatedGte) 353 return o 354 } 355 356 // SetLastUpdatedGte adds the lastUpdatedGte to the dcim device bay templates list params 357 func (o *DcimDeviceBayTemplatesListParams) SetLastUpdatedGte(lastUpdatedGte *string) { 358 o.LastUpdatedGte = lastUpdatedGte 359 } 360 361 // WithLastUpdatedLte adds the lastUpdatedLte to the dcim device bay templates list params 362 func (o *DcimDeviceBayTemplatesListParams) WithLastUpdatedLte(lastUpdatedLte *string) *DcimDeviceBayTemplatesListParams { 363 o.SetLastUpdatedLte(lastUpdatedLte) 364 return o 365 } 366 367 // SetLastUpdatedLte adds the lastUpdatedLte to the dcim device bay templates list params 368 func (o *DcimDeviceBayTemplatesListParams) SetLastUpdatedLte(lastUpdatedLte *string) { 369 o.LastUpdatedLte = lastUpdatedLte 370 } 371 372 // WithLimit adds the limit to the dcim device bay templates list params 373 func (o *DcimDeviceBayTemplatesListParams) WithLimit(limit *int64) *DcimDeviceBayTemplatesListParams { 374 o.SetLimit(limit) 375 return o 376 } 377 378 // SetLimit adds the limit to the dcim device bay templates list params 379 func (o *DcimDeviceBayTemplatesListParams) SetLimit(limit *int64) { 380 o.Limit = limit 381 } 382 383 // WithName adds the name to the dcim device bay templates list params 384 func (o *DcimDeviceBayTemplatesListParams) WithName(name *string) *DcimDeviceBayTemplatesListParams { 385 o.SetName(name) 386 return o 387 } 388 389 // SetName adds the name to the dcim device bay templates list params 390 func (o *DcimDeviceBayTemplatesListParams) SetName(name *string) { 391 o.Name = name 392 } 393 394 // WithNameEmpty adds the nameEmpty to the dcim device bay templates list params 395 func (o *DcimDeviceBayTemplatesListParams) WithNameEmpty(nameEmpty *string) *DcimDeviceBayTemplatesListParams { 396 o.SetNameEmpty(nameEmpty) 397 return o 398 } 399 400 // SetNameEmpty adds the nameEmpty to the dcim device bay templates list params 401 func (o *DcimDeviceBayTemplatesListParams) SetNameEmpty(nameEmpty *string) { 402 o.NameEmpty = nameEmpty 403 } 404 405 // WithNameIc adds the nameIc to the dcim device bay templates list params 406 func (o *DcimDeviceBayTemplatesListParams) WithNameIc(nameIc *string) *DcimDeviceBayTemplatesListParams { 407 o.SetNameIc(nameIc) 408 return o 409 } 410 411 // SetNameIc adds the nameIc to the dcim device bay templates list params 412 func (o *DcimDeviceBayTemplatesListParams) SetNameIc(nameIc *string) { 413 o.NameIc = nameIc 414 } 415 416 // WithNameIe adds the nameIe to the dcim device bay templates list params 417 func (o *DcimDeviceBayTemplatesListParams) WithNameIe(nameIe *string) *DcimDeviceBayTemplatesListParams { 418 o.SetNameIe(nameIe) 419 return o 420 } 421 422 // SetNameIe adds the nameIe to the dcim device bay templates list params 423 func (o *DcimDeviceBayTemplatesListParams) SetNameIe(nameIe *string) { 424 o.NameIe = nameIe 425 } 426 427 // WithNameIew adds the nameIew to the dcim device bay templates list params 428 func (o *DcimDeviceBayTemplatesListParams) WithNameIew(nameIew *string) *DcimDeviceBayTemplatesListParams { 429 o.SetNameIew(nameIew) 430 return o 431 } 432 433 // SetNameIew adds the nameIew to the dcim device bay templates list params 434 func (o *DcimDeviceBayTemplatesListParams) SetNameIew(nameIew *string) { 435 o.NameIew = nameIew 436 } 437 438 // WithNameIsw adds the nameIsw to the dcim device bay templates list params 439 func (o *DcimDeviceBayTemplatesListParams) WithNameIsw(nameIsw *string) *DcimDeviceBayTemplatesListParams { 440 o.SetNameIsw(nameIsw) 441 return o 442 } 443 444 // SetNameIsw adds the nameIsw to the dcim device bay templates list params 445 func (o *DcimDeviceBayTemplatesListParams) SetNameIsw(nameIsw *string) { 446 o.NameIsw = nameIsw 447 } 448 449 // WithNamen adds the namen to the dcim device bay templates list params 450 func (o *DcimDeviceBayTemplatesListParams) WithNamen(namen *string) *DcimDeviceBayTemplatesListParams { 451 o.SetNamen(namen) 452 return o 453 } 454 455 // SetNamen adds the nameN to the dcim device bay templates list params 456 func (o *DcimDeviceBayTemplatesListParams) SetNamen(namen *string) { 457 o.Namen = namen 458 } 459 460 // WithNameNic adds the nameNic to the dcim device bay templates list params 461 func (o *DcimDeviceBayTemplatesListParams) WithNameNic(nameNic *string) *DcimDeviceBayTemplatesListParams { 462 o.SetNameNic(nameNic) 463 return o 464 } 465 466 // SetNameNic adds the nameNic to the dcim device bay templates list params 467 func (o *DcimDeviceBayTemplatesListParams) SetNameNic(nameNic *string) { 468 o.NameNic = nameNic 469 } 470 471 // WithNameNie adds the nameNie to the dcim device bay templates list params 472 func (o *DcimDeviceBayTemplatesListParams) WithNameNie(nameNie *string) *DcimDeviceBayTemplatesListParams { 473 o.SetNameNie(nameNie) 474 return o 475 } 476 477 // SetNameNie adds the nameNie to the dcim device bay templates list params 478 func (o *DcimDeviceBayTemplatesListParams) SetNameNie(nameNie *string) { 479 o.NameNie = nameNie 480 } 481 482 // WithNameNiew adds the nameNiew to the dcim device bay templates list params 483 func (o *DcimDeviceBayTemplatesListParams) WithNameNiew(nameNiew *string) *DcimDeviceBayTemplatesListParams { 484 o.SetNameNiew(nameNiew) 485 return o 486 } 487 488 // SetNameNiew adds the nameNiew to the dcim device bay templates list params 489 func (o *DcimDeviceBayTemplatesListParams) SetNameNiew(nameNiew *string) { 490 o.NameNiew = nameNiew 491 } 492 493 // WithNameNisw adds the nameNisw to the dcim device bay templates list params 494 func (o *DcimDeviceBayTemplatesListParams) WithNameNisw(nameNisw *string) *DcimDeviceBayTemplatesListParams { 495 o.SetNameNisw(nameNisw) 496 return o 497 } 498 499 // SetNameNisw adds the nameNisw to the dcim device bay templates list params 500 func (o *DcimDeviceBayTemplatesListParams) SetNameNisw(nameNisw *string) { 501 o.NameNisw = nameNisw 502 } 503 504 // WithOffset adds the offset to the dcim device bay templates list params 505 func (o *DcimDeviceBayTemplatesListParams) WithOffset(offset *int64) *DcimDeviceBayTemplatesListParams { 506 o.SetOffset(offset) 507 return o 508 } 509 510 // SetOffset adds the offset to the dcim device bay templates list params 511 func (o *DcimDeviceBayTemplatesListParams) SetOffset(offset *int64) { 512 o.Offset = offset 513 } 514 515 // WriteToRequest writes these params to a swagger request 516 func (o *DcimDeviceBayTemplatesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { 517 518 if err := r.SetTimeout(o.timeout); err != nil { 519 return err 520 } 521 var res []error 522 523 if o.Created != nil { 524 525 // query param created 526 var qrCreated string 527 528 if o.Created != nil { 529 qrCreated = *o.Created 530 } 531 qCreated := qrCreated 532 if qCreated != "" { 533 534 if err := r.SetQueryParam("created", qCreated); err != nil { 535 return err 536 } 537 } 538 } 539 540 if o.CreatedGte != nil { 541 542 // query param created__gte 543 var qrCreatedGte string 544 545 if o.CreatedGte != nil { 546 qrCreatedGte = *o.CreatedGte 547 } 548 qCreatedGte := qrCreatedGte 549 if qCreatedGte != "" { 550 551 if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { 552 return err 553 } 554 } 555 } 556 557 if o.CreatedLte != nil { 558 559 // query param created__lte 560 var qrCreatedLte string 561 562 if o.CreatedLte != nil { 563 qrCreatedLte = *o.CreatedLte 564 } 565 qCreatedLte := qrCreatedLte 566 if qCreatedLte != "" { 567 568 if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { 569 return err 570 } 571 } 572 } 573 574 if o.DevicetypeID != nil { 575 576 // query param devicetype_id 577 var qrDevicetypeID string 578 579 if o.DevicetypeID != nil { 580 qrDevicetypeID = *o.DevicetypeID 581 } 582 qDevicetypeID := qrDevicetypeID 583 if qDevicetypeID != "" { 584 585 if err := r.SetQueryParam("devicetype_id", qDevicetypeID); err != nil { 586 return err 587 } 588 } 589 } 590 591 if o.DevicetypeIDn != nil { 592 593 // query param devicetype_id__n 594 var qrDevicetypeIDn string 595 596 if o.DevicetypeIDn != nil { 597 qrDevicetypeIDn = *o.DevicetypeIDn 598 } 599 qDevicetypeIDn := qrDevicetypeIDn 600 if qDevicetypeIDn != "" { 601 602 if err := r.SetQueryParam("devicetype_id__n", qDevicetypeIDn); err != nil { 603 return err 604 } 605 } 606 } 607 608 if o.ID != nil { 609 610 // query param id 611 var qrID string 612 613 if o.ID != nil { 614 qrID = *o.ID 615 } 616 qID := qrID 617 if qID != "" { 618 619 if err := r.SetQueryParam("id", qID); err != nil { 620 return err 621 } 622 } 623 } 624 625 if o.IDGt != nil { 626 627 // query param id__gt 628 var qrIDGt string 629 630 if o.IDGt != nil { 631 qrIDGt = *o.IDGt 632 } 633 qIDGt := qrIDGt 634 if qIDGt != "" { 635 636 if err := r.SetQueryParam("id__gt", qIDGt); err != nil { 637 return err 638 } 639 } 640 } 641 642 if o.IDGte != nil { 643 644 // query param id__gte 645 var qrIDGte string 646 647 if o.IDGte != nil { 648 qrIDGte = *o.IDGte 649 } 650 qIDGte := qrIDGte 651 if qIDGte != "" { 652 653 if err := r.SetQueryParam("id__gte", qIDGte); err != nil { 654 return err 655 } 656 } 657 } 658 659 if o.IDLt != nil { 660 661 // query param id__lt 662 var qrIDLt string 663 664 if o.IDLt != nil { 665 qrIDLt = *o.IDLt 666 } 667 qIDLt := qrIDLt 668 if qIDLt != "" { 669 670 if err := r.SetQueryParam("id__lt", qIDLt); err != nil { 671 return err 672 } 673 } 674 } 675 676 if o.IDLte != nil { 677 678 // query param id__lte 679 var qrIDLte string 680 681 if o.IDLte != nil { 682 qrIDLte = *o.IDLte 683 } 684 qIDLte := qrIDLte 685 if qIDLte != "" { 686 687 if err := r.SetQueryParam("id__lte", qIDLte); err != nil { 688 return err 689 } 690 } 691 } 692 693 if o.IDn != nil { 694 695 // query param id__n 696 var qrIDn string 697 698 if o.IDn != nil { 699 qrIDn = *o.IDn 700 } 701 qIDn := qrIDn 702 if qIDn != "" { 703 704 if err := r.SetQueryParam("id__n", qIDn); err != nil { 705 return err 706 } 707 } 708 } 709 710 if o.LastUpdated != nil { 711 712 // query param last_updated 713 var qrLastUpdated string 714 715 if o.LastUpdated != nil { 716 qrLastUpdated = *o.LastUpdated 717 } 718 qLastUpdated := qrLastUpdated 719 if qLastUpdated != "" { 720 721 if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { 722 return err 723 } 724 } 725 } 726 727 if o.LastUpdatedGte != nil { 728 729 // query param last_updated__gte 730 var qrLastUpdatedGte string 731 732 if o.LastUpdatedGte != nil { 733 qrLastUpdatedGte = *o.LastUpdatedGte 734 } 735 qLastUpdatedGte := qrLastUpdatedGte 736 if qLastUpdatedGte != "" { 737 738 if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { 739 return err 740 } 741 } 742 } 743 744 if o.LastUpdatedLte != nil { 745 746 // query param last_updated__lte 747 var qrLastUpdatedLte string 748 749 if o.LastUpdatedLte != nil { 750 qrLastUpdatedLte = *o.LastUpdatedLte 751 } 752 qLastUpdatedLte := qrLastUpdatedLte 753 if qLastUpdatedLte != "" { 754 755 if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { 756 return err 757 } 758 } 759 } 760 761 if o.Limit != nil { 762 763 // query param limit 764 var qrLimit int64 765 766 if o.Limit != nil { 767 qrLimit = *o.Limit 768 } 769 qLimit := swag.FormatInt64(qrLimit) 770 if qLimit != "" { 771 772 if err := r.SetQueryParam("limit", qLimit); err != nil { 773 return err 774 } 775 } 776 } 777 778 if o.Name != nil { 779 780 // query param name 781 var qrName string 782 783 if o.Name != nil { 784 qrName = *o.Name 785 } 786 qName := qrName 787 if qName != "" { 788 789 if err := r.SetQueryParam("name", qName); err != nil { 790 return err 791 } 792 } 793 } 794 795 if o.NameEmpty != nil { 796 797 // query param name__empty 798 var qrNameEmpty string 799 800 if o.NameEmpty != nil { 801 qrNameEmpty = *o.NameEmpty 802 } 803 qNameEmpty := qrNameEmpty 804 if qNameEmpty != "" { 805 806 if err := r.SetQueryParam("name__empty", qNameEmpty); err != nil { 807 return err 808 } 809 } 810 } 811 812 if o.NameIc != nil { 813 814 // query param name__ic 815 var qrNameIc string 816 817 if o.NameIc != nil { 818 qrNameIc = *o.NameIc 819 } 820 qNameIc := qrNameIc 821 if qNameIc != "" { 822 823 if err := r.SetQueryParam("name__ic", qNameIc); err != nil { 824 return err 825 } 826 } 827 } 828 829 if o.NameIe != nil { 830 831 // query param name__ie 832 var qrNameIe string 833 834 if o.NameIe != nil { 835 qrNameIe = *o.NameIe 836 } 837 qNameIe := qrNameIe 838 if qNameIe != "" { 839 840 if err := r.SetQueryParam("name__ie", qNameIe); err != nil { 841 return err 842 } 843 } 844 } 845 846 if o.NameIew != nil { 847 848 // query param name__iew 849 var qrNameIew string 850 851 if o.NameIew != nil { 852 qrNameIew = *o.NameIew 853 } 854 qNameIew := qrNameIew 855 if qNameIew != "" { 856 857 if err := r.SetQueryParam("name__iew", qNameIew); err != nil { 858 return err 859 } 860 } 861 } 862 863 if o.NameIsw != nil { 864 865 // query param name__isw 866 var qrNameIsw string 867 868 if o.NameIsw != nil { 869 qrNameIsw = *o.NameIsw 870 } 871 qNameIsw := qrNameIsw 872 if qNameIsw != "" { 873 874 if err := r.SetQueryParam("name__isw", qNameIsw); err != nil { 875 return err 876 } 877 } 878 } 879 880 if o.Namen != nil { 881 882 // query param name__n 883 var qrNamen string 884 885 if o.Namen != nil { 886 qrNamen = *o.Namen 887 } 888 qNamen := qrNamen 889 if qNamen != "" { 890 891 if err := r.SetQueryParam("name__n", qNamen); err != nil { 892 return err 893 } 894 } 895 } 896 897 if o.NameNic != nil { 898 899 // query param name__nic 900 var qrNameNic string 901 902 if o.NameNic != nil { 903 qrNameNic = *o.NameNic 904 } 905 qNameNic := qrNameNic 906 if qNameNic != "" { 907 908 if err := r.SetQueryParam("name__nic", qNameNic); err != nil { 909 return err 910 } 911 } 912 } 913 914 if o.NameNie != nil { 915 916 // query param name__nie 917 var qrNameNie string 918 919 if o.NameNie != nil { 920 qrNameNie = *o.NameNie 921 } 922 qNameNie := qrNameNie 923 if qNameNie != "" { 924 925 if err := r.SetQueryParam("name__nie", qNameNie); err != nil { 926 return err 927 } 928 } 929 } 930 931 if o.NameNiew != nil { 932 933 // query param name__niew 934 var qrNameNiew string 935 936 if o.NameNiew != nil { 937 qrNameNiew = *o.NameNiew 938 } 939 qNameNiew := qrNameNiew 940 if qNameNiew != "" { 941 942 if err := r.SetQueryParam("name__niew", qNameNiew); err != nil { 943 return err 944 } 945 } 946 } 947 948 if o.NameNisw != nil { 949 950 // query param name__nisw 951 var qrNameNisw string 952 953 if o.NameNisw != nil { 954 qrNameNisw = *o.NameNisw 955 } 956 qNameNisw := qrNameNisw 957 if qNameNisw != "" { 958 959 if err := r.SetQueryParam("name__nisw", qNameNisw); err != nil { 960 return err 961 } 962 } 963 } 964 965 if o.Offset != nil { 966 967 // query param offset 968 var qrOffset int64 969 970 if o.Offset != nil { 971 qrOffset = *o.Offset 972 } 973 qOffset := swag.FormatInt64(qrOffset) 974 if qOffset != "" { 975 976 if err := r.SetQueryParam("offset", qOffset); err != nil { 977 return err 978 } 979 } 980 } 981 982 if len(res) > 0 { 983 return errors.CompositeValidationError(res...) 984 } 985 return nil 986 }