Team Ai
Datasetpublic

codekingpro/portable-devtools

sourceHugging Faceupdated 5mo agoView on Hugging Face
1likes14kdownloads
v1_node_config_status.py201 linesDownload Raw Back to models
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 V1NodeConfigStatus(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        'active': 'V1NodeConfigSource',37        'assigned': 'V1NodeConfigSource',38        'error': 'str',39        'last_known_good': 'V1NodeConfigSource'40    }41 42    attribute_map = {43        'active': 'active',44        'assigned': 'assigned',45        'error': 'error',46        'last_known_good': 'lastKnownGood'47    }48 49    def __init__(self, active=None, assigned=None, error=None, last_known_good=None, local_vars_configuration=None):  # noqa: E50150        """V1NodeConfigStatus - 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._active = None56        self._assigned = None57        self._error = None58        self._last_known_good = None59        self.discriminator = None60 61        if active is not None:62            self.active = active63        if assigned is not None:64            self.assigned = assigned65        if error is not None:66            self.error = error67        if last_known_good is not None:68            self.last_known_good = last_known_good69 70    @property71    def active(self):72        """Gets the active of this V1NodeConfigStatus.  # noqa: E50173 74 75        :return: The active of this V1NodeConfigStatus.  # noqa: E50176        :rtype: V1NodeConfigSource77        """78        return self._active79 80    @active.setter81    def active(self, active):82        """Sets the active of this V1NodeConfigStatus.83 84 85        :param active: The active of this V1NodeConfigStatus.  # noqa: E50186        :type: V1NodeConfigSource87        """88 89        self._active = active90 91    @property92    def assigned(self):93        """Gets the assigned of this V1NodeConfigStatus.  # noqa: E50194 95 96        :return: The assigned of this V1NodeConfigStatus.  # noqa: E50197        :rtype: V1NodeConfigSource98        """99        return self._assigned100 101    @assigned.setter102    def assigned(self, assigned):103        """Sets the assigned of this V1NodeConfigStatus.104 105 106        :param assigned: The assigned of this V1NodeConfigStatus.  # noqa: E501107        :type: V1NodeConfigSource108        """109 110        self._assigned = assigned111 112    @property113    def error(self):114        """Gets the error of this V1NodeConfigStatus.  # noqa: E501115 116        Error describes any problems reconciling the Spec.ConfigSource to the Active config. Errors may occur, for example, attempting to checkpoint Spec.ConfigSource to the local Assigned record, attempting to checkpoint the payload associated with Spec.ConfigSource, attempting to load or validate the Assigned config, etc. Errors may occur at different points while syncing config. Earlier errors (e.g. download or checkpointing errors) will not result in a rollback to LastKnownGood, and may resolve across Kubelet retries. Later errors (e.g. loading or validating a checkpointed config) will result in a rollback to LastKnownGood. In the latter case, it is usually possible to resolve the error by fixing the config assigned in Spec.ConfigSource. You can find additional information for debugging by searching the error message in the Kubelet log. Error is a human-readable description of the error state; machines can check whether or not Error is empty, but should not rely on the stability of the Error text across Kubelet versions.  # noqa: E501117 118        :return: The error of this V1NodeConfigStatus.  # noqa: E501119        :rtype: str120        """121        return self._error122 123    @error.setter124    def error(self, error):125        """Sets the error of this V1NodeConfigStatus.126 127        Error describes any problems reconciling the Spec.ConfigSource to the Active config. Errors may occur, for example, attempting to checkpoint Spec.ConfigSource to the local Assigned record, attempting to checkpoint the payload associated with Spec.ConfigSource, attempting to load or validate the Assigned config, etc. Errors may occur at different points while syncing config. Earlier errors (e.g. download or checkpointing errors) will not result in a rollback to LastKnownGood, and may resolve across Kubelet retries. Later errors (e.g. loading or validating a checkpointed config) will result in a rollback to LastKnownGood. In the latter case, it is usually possible to resolve the error by fixing the config assigned in Spec.ConfigSource. You can find additional information for debugging by searching the error message in the Kubelet log. Error is a human-readable description of the error state; machines can check whether or not Error is empty, but should not rely on the stability of the Error text across Kubelet versions.  # noqa: E501128 129        :param error: The error of this V1NodeConfigStatus.  # noqa: E501130        :type: str131        """132 133        self._error = error134 135    @property136    def last_known_good(self):137        """Gets the last_known_good of this V1NodeConfigStatus.  # noqa: E501138 139 140        :return: The last_known_good of this V1NodeConfigStatus.  # noqa: E501141        :rtype: V1NodeConfigSource142        """143        return self._last_known_good144 145    @last_known_good.setter146    def last_known_good(self, last_known_good):147        """Sets the last_known_good of this V1NodeConfigStatus.148 149 150        :param last_known_good: The last_known_good of this V1NodeConfigStatus.  # noqa: E501151        :type: V1NodeConfigSource152        """153 154        self._last_known_good = last_known_good155 156    def to_dict(self):157        """Returns the model properties as a dict"""158        result = {}159 160        for attr, _ in six.iteritems(self.openapi_types):161            value = getattr(self, attr)162            if isinstance(value, list):163                result[attr] = list(map(164                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,165                    value166                ))167            elif hasattr(value, "to_dict"):168                result[attr] = value.to_dict()169            elif isinstance(value, dict):170                result[attr] = dict(map(171                    lambda item: (item[0], item[1].to_dict())172                    if hasattr(item[1], "to_dict") else item,173                    value.items()174                ))175            else:176                result[attr] = value177 178        return result179 180    def to_str(self):181        """Returns the string representation of the model"""182        return pprint.pformat(self.to_dict())183 184    def __repr__(self):185        """For `print` and `pprint`"""186        return self.to_str()187 188    def __eq__(self, other):189        """Returns true if both objects are equal"""190        if not isinstance(other, V1NodeConfigStatus):191            return False192 193        return self.to_dict() == other.to_dict()194 195    def __ne__(self, other):196        """Returns true if both objects are not equal"""197        if not isinstance(other, V1NodeConfigStatus):198            return True199 200        return self.to_dict() != other.to_dict()201 
codekingpro/portable-devtools · Team Ai