# coding: utf-8

"""
    Task Execution Service

    No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)  # noqa: E501

    The version of the OpenAPI document: v1
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from libica.openapi.libtes.configuration import Configuration


class HeartbeatTaskRunRequest(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 = {
        'last_heartbeat': 'bool',
        'pod_name': 'str',
        'pod_uid': 'str',
        'pod_hardware_details': 'str',
        'job_retry_count': 'int',
        'nonce': 'str',
        'container_status': 'list[ContainerStatus]'
    }

    attribute_map = {
        'last_heartbeat': 'lastHeartbeat',
        'pod_name': 'podName',
        'pod_uid': 'podUID',
        'pod_hardware_details': 'podHardwareDetails',
        'job_retry_count': 'jobRetryCount',
        'nonce': 'nonce',
        'container_status': 'containerStatus'
    }

    def __init__(self, last_heartbeat=None, pod_name=None, pod_uid=None, pod_hardware_details=None, job_retry_count=None, nonce=None, container_status=None, local_vars_configuration=None):  # noqa: E501
        """HeartbeatTaskRunRequest - 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._last_heartbeat = None
        self._pod_name = None
        self._pod_uid = None
        self._pod_hardware_details = None
        self._job_retry_count = None
        self._nonce = None
        self._container_status = None
        self.discriminator = None

        if last_heartbeat is not None:
            self.last_heartbeat = last_heartbeat
        if pod_name is not None:
            self.pod_name = pod_name
        if pod_uid is not None:
            self.pod_uid = pod_uid
        if pod_hardware_details is not None:
            self.pod_hardware_details = pod_hardware_details
        if job_retry_count is not None:
            self.job_retry_count = job_retry_count
        if nonce is not None:
            self.nonce = nonce
        if container_status is not None:
            self.container_status = container_status

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

        LastHeartbeat  # noqa: E501

        :return: The last_heartbeat of this HeartbeatTaskRunRequest.  # noqa: E501
        :rtype: bool
        """
        return self._last_heartbeat

    @last_heartbeat.setter
    def last_heartbeat(self, last_heartbeat):
        """Sets the last_heartbeat of this HeartbeatTaskRunRequest.

        LastHeartbeat  # noqa: E501

        :param last_heartbeat: The last_heartbeat of this HeartbeatTaskRunRequest.  # noqa: E501
        :type: bool
        """

        self._last_heartbeat = last_heartbeat

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


        :return: The pod_name of this HeartbeatTaskRunRequest.  # noqa: E501
        :rtype: str
        """
        return self._pod_name

    @pod_name.setter
    def pod_name(self, pod_name):
        """Sets the pod_name of this HeartbeatTaskRunRequest.


        :param pod_name: The pod_name of this HeartbeatTaskRunRequest.  # noqa: E501
        :type: str
        """

        self._pod_name = pod_name

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


        :return: The pod_uid of this HeartbeatTaskRunRequest.  # noqa: E501
        :rtype: str
        """
        return self._pod_uid

    @pod_uid.setter
    def pod_uid(self, pod_uid):
        """Sets the pod_uid of this HeartbeatTaskRunRequest.


        :param pod_uid: The pod_uid of this HeartbeatTaskRunRequest.  # noqa: E501
        :type: str
        """

        self._pod_uid = pod_uid

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


        :return: The pod_hardware_details of this HeartbeatTaskRunRequest.  # noqa: E501
        :rtype: str
        """
        return self._pod_hardware_details

    @pod_hardware_details.setter
    def pod_hardware_details(self, pod_hardware_details):
        """Sets the pod_hardware_details of this HeartbeatTaskRunRequest.


        :param pod_hardware_details: The pod_hardware_details of this HeartbeatTaskRunRequest.  # noqa: E501
        :type: str
        """

        self._pod_hardware_details = pod_hardware_details

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


        :return: The job_retry_count of this HeartbeatTaskRunRequest.  # noqa: E501
        :rtype: int
        """
        return self._job_retry_count

    @job_retry_count.setter
    def job_retry_count(self, job_retry_count):
        """Sets the job_retry_count of this HeartbeatTaskRunRequest.


        :param job_retry_count: The job_retry_count of this HeartbeatTaskRunRequest.  # noqa: E501
        :type: int
        """

        self._job_retry_count = job_retry_count

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


        :return: The nonce of this HeartbeatTaskRunRequest.  # noqa: E501
        :rtype: str
        """
        return self._nonce

    @nonce.setter
    def nonce(self, nonce):
        """Sets the nonce of this HeartbeatTaskRunRequest.


        :param nonce: The nonce of this HeartbeatTaskRunRequest.  # noqa: E501
        :type: str
        """

        self._nonce = nonce

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


        :return: The container_status of this HeartbeatTaskRunRequest.  # noqa: E501
        :rtype: list[ContainerStatus]
        """
        return self._container_status

    @container_status.setter
    def container_status(self, container_status):
        """Sets the container_status of this HeartbeatTaskRunRequest.


        :param container_status: The container_status of this HeartbeatTaskRunRequest.  # noqa: E501
        :type: list[ContainerStatus]
        """

        self._container_status = container_status

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

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