# coding: utf-8

"""
    Cherwell REST API

    Unofficial Python Cherwell REST API library.  # noqa: E501

    The version of the OpenAPI document: 9.3.2
    Contact: See AUTHORS.
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from pycherwell.configuration import Configuration


class Right(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 = {
        'add': 'bool',
        'allow': 'bool',
        'category_description': 'str',
        'category_id': 'str',
        'category_name': 'str',
        'delete': 'bool',
        'edit': 'bool',
        'is_yes_no_right': 'bool',
        'non_scope_owner_add': 'bool',
        'non_scope_owner_delete': 'bool',
        'non_scope_owner_edit': 'bool',
        'non_scope_owner_view': 'bool',
        'right_id': 'str',
        'right_name': 'str',
        'standard_right_name': 'str',
        'view_run_open': 'bool'
    }

    attribute_map = {
        'add': 'add',
        'allow': 'allow',
        'category_description': 'categoryDescription',
        'category_id': 'categoryId',
        'category_name': 'categoryName',
        'delete': 'delete',
        'edit': 'edit',
        'is_yes_no_right': 'isYesNoRight',
        'non_scope_owner_add': 'nonScopeOwnerAdd',
        'non_scope_owner_delete': 'nonScopeOwnerDelete',
        'non_scope_owner_edit': 'nonScopeOwnerEdit',
        'non_scope_owner_view': 'nonScopeOwnerView',
        'right_id': 'rightId',
        'right_name': 'rightName',
        'standard_right_name': 'standardRightName',
        'view_run_open': 'viewRunOpen'
    }

    def __init__(self, add=None, allow=None, category_description=None, category_id=None, category_name=None, delete=None, edit=None, is_yes_no_right=None, non_scope_owner_add=None, non_scope_owner_delete=None, non_scope_owner_edit=None, non_scope_owner_view=None, right_id=None, right_name=None, standard_right_name=None, view_run_open=None, local_vars_configuration=None):  # noqa: E501
        """Right - 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._add = None
        self._allow = None
        self._category_description = None
        self._category_id = None
        self._category_name = None
        self._delete = None
        self._edit = None
        self._is_yes_no_right = None
        self._non_scope_owner_add = None
        self._non_scope_owner_delete = None
        self._non_scope_owner_edit = None
        self._non_scope_owner_view = None
        self._right_id = None
        self._right_name = None
        self._standard_right_name = None
        self._view_run_open = None
        self.discriminator = None

        if add is not None:
            self.add = add
        if allow is not None:
            self.allow = allow
        if category_description is not None:
            self.category_description = category_description
        if category_id is not None:
            self.category_id = category_id
        if category_name is not None:
            self.category_name = category_name
        if delete is not None:
            self.delete = delete
        if edit is not None:
            self.edit = edit
        if is_yes_no_right is not None:
            self.is_yes_no_right = is_yes_no_right
        if non_scope_owner_add is not None:
            self.non_scope_owner_add = non_scope_owner_add
        if non_scope_owner_delete is not None:
            self.non_scope_owner_delete = non_scope_owner_delete
        if non_scope_owner_edit is not None:
            self.non_scope_owner_edit = non_scope_owner_edit
        if non_scope_owner_view is not None:
            self.non_scope_owner_view = non_scope_owner_view
        if right_id is not None:
            self.right_id = right_id
        if right_name is not None:
            self.right_name = right_name
        if standard_right_name is not None:
            self.standard_right_name = standard_right_name
        if view_run_open is not None:
            self.view_run_open = view_run_open

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


        :return: The add of this Right.  # noqa: E501
        :rtype: bool
        """
        return self._add

    @add.setter
    def add(self, add):
        """Sets the add of this Right.


        :param add: The add of this Right.  # noqa: E501
        :type: bool
        """

        self._add = add

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


        :return: The allow of this Right.  # noqa: E501
        :rtype: bool
        """
        return self._allow

    @allow.setter
    def allow(self, allow):
        """Sets the allow of this Right.


        :param allow: The allow of this Right.  # noqa: E501
        :type: bool
        """

        self._allow = allow

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


        :return: The category_description of this Right.  # noqa: E501
        :rtype: str
        """
        return self._category_description

    @category_description.setter
    def category_description(self, category_description):
        """Sets the category_description of this Right.


        :param category_description: The category_description of this Right.  # noqa: E501
        :type: str
        """

        self._category_description = category_description

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


        :return: The category_id of this Right.  # noqa: E501
        :rtype: str
        """
        return self._category_id

    @category_id.setter
    def category_id(self, category_id):
        """Sets the category_id of this Right.


        :param category_id: The category_id of this Right.  # noqa: E501
        :type: str
        """

        self._category_id = category_id

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


        :return: The category_name of this Right.  # noqa: E501
        :rtype: str
        """
        return self._category_name

    @category_name.setter
    def category_name(self, category_name):
        """Sets the category_name of this Right.


        :param category_name: The category_name of this Right.  # noqa: E501
        :type: str
        """

        self._category_name = category_name

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


        :return: The delete of this Right.  # noqa: E501
        :rtype: bool
        """
        return self._delete

    @delete.setter
    def delete(self, delete):
        """Sets the delete of this Right.


        :param delete: The delete of this Right.  # noqa: E501
        :type: bool
        """

        self._delete = delete

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


        :return: The edit of this Right.  # noqa: E501
        :rtype: bool
        """
        return self._edit

    @edit.setter
    def edit(self, edit):
        """Sets the edit of this Right.


        :param edit: The edit of this Right.  # noqa: E501
        :type: bool
        """

        self._edit = edit

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


        :return: The is_yes_no_right of this Right.  # noqa: E501
        :rtype: bool
        """
        return self._is_yes_no_right

    @is_yes_no_right.setter
    def is_yes_no_right(self, is_yes_no_right):
        """Sets the is_yes_no_right of this Right.


        :param is_yes_no_right: The is_yes_no_right of this Right.  # noqa: E501
        :type: bool
        """

        self._is_yes_no_right = is_yes_no_right

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


        :return: The non_scope_owner_add of this Right.  # noqa: E501
        :rtype: bool
        """
        return self._non_scope_owner_add

    @non_scope_owner_add.setter
    def non_scope_owner_add(self, non_scope_owner_add):
        """Sets the non_scope_owner_add of this Right.


        :param non_scope_owner_add: The non_scope_owner_add of this Right.  # noqa: E501
        :type: bool
        """

        self._non_scope_owner_add = non_scope_owner_add

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


        :return: The non_scope_owner_delete of this Right.  # noqa: E501
        :rtype: bool
        """
        return self._non_scope_owner_delete

    @non_scope_owner_delete.setter
    def non_scope_owner_delete(self, non_scope_owner_delete):
        """Sets the non_scope_owner_delete of this Right.


        :param non_scope_owner_delete: The non_scope_owner_delete of this Right.  # noqa: E501
        :type: bool
        """

        self._non_scope_owner_delete = non_scope_owner_delete

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


        :return: The non_scope_owner_edit of this Right.  # noqa: E501
        :rtype: bool
        """
        return self._non_scope_owner_edit

    @non_scope_owner_edit.setter
    def non_scope_owner_edit(self, non_scope_owner_edit):
        """Sets the non_scope_owner_edit of this Right.


        :param non_scope_owner_edit: The non_scope_owner_edit of this Right.  # noqa: E501
        :type: bool
        """

        self._non_scope_owner_edit = non_scope_owner_edit

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


        :return: The non_scope_owner_view of this Right.  # noqa: E501
        :rtype: bool
        """
        return self._non_scope_owner_view

    @non_scope_owner_view.setter
    def non_scope_owner_view(self, non_scope_owner_view):
        """Sets the non_scope_owner_view of this Right.


        :param non_scope_owner_view: The non_scope_owner_view of this Right.  # noqa: E501
        :type: bool
        """

        self._non_scope_owner_view = non_scope_owner_view

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


        :return: The right_id of this Right.  # noqa: E501
        :rtype: str
        """
        return self._right_id

    @right_id.setter
    def right_id(self, right_id):
        """Sets the right_id of this Right.


        :param right_id: The right_id of this Right.  # noqa: E501
        :type: str
        """

        self._right_id = right_id

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


        :return: The right_name of this Right.  # noqa: E501
        :rtype: str
        """
        return self._right_name

    @right_name.setter
    def right_name(self, right_name):
        """Sets the right_name of this Right.


        :param right_name: The right_name of this Right.  # noqa: E501
        :type: str
        """

        self._right_name = right_name

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


        :return: The standard_right_name of this Right.  # noqa: E501
        :rtype: str
        """
        return self._standard_right_name

    @standard_right_name.setter
    def standard_right_name(self, standard_right_name):
        """Sets the standard_right_name of this Right.


        :param standard_right_name: The standard_right_name of this Right.  # noqa: E501
        :type: str
        """

        self._standard_right_name = standard_right_name

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


        :return: The view_run_open of this Right.  # noqa: E501
        :rtype: bool
        """
        return self._view_run_open

    @view_run_open.setter
    def view_run_open(self, view_run_open):
        """Sets the view_run_open of this Right.


        :param view_run_open: The view_run_open of this Right.  # noqa: E501
        :type: bool
        """

        self._view_run_open = view_run_open

    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, Right):
            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, Right):
            return True

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