# coding: utf-8

"""
    Tekton

    Python SDK for Tekton Pipeline  # noqa: E501

    OpenAPI spec version: v0.1
    
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""


import pprint
import re  # noqa: F401

import six

from kubernetes.client import V1ContainerState  # noqa: F401,E501
from tekton.models.v1_time import V1Time  # noqa: F401,E501


class V1beta1ConditionCheckStatusFields(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 = {
        'check': 'V1ContainerState',
        'completion_time': 'V1Time',
        'pod_name': 'str',
        'start_time': 'V1Time'
    }

    attribute_map = {
        'check': 'check',
        'completion_time': 'completionTime',
        'pod_name': 'podName',
        'start_time': 'startTime'
    }

    def __init__(self, check=None, completion_time=None, pod_name=None, start_time=None):  # noqa: E501
        """V1beta1ConditionCheckStatusFields - a model defined in Swagger"""  # noqa: E501

        self._check = None
        self._completion_time = None
        self._pod_name = None
        self._start_time = None
        self.discriminator = None

        if check is not None:
            self.check = check
        if completion_time is not None:
            self.completion_time = completion_time
        self.pod_name = pod_name
        if start_time is not None:
            self.start_time = start_time

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

        Check describes the state of the check container.  # noqa: E501

        :return: The check of this V1beta1ConditionCheckStatusFields.  # noqa: E501
        :rtype: V1ContainerState
        """
        return self._check

    @check.setter
    def check(self, check):
        """Sets the check of this V1beta1ConditionCheckStatusFields.

        Check describes the state of the check container.  # noqa: E501

        :param check: The check of this V1beta1ConditionCheckStatusFields.  # noqa: E501
        :type: V1ContainerState
        """

        self._check = check

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

        CompletionTime is the time the check pod completed.  # noqa: E501

        :return: The completion_time of this V1beta1ConditionCheckStatusFields.  # noqa: E501
        :rtype: V1Time
        """
        return self._completion_time

    @completion_time.setter
    def completion_time(self, completion_time):
        """Sets the completion_time of this V1beta1ConditionCheckStatusFields.

        CompletionTime is the time the check pod completed.  # noqa: E501

        :param completion_time: The completion_time of this V1beta1ConditionCheckStatusFields.  # noqa: E501
        :type: V1Time
        """

        self._completion_time = completion_time

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

        PodName is the name of the pod responsible for executing this condition check.  # noqa: E501

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

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

        PodName is the name of the pod responsible for executing this condition check.  # noqa: E501

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

        self._pod_name = pod_name

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

        StartTime is the time the check is actually started.  # noqa: E501

        :return: The start_time of this V1beta1ConditionCheckStatusFields.  # noqa: E501
        :rtype: V1Time
        """
        return self._start_time

    @start_time.setter
    def start_time(self, start_time):
        """Sets the start_time of this V1beta1ConditionCheckStatusFields.

        StartTime is the time the check is actually started.  # noqa: E501

        :param start_time: The start_time of this V1beta1ConditionCheckStatusFields.  # noqa: E501
        :type: V1Time
        """

        self._start_time = start_time

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

        return self.__dict__ == other.__dict__

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