# coding: utf-8

"""
    CartoVista REST API

    No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)  # noqa: E501

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

import pprint
import re  # noqa: F401

import six

class ApplyGenericPermissionsParameter(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 = {
        'permissions': 'list[UserGroupPermission]',
        'default_permissions': 'list[DefaultPermissions]',
        'trickle_down': 'bool',
        'make_data_public': 'bool'
    }

    attribute_map = {
        'permissions': 'permissions',
        'default_permissions': 'defaultPermissions',
        'trickle_down': 'trickleDown',
        'make_data_public': 'makeDataPublic'
    }

    def __init__(self, permissions=None, default_permissions=None, trickle_down=None, make_data_public=None):  # noqa: E501
        """ApplyGenericPermissionsParameter - a model defined in Swagger"""  # noqa: E501
        self._permissions = None
        self._default_permissions = None
        self._trickle_down = None
        self._make_data_public = None
        self.discriminator = None
        if permissions is not None:
            self.permissions = permissions
        if default_permissions is not None:
            self.default_permissions = default_permissions
        if trickle_down is not None:
            self.trickle_down = trickle_down
        if make_data_public is not None:
            self.make_data_public = make_data_public

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


        :return: The permissions of this ApplyGenericPermissionsParameter.  # noqa: E501
        :rtype: list[UserGroupPermission]
        """
        return self._permissions

    @permissions.setter
    def permissions(self, permissions):
        """Sets the permissions of this ApplyGenericPermissionsParameter.


        :param permissions: The permissions of this ApplyGenericPermissionsParameter.  # noqa: E501
        :type: list[UserGroupPermission]
        """

        self._permissions = permissions

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


        :return: The default_permissions of this ApplyGenericPermissionsParameter.  # noqa: E501
        :rtype: list[DefaultPermissions]
        """
        return self._default_permissions

    @default_permissions.setter
    def default_permissions(self, default_permissions):
        """Sets the default_permissions of this ApplyGenericPermissionsParameter.


        :param default_permissions: The default_permissions of this ApplyGenericPermissionsParameter.  # noqa: E501
        :type: list[DefaultPermissions]
        """

        self._default_permissions = default_permissions

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


        :return: The trickle_down of this ApplyGenericPermissionsParameter.  # noqa: E501
        :rtype: bool
        """
        return self._trickle_down

    @trickle_down.setter
    def trickle_down(self, trickle_down):
        """Sets the trickle_down of this ApplyGenericPermissionsParameter.


        :param trickle_down: The trickle_down of this ApplyGenericPermissionsParameter.  # noqa: E501
        :type: bool
        """

        self._trickle_down = trickle_down

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


        :return: The make_data_public of this ApplyGenericPermissionsParameter.  # noqa: E501
        :rtype: bool
        """
        return self._make_data_public

    @make_data_public.setter
    def make_data_public(self, make_data_public):
        """Sets the make_data_public of this ApplyGenericPermissionsParameter.


        :param make_data_public: The make_data_public of this ApplyGenericPermissionsParameter.  # noqa: E501
        :type: bool
        """

        self._make_data_public = make_data_public

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

        return self.__dict__ == other.__dict__

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