# 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 DomainMonitorInsightsDto(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 = {
        'monitor_id': 'str',
        'since': 'datetime',
        'before': 'datetime',
        'total_runs': 'int',
        'healthy_runs': 'int',
        'degraded_runs': 'int',
        'critical_runs': 'int',
        'failed_runs': 'int',
        'success_rate': 'float',
        'average_health_score': 'float',
        'current_healthy_streak': 'int',
        'best_healthy_streak': 'int',
        'good_performance_signals': 'list[str]',
        'attention_signals': 'list[str]',
        'top_findings': 'list[str]',
        'latest_run': 'DomainMonitorRunDto'
    }

    attribute_map = {
        'monitor_id': 'monitorId',
        'since': 'since',
        'before': 'before',
        'total_runs': 'totalRuns',
        'healthy_runs': 'healthyRuns',
        'degraded_runs': 'degradedRuns',
        'critical_runs': 'criticalRuns',
        'failed_runs': 'failedRuns',
        'success_rate': 'successRate',
        'average_health_score': 'averageHealthScore',
        'current_healthy_streak': 'currentHealthyStreak',
        'best_healthy_streak': 'bestHealthyStreak',
        'good_performance_signals': 'goodPerformanceSignals',
        'attention_signals': 'attentionSignals',
        'top_findings': 'topFindings',
        'latest_run': 'latestRun'
    }

    def __init__(self, monitor_id=None, since=None, before=None, total_runs=None, healthy_runs=None, degraded_runs=None, critical_runs=None, failed_runs=None, success_rate=None, average_health_score=None, current_healthy_streak=None, best_healthy_streak=None, good_performance_signals=None, attention_signals=None, top_findings=None, latest_run=None, local_vars_configuration=None):  # noqa: E501
        """DomainMonitorInsightsDto - 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._monitor_id = None
        self._since = None
        self._before = None
        self._total_runs = None
        self._healthy_runs = None
        self._degraded_runs = None
        self._critical_runs = None
        self._failed_runs = None
        self._success_rate = None
        self._average_health_score = None
        self._current_healthy_streak = None
        self._best_healthy_streak = None
        self._good_performance_signals = None
        self._attention_signals = None
        self._top_findings = None
        self._latest_run = None
        self.discriminator = None

        self.monitor_id = monitor_id
        self.since = since
        self.before = before
        self.total_runs = total_runs
        self.healthy_runs = healthy_runs
        self.degraded_runs = degraded_runs
        self.critical_runs = critical_runs
        self.failed_runs = failed_runs
        self.success_rate = success_rate
        self.average_health_score = average_health_score
        self.current_healthy_streak = current_healthy_streak
        self.best_healthy_streak = best_healthy_streak
        self.good_performance_signals = good_performance_signals
        self.attention_signals = attention_signals
        self.top_findings = top_findings
        if latest_run is not None:
            self.latest_run = latest_run

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


        :return: The monitor_id of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: str
        """
        return self._monitor_id

    @monitor_id.setter
    def monitor_id(self, monitor_id):
        """Sets the monitor_id of this DomainMonitorInsightsDto.


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

        self._monitor_id = monitor_id

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


        :return: The since of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: datetime
        """
        return self._since

    @since.setter
    def since(self, since):
        """Sets the since of this DomainMonitorInsightsDto.


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

        self._since = since

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


        :return: The before of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: datetime
        """
        return self._before

    @before.setter
    def before(self, before):
        """Sets the before of this DomainMonitorInsightsDto.


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

        self._before = before

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


        :return: The total_runs of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: int
        """
        return self._total_runs

    @total_runs.setter
    def total_runs(self, total_runs):
        """Sets the total_runs of this DomainMonitorInsightsDto.


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

        self._total_runs = total_runs

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


        :return: The healthy_runs of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: int
        """
        return self._healthy_runs

    @healthy_runs.setter
    def healthy_runs(self, healthy_runs):
        """Sets the healthy_runs of this DomainMonitorInsightsDto.


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

        self._healthy_runs = healthy_runs

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


        :return: The degraded_runs of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: int
        """
        return self._degraded_runs

    @degraded_runs.setter
    def degraded_runs(self, degraded_runs):
        """Sets the degraded_runs of this DomainMonitorInsightsDto.


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

        self._degraded_runs = degraded_runs

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


        :return: The critical_runs of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: int
        """
        return self._critical_runs

    @critical_runs.setter
    def critical_runs(self, critical_runs):
        """Sets the critical_runs of this DomainMonitorInsightsDto.


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

        self._critical_runs = critical_runs

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


        :return: The failed_runs of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: int
        """
        return self._failed_runs

    @failed_runs.setter
    def failed_runs(self, failed_runs):
        """Sets the failed_runs of this DomainMonitorInsightsDto.


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

        self._failed_runs = failed_runs

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


        :return: The success_rate of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: float
        """
        return self._success_rate

    @success_rate.setter
    def success_rate(self, success_rate):
        """Sets the success_rate of this DomainMonitorInsightsDto.


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

        self._success_rate = success_rate

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


        :return: The average_health_score of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: float
        """
        return self._average_health_score

    @average_health_score.setter
    def average_health_score(self, average_health_score):
        """Sets the average_health_score of this DomainMonitorInsightsDto.


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

        self._average_health_score = average_health_score

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


        :return: The current_healthy_streak of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: int
        """
        return self._current_healthy_streak

    @current_healthy_streak.setter
    def current_healthy_streak(self, current_healthy_streak):
        """Sets the current_healthy_streak of this DomainMonitorInsightsDto.


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

        self._current_healthy_streak = current_healthy_streak

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


        :return: The best_healthy_streak of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: int
        """
        return self._best_healthy_streak

    @best_healthy_streak.setter
    def best_healthy_streak(self, best_healthy_streak):
        """Sets the best_healthy_streak of this DomainMonitorInsightsDto.


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

        self._best_healthy_streak = best_healthy_streak

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


        :return: The good_performance_signals of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: list[str]
        """
        return self._good_performance_signals

    @good_performance_signals.setter
    def good_performance_signals(self, good_performance_signals):
        """Sets the good_performance_signals of this DomainMonitorInsightsDto.


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

        self._good_performance_signals = good_performance_signals

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


        :return: The attention_signals of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: list[str]
        """
        return self._attention_signals

    @attention_signals.setter
    def attention_signals(self, attention_signals):
        """Sets the attention_signals of this DomainMonitorInsightsDto.


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

        self._attention_signals = attention_signals

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


        :return: The top_findings of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: list[str]
        """
        return self._top_findings

    @top_findings.setter
    def top_findings(self, top_findings):
        """Sets the top_findings of this DomainMonitorInsightsDto.


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

        self._top_findings = top_findings

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


        :return: The latest_run of this DomainMonitorInsightsDto.  # noqa: E501
        :rtype: DomainMonitorRunDto
        """
        return self._latest_run

    @latest_run.setter
    def latest_run(self, latest_run):
        """Sets the latest_run of this DomainMonitorInsightsDto.


        :param latest_run: The latest_run of this DomainMonitorInsightsDto.  # noqa: E501
        :type: DomainMonitorRunDto
        """

        self._latest_run = latest_run

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

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