k8s.io/client-go@v0.22.2/applyconfigurations/core/v1/containerstatus.go (about)

     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 v1
    20  
    21  // ContainerStatusApplyConfiguration represents an declarative configuration of the ContainerStatus type for use
    22  // with apply.
    23  type ContainerStatusApplyConfiguration struct {
    24  	Name                 *string                           `json:"name,omitempty"`
    25  	State                *ContainerStateApplyConfiguration `json:"state,omitempty"`
    26  	LastTerminationState *ContainerStateApplyConfiguration `json:"lastState,omitempty"`
    27  	Ready                *bool                             `json:"ready,omitempty"`
    28  	RestartCount         *int32                            `json:"restartCount,omitempty"`
    29  	Image                *string                           `json:"image,omitempty"`
    30  	ImageID              *string                           `json:"imageID,omitempty"`
    31  	ContainerID          *string                           `json:"containerID,omitempty"`
    32  	Started              *bool                             `json:"started,omitempty"`
    33  }
    34  
    35  // ContainerStatusApplyConfiguration constructs an declarative configuration of the ContainerStatus type for use with
    36  // apply.
    37  func ContainerStatus() *ContainerStatusApplyConfiguration {
    38  	return &ContainerStatusApplyConfiguration{}
    39  }
    40  
    41  // WithName sets the Name 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 Name field is set to the value of the last call.
    44  func (b *ContainerStatusApplyConfiguration) WithName(value string) *ContainerStatusApplyConfiguration {
    45  	b.Name = &value
    46  	return b
    47  }
    48  
    49  // WithState sets the State 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 State field is set to the value of the last call.
    52  func (b *ContainerStatusApplyConfiguration) WithState(value *ContainerStateApplyConfiguration) *ContainerStatusApplyConfiguration {
    53  	b.State = value
    54  	return b
    55  }
    56  
    57  // WithLastTerminationState sets the LastTerminationState field in the declarative configuration to the given value
    58  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
    59  // If called multiple times, the LastTerminationState field is set to the value of the last call.
    60  func (b *ContainerStatusApplyConfiguration) WithLastTerminationState(value *ContainerStateApplyConfiguration) *ContainerStatusApplyConfiguration {
    61  	b.LastTerminationState = value
    62  	return b
    63  }
    64  
    65  // WithReady sets the Ready field in the declarative configuration to the given value
    66  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
    67  // If called multiple times, the Ready field is set to the value of the last call.
    68  func (b *ContainerStatusApplyConfiguration) WithReady(value bool) *ContainerStatusApplyConfiguration {
    69  	b.Ready = &value
    70  	return b
    71  }
    72  
    73  // WithRestartCount sets the RestartCount field in the declarative configuration to the given value
    74  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
    75  // If called multiple times, the RestartCount field is set to the value of the last call.
    76  func (b *ContainerStatusApplyConfiguration) WithRestartCount(value int32) *ContainerStatusApplyConfiguration {
    77  	b.RestartCount = &value
    78  	return b
    79  }
    80  
    81  // WithImage sets the Image field in the declarative configuration to the given value
    82  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
    83  // If called multiple times, the Image field is set to the value of the last call.
    84  func (b *ContainerStatusApplyConfiguration) WithImage(value string) *ContainerStatusApplyConfiguration {
    85  	b.Image = &value
    86  	return b
    87  }
    88  
    89  // WithImageID sets the ImageID field in the declarative configuration to the given value
    90  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
    91  // If called multiple times, the ImageID field is set to the value of the last call.
    92  func (b *ContainerStatusApplyConfiguration) WithImageID(value string) *ContainerStatusApplyConfiguration {
    93  	b.ImageID = &value
    94  	return b
    95  }
    96  
    97  // WithContainerID sets the ContainerID field in the declarative configuration to the given value
    98  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
    99  // If called multiple times, the ContainerID field is set to the value of the last call.
   100  func (b *ContainerStatusApplyConfiguration) WithContainerID(value string) *ContainerStatusApplyConfiguration {
   101  	b.ContainerID = &value
   102  	return b
   103  }
   104  
   105  // WithStarted sets the Started field in the declarative configuration to the given value
   106  // and returns the receiver, so that objects can be built by chaining "With" function invocations.
   107  // If called multiple times, the Started field is set to the value of the last call.
   108  func (b *ContainerStatusApplyConfiguration) WithStarted(value bool) *ContainerStatusApplyConfiguration {
   109  	b.Started = &value
   110  	return b
   111  }