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 V1UserInfo(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 'extra': 'dict(str, list[str])',37 'groups': 'list[str]',38 'uid': 'str',39 'username': 'str'40 }41 42 attribute_map = {43 'extra': 'extra',44 'groups': 'groups',45 'uid': 'uid',46 'username': 'username'47 }48 49 def __init__(self, extra=None, groups=None, uid=None, username=None, local_vars_configuration=None): # noqa: E50150 """V1UserInfo - a model defined in OpenAPI""" # noqa: E50151 if local_vars_configuration is None:52 local_vars_configuration = Configuration()53 self.local_vars_configuration = local_vars_configuration54 55 self._extra = None56 self._groups = None57 self._uid = None58 self._username = None59 self.discriminator = None60 61 if extra is not None:62 self.extra = extra63 if groups is not None:64 self.groups = groups65 if uid is not None:66 self.uid = uid67 if username is not None:68 self.username = username69 70 @property71 def extra(self):72 """Gets the extra of this V1UserInfo. # noqa: E50173 74 Any additional information provided by the authenticator. # noqa: E50175 76 :return: The extra of this V1UserInfo. # noqa: E50177 :rtype: dict(str, list[str])78 """79 return self._extra80 81 @extra.setter82 def extra(self, extra):83 """Sets the extra of this V1UserInfo.84 85 Any additional information provided by the authenticator. # noqa: E50186 87 :param extra: The extra of this V1UserInfo. # noqa: E50188 :type: dict(str, list[str])89 """90 91 self._extra = extra92 93 @property94 def groups(self):95 """Gets the groups of this V1UserInfo. # noqa: E50196 97 The names of groups this user is a part of. # noqa: E50198 99 :return: The groups of this V1UserInfo. # noqa: E501100 :rtype: list[str]101 """102 return self._groups103 104 @groups.setter105 def groups(self, groups):106 """Sets the groups of this V1UserInfo.107 108 The names of groups this user is a part of. # noqa: E501109 110 :param groups: The groups of this V1UserInfo. # noqa: E501111 :type: list[str]112 """113 114 self._groups = groups115 116 @property117 def uid(self):118 """Gets the uid of this V1UserInfo. # noqa: E501119 120 A unique value that identifies this user across time. If this user is deleted and another user by the same name is added, they will have different UIDs. # noqa: E501121 122 :return: The uid of this V1UserInfo. # noqa: E501123 :rtype: str124 """125 return self._uid126 127 @uid.setter128 def uid(self, uid):129 """Sets the uid of this V1UserInfo.130 131 A unique value that identifies this user across time. If this user is deleted and another user by the same name is added, they will have different UIDs. # noqa: E501132 133 :param uid: The uid of this V1UserInfo. # noqa: E501134 :type: str135 """136 137 self._uid = uid138 139 @property140 def username(self):141 """Gets the username of this V1UserInfo. # noqa: E501142 143 The name that uniquely identifies this user among all active users. # noqa: E501144 145 :return: The username of this V1UserInfo. # noqa: E501146 :rtype: str147 """148 return self._username149 150 @username.setter151 def username(self, username):152 """Sets the username of this V1UserInfo.153 154 The name that uniquely identifies this user among all active users. # noqa: E501155 156 :param username: The username of this V1UserInfo. # noqa: E501157 :type: str158 """159 160 self._username = username161 162 def to_dict(self):163 """Returns the model properties as a dict"""164 result = {}165 166 for attr, _ in six.iteritems(self.openapi_types):167 value = getattr(self, attr)168 if isinstance(value, list):169 result[attr] = list(map(170 lambda x: x.to_dict() if hasattr(x, "to_dict") else x,171 value172 ))173 elif hasattr(value, "to_dict"):174 result[attr] = value.to_dict()175 elif isinstance(value, dict):176 result[attr] = dict(map(177 lambda item: (item[0], item[1].to_dict())178 if hasattr(item[1], "to_dict") else item,179 value.items()180 ))181 else:182 result[attr] = value183 184 return result185 186 def to_str(self):187 """Returns the string representation of the model"""188 return pprint.pformat(self.to_dict())189 190 def __repr__(self):191 """For `print` and `pprint`"""192 return self.to_str()193 194 def __eq__(self, other):195 """Returns true if both objects are equal"""196 if not isinstance(other, V1UserInfo):197 return False198 199 return self.to_dict() == other.to_dict()200 201 def __ne__(self, other):202 """Returns true if both objects are not equal"""203 if not isinstance(other, V1UserInfo):204 return True205 206 return self.to_dict() != other.to_dict()207 