# coding: utf-8

"""
    Cloudera Manager API

    <h1>Cloudera Manager API v57</h1>       <p>Introduced in Cloudera Manager 7.13.1</p>       <p><a href=\"http://www.cloudera.com/documentation.html\">Cloudera Product Documentation</a></p>  # noqa: E501

    OpenAPI spec version: 7.13.1
    
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""

import pprint
import re  # noqa: F401

import six

class ApiConfigEnforcement(object):
    """NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    """
    """
    Attributes:
      swagger_types (dict): The key is attribute name
                            and the value is attribute type.
      attribute_map (dict): The key is attribute name
                            and the value is json key in definition.
    """
    swagger_types = {
        'label': 'str',
        'default_value': 'str',
        'unit': 'str',
        'separator': 'str'
    }

    attribute_map = {
        'label': 'label',
        'default_value': 'defaultValue',
        'unit': 'unit',
        'separator': 'separator'
    }

    def __init__(self, label=None, default_value=None, unit=None, separator=None):  # noqa: E501
        """ApiConfigEnforcement - a model defined in Swagger"""  # noqa: E501
        self._label = None
        self._default_value = None
        self._unit = None
        self._separator = None
        self.discriminator = None
        if label is not None:
            self.label = label
        if default_value is not None:
            self.default_value = default_value
        if unit is not None:
            self.unit = unit
        if separator is not None:
            self.separator = separator

    @property
    def label(self):
        """Gets the label of this ApiConfigEnforcement.  # noqa: E501

        A label can be used to retrieve a set of configurations where this enforcement is applied. This is currently restricted to only those enums defined in ParamSpecLabel.java.  All these configurations having the same label must be uniform. In other words, all these configurations must accept the same configuration input.  There are two variations. Different configurations may have 1. different units for numeric configurations 2. different separators for list style configurations.  # noqa: E501

        :return: The label of this ApiConfigEnforcement.  # noqa: E501
        :rtype: str
        """
        return self._label

    @label.setter
    def label(self, label):
        """Sets the label of this ApiConfigEnforcement.

        A label can be used to retrieve a set of configurations where this enforcement is applied. This is currently restricted to only those enums defined in ParamSpecLabel.java.  All these configurations having the same label must be uniform. In other words, all these configurations must accept the same configuration input.  There are two variations. Different configurations may have 1. different units for numeric configurations 2. different separators for list style configurations.  # noqa: E501

        :param label: The label of this ApiConfigEnforcement.  # noqa: E501
        :type: str
        """

        self._label = label

    @property
    def default_value(self):
        """Gets the default_value of this ApiConfigEnforcement.  # noqa: E501

        The new default value that these configurations should use instead of what is supplied by in Cloudera Manager by default.  # noqa: E501

        :return: The default_value of this ApiConfigEnforcement.  # noqa: E501
        :rtype: str
        """
        return self._default_value

    @default_value.setter
    def default_value(self, default_value):
        """Sets the default_value of this ApiConfigEnforcement.

        The new default value that these configurations should use instead of what is supplied by in Cloudera Manager by default.  # noqa: E501

        :param default_value: The default_value of this ApiConfigEnforcement.  # noqa: E501
        :type: str
        """

        self._default_value = default_value

    @property
    def unit(self):
        """Gets the unit of this ApiConfigEnforcement.  # noqa: E501

        This can be MILLISECONDS, SECONDS, MINUTES, HOURS, BYTES, KILOBYTES, MEGABYTES, GIGABYTES, PERCENT, PAGES, TIMES, LINES. Optional.  # noqa: E501

        :return: The unit of this ApiConfigEnforcement.  # noqa: E501
        :rtype: str
        """
        return self._unit

    @unit.setter
    def unit(self, unit):
        """Sets the unit of this ApiConfigEnforcement.

        This can be MILLISECONDS, SECONDS, MINUTES, HOURS, BYTES, KILOBYTES, MEGABYTES, GIGABYTES, PERCENT, PAGES, TIMES, LINES. Optional.  # noqa: E501

        :param unit: The unit of this ApiConfigEnforcement.  # noqa: E501
        :type: str
        """

        self._unit = unit

    @property
    def separator(self):
        """Gets the separator of this ApiConfigEnforcement.  # noqa: E501

        The new default value could be applied to configurations that require different separators. We need to know the separator the supplied default value has in order to generate the correct default value correctly. Optional.  # noqa: E501

        :return: The separator of this ApiConfigEnforcement.  # noqa: E501
        :rtype: str
        """
        return self._separator

    @separator.setter
    def separator(self, separator):
        """Sets the separator of this ApiConfigEnforcement.

        The new default value could be applied to configurations that require different separators. We need to know the separator the supplied default value has in order to generate the correct default value correctly. Optional.  # noqa: E501

        :param separator: The separator of this ApiConfigEnforcement.  # noqa: E501
        :type: str
        """

        self._separator = separator

    def to_dict(self):
        """Returns the model properties as a dict"""
        result = {}

        for attr, _ in six.iteritems(self.swagger_types):
            value = getattr(self, attr)
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                    value
                ))
            elif hasattr(value, "to_dict"):
                result[attr] = value.to_dict()
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], item[1].to_dict())
                    if hasattr(item[1], "to_dict") else item,
                    value.items()
                ))
            else:
                result[attr] = value
        if issubclass(ApiConfigEnforcement, dict):
            for key, value in self.items():
                result[key] = value

        return result

    def to_str(self):
        """Returns the string representation of the model"""
        return pprint.pformat(self.to_dict())

    def __repr__(self):
        """For `print` and `pprint`"""
        return self.to_str()

    def __eq__(self, other):
        """Returns true if both objects are equal"""
        if not isinstance(other, ApiConfigEnforcement):
            return False

        return self.__dict__ == other.__dict__

    def __ne__(self, other):
        """Returns true if both objects are not equal"""
        return not self == other
