| 1 |
/* |
| 2 |
Copyright The Kubernetes Authors. |
| 3 |
|
| 4 |
Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 |
you may not use this file except in compliance with the License. |
| 6 |
You may obtain a copy of the License at |
| 7 |
|
| 8 |
http://www.apache.org/licenses/LICENSE-2.0 |
| 9 |
|
| 10 |
Unless required by applicable law or agreed to in writing, software |
| 11 |
distributed under the License is distributed on an "AS IS" BASIS, |
| 12 |
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 |
See the License for the specific language governing permissions and |
| 14 |
limitations under the License. |
| 15 |
*/ |
| 16 |
|
| 17 |
// Code generated by applyconfiguration-gen. DO NOT EDIT. |
| 18 |
|
| 19 |
package v1beta2 |
| 20 |
|
| 21 |
import ( |
| 22 |
appsv1beta2 "k8s.io/api/apps/v1beta2" |
| 23 |
v1 "k8s.io/api/core/v1" |
| 24 |
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" |
| 25 |
) |
| 26 |
|
| 27 |
// ReplicaSetConditionApplyConfiguration represents a declarative configuration of the ReplicaSetCondition type for use |
| 28 |
// with apply. |
| 29 |
type ReplicaSetConditionApplyConfiguration struct { |
| 30 |
Type *appsv1beta2.ReplicaSetConditionType `json:"type,omitempty"` |
| 31 |
Status *v1.ConditionStatus `json:"status,omitempty"` |
| 32 |
LastTransitionTime *metav1.Time `json:"lastTransitionTime,omitempty"` |
| 33 |
Reason *string `json:"reason,omitempty"` |
| 34 |
Message *string `json:"message,omitempty"` |
| 35 |
} |
| 36 |
|
| 37 |
// ReplicaSetConditionApplyConfiguration constructs a declarative configuration of the ReplicaSetCondition type for use with |
| 38 |
// apply. |
| 39 |
func ReplicaSetCondition() *ReplicaSetConditionApplyConfiguration { |
| 40 |
return &ReplicaSetConditionApplyConfiguration{} |
| 41 |
} |
| 42 |
|
| 43 |
// WithType sets the Type field in the declarative configuration to the given value |
| 44 |
// and returns the receiver, so that objects can be built by chaining "With" function invocations. |
| 45 |
// If called multiple times, the Type field is set to the value of the last call. |
| 46 |
func (b *ReplicaSetConditionApplyConfiguration) WithType(value appsv1beta2.ReplicaSetConditionType) *ReplicaSetConditionApplyConfiguration { |
| 47 |
b.Type = &value |
| 48 |
return b |
| 49 |
} |
| 50 |
|
| 51 |
// WithStatus sets the Status field in the declarative configuration to the given value |
| 52 |
// and returns the receiver, so that objects can be built by chaining "With" function invocations. |
| 53 |
// If called multiple times, the Status field is set to the value of the last call. |
| 54 |
func (b *ReplicaSetConditionApplyConfiguration) WithStatus(value v1.ConditionStatus) *ReplicaSetConditionApplyConfiguration { |
| 55 |
b.Status = &value |
| 56 |
return b |
| 57 |
} |
| 58 |
|
| 59 |
// WithLastTransitionTime sets the LastTransitionTime field in the declarative configuration to the given value |
| 60 |
// and returns the receiver, so that objects can be built by chaining "With" function invocations. |
| 61 |
// If called multiple times, the LastTransitionTime field is set to the value of the last call. |
| 62 |
func (b *ReplicaSetConditionApplyConfiguration) WithLastTransitionTime(value metav1.Time) *ReplicaSetConditionApplyConfiguration { |
| 63 |
b.LastTransitionTime = &value |
| 64 |
return b |
| 65 |
} |
| 66 |
|
| 67 |
// WithReason sets the Reason field in the declarative configuration to the given value |
| 68 |
// and returns the receiver, so that objects can be built by chaining "With" function invocations. |
| 69 |
// If called multiple times, the Reason field is set to the value of the last call. |
| 70 |
func (b *ReplicaSetConditionApplyConfiguration) WithReason(value string) *ReplicaSetConditionApplyConfiguration { |
| 71 |
b.Reason = &value |
| 72 |
return b |
| 73 |
} |
| 74 |
|
| 75 |
// WithMessage sets the Message field in the declarative configuration to the given value |
| 76 |
// and returns the receiver, so that objects can be built by chaining "With" function invocations. |
| 77 |
// If called multiple times, the Message field is set to the value of the last call. |
| 78 |
func (b *ReplicaSetConditionApplyConfiguration) WithMessage(value string) *ReplicaSetConditionApplyConfiguration { |
| 79 |
b.Message = &value |
| 80 |
return b |
| 81 |
} |