<gh_stars>0
# coding: utf-8

"""
    Mail Baby API

    This is an API defintion for accesssing the Mail.Baby mail service.  # noqa: E501

    OpenAPI spec version: 1.0.0
    Contact: <EMAIL>
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""

import pprint
import re  # noqa: F401

import six

class SendMail(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 = {
        'to': 'str',
        '_from': 'str',
        'subject': 'str',
        'body': 'str'
    }

    attribute_map = {
        'to': 'to',
        '_from': 'from',
        'subject': 'subject',
        'body': 'body'
    }

    def __init__(self, to=None, _from=None, subject=None, body=None):  # noqa: E501
        """SendMail - a model defined in Swagger"""  # noqa: E501
        self._to = None
        self.__from = None
        self._subject = None
        self._body = None
        self.discriminator = None
        self.to = to
        self._from = _from
        self.subject = subject
        self.body = body

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

        The Contact whom is the primary recipient of this email.  # noqa: E501

        :return: The to of this SendMail.  # noqa: E501
        :rtype: str
        """
        return self._to

    @to.setter
    def to(self, to):
        """Sets the to of this SendMail.

        The Contact whom is the primary recipient of this email.  # noqa: E501

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

        self._to = to

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

        The contact whom is the this email is from.  # noqa: E501

        :return: The _from of this SendMail.  # noqa: E501
        :rtype: str
        """
        return self.__from

    @_from.setter
    def _from(self, _from):
        """Sets the _from of this SendMail.

        The contact whom is the this email is from.  # noqa: E501

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

        self.__from = _from

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

        The subject or title of the email  # noqa: E501

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

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

        The subject or title of the email  # noqa: E501

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

        self._subject = subject

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

        The main email contents.  # noqa: E501

        :return: The body of this SendMail.  # noqa: E501
        :rtype: str
        """
        return self._body

    @body.setter
    def body(self, body):
        """Sets the body of this SendMail.

        The main email contents.  # noqa: E501

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

        self._body = body

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

        return self.__dict__ == other.__dict__

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