servicereference.go 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. /*
  2. Copyright The Kubernetes Authors.
  3. Licensed under the Apache License, Version 2.0 (the "License");
  4. you may not use this file except in compliance with the License.
  5. You may obtain a copy of the License at
  6. http://www.apache.org/licenses/LICENSE-2.0
  7. Unless required by applicable law or agreed to in writing, software
  8. distributed under the License is distributed on an "AS IS" BASIS,
  9. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  10. See the License for the specific language governing permissions and
  11. limitations under the License.
  12. */
  13. // Code generated by applyconfiguration-gen. DO NOT EDIT.
  14. package v1beta1
  15. // ServiceReferenceApplyConfiguration represents an declarative configuration of the ServiceReference type for use
  16. // with apply.
  17. type ServiceReferenceApplyConfiguration struct {
  18. Namespace *string `json:"namespace,omitempty"`
  19. Name *string `json:"name,omitempty"`
  20. Path *string `json:"path,omitempty"`
  21. Port *int32 `json:"port,omitempty"`
  22. }
  23. // ServiceReferenceApplyConfiguration constructs an declarative configuration of the ServiceReference type for use with
  24. // apply.
  25. func ServiceReference() *ServiceReferenceApplyConfiguration {
  26. return &ServiceReferenceApplyConfiguration{}
  27. }
  28. // WithNamespace sets the Namespace field in the declarative configuration to the given value
  29. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  30. // If called multiple times, the Namespace field is set to the value of the last call.
  31. func (b *ServiceReferenceApplyConfiguration) WithNamespace(value string) *ServiceReferenceApplyConfiguration {
  32. b.Namespace = &value
  33. return b
  34. }
  35. // WithName sets the Name field in the declarative configuration to the given value
  36. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  37. // If called multiple times, the Name field is set to the value of the last call.
  38. func (b *ServiceReferenceApplyConfiguration) WithName(value string) *ServiceReferenceApplyConfiguration {
  39. b.Name = &value
  40. return b
  41. }
  42. // WithPath sets the Path field in the declarative configuration to the given value
  43. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  44. // If called multiple times, the Path field is set to the value of the last call.
  45. func (b *ServiceReferenceApplyConfiguration) WithPath(value string) *ServiceReferenceApplyConfiguration {
  46. b.Path = &value
  47. return b
  48. }
  49. // WithPort sets the Port field in the declarative configuration to the given value
  50. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  51. // If called multiple times, the Port field is set to the value of the last call.
  52. func (b *ServiceReferenceApplyConfiguration) WithPort(value int32) *ServiceReferenceApplyConfiguration {
  53. b.Port = &value
  54. return b
  55. }