# 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 DeliverabilitySimulationJobDto(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 = {
        'id': 'str',
        'test_id': 'str',
        'scope': 'str',
        'status': 'str',
        'created_at': 'datetime',
        'updated_at': 'datetime',
        'started_at': 'datetime',
        'completed_at': 'datetime',
        'total_targets': 'int',
        'total_planned_sends': 'int',
        'next_send_index': 'int',
        'sent_count': 'int',
        'success_count': 'int',
        'failure_count': 'int',
        'progress_percent': 'float',
        'active_target_label': 'str',
        'estimated_remaining_ms': 'int',
        'config_snapshot': 'DeliverabilitySimulationJobConfigDto',
        'error_summary': 'DeliverabilitySimulationJobErrorSummaryDto'
    }

    attribute_map = {
        'id': 'id',
        'test_id': 'testId',
        'scope': 'scope',
        'status': 'status',
        'created_at': 'createdAt',
        'updated_at': 'updatedAt',
        'started_at': 'startedAt',
        'completed_at': 'completedAt',
        'total_targets': 'totalTargets',
        'total_planned_sends': 'totalPlannedSends',
        'next_send_index': 'nextSendIndex',
        'sent_count': 'sentCount',
        'success_count': 'successCount',
        'failure_count': 'failureCount',
        'progress_percent': 'progressPercent',
        'active_target_label': 'activeTargetLabel',
        'estimated_remaining_ms': 'estimatedRemainingMs',
        'config_snapshot': 'configSnapshot',
        'error_summary': 'errorSummary'
    }

    def __init__(self, id=None, test_id=None, scope=None, status=None, created_at=None, updated_at=None, started_at=None, completed_at=None, total_targets=None, total_planned_sends=None, next_send_index=None, sent_count=None, success_count=None, failure_count=None, progress_percent=None, active_target_label=None, estimated_remaining_ms=None, config_snapshot=None, error_summary=None, local_vars_configuration=None):  # noqa: E501
        """DeliverabilitySimulationJobDto - 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._id = None
        self._test_id = None
        self._scope = None
        self._status = None
        self._created_at = None
        self._updated_at = None
        self._started_at = None
        self._completed_at = None
        self._total_targets = None
        self._total_planned_sends = None
        self._next_send_index = None
        self._sent_count = None
        self._success_count = None
        self._failure_count = None
        self._progress_percent = None
        self._active_target_label = None
        self._estimated_remaining_ms = None
        self._config_snapshot = None
        self._error_summary = None
        self.discriminator = None

        self.id = id
        self.test_id = test_id
        self.scope = scope
        self.status = status
        self.created_at = created_at
        self.updated_at = updated_at
        self.started_at = started_at
        self.completed_at = completed_at
        self.total_targets = total_targets
        self.total_planned_sends = total_planned_sends
        self.next_send_index = next_send_index
        self.sent_count = sent_count
        self.success_count = success_count
        self.failure_count = failure_count
        self.progress_percent = progress_percent
        self.active_target_label = active_target_label
        self.estimated_remaining_ms = estimated_remaining_ms
        self.config_snapshot = config_snapshot
        self.error_summary = error_summary

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


        :return: The id of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: str
        """
        return self._id

    @id.setter
    def id(self, id):
        """Sets the id of this DeliverabilitySimulationJobDto.


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

        self._id = id

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


        :return: The test_id of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: str
        """
        return self._test_id

    @test_id.setter
    def test_id(self, test_id):
        """Sets the test_id of this DeliverabilitySimulationJobDto.


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

        self._test_id = test_id

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


        :return: The scope of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: str
        """
        return self._scope

    @scope.setter
    def scope(self, scope):
        """Sets the scope of this DeliverabilitySimulationJobDto.


        :param scope: The scope of this DeliverabilitySimulationJobDto.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and scope is None:  # noqa: E501
            raise ValueError("Invalid value for `scope`, must not be `None`")  # noqa: E501
        allowed_values = ["INBOX", "PHONE"]  # noqa: E501
        if self.local_vars_configuration.client_side_validation and scope not in allowed_values:  # noqa: E501
            raise ValueError(
                "Invalid value for `scope` ({0}), must be one of {1}"  # noqa: E501
                .format(scope, allowed_values)
            )

        self._scope = scope

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


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

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


        :param status: The status of this DeliverabilitySimulationJobDto.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and status is None:  # noqa: E501
            raise ValueError("Invalid value for `status`, must not be `None`")  # noqa: E501
        allowed_values = ["RUNNING", "PAUSED", "CANCELLED", "COMPLETED", "FAILED"]  # noqa: E501
        if self.local_vars_configuration.client_side_validation and status not in allowed_values:  # noqa: E501
            raise ValueError(
                "Invalid value for `status` ({0}), must be one of {1}"  # noqa: E501
                .format(status, allowed_values)
            )

        self._status = status

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


        :return: The created_at of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: datetime
        """
        return self._created_at

    @created_at.setter
    def created_at(self, created_at):
        """Sets the created_at of this DeliverabilitySimulationJobDto.


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

        self._created_at = created_at

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


        :return: The updated_at of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: datetime
        """
        return self._updated_at

    @updated_at.setter
    def updated_at(self, updated_at):
        """Sets the updated_at of this DeliverabilitySimulationJobDto.


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

        self._updated_at = updated_at

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


        :return: The started_at of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: datetime
        """
        return self._started_at

    @started_at.setter
    def started_at(self, started_at):
        """Sets the started_at of this DeliverabilitySimulationJobDto.


        :param started_at: The started_at of this DeliverabilitySimulationJobDto.  # noqa: E501
        :type: datetime
        """

        self._started_at = started_at

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


        :return: The completed_at of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: datetime
        """
        return self._completed_at

    @completed_at.setter
    def completed_at(self, completed_at):
        """Sets the completed_at of this DeliverabilitySimulationJobDto.


        :param completed_at: The completed_at of this DeliverabilitySimulationJobDto.  # noqa: E501
        :type: datetime
        """

        self._completed_at = completed_at

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


        :return: The total_targets of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: int
        """
        return self._total_targets

    @total_targets.setter
    def total_targets(self, total_targets):
        """Sets the total_targets of this DeliverabilitySimulationJobDto.


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

        self._total_targets = total_targets

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


        :return: The total_planned_sends of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: int
        """
        return self._total_planned_sends

    @total_planned_sends.setter
    def total_planned_sends(self, total_planned_sends):
        """Sets the total_planned_sends of this DeliverabilitySimulationJobDto.


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

        self._total_planned_sends = total_planned_sends

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


        :return: The next_send_index of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: int
        """
        return self._next_send_index

    @next_send_index.setter
    def next_send_index(self, next_send_index):
        """Sets the next_send_index of this DeliverabilitySimulationJobDto.


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

        self._next_send_index = next_send_index

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


        :return: The sent_count of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: int
        """
        return self._sent_count

    @sent_count.setter
    def sent_count(self, sent_count):
        """Sets the sent_count of this DeliverabilitySimulationJobDto.


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

        self._sent_count = sent_count

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


        :return: The success_count of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: int
        """
        return self._success_count

    @success_count.setter
    def success_count(self, success_count):
        """Sets the success_count of this DeliverabilitySimulationJobDto.


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

        self._success_count = success_count

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


        :return: The failure_count of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: int
        """
        return self._failure_count

    @failure_count.setter
    def failure_count(self, failure_count):
        """Sets the failure_count of this DeliverabilitySimulationJobDto.


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

        self._failure_count = failure_count

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


        :return: The progress_percent of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: float
        """
        return self._progress_percent

    @progress_percent.setter
    def progress_percent(self, progress_percent):
        """Sets the progress_percent of this DeliverabilitySimulationJobDto.


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

        self._progress_percent = progress_percent

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


        :return: The active_target_label of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: str
        """
        return self._active_target_label

    @active_target_label.setter
    def active_target_label(self, active_target_label):
        """Sets the active_target_label of this DeliverabilitySimulationJobDto.


        :param active_target_label: The active_target_label of this DeliverabilitySimulationJobDto.  # noqa: E501
        :type: str
        """

        self._active_target_label = active_target_label

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


        :return: The estimated_remaining_ms of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: int
        """
        return self._estimated_remaining_ms

    @estimated_remaining_ms.setter
    def estimated_remaining_ms(self, estimated_remaining_ms):
        """Sets the estimated_remaining_ms of this DeliverabilitySimulationJobDto.


        :param estimated_remaining_ms: The estimated_remaining_ms of this DeliverabilitySimulationJobDto.  # noqa: E501
        :type: int
        """

        self._estimated_remaining_ms = estimated_remaining_ms

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


        :return: The config_snapshot of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: DeliverabilitySimulationJobConfigDto
        """
        return self._config_snapshot

    @config_snapshot.setter
    def config_snapshot(self, config_snapshot):
        """Sets the config_snapshot of this DeliverabilitySimulationJobDto.


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

        self._config_snapshot = config_snapshot

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


        :return: The error_summary of this DeliverabilitySimulationJobDto.  # noqa: E501
        :rtype: DeliverabilitySimulationJobErrorSummaryDto
        """
        return self._error_summary

    @error_summary.setter
    def error_summary(self, error_summary):
        """Sets the error_summary of this DeliverabilitySimulationJobDto.


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

        self._error_summary = error_summary

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

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