github.com/cilium/cilium@v1.16.2/pkg/policy/api/zz_generated.deepequal.go (about) 1 //go:build !ignore_autogenerated 2 // +build !ignore_autogenerated 3 4 // SPDX-License-Identifier: Apache-2.0 5 // Copyright Authors of Cilium 6 7 // Code generated by deepequal-gen. DO NOT EDIT. 8 9 package api 10 11 // DeepEqual is an autogenerated deepequal function, deeply comparing the 12 // receiver with other. in must be non-nil. 13 func (in *AWSGroup) DeepEqual(other *AWSGroup) bool { 14 if other == nil { 15 return false 16 } 17 18 if ((in.Labels != nil) && (other.Labels != nil)) || ((in.Labels == nil) != (other.Labels == nil)) { 19 in, other := &in.Labels, &other.Labels 20 if other == nil { 21 return false 22 } 23 24 if len(*in) != len(*other) { 25 return false 26 } else { 27 for key, inValue := range *in { 28 if otherValue, present := (*other)[key]; !present { 29 return false 30 } else { 31 if inValue != otherValue { 32 return false 33 } 34 } 35 } 36 } 37 } 38 39 if ((in.SecurityGroupsIds != nil) && (other.SecurityGroupsIds != nil)) || ((in.SecurityGroupsIds == nil) != (other.SecurityGroupsIds == nil)) { 40 in, other := &in.SecurityGroupsIds, &other.SecurityGroupsIds 41 if other == nil { 42 return false 43 } 44 45 if len(*in) != len(*other) { 46 return false 47 } else { 48 for i, inElement := range *in { 49 if inElement != (*other)[i] { 50 return false 51 } 52 } 53 } 54 } 55 56 if ((in.SecurityGroupsNames != nil) && (other.SecurityGroupsNames != nil)) || ((in.SecurityGroupsNames == nil) != (other.SecurityGroupsNames == nil)) { 57 in, other := &in.SecurityGroupsNames, &other.SecurityGroupsNames 58 if other == nil { 59 return false 60 } 61 62 if len(*in) != len(*other) { 63 return false 64 } else { 65 for i, inElement := range *in { 66 if inElement != (*other)[i] { 67 return false 68 } 69 } 70 } 71 } 72 73 if in.Region != other.Region { 74 return false 75 } 76 77 return true 78 } 79 80 // DeepEqual is an autogenerated deepequal function, deeply comparing the 81 // receiver with other. in must be non-nil. 82 func (in *Authentication) DeepEqual(other *Authentication) bool { 83 if other == nil { 84 return false 85 } 86 87 if in.Mode != other.Mode { 88 return false 89 } 90 91 return true 92 } 93 94 // DeepEqual is an autogenerated deepequal function, deeply comparing the 95 // receiver with other. in must be non-nil. 96 func (in *CIDRRule) DeepEqual(other *CIDRRule) bool { 97 if other == nil { 98 return false 99 } 100 101 if in.Cidr != other.Cidr { 102 return false 103 } 104 if in.CIDRGroupRef != other.CIDRGroupRef { 105 return false 106 } 107 if ((in.ExceptCIDRs != nil) && (other.ExceptCIDRs != nil)) || ((in.ExceptCIDRs == nil) != (other.ExceptCIDRs == nil)) { 108 in, other := &in.ExceptCIDRs, &other.ExceptCIDRs 109 if other == nil { 110 return false 111 } 112 113 if len(*in) != len(*other) { 114 return false 115 } else { 116 for i, inElement := range *in { 117 if inElement != (*other)[i] { 118 return false 119 } 120 } 121 } 122 } 123 124 if in.Generated != other.Generated { 125 return false 126 } 127 128 return true 129 } 130 131 // DeepEqual is an autogenerated deepequal function, deeply comparing the 132 // receiver with other. in must be non-nil. 133 func (in *CIDRRuleSlice) DeepEqual(other *CIDRRuleSlice) bool { 134 if other == nil { 135 return false 136 } 137 138 if len(*in) != len(*other) { 139 return false 140 } else { 141 for i, inElement := range *in { 142 if !inElement.DeepEqual(&(*other)[i]) { 143 return false 144 } 145 } 146 } 147 148 return true 149 } 150 151 // DeepEqual is an autogenerated deepequal function, deeply comparing the 152 // receiver with other. in must be non-nil. 153 func (in *CIDRSlice) DeepEqual(other *CIDRSlice) bool { 154 if other == nil { 155 return false 156 } 157 158 if len(*in) != len(*other) { 159 return false 160 } else { 161 for i, inElement := range *in { 162 if inElement != (*other)[i] { 163 return false 164 } 165 } 166 } 167 168 return true 169 } 170 171 // DeepEqual is an autogenerated deepequal function, deeply comparing the 172 // receiver with other. in must be non-nil. 173 func (in *DefaultDenyConfig) DeepEqual(other *DefaultDenyConfig) bool { 174 if other == nil { 175 return false 176 } 177 178 if (in.Ingress == nil) != (other.Ingress == nil) { 179 return false 180 } else if in.Ingress != nil { 181 if *in.Ingress != *other.Ingress { 182 return false 183 } 184 } 185 186 if (in.Egress == nil) != (other.Egress == nil) { 187 return false 188 } else if in.Egress != nil { 189 if *in.Egress != *other.Egress { 190 return false 191 } 192 } 193 194 return true 195 } 196 197 // deepEqual is an autogenerated deepequal function, deeply comparing the 198 // receiver with other. in must be non-nil. 199 func (in *EgressCommonRule) deepEqual(other *EgressCommonRule) bool { 200 if other == nil { 201 return false 202 } 203 204 if ((in.ToEndpoints != nil) && (other.ToEndpoints != nil)) || ((in.ToEndpoints == nil) != (other.ToEndpoints == nil)) { 205 in, other := &in.ToEndpoints, &other.ToEndpoints 206 if other == nil { 207 return false 208 } 209 210 if len(*in) != len(*other) { 211 return false 212 } else { 213 for i, inElement := range *in { 214 if !inElement.DeepEqual(&(*other)[i]) { 215 return false 216 } 217 } 218 } 219 } 220 221 if ((in.ToRequires != nil) && (other.ToRequires != nil)) || ((in.ToRequires == nil) != (other.ToRequires == nil)) { 222 in, other := &in.ToRequires, &other.ToRequires 223 if other == nil { 224 return false 225 } 226 227 if len(*in) != len(*other) { 228 return false 229 } else { 230 for i, inElement := range *in { 231 if !inElement.DeepEqual(&(*other)[i]) { 232 return false 233 } 234 } 235 } 236 } 237 238 if ((in.ToCIDR != nil) && (other.ToCIDR != nil)) || ((in.ToCIDR == nil) != (other.ToCIDR == nil)) { 239 in, other := &in.ToCIDR, &other.ToCIDR 240 if other == nil || !in.DeepEqual(other) { 241 return false 242 } 243 } 244 245 if ((in.ToCIDRSet != nil) && (other.ToCIDRSet != nil)) || ((in.ToCIDRSet == nil) != (other.ToCIDRSet == nil)) { 246 in, other := &in.ToCIDRSet, &other.ToCIDRSet 247 if other == nil || !in.DeepEqual(other) { 248 return false 249 } 250 } 251 252 if ((in.ToEntities != nil) && (other.ToEntities != nil)) || ((in.ToEntities == nil) != (other.ToEntities == nil)) { 253 in, other := &in.ToEntities, &other.ToEntities 254 if other == nil || !in.DeepEqual(other) { 255 return false 256 } 257 } 258 259 if ((in.ToServices != nil) && (other.ToServices != nil)) || ((in.ToServices == nil) != (other.ToServices == nil)) { 260 in, other := &in.ToServices, &other.ToServices 261 if other == nil { 262 return false 263 } 264 265 if len(*in) != len(*other) { 266 return false 267 } else { 268 for i, inElement := range *in { 269 if !inElement.DeepEqual(&(*other)[i]) { 270 return false 271 } 272 } 273 } 274 } 275 276 if ((in.ToGroups != nil) && (other.ToGroups != nil)) || ((in.ToGroups == nil) != (other.ToGroups == nil)) { 277 in, other := &in.ToGroups, &other.ToGroups 278 if other == nil { 279 return false 280 } 281 282 if len(*in) != len(*other) { 283 return false 284 } else { 285 for i, inElement := range *in { 286 if !inElement.DeepEqual(&(*other)[i]) { 287 return false 288 } 289 } 290 } 291 } 292 293 if ((in.ToNodes != nil) && (other.ToNodes != nil)) || ((in.ToNodes == nil) != (other.ToNodes == nil)) { 294 in, other := &in.ToNodes, &other.ToNodes 295 if other == nil { 296 return false 297 } 298 299 if len(*in) != len(*other) { 300 return false 301 } else { 302 for i, inElement := range *in { 303 if !inElement.DeepEqual(&(*other)[i]) { 304 return false 305 } 306 } 307 } 308 } 309 310 if ((in.aggregatedSelectors != nil) && (other.aggregatedSelectors != nil)) || ((in.aggregatedSelectors == nil) != (other.aggregatedSelectors == nil)) { 311 in, other := &in.aggregatedSelectors, &other.aggregatedSelectors 312 if other == nil || !in.DeepEqual(other) { 313 return false 314 } 315 } 316 317 return true 318 } 319 320 // DeepEqual is an autogenerated deepequal function, deeply comparing the 321 // receiver with other. in must be non-nil. 322 func (in *EgressDenyRule) DeepEqual(other *EgressDenyRule) bool { 323 if other == nil { 324 return false 325 } 326 327 if !in.EgressCommonRule.DeepEqual(&other.EgressCommonRule) { 328 return false 329 } 330 331 if ((in.ToPorts != nil) && (other.ToPorts != nil)) || ((in.ToPorts == nil) != (other.ToPorts == nil)) { 332 in, other := &in.ToPorts, &other.ToPorts 333 if other == nil || !in.DeepEqual(other) { 334 return false 335 } 336 } 337 338 if ((in.ICMPs != nil) && (other.ICMPs != nil)) || ((in.ICMPs == nil) != (other.ICMPs == nil)) { 339 in, other := &in.ICMPs, &other.ICMPs 340 if other == nil || !in.DeepEqual(other) { 341 return false 342 } 343 } 344 345 return true 346 } 347 348 // DeepEqual is an autogenerated deepequal function, deeply comparing the 349 // receiver with other. in must be non-nil. 350 func (in *EgressRule) DeepEqual(other *EgressRule) bool { 351 if other == nil { 352 return false 353 } 354 355 if !in.EgressCommonRule.DeepEqual(&other.EgressCommonRule) { 356 return false 357 } 358 359 if ((in.ToPorts != nil) && (other.ToPorts != nil)) || ((in.ToPorts == nil) != (other.ToPorts == nil)) { 360 in, other := &in.ToPorts, &other.ToPorts 361 if other == nil || !in.DeepEqual(other) { 362 return false 363 } 364 } 365 366 if ((in.ToFQDNs != nil) && (other.ToFQDNs != nil)) || ((in.ToFQDNs == nil) != (other.ToFQDNs == nil)) { 367 in, other := &in.ToFQDNs, &other.ToFQDNs 368 if other == nil || !in.DeepEqual(other) { 369 return false 370 } 371 } 372 373 if ((in.ICMPs != nil) && (other.ICMPs != nil)) || ((in.ICMPs == nil) != (other.ICMPs == nil)) { 374 in, other := &in.ICMPs, &other.ICMPs 375 if other == nil || !in.DeepEqual(other) { 376 return false 377 } 378 } 379 380 if (in.Authentication == nil) != (other.Authentication == nil) { 381 return false 382 } else if in.Authentication != nil { 383 if !in.Authentication.DeepEqual(other.Authentication) { 384 return false 385 } 386 } 387 388 return true 389 } 390 391 // DeepEqual is an autogenerated deepequal function, deeply comparing the 392 // receiver with other. in must be non-nil. 393 func (in *EndpointSelector) DeepEqual(other *EndpointSelector) bool { 394 if other == nil { 395 return false 396 } 397 398 if (in.LabelSelector == nil) != (other.LabelSelector == nil) { 399 return false 400 } else if in.LabelSelector != nil { 401 if !in.LabelSelector.DeepEqual(other.LabelSelector) { 402 return false 403 } 404 } 405 406 if (in.requirements == nil) != (other.requirements == nil) { 407 return false 408 } else if in.requirements != nil { 409 if !in.requirements.DeepEqual(other.requirements) { 410 return false 411 } 412 } 413 414 if in.cachedLabelSelectorString != other.cachedLabelSelectorString { 415 return false 416 } 417 418 return true 419 } 420 421 // DeepEqual is an autogenerated deepequal function, deeply comparing the 422 // receiver with other. in must be non-nil. 423 func (in *EndpointSelectorSlice) DeepEqual(other *EndpointSelectorSlice) bool { 424 if other == nil { 425 return false 426 } 427 428 if len(*in) != len(*other) { 429 return false 430 } else { 431 for i, inElement := range *in { 432 if !inElement.DeepEqual(&(*other)[i]) { 433 return false 434 } 435 } 436 } 437 438 return true 439 } 440 441 // DeepEqual is an autogenerated deepequal function, deeply comparing the 442 // receiver with other. in must be non-nil. 443 func (in *EntitySlice) DeepEqual(other *EntitySlice) bool { 444 if other == nil { 445 return false 446 } 447 448 if len(*in) != len(*other) { 449 return false 450 } else { 451 for i, inElement := range *in { 452 if inElement != (*other)[i] { 453 return false 454 } 455 } 456 } 457 458 return true 459 } 460 461 // DeepEqual is an autogenerated deepequal function, deeply comparing the 462 // receiver with other. in must be non-nil. 463 func (in *EnvoyConfig) DeepEqual(other *EnvoyConfig) bool { 464 if other == nil { 465 return false 466 } 467 468 if in.Kind != other.Kind { 469 return false 470 } 471 if in.Name != other.Name { 472 return false 473 } 474 475 return true 476 } 477 478 // DeepEqual is an autogenerated deepequal function, deeply comparing the 479 // receiver with other. in must be non-nil. 480 func (in *FQDNSelector) DeepEqual(other *FQDNSelector) bool { 481 if other == nil { 482 return false 483 } 484 485 if in.MatchName != other.MatchName { 486 return false 487 } 488 if in.MatchPattern != other.MatchPattern { 489 return false 490 } 491 492 return true 493 } 494 495 // DeepEqual is an autogenerated deepequal function, deeply comparing the 496 // receiver with other. in must be non-nil. 497 func (in *FQDNSelectorSlice) DeepEqual(other *FQDNSelectorSlice) bool { 498 if other == nil { 499 return false 500 } 501 502 if len(*in) != len(*other) { 503 return false 504 } else { 505 for i, inElement := range *in { 506 if !inElement.DeepEqual(&(*other)[i]) { 507 return false 508 } 509 } 510 } 511 512 return true 513 } 514 515 // DeepEqual is an autogenerated deepequal function, deeply comparing the 516 // receiver with other. in must be non-nil. 517 func (in *Groups) DeepEqual(other *Groups) bool { 518 if other == nil { 519 return false 520 } 521 522 if (in.AWS == nil) != (other.AWS == nil) { 523 return false 524 } else if in.AWS != nil { 525 if !in.AWS.DeepEqual(other.AWS) { 526 return false 527 } 528 } 529 530 return true 531 } 532 533 // DeepEqual is an autogenerated deepequal function, deeply comparing the 534 // receiver with other. in must be non-nil. 535 func (in *HeaderMatch) DeepEqual(other *HeaderMatch) bool { 536 if other == nil { 537 return false 538 } 539 540 if in.Mismatch != other.Mismatch { 541 return false 542 } 543 if in.Name != other.Name { 544 return false 545 } 546 if (in.Secret == nil) != (other.Secret == nil) { 547 return false 548 } else if in.Secret != nil { 549 if !in.Secret.DeepEqual(other.Secret) { 550 return false 551 } 552 } 553 554 if in.Value != other.Value { 555 return false 556 } 557 558 return true 559 } 560 561 // deepEqual is an autogenerated deepequal function, deeply comparing the 562 // receiver with other. in must be non-nil. 563 func (in *ICMPField) deepEqual(other *ICMPField) bool { 564 if other == nil { 565 return false 566 } 567 568 if in.Family != other.Family { 569 return false 570 } 571 572 return true 573 } 574 575 // DeepEqual is an autogenerated deepequal function, deeply comparing the 576 // receiver with other. in must be non-nil. 577 func (in *ICMPRule) DeepEqual(other *ICMPRule) bool { 578 if other == nil { 579 return false 580 } 581 582 if ((in.Fields != nil) && (other.Fields != nil)) || ((in.Fields == nil) != (other.Fields == nil)) { 583 in, other := &in.Fields, &other.Fields 584 if other == nil { 585 return false 586 } 587 588 if len(*in) != len(*other) { 589 return false 590 } else { 591 for i, inElement := range *in { 592 if !inElement.DeepEqual(&(*other)[i]) { 593 return false 594 } 595 } 596 } 597 } 598 599 return true 600 } 601 602 // DeepEqual is an autogenerated deepequal function, deeply comparing the 603 // receiver with other. in must be non-nil. 604 func (in *ICMPRules) DeepEqual(other *ICMPRules) bool { 605 if other == nil { 606 return false 607 } 608 609 if len(*in) != len(*other) { 610 return false 611 } else { 612 for i, inElement := range *in { 613 if !inElement.DeepEqual(&(*other)[i]) { 614 return false 615 } 616 } 617 } 618 619 return true 620 } 621 622 // deepEqual is an autogenerated deepequal function, deeply comparing the 623 // receiver with other. in must be non-nil. 624 func (in *IngressCommonRule) deepEqual(other *IngressCommonRule) bool { 625 if other == nil { 626 return false 627 } 628 629 if ((in.FromEndpoints != nil) && (other.FromEndpoints != nil)) || ((in.FromEndpoints == nil) != (other.FromEndpoints == nil)) { 630 in, other := &in.FromEndpoints, &other.FromEndpoints 631 if other == nil { 632 return false 633 } 634 635 if len(*in) != len(*other) { 636 return false 637 } else { 638 for i, inElement := range *in { 639 if !inElement.DeepEqual(&(*other)[i]) { 640 return false 641 } 642 } 643 } 644 } 645 646 if ((in.FromRequires != nil) && (other.FromRequires != nil)) || ((in.FromRequires == nil) != (other.FromRequires == nil)) { 647 in, other := &in.FromRequires, &other.FromRequires 648 if other == nil { 649 return false 650 } 651 652 if len(*in) != len(*other) { 653 return false 654 } else { 655 for i, inElement := range *in { 656 if !inElement.DeepEqual(&(*other)[i]) { 657 return false 658 } 659 } 660 } 661 } 662 663 if ((in.FromCIDR != nil) && (other.FromCIDR != nil)) || ((in.FromCIDR == nil) != (other.FromCIDR == nil)) { 664 in, other := &in.FromCIDR, &other.FromCIDR 665 if other == nil || !in.DeepEqual(other) { 666 return false 667 } 668 } 669 670 if ((in.FromCIDRSet != nil) && (other.FromCIDRSet != nil)) || ((in.FromCIDRSet == nil) != (other.FromCIDRSet == nil)) { 671 in, other := &in.FromCIDRSet, &other.FromCIDRSet 672 if other == nil || !in.DeepEqual(other) { 673 return false 674 } 675 } 676 677 if ((in.FromEntities != nil) && (other.FromEntities != nil)) || ((in.FromEntities == nil) != (other.FromEntities == nil)) { 678 in, other := &in.FromEntities, &other.FromEntities 679 if other == nil || !in.DeepEqual(other) { 680 return false 681 } 682 } 683 684 if ((in.FromGroups != nil) && (other.FromGroups != nil)) || ((in.FromGroups == nil) != (other.FromGroups == nil)) { 685 in, other := &in.FromGroups, &other.FromGroups 686 if other == nil { 687 return false 688 } 689 690 if len(*in) != len(*other) { 691 return false 692 } else { 693 for i, inElement := range *in { 694 if !inElement.DeepEqual(&(*other)[i]) { 695 return false 696 } 697 } 698 } 699 } 700 701 if ((in.FromNodes != nil) && (other.FromNodes != nil)) || ((in.FromNodes == nil) != (other.FromNodes == nil)) { 702 in, other := &in.FromNodes, &other.FromNodes 703 if other == nil { 704 return false 705 } 706 707 if len(*in) != len(*other) { 708 return false 709 } else { 710 for i, inElement := range *in { 711 if !inElement.DeepEqual(&(*other)[i]) { 712 return false 713 } 714 } 715 } 716 } 717 718 if ((in.aggregatedSelectors != nil) && (other.aggregatedSelectors != nil)) || ((in.aggregatedSelectors == nil) != (other.aggregatedSelectors == nil)) { 719 in, other := &in.aggregatedSelectors, &other.aggregatedSelectors 720 if other == nil || !in.DeepEqual(other) { 721 return false 722 } 723 } 724 725 return true 726 } 727 728 // DeepEqual is an autogenerated deepequal function, deeply comparing the 729 // receiver with other. in must be non-nil. 730 func (in *IngressDenyRule) DeepEqual(other *IngressDenyRule) bool { 731 if other == nil { 732 return false 733 } 734 735 if !in.IngressCommonRule.DeepEqual(&other.IngressCommonRule) { 736 return false 737 } 738 739 if ((in.ToPorts != nil) && (other.ToPorts != nil)) || ((in.ToPorts == nil) != (other.ToPorts == nil)) { 740 in, other := &in.ToPorts, &other.ToPorts 741 if other == nil || !in.DeepEqual(other) { 742 return false 743 } 744 } 745 746 if ((in.ICMPs != nil) && (other.ICMPs != nil)) || ((in.ICMPs == nil) != (other.ICMPs == nil)) { 747 in, other := &in.ICMPs, &other.ICMPs 748 if other == nil || !in.DeepEqual(other) { 749 return false 750 } 751 } 752 753 return true 754 } 755 756 // DeepEqual is an autogenerated deepequal function, deeply comparing the 757 // receiver with other. in must be non-nil. 758 func (in *IngressRule) DeepEqual(other *IngressRule) bool { 759 if other == nil { 760 return false 761 } 762 763 if !in.IngressCommonRule.DeepEqual(&other.IngressCommonRule) { 764 return false 765 } 766 767 if ((in.ToPorts != nil) && (other.ToPorts != nil)) || ((in.ToPorts == nil) != (other.ToPorts == nil)) { 768 in, other := &in.ToPorts, &other.ToPorts 769 if other == nil || !in.DeepEqual(other) { 770 return false 771 } 772 } 773 774 if ((in.ICMPs != nil) && (other.ICMPs != nil)) || ((in.ICMPs == nil) != (other.ICMPs == nil)) { 775 in, other := &in.ICMPs, &other.ICMPs 776 if other == nil || !in.DeepEqual(other) { 777 return false 778 } 779 } 780 781 if (in.Authentication == nil) != (other.Authentication == nil) { 782 return false 783 } else if in.Authentication != nil { 784 if !in.Authentication.DeepEqual(other.Authentication) { 785 return false 786 } 787 } 788 789 return true 790 } 791 792 // DeepEqual is an autogenerated deepequal function, deeply comparing the 793 // receiver with other. in must be non-nil. 794 func (in *K8sServiceNamespace) DeepEqual(other *K8sServiceNamespace) bool { 795 if other == nil { 796 return false 797 } 798 799 if in.ServiceName != other.ServiceName { 800 return false 801 } 802 if in.Namespace != other.Namespace { 803 return false 804 } 805 806 return true 807 } 808 809 // DeepEqual is an autogenerated deepequal function, deeply comparing the 810 // receiver with other. in must be non-nil. 811 func (in *K8sServiceSelectorNamespace) DeepEqual(other *K8sServiceSelectorNamespace) bool { 812 if other == nil { 813 return false 814 } 815 816 if !in.Selector.DeepEqual(&other.Selector) { 817 return false 818 } 819 820 if in.Namespace != other.Namespace { 821 return false 822 } 823 824 return true 825 } 826 827 // DeepEqual is an autogenerated deepequal function, deeply comparing the 828 // receiver with other. in must be non-nil. 829 func (in *L7Rules) DeepEqual(other *L7Rules) bool { 830 if other == nil { 831 return false 832 } 833 834 if ((in.HTTP != nil) && (other.HTTP != nil)) || ((in.HTTP == nil) != (other.HTTP == nil)) { 835 in, other := &in.HTTP, &other.HTTP 836 if other == nil { 837 return false 838 } 839 840 if len(*in) != len(*other) { 841 return false 842 } else { 843 for i, inElement := range *in { 844 if !inElement.DeepEqual(&(*other)[i]) { 845 return false 846 } 847 } 848 } 849 } 850 851 if ((in.Kafka != nil) && (other.Kafka != nil)) || ((in.Kafka == nil) != (other.Kafka == nil)) { 852 in, other := &in.Kafka, &other.Kafka 853 if other == nil { 854 return false 855 } 856 857 if len(*in) != len(*other) { 858 return false 859 } else { 860 for i, inElement := range *in { 861 if !inElement.DeepEqual(&(*other)[i]) { 862 return false 863 } 864 } 865 } 866 } 867 868 if ((in.DNS != nil) && (other.DNS != nil)) || ((in.DNS == nil) != (other.DNS == nil)) { 869 in, other := &in.DNS, &other.DNS 870 if other == nil { 871 return false 872 } 873 874 if len(*in) != len(*other) { 875 return false 876 } else { 877 for i, inElement := range *in { 878 if !inElement.DeepEqual(&(*other)[i]) { 879 return false 880 } 881 } 882 } 883 } 884 885 if in.L7Proto != other.L7Proto { 886 return false 887 } 888 if ((in.L7 != nil) && (other.L7 != nil)) || ((in.L7 == nil) != (other.L7 == nil)) { 889 in, other := &in.L7, &other.L7 890 if other == nil { 891 return false 892 } 893 894 if len(*in) != len(*other) { 895 return false 896 } else { 897 for i, inElement := range *in { 898 if !inElement.DeepEqual(&(*other)[i]) { 899 return false 900 } 901 } 902 } 903 } 904 905 return true 906 } 907 908 // DeepEqual is an autogenerated deepequal function, deeply comparing the 909 // receiver with other. in must be non-nil. 910 func (in *Listener) DeepEqual(other *Listener) bool { 911 if other == nil { 912 return false 913 } 914 915 if (in.EnvoyConfig == nil) != (other.EnvoyConfig == nil) { 916 return false 917 } else if in.EnvoyConfig != nil { 918 if !in.EnvoyConfig.DeepEqual(other.EnvoyConfig) { 919 return false 920 } 921 } 922 923 if in.Name != other.Name { 924 return false 925 } 926 if in.Priority != other.Priority { 927 return false 928 } 929 930 return true 931 } 932 933 // DeepEqual is an autogenerated deepequal function, deeply comparing the 934 // receiver with other. in must be non-nil. 935 func (in *PortDenyRule) DeepEqual(other *PortDenyRule) bool { 936 if other == nil { 937 return false 938 } 939 940 if ((in.Ports != nil) && (other.Ports != nil)) || ((in.Ports == nil) != (other.Ports == nil)) { 941 in, other := &in.Ports, &other.Ports 942 if other == nil { 943 return false 944 } 945 946 if len(*in) != len(*other) { 947 return false 948 } else { 949 for i, inElement := range *in { 950 if !inElement.DeepEqual(&(*other)[i]) { 951 return false 952 } 953 } 954 } 955 } 956 957 return true 958 } 959 960 // DeepEqual is an autogenerated deepequal function, deeply comparing the 961 // receiver with other. in must be non-nil. 962 func (in *PortDenyRules) DeepEqual(other *PortDenyRules) bool { 963 if other == nil { 964 return false 965 } 966 967 if len(*in) != len(*other) { 968 return false 969 } else { 970 for i, inElement := range *in { 971 if !inElement.DeepEqual(&(*other)[i]) { 972 return false 973 } 974 } 975 } 976 977 return true 978 } 979 980 // DeepEqual is an autogenerated deepequal function, deeply comparing the 981 // receiver with other. in must be non-nil. 982 func (in *PortProtocol) DeepEqual(other *PortProtocol) bool { 983 if other == nil { 984 return false 985 } 986 987 if in.Port != other.Port { 988 return false 989 } 990 if in.EndPort != other.EndPort { 991 return false 992 } 993 if in.Protocol != other.Protocol { 994 return false 995 } 996 997 return true 998 } 999 1000 // DeepEqual is an autogenerated deepequal function, deeply comparing the 1001 // receiver with other. in must be non-nil. 1002 func (in *PortRule) DeepEqual(other *PortRule) bool { 1003 if other == nil { 1004 return false 1005 } 1006 1007 if ((in.Ports != nil) && (other.Ports != nil)) || ((in.Ports == nil) != (other.Ports == nil)) { 1008 in, other := &in.Ports, &other.Ports 1009 if other == nil { 1010 return false 1011 } 1012 1013 if len(*in) != len(*other) { 1014 return false 1015 } else { 1016 for i, inElement := range *in { 1017 if !inElement.DeepEqual(&(*other)[i]) { 1018 return false 1019 } 1020 } 1021 } 1022 } 1023 1024 if (in.TerminatingTLS == nil) != (other.TerminatingTLS == nil) { 1025 return false 1026 } else if in.TerminatingTLS != nil { 1027 if !in.TerminatingTLS.DeepEqual(other.TerminatingTLS) { 1028 return false 1029 } 1030 } 1031 1032 if (in.OriginatingTLS == nil) != (other.OriginatingTLS == nil) { 1033 return false 1034 } else if in.OriginatingTLS != nil { 1035 if !in.OriginatingTLS.DeepEqual(other.OriginatingTLS) { 1036 return false 1037 } 1038 } 1039 1040 if ((in.ServerNames != nil) && (other.ServerNames != nil)) || ((in.ServerNames == nil) != (other.ServerNames == nil)) { 1041 in, other := &in.ServerNames, &other.ServerNames 1042 if other == nil { 1043 return false 1044 } 1045 1046 if len(*in) != len(*other) { 1047 return false 1048 } else { 1049 for i, inElement := range *in { 1050 if inElement != (*other)[i] { 1051 return false 1052 } 1053 } 1054 } 1055 } 1056 1057 if (in.Listener == nil) != (other.Listener == nil) { 1058 return false 1059 } else if in.Listener != nil { 1060 if !in.Listener.DeepEqual(other.Listener) { 1061 return false 1062 } 1063 } 1064 1065 if (in.Rules == nil) != (other.Rules == nil) { 1066 return false 1067 } else if in.Rules != nil { 1068 if !in.Rules.DeepEqual(other.Rules) { 1069 return false 1070 } 1071 } 1072 1073 return true 1074 } 1075 1076 // DeepEqual is an autogenerated deepequal function, deeply comparing the 1077 // receiver with other. in must be non-nil. 1078 func (in *PortRuleDNS) DeepEqual(other *PortRuleDNS) bool { 1079 if other == nil { 1080 return false 1081 } 1082 1083 if in.MatchName != other.MatchName { 1084 return false 1085 } 1086 if in.MatchPattern != other.MatchPattern { 1087 return false 1088 } 1089 1090 return true 1091 } 1092 1093 // DeepEqual is an autogenerated deepequal function, deeply comparing the 1094 // receiver with other. in must be non-nil. 1095 func (in *PortRuleHTTP) DeepEqual(other *PortRuleHTTP) bool { 1096 if other == nil { 1097 return false 1098 } 1099 1100 if in.Path != other.Path { 1101 return false 1102 } 1103 if in.Method != other.Method { 1104 return false 1105 } 1106 if in.Host != other.Host { 1107 return false 1108 } 1109 if ((in.Headers != nil) && (other.Headers != nil)) || ((in.Headers == nil) != (other.Headers == nil)) { 1110 in, other := &in.Headers, &other.Headers 1111 if other == nil { 1112 return false 1113 } 1114 1115 if len(*in) != len(*other) { 1116 return false 1117 } else { 1118 for i, inElement := range *in { 1119 if inElement != (*other)[i] { 1120 return false 1121 } 1122 } 1123 } 1124 } 1125 1126 if ((in.HeaderMatches != nil) && (other.HeaderMatches != nil)) || ((in.HeaderMatches == nil) != (other.HeaderMatches == nil)) { 1127 in, other := &in.HeaderMatches, &other.HeaderMatches 1128 if other == nil { 1129 return false 1130 } 1131 1132 if len(*in) != len(*other) { 1133 return false 1134 } else { 1135 for i, inElement := range *in { 1136 if !inElement.DeepEqual((*other)[i]) { 1137 return false 1138 } 1139 } 1140 } 1141 } 1142 1143 return true 1144 } 1145 1146 // DeepEqual is an autogenerated deepequal function, deeply comparing the 1147 // receiver with other. in must be non-nil. 1148 func (in *PortRuleL7) DeepEqual(other *PortRuleL7) bool { 1149 if other == nil { 1150 return false 1151 } 1152 1153 if len(*in) != len(*other) { 1154 return false 1155 } else { 1156 for key, inValue := range *in { 1157 if otherValue, present := (*other)[key]; !present { 1158 return false 1159 } else { 1160 if inValue != otherValue { 1161 return false 1162 } 1163 } 1164 } 1165 } 1166 1167 return true 1168 } 1169 1170 // DeepEqual is an autogenerated deepequal function, deeply comparing the 1171 // receiver with other. in must be non-nil. 1172 func (in *PortRules) DeepEqual(other *PortRules) bool { 1173 if other == nil { 1174 return false 1175 } 1176 1177 if len(*in) != len(*other) { 1178 return false 1179 } else { 1180 for i, inElement := range *in { 1181 if !inElement.DeepEqual(&(*other)[i]) { 1182 return false 1183 } 1184 } 1185 } 1186 1187 return true 1188 } 1189 1190 // deepEqual is an autogenerated deepequal function, deeply comparing the 1191 // receiver with other. in must be non-nil. 1192 func (in *Rule) deepEqual(other *Rule) bool { 1193 if other == nil { 1194 return false 1195 } 1196 1197 if !in.EndpointSelector.DeepEqual(&other.EndpointSelector) { 1198 return false 1199 } 1200 1201 if !in.NodeSelector.DeepEqual(&other.NodeSelector) { 1202 return false 1203 } 1204 1205 if ((in.Ingress != nil) && (other.Ingress != nil)) || ((in.Ingress == nil) != (other.Ingress == nil)) { 1206 in, other := &in.Ingress, &other.Ingress 1207 if other == nil { 1208 return false 1209 } 1210 1211 if len(*in) != len(*other) { 1212 return false 1213 } else { 1214 for i, inElement := range *in { 1215 if !inElement.DeepEqual(&(*other)[i]) { 1216 return false 1217 } 1218 } 1219 } 1220 } 1221 1222 if ((in.IngressDeny != nil) && (other.IngressDeny != nil)) || ((in.IngressDeny == nil) != (other.IngressDeny == nil)) { 1223 in, other := &in.IngressDeny, &other.IngressDeny 1224 if other == nil { 1225 return false 1226 } 1227 1228 if len(*in) != len(*other) { 1229 return false 1230 } else { 1231 for i, inElement := range *in { 1232 if !inElement.DeepEqual(&(*other)[i]) { 1233 return false 1234 } 1235 } 1236 } 1237 } 1238 1239 if ((in.Egress != nil) && (other.Egress != nil)) || ((in.Egress == nil) != (other.Egress == nil)) { 1240 in, other := &in.Egress, &other.Egress 1241 if other == nil { 1242 return false 1243 } 1244 1245 if len(*in) != len(*other) { 1246 return false 1247 } else { 1248 for i, inElement := range *in { 1249 if !inElement.DeepEqual(&(*other)[i]) { 1250 return false 1251 } 1252 } 1253 } 1254 } 1255 1256 if ((in.EgressDeny != nil) && (other.EgressDeny != nil)) || ((in.EgressDeny == nil) != (other.EgressDeny == nil)) { 1257 in, other := &in.EgressDeny, &other.EgressDeny 1258 if other == nil { 1259 return false 1260 } 1261 1262 if len(*in) != len(*other) { 1263 return false 1264 } else { 1265 for i, inElement := range *in { 1266 if !inElement.DeepEqual(&(*other)[i]) { 1267 return false 1268 } 1269 } 1270 } 1271 } 1272 1273 if ((in.Labels != nil) && (other.Labels != nil)) || ((in.Labels == nil) != (other.Labels == nil)) { 1274 in, other := &in.Labels, &other.Labels 1275 if other == nil || !in.DeepEqual(other) { 1276 return false 1277 } 1278 } 1279 1280 if !in.EnableDefaultDeny.DeepEqual(&other.EnableDefaultDeny) { 1281 return false 1282 } 1283 1284 if in.Description != other.Description { 1285 return false 1286 } 1287 1288 return true 1289 } 1290 1291 // deepEqual is an autogenerated deepequal function, deeply comparing the 1292 // receiver with other. in must be non-nil. 1293 func (in *Rules) deepEqual(other *Rules) bool { 1294 if other == nil { 1295 return false 1296 } 1297 1298 if len(*in) != len(*other) { 1299 return false 1300 } else { 1301 for i, inElement := range *in { 1302 if !inElement.DeepEqual((*other)[i]) { 1303 return false 1304 } 1305 } 1306 } 1307 1308 return true 1309 } 1310 1311 // DeepEqual is an autogenerated deepequal function, deeply comparing the 1312 // receiver with other. in must be non-nil. 1313 func (in *Secret) DeepEqual(other *Secret) bool { 1314 if other == nil { 1315 return false 1316 } 1317 1318 if in.Namespace != other.Namespace { 1319 return false 1320 } 1321 if in.Name != other.Name { 1322 return false 1323 } 1324 1325 return true 1326 } 1327 1328 // DeepEqual is an autogenerated deepequal function, deeply comparing the 1329 // receiver with other. in must be non-nil. 1330 func (in *Service) DeepEqual(other *Service) bool { 1331 if other == nil { 1332 return false 1333 } 1334 1335 if (in.K8sServiceSelector == nil) != (other.K8sServiceSelector == nil) { 1336 return false 1337 } else if in.K8sServiceSelector != nil { 1338 if !in.K8sServiceSelector.DeepEqual(other.K8sServiceSelector) { 1339 return false 1340 } 1341 } 1342 1343 if (in.K8sService == nil) != (other.K8sService == nil) { 1344 return false 1345 } else if in.K8sService != nil { 1346 if !in.K8sService.DeepEqual(other.K8sService) { 1347 return false 1348 } 1349 } 1350 1351 return true 1352 } 1353 1354 // DeepEqual is an autogenerated deepequal function, deeply comparing the 1355 // receiver with other. in must be non-nil. 1356 func (in *ServiceSelector) DeepEqual(other *ServiceSelector) bool { 1357 if other == nil { 1358 return false 1359 } 1360 1361 if (in.LabelSelector == nil) != (other.LabelSelector == nil) { 1362 return false 1363 } else if in.LabelSelector != nil { 1364 if !in.LabelSelector.DeepEqual(other.LabelSelector) { 1365 return false 1366 } 1367 } 1368 1369 if (in.requirements == nil) != (other.requirements == nil) { 1370 return false 1371 } else if in.requirements != nil { 1372 if !in.requirements.DeepEqual(other.requirements) { 1373 return false 1374 } 1375 } 1376 1377 if in.cachedLabelSelectorString != other.cachedLabelSelectorString { 1378 return false 1379 } 1380 1381 return true 1382 } 1383 1384 // DeepEqual is an autogenerated deepequal function, deeply comparing the 1385 // receiver with other. in must be non-nil. 1386 func (in *TLSContext) DeepEqual(other *TLSContext) bool { 1387 if other == nil { 1388 return false 1389 } 1390 1391 if (in.Secret == nil) != (other.Secret == nil) { 1392 return false 1393 } else if in.Secret != nil { 1394 if !in.Secret.DeepEqual(other.Secret) { 1395 return false 1396 } 1397 } 1398 1399 if in.TrustedCA != other.TrustedCA { 1400 return false 1401 } 1402 if in.Certificate != other.Certificate { 1403 return false 1404 } 1405 if in.PrivateKey != other.PrivateKey { 1406 return false 1407 } 1408 1409 return true 1410 }