# coding: utf-8

"""
    communications-email

    These APIs ensures an easy integration process of email management for developers to send, read, and track email histories within applications.  # noqa: E501

    OpenAPI spec version: 1.0.0
    
    Generated by: phenom
"""

import pprint
import re  # noqa: F401

import six

class EmailHistoryData(object):
    """
    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 = {
        'created_date': 'int',
        'to_name': 'str',
        'subject': 'str',
        'from_name': 'str',
        'to_email': 'str',
        'from_email': 'str',
        'source': 'str',
        'email_activity_id': 'str'
    }

    attribute_map = {
        'created_date': 'createdDate',
        'to_name': 'toName',
        'subject': 'subject',
        'from_name': 'fromName',
        'to_email': 'toEmail',
        'from_email': 'fromEmail',
        'source': 'source',
        'email_activity_id': 'emailActivityId'
    }

    def __init__(self, created_date=None, to_name=None, subject=None, from_name=None, to_email=None, from_email=None, source=None, email_activity_id=None):  # noqa: E501
        """EmailHistoryData - a model defined in Swagger"""  # noqa: E501
        self._created_date = None
        self._to_name = None
        self._subject = None
        self._from_name = None
        self._to_email = None
        self._from_email = None
        self._source = None
        self._email_activity_id = None
        self.discriminator = None
        if created_date is not None:
            self.created_date = created_date
        if to_name is not None:
            self.to_name = to_name
        if subject is not None:
            self.subject = subject
        if from_name is not None:
            self.from_name = from_name
        if to_email is not None:
            self.to_email = to_email
        if from_email is not None:
            self.from_email = from_email
        if source is not None:
            self.source = source
        if email_activity_id is not None:
            self.email_activity_id = email_activity_id

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

        Email created Date.  # noqa: E501

        :return: The created_date of this EmailHistoryData.  # noqa: E501
        :rtype: int
        """
        return self._created_date

    @created_date.setter
    def created_date(self, created_date):
        """Sets the created_date of this EmailHistoryData.

        Email created Date.  # noqa: E501

        :param created_date: The created_date of this EmailHistoryData.  # noqa: E501
        :type: int
        """

        self._created_date = created_date

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

        Recipient's name in the email.  # noqa: E501

        :return: The to_name of this EmailHistoryData.  # noqa: E501
        :rtype: str
        """
        return self._to_name

    @to_name.setter
    def to_name(self, to_name):
        """Sets the to_name of this EmailHistoryData.

        Recipient's name in the email.  # noqa: E501

        :param to_name: The to_name of this EmailHistoryData.  # noqa: E501
        :type: str
        """

        self._to_name = to_name

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

        Subject of the email.  # noqa: E501

        :return: The subject of this EmailHistoryData.  # noqa: E501
        :rtype: str
        """
        return self._subject

    @subject.setter
    def subject(self, subject):
        """Sets the subject of this EmailHistoryData.

        Subject of the email.  # noqa: E501

        :param subject: The subject of this EmailHistoryData.  # noqa: E501
        :type: str
        """

        self._subject = subject

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

        Sender Name in the email.  # noqa: E501

        :return: The from_name of this EmailHistoryData.  # noqa: E501
        :rtype: str
        """
        return self._from_name

    @from_name.setter
    def from_name(self, from_name):
        """Sets the from_name of this EmailHistoryData.

        Sender Name in the email.  # noqa: E501

        :param from_name: The from_name of this EmailHistoryData.  # noqa: E501
        :type: str
        """

        self._from_name = from_name

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

        Recipient's email address.  # noqa: E501

        :return: The to_email of this EmailHistoryData.  # noqa: E501
        :rtype: str
        """
        return self._to_email

    @to_email.setter
    def to_email(self, to_email):
        """Sets the to_email of this EmailHistoryData.

        Recipient's email address.  # noqa: E501

        :param to_email: The to_email of this EmailHistoryData.  # noqa: E501
        :type: str
        """

        self._to_email = to_email

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

        Sender's email address.  # noqa: E501

        :return: The from_email of this EmailHistoryData.  # noqa: E501
        :rtype: str
        """
        return self._from_email

    @from_email.setter
    def from_email(self, from_email):
        """Sets the from_email of this EmailHistoryData.

        Sender's email address.  # noqa: E501

        :param from_email: The from_email of this EmailHistoryData.  # noqa: E501
        :type: str
        """

        self._from_email = from_email

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

        Source for the email history.  # noqa: E501

        :return: The source of this EmailHistoryData.  # noqa: E501
        :rtype: str
        """
        return self._source

    @source.setter
    def source(self, source):
        """Sets the source of this EmailHistoryData.

        Source for the email history.  # noqa: E501

        :param source: The source of this EmailHistoryData.  # noqa: E501
        :type: str
        """

        self._source = source

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

        Activity ID of the email.  # noqa: E501

        :return: The email_activity_id of this EmailHistoryData.  # noqa: E501
        :rtype: str
        """
        return self._email_activity_id

    @email_activity_id.setter
    def email_activity_id(self, email_activity_id):
        """Sets the email_activity_id of this EmailHistoryData.

        Activity ID of the email.  # noqa: E501

        :param email_activity_id: The email_activity_id of this EmailHistoryData.  # noqa: E501
        :type: str
        """

        self._email_activity_id = email_activity_id

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

        return self.__dict__ == other.__dict__

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