# coding: utf-8

"""
    Lists

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

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


try:
    from inspect import getfullargspec
except ImportError:
    from inspect import getargspec as getfullargspec
import pprint
import re  # noqa: F401
import six

from hubspot.crm.lists.configuration import Configuration


class ListCreateRequest(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 = {
        "object_type_id": "str",
        "processing_type": "str",
        "custom_properties": "dict[str, str]",
        "list_folder_id": "int",
        "name": "str",
        "filter_branch": "PublicPropertyAssociationFilterBranchFilterBranchesInner",
    }

    attribute_map = {
        "object_type_id": "objectTypeId",
        "processing_type": "processingType",
        "custom_properties": "customProperties",
        "list_folder_id": "listFolderId",
        "name": "name",
        "filter_branch": "filterBranch",
    }

    def __init__(self, object_type_id=None, processing_type=None, custom_properties=None, list_folder_id=None, name=None, filter_branch=None, local_vars_configuration=None):  # noqa: E501
        """ListCreateRequest - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration.get_default_copy()
        self.local_vars_configuration = local_vars_configuration

        self._object_type_id = None
        self._processing_type = None
        self._custom_properties = None
        self._list_folder_id = None
        self._name = None
        self._filter_branch = None
        self.discriminator = None

        self.object_type_id = object_type_id
        self.processing_type = processing_type
        if custom_properties is not None:
            self.custom_properties = custom_properties
        if list_folder_id is not None:
            self.list_folder_id = list_folder_id
        self.name = name
        if filter_branch is not None:
            self.filter_branch = filter_branch

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

        The object type ID of the type of objects that the list will store.  # noqa: E501

        :return: The object_type_id of this ListCreateRequest.  # noqa: E501
        :rtype: str
        """
        return self._object_type_id

    @object_type_id.setter
    def object_type_id(self, object_type_id):
        """Sets the object_type_id of this ListCreateRequest.

        The object type ID of the type of objects that the list will store.  # noqa: E501

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

        self._object_type_id = object_type_id

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

        The processing type of the list. One of: `SNAPSHOT`, `MANUAL`, or `DYNAMIC`.  # noqa: E501

        :return: The processing_type of this ListCreateRequest.  # noqa: E501
        :rtype: str
        """
        return self._processing_type

    @processing_type.setter
    def processing_type(self, processing_type):
        """Sets the processing_type of this ListCreateRequest.

        The processing type of the list. One of: `SNAPSHOT`, `MANUAL`, or `DYNAMIC`.  # noqa: E501

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

        self._processing_type = processing_type

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

        The list of custom properties to tie to the list. Custom property name is the key, the value is the value.  # noqa: E501

        :return: The custom_properties of this ListCreateRequest.  # noqa: E501
        :rtype: dict[str, str]
        """
        return self._custom_properties

    @custom_properties.setter
    def custom_properties(self, custom_properties):
        """Sets the custom_properties of this ListCreateRequest.

        The list of custom properties to tie to the list. Custom property name is the key, the value is the value.  # noqa: E501

        :param custom_properties: The custom_properties of this ListCreateRequest.  # noqa: E501
        :type custom_properties: dict[str, str]
        """

        self._custom_properties = custom_properties

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

        The ID of the folder that the list should be created in. If left blank, then the list will be created in the root of the list folder structure.  # noqa: E501

        :return: The list_folder_id of this ListCreateRequest.  # noqa: E501
        :rtype: int
        """
        return self._list_folder_id

    @list_folder_id.setter
    def list_folder_id(self, list_folder_id):
        """Sets the list_folder_id of this ListCreateRequest.

        The ID of the folder that the list should be created in. If left blank, then the list will be created in the root of the list folder structure.  # noqa: E501

        :param list_folder_id: The list_folder_id of this ListCreateRequest.  # noqa: E501
        :type list_folder_id: int
        """

        self._list_folder_id = list_folder_id

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

        The name of the list, which must be globally unique across all public lists in the portal.  # noqa: E501

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

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

        The name of the list, which must be globally unique across all public lists in the portal.  # noqa: E501

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

        self._name = name

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


        :return: The filter_branch of this ListCreateRequest.  # noqa: E501
        :rtype: PublicPropertyAssociationFilterBranchFilterBranchesInner
        """
        return self._filter_branch

    @filter_branch.setter
    def filter_branch(self, filter_branch):
        """Sets the filter_branch of this ListCreateRequest.


        :param filter_branch: The filter_branch of this ListCreateRequest.  # noqa: E501
        :type filter_branch: PublicPropertyAssociationFilterBranchFilterBranchesInner
        """

        self._filter_branch = filter_branch

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

        def convert(x):
            if hasattr(x, "to_dict"):
                args = getfullargspec(x.to_dict).args
                if len(args) == 1:
                    return x.to_dict()
                else:
                    return x.to_dict(serialize)
            else:
                return x

        for attr, _ in six.iteritems(self.openapi_types):
            value = getattr(self, attr)
            attr = self.attribute_map.get(attr, attr) if serialize else attr
            if isinstance(value, list):
                result[attr] = list(map(lambda x: convert(x), value))
            elif isinstance(value, dict):
                result[attr] = dict(map(lambda item: (item[0], convert(item[1])), value.items()))
            else:
                result[attr] = convert(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, ListCreateRequest):
            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, ListCreateRequest):
            return True

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