...

Source file src/k8s.io/client-go/applyconfigurations/apps/v1beta2/daemonsetspec.go

Documentation: k8s.io/client-go/applyconfigurations/apps/v1beta2

     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  	corev1 "k8s.io/client-go/applyconfigurations/core/v1"
    23  	v1 "k8s.io/client-go/applyconfigurations/meta/v1"
    24  )
    25  
    26  // DaemonSetSpecApplyConfiguration represents an declarative configuration of the DaemonSetSpec type for use
    27  // with apply.
    28  type DaemonSetSpecApplyConfiguration struct {
    29  	Selector             *v1.LabelSelectorApplyConfiguration        `json:"selector,omitempty"`
    30  	Template             *corev1.PodTemplateSpecApplyConfiguration  `json:"template,omitempty"`
    31  	UpdateStrategy       *DaemonSetUpdateStrategyApplyConfiguration `json:"updateStrategy,omitempty"`
    32  	MinReadySeconds      *int32                                     `json:"minReadySeconds,omitempty"`
    33  	RevisionHistoryLimit *int32                                     `json:"revisionHistoryLimit,omitempty"`
    34  }
    35  
    36  // DaemonSetSpecApplyConfiguration constructs an declarative configuration of the DaemonSetSpec type for use with
    37  // apply.
    38  func DaemonSetSpec() *DaemonSetSpecApplyConfiguration {
    39  	return &DaemonSetSpecApplyConfiguration{}
    40  }
    41  
    42  // WithSelector sets the Selector 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 Selector field is set to the value of the last call.
    45  func (b *DaemonSetSpecApplyConfiguration) WithSelector(value *v1.LabelSelectorApplyConfiguration) *DaemonSetSpecApplyConfiguration {
    46  	b.Selector = value
    47  	return b
    48  }
    49  
    50  // WithTemplate sets the Template field in the declarative configuration to the given value
    51  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
    52  // If called multiple times, the Template field is set to the value of the last call.
    53  func (b *DaemonSetSpecApplyConfiguration) WithTemplate(value *corev1.PodTemplateSpecApplyConfiguration) *DaemonSetSpecApplyConfiguration {
    54  	b.Template = value
    55  	return b
    56  }
    57  
    58  // WithUpdateStrategy sets the UpdateStrategy field in the declarative configuration to the given value
    59  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
    60  // If called multiple times, the UpdateStrategy field is set to the value of the last call.
    61  func (b *DaemonSetSpecApplyConfiguration) WithUpdateStrategy(value *DaemonSetUpdateStrategyApplyConfiguration) *DaemonSetSpecApplyConfiguration {
    62  	b.UpdateStrategy = value
    63  	return b
    64  }
    65  
    66  // WithMinReadySeconds sets the MinReadySeconds field in the declarative configuration to the given value
    67  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
    68  // If called multiple times, the MinReadySeconds field is set to the value of the last call.
    69  func (b *DaemonSetSpecApplyConfiguration) WithMinReadySeconds(value int32) *DaemonSetSpecApplyConfiguration {
    70  	b.MinReadySeconds = &value
    71  	return b
    72  }
    73  
    74  // WithRevisionHistoryLimit sets the RevisionHistoryLimit field in the declarative configuration to the given value
    75  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
    76  // If called multiple times, the RevisionHistoryLimit field is set to the value of the last call.
    77  func (b *DaemonSetSpecApplyConfiguration) WithRevisionHistoryLimit(value int32) *DaemonSetSpecApplyConfiguration {
    78  	b.RevisionHistoryLimit = &value
    79  	return b
    80  }
    81  

View as plain text