# coding: utf-8

"""
    Mailchimp Marketing API

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

    OpenAPI spec version: 3.0.74
    Contact: apihelp@mailchimp.com
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""


import pprint
import re  # noqa: F401

import six


class AddListMembers1(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 = {
        'email_address': 'str',
        'email_type': 'str',
        'status': 'str',
        'merge_fields': 'dict(str, object)',
        'interests': 'dict(str, bool)',
        'language': 'str',
        'vip': 'bool',
        'location': 'Location',
        'marketing_permissions': 'list[MarketingPermission1]',
        'ip_signup': 'str',
        'timestamp_signup': 'datetime',
        'ip_opt': 'str',
        'timestamp_opt': 'datetime',
        'tags': 'list[str]'
    }

    attribute_map = {
        'email_address': 'email_address',
        'email_type': 'email_type',
        'status': 'status',
        'merge_fields': 'merge_fields',
        'interests': 'interests',
        'language': 'language',
        'vip': 'vip',
        'location': 'location',
        'marketing_permissions': 'marketing_permissions',
        'ip_signup': 'ip_signup',
        'timestamp_signup': 'timestamp_signup',
        'ip_opt': 'ip_opt',
        'timestamp_opt': 'timestamp_opt',
        'tags': 'tags'
    }

    def __init__(self, email_address=None, email_type=None, status=None, merge_fields=None, interests=None, language=None, vip=None, location=None, marketing_permissions=None, ip_signup=None, timestamp_signup=None, ip_opt=None, timestamp_opt=None, tags=None):  # noqa: E501
        """AddListMembers1 - a model defined in Swagger"""  # noqa: E501

        self._email_address = None
        self._email_type = None
        self._status = None
        self._merge_fields = None
        self._interests = None
        self._language = None
        self._vip = None
        self._location = None
        self._marketing_permissions = None
        self._ip_signup = None
        self._timestamp_signup = None
        self._ip_opt = None
        self._timestamp_opt = None
        self._tags = None
        self.discriminator = None

        self.email_address = email_address
        if email_type is not None:
            self.email_type = email_type
        self.status = status
        if merge_fields is not None:
            self.merge_fields = merge_fields
        if interests is not None:
            self.interests = interests
        if language is not None:
            self.language = language
        if vip is not None:
            self.vip = vip
        if location is not None:
            self.location = location
        if marketing_permissions is not None:
            self.marketing_permissions = marketing_permissions
        if ip_signup is not None:
            self.ip_signup = ip_signup
        if timestamp_signup is not None:
            self.timestamp_signup = timestamp_signup
        if ip_opt is not None:
            self.ip_opt = ip_opt
        if timestamp_opt is not None:
            self.timestamp_opt = timestamp_opt
        if tags is not None:
            self.tags = tags

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

        Email address for a subscriber.  # noqa: E501

        :return: The email_address of this AddListMembers1.  # noqa: E501
        :rtype: str
        """
        return self._email_address

    @email_address.setter
    def email_address(self, email_address):
        """Sets the email_address of this AddListMembers1.

        Email address for a subscriber.  # noqa: E501

        :param email_address: The email_address of this AddListMembers1.  # noqa: E501
        :type: str
        """
        if email_address is None:
            raise ValueError("Invalid value for `email_address`, must not be `None`")  # noqa: E501

        self._email_address = email_address

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

        Type of email this member asked to get ('html' or 'text').  # noqa: E501

        :return: The email_type of this AddListMembers1.  # noqa: E501
        :rtype: str
        """
        return self._email_type

    @email_type.setter
    def email_type(self, email_type):
        """Sets the email_type of this AddListMembers1.

        Type of email this member asked to get ('html' or 'text').  # noqa: E501

        :param email_type: The email_type of this AddListMembers1.  # noqa: E501
        :type: str
        """

        self._email_type = email_type

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

        Subscriber's current status.  # noqa: E501

        :return: The status of this AddListMembers1.  # noqa: E501
        :rtype: str
        """
        return self._status

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

        Subscriber's current status.  # noqa: E501

        :param status: The status of this AddListMembers1.  # noqa: E501
        :type: str
        """
        if status is None:
            raise ValueError("Invalid value for `status`, must not be `None`")  # noqa: E501
        allowed_values = ["subscribed", "unsubscribed", "cleaned", "pending", "transactional"]  # noqa: E501
        if status not in allowed_values:
            raise ValueError(
                "Invalid value for `status` ({0}), must be one of {1}"  # noqa: E501
                .format(status, allowed_values)
            )

        self._status = status

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

        A dictionary of merge fields where the keys are the merge tags. See the [Merge Fields documentation](https://mailchimp.com/developer/marketing/docs/merge-fields/#structure) for more about the structure.  # noqa: E501

        :return: The merge_fields of this AddListMembers1.  # noqa: E501
        :rtype: dict(str, object)
        """
        return self._merge_fields

    @merge_fields.setter
    def merge_fields(self, merge_fields):
        """Sets the merge_fields of this AddListMembers1.

        A dictionary of merge fields where the keys are the merge tags. See the [Merge Fields documentation](https://mailchimp.com/developer/marketing/docs/merge-fields/#structure) for more about the structure.  # noqa: E501

        :param merge_fields: The merge_fields of this AddListMembers1.  # noqa: E501
        :type: dict(str, object)
        """

        self._merge_fields = merge_fields

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

        The key of this object's properties is the ID of the interest in question.  # noqa: E501

        :return: The interests of this AddListMembers1.  # noqa: E501
        :rtype: dict(str, bool)
        """
        return self._interests

    @interests.setter
    def interests(self, interests):
        """Sets the interests of this AddListMembers1.

        The key of this object's properties is the ID of the interest in question.  # noqa: E501

        :param interests: The interests of this AddListMembers1.  # noqa: E501
        :type: dict(str, bool)
        """

        self._interests = interests

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

        If set/detected, the [subscriber's language](https://mailchimp.com/help/view-and-edit-contact-languages/).  # noqa: E501

        :return: The language of this AddListMembers1.  # noqa: E501
        :rtype: str
        """
        return self._language

    @language.setter
    def language(self, language):
        """Sets the language of this AddListMembers1.

        If set/detected, the [subscriber's language](https://mailchimp.com/help/view-and-edit-contact-languages/).  # noqa: E501

        :param language: The language of this AddListMembers1.  # noqa: E501
        :type: str
        """

        self._language = language

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

        [VIP status](https://mailchimp.com/help/designate-and-send-to-vip-contacts/) for subscriber.  # noqa: E501

        :return: The vip of this AddListMembers1.  # noqa: E501
        :rtype: bool
        """
        return self._vip

    @vip.setter
    def vip(self, vip):
        """Sets the vip of this AddListMembers1.

        [VIP status](https://mailchimp.com/help/designate-and-send-to-vip-contacts/) for subscriber.  # noqa: E501

        :param vip: The vip of this AddListMembers1.  # noqa: E501
        :type: bool
        """

        self._vip = vip

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


        :return: The location of this AddListMembers1.  # noqa: E501
        :rtype: Location
        """
        return self._location

    @location.setter
    def location(self, location):
        """Sets the location of this AddListMembers1.


        :param location: The location of this AddListMembers1.  # noqa: E501
        :type: Location
        """

        self._location = location

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

        The marketing permissions for the subscriber.  # noqa: E501

        :return: The marketing_permissions of this AddListMembers1.  # noqa: E501
        :rtype: list[MarketingPermission1]
        """
        return self._marketing_permissions

    @marketing_permissions.setter
    def marketing_permissions(self, marketing_permissions):
        """Sets the marketing_permissions of this AddListMembers1.

        The marketing permissions for the subscriber.  # noqa: E501

        :param marketing_permissions: The marketing_permissions of this AddListMembers1.  # noqa: E501
        :type: list[MarketingPermission1]
        """

        self._marketing_permissions = marketing_permissions

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

        IP address the subscriber signed up from.  # noqa: E501

        :return: The ip_signup of this AddListMembers1.  # noqa: E501
        :rtype: str
        """
        return self._ip_signup

    @ip_signup.setter
    def ip_signup(self, ip_signup):
        """Sets the ip_signup of this AddListMembers1.

        IP address the subscriber signed up from.  # noqa: E501

        :param ip_signup: The ip_signup of this AddListMembers1.  # noqa: E501
        :type: str
        """

        self._ip_signup = ip_signup

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

        The date and time the subscriber signed up for the list in ISO 8601 format.  # noqa: E501

        :return: The timestamp_signup of this AddListMembers1.  # noqa: E501
        :rtype: datetime
        """
        return self._timestamp_signup

    @timestamp_signup.setter
    def timestamp_signup(self, timestamp_signup):
        """Sets the timestamp_signup of this AddListMembers1.

        The date and time the subscriber signed up for the list in ISO 8601 format.  # noqa: E501

        :param timestamp_signup: The timestamp_signup of this AddListMembers1.  # noqa: E501
        :type: datetime
        """

        self._timestamp_signup = timestamp_signup

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

        The IP address the subscriber used to confirm their opt-in status.  # noqa: E501

        :return: The ip_opt of this AddListMembers1.  # noqa: E501
        :rtype: str
        """
        return self._ip_opt

    @ip_opt.setter
    def ip_opt(self, ip_opt):
        """Sets the ip_opt of this AddListMembers1.

        The IP address the subscriber used to confirm their opt-in status.  # noqa: E501

        :param ip_opt: The ip_opt of this AddListMembers1.  # noqa: E501
        :type: str
        """

        self._ip_opt = ip_opt

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

        The date and time the subscribe confirmed their opt-in status in ISO 8601 format.  # noqa: E501

        :return: The timestamp_opt of this AddListMembers1.  # noqa: E501
        :rtype: datetime
        """
        return self._timestamp_opt

    @timestamp_opt.setter
    def timestamp_opt(self, timestamp_opt):
        """Sets the timestamp_opt of this AddListMembers1.

        The date and time the subscribe confirmed their opt-in status in ISO 8601 format.  # noqa: E501

        :param timestamp_opt: The timestamp_opt of this AddListMembers1.  # noqa: E501
        :type: datetime
        """

        self._timestamp_opt = timestamp_opt

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

        The tags that are associated with a member.  # noqa: E501

        :return: The tags of this AddListMembers1.  # noqa: E501
        :rtype: list[str]
        """
        return self._tags

    @tags.setter
    def tags(self, tags):
        """Sets the tags of this AddListMembers1.

        The tags that are associated with a member.  # noqa: E501

        :param tags: The tags of this AddListMembers1.  # noqa: E501
        :type: list[str]
        """

        self._tags = tags

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

        return self.__dict__ == other.__dict__

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