# coding: utf-8

"""
    MailSlurp API

    MailSlurp is an API for sending and receiving emails and SMS from dynamically allocated email addresses and phone numbers. It's designed for developers and QA teams to test applications, process inbound emails, send templated notifications, attachments, and more.  ## Resources  - [Homepage](https://www.mailslurp.com) - Get an [API KEY](https://app.mailslurp.com/sign-up/) - Generated [SDK Clients](https://docs.mailslurp.com/) - [Examples](https://github.com/mailslurp/examples) repository  # noqa: E501

    The version of the OpenAPI document: 6.5.2
    Contact: contact@mailslurp.dev
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from mailslurp_client.configuration import Configuration


class LookupSpfDomainResults(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 = {
        'valid': 'bool',
        'host': 'str',
        'record': 'str',
        'flattened_record': 'str',
        'lookup_count': 'int',
        'mechanisms': 'list[SpfMechanismResult]',
        'warnings': 'list[str]',
        'errors': 'list[str]'
    }

    attribute_map = {
        'valid': 'valid',
        'host': 'host',
        'record': 'record',
        'flattened_record': 'flattenedRecord',
        'lookup_count': 'lookupCount',
        'mechanisms': 'mechanisms',
        'warnings': 'warnings',
        'errors': 'errors'
    }

    def __init__(self, valid=None, host=None, record=None, flattened_record=None, lookup_count=None, mechanisms=None, warnings=None, errors=None, local_vars_configuration=None):  # noqa: E501
        """LookupSpfDomainResults - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration()
        self.local_vars_configuration = local_vars_configuration

        self._valid = None
        self._host = None
        self._record = None
        self._flattened_record = None
        self._lookup_count = None
        self._mechanisms = None
        self._warnings = None
        self._errors = None
        self.discriminator = None

        self.valid = valid
        self.host = host
        if record is not None:
            self.record = record
        if flattened_record is not None:
            self.flattened_record = flattened_record
        self.lookup_count = lookup_count
        self.mechanisms = mechanisms
        self.warnings = warnings
        self.errors = errors

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


        :return: The valid of this LookupSpfDomainResults.  # noqa: E501
        :rtype: bool
        """
        return self._valid

    @valid.setter
    def valid(self, valid):
        """Sets the valid of this LookupSpfDomainResults.


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

        self._valid = valid

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


        :return: The host of this LookupSpfDomainResults.  # noqa: E501
        :rtype: str
        """
        return self._host

    @host.setter
    def host(self, host):
        """Sets the host of this LookupSpfDomainResults.


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

        self._host = host

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


        :return: The record of this LookupSpfDomainResults.  # noqa: E501
        :rtype: str
        """
        return self._record

    @record.setter
    def record(self, record):
        """Sets the record of this LookupSpfDomainResults.


        :param record: The record of this LookupSpfDomainResults.  # noqa: E501
        :type: str
        """

        self._record = record

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


        :return: The flattened_record of this LookupSpfDomainResults.  # noqa: E501
        :rtype: str
        """
        return self._flattened_record

    @flattened_record.setter
    def flattened_record(self, flattened_record):
        """Sets the flattened_record of this LookupSpfDomainResults.


        :param flattened_record: The flattened_record of this LookupSpfDomainResults.  # noqa: E501
        :type: str
        """

        self._flattened_record = flattened_record

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


        :return: The lookup_count of this LookupSpfDomainResults.  # noqa: E501
        :rtype: int
        """
        return self._lookup_count

    @lookup_count.setter
    def lookup_count(self, lookup_count):
        """Sets the lookup_count of this LookupSpfDomainResults.


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

        self._lookup_count = lookup_count

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


        :return: The mechanisms of this LookupSpfDomainResults.  # noqa: E501
        :rtype: list[SpfMechanismResult]
        """
        return self._mechanisms

    @mechanisms.setter
    def mechanisms(self, mechanisms):
        """Sets the mechanisms of this LookupSpfDomainResults.


        :param mechanisms: The mechanisms of this LookupSpfDomainResults.  # noqa: E501
        :type: list[SpfMechanismResult]
        """
        if self.local_vars_configuration.client_side_validation and mechanisms is None:  # noqa: E501
            raise ValueError("Invalid value for `mechanisms`, must not be `None`")  # noqa: E501

        self._mechanisms = mechanisms

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


        :return: The warnings of this LookupSpfDomainResults.  # noqa: E501
        :rtype: list[str]
        """
        return self._warnings

    @warnings.setter
    def warnings(self, warnings):
        """Sets the warnings of this LookupSpfDomainResults.


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

        self._warnings = warnings

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


        :return: The errors of this LookupSpfDomainResults.  # noqa: E501
        :rtype: list[str]
        """
        return self._errors

    @errors.setter
    def errors(self, errors):
        """Sets the errors of this LookupSpfDomainResults.


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

        self._errors = errors

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

        for attr, _ in six.iteritems(self.openapi_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

        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, LookupSpfDomainResults):
            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, LookupSpfDomainResults):
            return True

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