# 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 ApiAuthRole(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 = {
        'display_name': 'str',
        'name': 'str',
        'clusters': 'list[ApiClusterRef]',
        'users': 'list[ApiUser2Ref]',
        'external_user_mappings': 'list[ApiExternalUserMappingRef]',
        'base_role': 'ApiAuthRoleRef',
        'uuid': 'str',
        'is_custom': 'bool'
    }

    attribute_map = {
        'display_name': 'displayName',
        'name': 'name',
        'clusters': 'clusters',
        'users': 'users',
        'external_user_mappings': 'externalUserMappings',
        'base_role': 'baseRole',
        'uuid': 'uuid',
        'is_custom': 'isCustom'
    }

    def __init__(self, display_name=None, name=None, clusters=None, users=None, external_user_mappings=None, base_role=None, uuid=None, is_custom=None):  # noqa: E501
        """ApiAuthRole - a model defined in Swagger"""  # noqa: E501
        self._display_name = None
        self._name = None
        self._clusters = None
        self._users = None
        self._external_user_mappings = None
        self._base_role = None
        self._uuid = None
        self._is_custom = None
        self.discriminator = None
        if display_name is not None:
            self.display_name = display_name
        if name is not None:
            self.name = name
        if clusters is not None:
            self.clusters = clusters
        if users is not None:
            self.users = users
        if external_user_mappings is not None:
            self.external_user_mappings = external_user_mappings
        if base_role is not None:
            self.base_role = base_role
        if uuid is not None:
            self.uuid = uuid
        if is_custom is not None:
            self.is_custom = is_custom

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


        :return: The display_name of this ApiAuthRole.  # noqa: E501
        :rtype: str
        """
        return self._display_name

    @display_name.setter
    def display_name(self, display_name):
        """Sets the display_name of this ApiAuthRole.


        :param display_name: The display_name of this ApiAuthRole.  # noqa: E501
        :type: str
        """

        self._display_name = display_name

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


        :return: The name of this ApiAuthRole.  # noqa: E501
        :rtype: str
        """
        return self._name

    @name.setter
    def name(self, name):
        """Sets the name of this ApiAuthRole.


        :param name: The name of this ApiAuthRole.  # noqa: E501
        :type: str
        """

        self._name = name

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


        :return: The clusters of this ApiAuthRole.  # noqa: E501
        :rtype: list[ApiClusterRef]
        """
        return self._clusters

    @clusters.setter
    def clusters(self, clusters):
        """Sets the clusters of this ApiAuthRole.


        :param clusters: The clusters of this ApiAuthRole.  # noqa: E501
        :type: list[ApiClusterRef]
        """

        self._clusters = clusters

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


        :return: The users of this ApiAuthRole.  # noqa: E501
        :rtype: list[ApiUser2Ref]
        """
        return self._users

    @users.setter
    def users(self, users):
        """Sets the users of this ApiAuthRole.


        :param users: The users of this ApiAuthRole.  # noqa: E501
        :type: list[ApiUser2Ref]
        """

        self._users = users

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


        :return: The external_user_mappings of this ApiAuthRole.  # noqa: E501
        :rtype: list[ApiExternalUserMappingRef]
        """
        return self._external_user_mappings

    @external_user_mappings.setter
    def external_user_mappings(self, external_user_mappings):
        """Sets the external_user_mappings of this ApiAuthRole.


        :param external_user_mappings: The external_user_mappings of this ApiAuthRole.  # noqa: E501
        :type: list[ApiExternalUserMappingRef]
        """

        self._external_user_mappings = external_user_mappings

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


        :return: The base_role of this ApiAuthRole.  # noqa: E501
        :rtype: ApiAuthRoleRef
        """
        return self._base_role

    @base_role.setter
    def base_role(self, base_role):
        """Sets the base_role of this ApiAuthRole.


        :param base_role: The base_role of this ApiAuthRole.  # noqa: E501
        :type: ApiAuthRoleRef
        """

        self._base_role = base_role

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

        Readonly. The UUID of the authRole. <p>  # noqa: E501

        :return: The uuid of this ApiAuthRole.  # noqa: E501
        :rtype: str
        """
        return self._uuid

    @uuid.setter
    def uuid(self, uuid):
        """Sets the uuid of this ApiAuthRole.

        Readonly. The UUID of the authRole. <p>  # noqa: E501

        :param uuid: The uuid of this ApiAuthRole.  # noqa: E501
        :type: str
        """

        self._uuid = uuid

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


        :return: The is_custom of this ApiAuthRole.  # noqa: E501
        :rtype: bool
        """
        return self._is_custom

    @is_custom.setter
    def is_custom(self, is_custom):
        """Sets the is_custom of this ApiAuthRole.


        :param is_custom: The is_custom of this ApiAuthRole.  # noqa: E501
        :type: bool
        """

        self._is_custom = is_custom

    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(ApiAuthRole, 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, ApiAuthRole):
            return False

        return self.__dict__ == other.__dict__

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