# coding: utf-8

"""
    identity-service

    No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)  # noqa: E501

    The version of the OpenAPI document: 1.0.0
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from dhicn_identity_service.configuration import Configuration


class AddSuperUserInput(object):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    """
    Attributes:
      openapi_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.
    """
    openapi_types = {
        'user_name': 'str',
        'surname': 'str',
        'tenant_ids': 'list[str]',
        'status': 'int'
    }

    attribute_map = {
        'user_name': 'userName',
        'surname': 'surname',
        'tenant_ids': 'tenantIds',
        'status': 'status'
    }

    def __init__(self, user_name=None, surname=None, tenant_ids=None, status=None, local_vars_configuration=None):  # noqa: E501
        """AddSuperUserInput - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration()
        self.local_vars_configuration = local_vars_configuration

        self._user_name = None
        self._surname = None
        self._tenant_ids = None
        self._status = None
        self.discriminator = None

        self.user_name = user_name
        self.surname = surname
        self.tenant_ids = tenant_ids
        self.status = status

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

        超级用户名 super user name  # noqa: E501

        :return: The user_name of this AddSuperUserInput.  # noqa: E501
        :rtype: str
        """
        return self._user_name

    @user_name.setter
    def user_name(self, user_name):
        """Sets the user_name of this AddSuperUserInput.

        超级用户名 super user name  # noqa: E501

        :param user_name: The user_name of this AddSuperUserInput.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and user_name is None:  # noqa: E501
            raise ValueError("Invalid value for `user_name`, must not be `None`")  # noqa: E501

        self._user_name = user_name

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

        姓氏 surname  # noqa: E501

        :return: The surname of this AddSuperUserInput.  # noqa: E501
        :rtype: str
        """
        return self._surname

    @surname.setter
    def surname(self, surname):
        """Sets the surname of this AddSuperUserInput.

        姓氏 surname  # noqa: E501

        :param surname: The surname of this AddSuperUserInput.  # noqa: E501
        :type: str
        """

        self._surname = surname

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

        在哪些租户下允许登录 tenant ids for which the super user can login  # noqa: E501

        :return: The tenant_ids of this AddSuperUserInput.  # noqa: E501
        :rtype: list[str]
        """
        return self._tenant_ids

    @tenant_ids.setter
    def tenant_ids(self, tenant_ids):
        """Sets the tenant_ids of this AddSuperUserInput.

        在哪些租户下允许登录 tenant ids for which the super user can login  # noqa: E501

        :param tenant_ids: The tenant_ids of this AddSuperUserInput.  # noqa: E501
        :type: list[str]
        """
        if self.local_vars_configuration.client_side_validation and tenant_ids is None:  # noqa: E501
            raise ValueError("Invalid value for `tenant_ids`, must not be `None`")  # noqa: E501

        self._tenant_ids = tenant_ids

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

        0-Normal(normal user) 1-Frozen(frozen user) 2-Cancelled(cancelled user)   # noqa: E501

        :return: The status of this AddSuperUserInput.  # noqa: E501
        :rtype: int
        """
        return self._status

    @status.setter
    def status(self, status):
        """Sets the status of this AddSuperUserInput.

        0-Normal(normal user) 1-Frozen(frozen user) 2-Cancelled(cancelled user)   # noqa: E501

        :param status: The status of this AddSuperUserInput.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and status is None:  # noqa: E501
            raise ValueError("Invalid value for `status`, must not be `None`")  # noqa: E501
        allowed_values = [0, 1, 2]  # noqa: E501
        if self.local_vars_configuration.client_side_validation and status not in allowed_values:  # noqa: E501
            raise ValueError(
                "Invalid value for `status` ({0}), must be one of {1}"  # noqa: E501
                .format(status, allowed_values)
            )

        self._status = status

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

        for attr, _ in six.iteritems(self.openapi_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

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

        return self.to_dict() == other.to_dict()

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

        return self.to_dict() != other.to_dict()
