statefulsetstatus.go 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  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 v1
  15. // StatefulSetStatusApplyConfiguration represents an declarative configuration of the StatefulSetStatus type for use
  16. // with apply.
  17. type StatefulSetStatusApplyConfiguration struct {
  18. ObservedGeneration *int64 `json:"observedGeneration,omitempty"`
  19. Replicas *int32 `json:"replicas,omitempty"`
  20. ReadyReplicas *int32 `json:"readyReplicas,omitempty"`
  21. CurrentReplicas *int32 `json:"currentReplicas,omitempty"`
  22. UpdatedReplicas *int32 `json:"updatedReplicas,omitempty"`
  23. CurrentRevision *string `json:"currentRevision,omitempty"`
  24. UpdateRevision *string `json:"updateRevision,omitempty"`
  25. CollisionCount *int32 `json:"collisionCount,omitempty"`
  26. Conditions []StatefulSetConditionApplyConfiguration `json:"conditions,omitempty"`
  27. AvailableReplicas *int32 `json:"availableReplicas,omitempty"`
  28. }
  29. // StatefulSetStatusApplyConfiguration constructs an declarative configuration of the StatefulSetStatus type for use with
  30. // apply.
  31. func StatefulSetStatus() *StatefulSetStatusApplyConfiguration {
  32. return &StatefulSetStatusApplyConfiguration{}
  33. }
  34. // WithObservedGeneration sets the ObservedGeneration field in the declarative configuration to the given value
  35. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  36. // If called multiple times, the ObservedGeneration field is set to the value of the last call.
  37. func (b *StatefulSetStatusApplyConfiguration) WithObservedGeneration(value int64) *StatefulSetStatusApplyConfiguration {
  38. b.ObservedGeneration = &value
  39. return b
  40. }
  41. // WithReplicas sets the Replicas field in the declarative configuration to the given value
  42. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  43. // If called multiple times, the Replicas field is set to the value of the last call.
  44. func (b *StatefulSetStatusApplyConfiguration) WithReplicas(value int32) *StatefulSetStatusApplyConfiguration {
  45. b.Replicas = &value
  46. return b
  47. }
  48. // WithReadyReplicas sets the ReadyReplicas field in the declarative configuration to the given value
  49. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  50. // If called multiple times, the ReadyReplicas field is set to the value of the last call.
  51. func (b *StatefulSetStatusApplyConfiguration) WithReadyReplicas(value int32) *StatefulSetStatusApplyConfiguration {
  52. b.ReadyReplicas = &value
  53. return b
  54. }
  55. // WithCurrentReplicas sets the CurrentReplicas field in the declarative configuration to the given value
  56. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  57. // If called multiple times, the CurrentReplicas field is set to the value of the last call.
  58. func (b *StatefulSetStatusApplyConfiguration) WithCurrentReplicas(value int32) *StatefulSetStatusApplyConfiguration {
  59. b.CurrentReplicas = &value
  60. return b
  61. }
  62. // WithUpdatedReplicas sets the UpdatedReplicas field in the declarative configuration to the given value
  63. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  64. // If called multiple times, the UpdatedReplicas field is set to the value of the last call.
  65. func (b *StatefulSetStatusApplyConfiguration) WithUpdatedReplicas(value int32) *StatefulSetStatusApplyConfiguration {
  66. b.UpdatedReplicas = &value
  67. return b
  68. }
  69. // WithCurrentRevision sets the CurrentRevision field in the declarative configuration to the given value
  70. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  71. // If called multiple times, the CurrentRevision field is set to the value of the last call.
  72. func (b *StatefulSetStatusApplyConfiguration) WithCurrentRevision(value string) *StatefulSetStatusApplyConfiguration {
  73. b.CurrentRevision = &value
  74. return b
  75. }
  76. // WithUpdateRevision sets the UpdateRevision field in the declarative configuration to the given value
  77. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  78. // If called multiple times, the UpdateRevision field is set to the value of the last call.
  79. func (b *StatefulSetStatusApplyConfiguration) WithUpdateRevision(value string) *StatefulSetStatusApplyConfiguration {
  80. b.UpdateRevision = &value
  81. return b
  82. }
  83. // WithCollisionCount sets the CollisionCount field in the declarative configuration to the given value
  84. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  85. // If called multiple times, the CollisionCount field is set to the value of the last call.
  86. func (b *StatefulSetStatusApplyConfiguration) WithCollisionCount(value int32) *StatefulSetStatusApplyConfiguration {
  87. b.CollisionCount = &value
  88. return b
  89. }
  90. // WithConditions adds the given value to the Conditions field in the declarative configuration
  91. // and returns the receiver, so that objects can be build by chaining "With" function invocations.
  92. // If called multiple times, values provided by each call will be appended to the Conditions field.
  93. func (b *StatefulSetStatusApplyConfiguration) WithConditions(values ...*StatefulSetConditionApplyConfiguration) *StatefulSetStatusApplyConfiguration {
  94. for i := range values {
  95. if values[i] == nil {
  96. panic("nil value passed to WithConditions")
  97. }
  98. b.Conditions = append(b.Conditions, *values[i])
  99. }
  100. return b
  101. }
  102. // WithAvailableReplicas sets the AvailableReplicas field in the declarative configuration to the given value
  103. // and returns the receiver, so that objects can be built by chaining "With" function invocations.
  104. // If called multiple times, the AvailableReplicas field is set to the value of the last call.
  105. func (b *StatefulSetStatusApplyConfiguration) WithAvailableReplicas(value int32) *StatefulSetStatusApplyConfiguration {
  106. b.AvailableReplicas = &value
  107. return b
  108. }