codekingpro/portable-devtools
114k
1# coding: utf-82 3"""4 Kubernetes5 6 No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E5017 8 The version of the OpenAPI document: release-1.359 Generated by: https://openapi-generator.tech10"""11 12 13import pprint14import re # noqa: F40115 16import six17 18from kubernetes.client.configuration import Configuration19 20 21class V1ContainerState(object):22 """NOTE: This class is auto generated by OpenAPI Generator.23 Ref: https://openapi-generator.tech24 25 Do not edit the class manually.26 """27 28 """29 Attributes:30 openapi_types (dict): The key is attribute name31 and the value is attribute type.32 attribute_map (dict): The key is attribute name33 and the value is json key in definition.34 """35 openapi_types = {36 'running': 'V1ContainerStateRunning',37 'terminated': 'V1ContainerStateTerminated',38 'waiting': 'V1ContainerStateWaiting'39 }40 41 attribute_map = {42 'running': 'running',43 'terminated': 'terminated',44 'waiting': 'waiting'45 }46 47 def __init__(self, running=None, terminated=None, waiting=None, local_vars_configuration=None): # noqa: E50148 """V1ContainerState - a model defined in OpenAPI""" # noqa: E50149 if local_vars_configuration is None:50 local_vars_configuration = Configuration()51 self.local_vars_configuration = local_vars_configuration52 53 self._running = None54 self._terminated = None55 self._waiting = None56 self.discriminator = None57 58 if running is not None:59 self.running = running60 if terminated is not None:61 self.terminated = terminated62 if waiting is not None:63 self.waiting = waiting64 65 @property66 def running(self):67 """Gets the running of this V1ContainerState. # noqa: E50168 69 70 :return: The running of this V1ContainerState. # noqa: E50171 :rtype: V1ContainerStateRunning72 """73 return self._running74 75 @running.setter76 def running(self, running):77 """Sets the running of this V1ContainerState.78 79 80 :param running: The running of this V1ContainerState. # noqa: E50181 :type: V1ContainerStateRunning82 """83 84 self._running = running85 86 @property87 def terminated(self):88 """Gets the terminated of this V1ContainerState. # noqa: E50189 90 91 :return: The terminated of this V1ContainerState. # noqa: E50192 :rtype: V1ContainerStateTerminated93 """94 return self._terminated95 96 @terminated.setter97 def terminated(self, terminated):98 """Sets the terminated of this V1ContainerState.99 100 101 :param terminated: The terminated of this V1ContainerState. # noqa: E501102 :type: V1ContainerStateTerminated103 """104 105 self._terminated = terminated106 107 @property108 def waiting(self):109 """Gets the waiting of this V1ContainerState. # noqa: E501110 111 112 :return: The waiting of this V1ContainerState. # noqa: E501113 :rtype: V1ContainerStateWaiting114 """115 return self._waiting116 117 @waiting.setter118 def waiting(self, waiting):119 """Sets the waiting of this V1ContainerState.120 121 122 :param waiting: The waiting of this V1ContainerState. # noqa: E501123 :type: V1ContainerStateWaiting124 """125 126 self._waiting = waiting127 128 def to_dict(self):129 """Returns the model properties as a dict"""130 result = {}131 132 for attr, _ in six.iteritems(self.openapi_types):133 value = getattr(self, attr)134 if isinstance(value, list):135 result[attr] = list(map(136 lambda x: x.to_dict() if hasattr(x, "to_dict") else x,137 value138 ))139 elif hasattr(value, "to_dict"):140 result[attr] = value.to_dict()141 elif isinstance(value, dict):142 result[attr] = dict(map(143 lambda item: (item[0], item[1].to_dict())144 if hasattr(item[1], "to_dict") else item,145 value.items()146 ))147 else:148 result[attr] = value149 150 return result151 152 def to_str(self):153 """Returns the string representation of the model"""154 return pprint.pformat(self.to_dict())155 156 def __repr__(self):157 """For `print` and `pprint`"""158 return self.to_str()159 160 def __eq__(self, other):161 """Returns true if both objects are equal"""162 if not isinstance(other, V1ContainerState):163 return False164 165 return self.to_dict() == other.to_dict()166 167 def __ne__(self, other):168 """Returns true if both objects are not equal"""169 if not isinstance(other, V1ContainerState):170 return True171 172 return self.to_dict() != other.to_dict()173 