# coding: utf-8

"""
    Aron API

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

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


try:
    from inspect import getfullargspec
except ImportError:
    from inspect import getargspec as getfullargspec
import pprint
import re  # noqa: F401
import six

from vessl.openapi_client.configuration import Configuration


class ResponseRunExecutionInfo(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 = {
        'arguments': 'V1RunArgument',
        'artifact_volume_info_list': 'list[ResponseRunExecutionArtifactVolume]',
        'create_dt': 'datetime',
        'created_by': 'ResponseUser',
        'endpoints': 'ResponseWorkloadEndpoints',
        'histories': 'list[ResponseWorkloadHistoryInfo]',
        'id': 'int',
        'immutable_slug': 'str',
        'interactive_end_dt': 'datetime',
        'is_starred': 'bool',
        'message': 'str',
        'metric_summary': 'V1LatestPlots',
        'organization': 'ResponseOrganization',
        'pipeline_step_execution': 'ResponseReducedPipelineStepExecution',
        'progress_percent': 'int',
        'project': 'ResponseProject',
        'run_spec': 'ResponseRunSpec',
        'status': 'str',
        'status_last_updated': 'datetime',
        'status_reason': 'str',
        'tags': 'list[ResponseTagResponse]',
        'volume_info_list': 'list[ResponseRunExecutionArtifactVolume]',
        'volume_operations': 'list[ResponsePathOperation]',
        'volume_v2_operations': 'list[ResponseWorkloadVolumeV2PathOperation]',
        'workload': 'ResponseWorkloadInfo'
    }

    attribute_map = {
        'arguments': 'arguments',
        'artifact_volume_info_list': 'artifact_volume_info_list',
        'create_dt': 'create_dt',
        'created_by': 'created_by',
        'endpoints': 'endpoints',
        'histories': 'histories',
        'id': 'id',
        'immutable_slug': 'immutable_slug',
        'interactive_end_dt': 'interactive_end_dt',
        'is_starred': 'is_starred',
        'message': 'message',
        'metric_summary': 'metric_summary',
        'organization': 'organization',
        'pipeline_step_execution': 'pipeline_step_execution',
        'progress_percent': 'progress_percent',
        'project': 'project',
        'run_spec': 'run_spec',
        'status': 'status',
        'status_last_updated': 'status_last_updated',
        'status_reason': 'status_reason',
        'tags': 'tags',
        'volume_info_list': 'volume_info_list',
        'volume_operations': 'volume_operations',
        'volume_v2_operations': 'volume_v2_operations',
        'workload': 'workload'
    }

    def __init__(self, arguments=None, artifact_volume_info_list=None, create_dt=None, created_by=None, endpoints=None, histories=None, id=None, immutable_slug=None, interactive_end_dt=None, is_starred=None, message=None, metric_summary=None, organization=None, pipeline_step_execution=None, progress_percent=None, project=None, run_spec=None, status=None, status_last_updated=None, status_reason=None, tags=None, volume_info_list=None, volume_operations=None, volume_v2_operations=None, workload=None, local_vars_configuration=None):  # noqa: E501
        """ResponseRunExecutionInfo - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration.get_default_copy()
        self.local_vars_configuration = local_vars_configuration

        self._arguments = None
        self._artifact_volume_info_list = None
        self._create_dt = None
        self._created_by = None
        self._endpoints = None
        self._histories = None
        self._id = None
        self._immutable_slug = None
        self._interactive_end_dt = None
        self._is_starred = None
        self._message = None
        self._metric_summary = None
        self._organization = None
        self._pipeline_step_execution = None
        self._progress_percent = None
        self._project = None
        self._run_spec = None
        self._status = None
        self._status_last_updated = None
        self._status_reason = None
        self._tags = None
        self._volume_info_list = None
        self._volume_operations = None
        self._volume_v2_operations = None
        self._workload = None
        self.discriminator = None

        if arguments is not None:
            self.arguments = arguments
        if artifact_volume_info_list is not None:
            self.artifact_volume_info_list = artifact_volume_info_list
        if create_dt is not None:
            self.create_dt = create_dt
        if created_by is not None:
            self.created_by = created_by
        if endpoints is not None:
            self.endpoints = endpoints
        self.histories = histories
        self.id = id
        self.immutable_slug = immutable_slug
        self.interactive_end_dt = interactive_end_dt
        self.is_starred = is_starred
        self.message = message
        if metric_summary is not None:
            self.metric_summary = metric_summary
        self.organization = organization
        if pipeline_step_execution is not None:
            self.pipeline_step_execution = pipeline_step_execution
        self.progress_percent = progress_percent
        if project is not None:
            self.project = project
        if run_spec is not None:
            self.run_spec = run_spec
        self.status = status
        if status_last_updated is not None:
            self.status_last_updated = status_last_updated
        self.status_reason = status_reason
        self.tags = tags
        if volume_info_list is not None:
            self.volume_info_list = volume_info_list
        if volume_operations is not None:
            self.volume_operations = volume_operations
        if volume_v2_operations is not None:
            self.volume_v2_operations = volume_v2_operations
        if workload is not None:
            self.workload = workload

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


        :return: The arguments of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: V1RunArgument
        """
        return self._arguments

    @arguments.setter
    def arguments(self, arguments):
        """Sets the arguments of this ResponseRunExecutionInfo.


        :param arguments: The arguments of this ResponseRunExecutionInfo.  # noqa: E501
        :type arguments: V1RunArgument
        """

        self._arguments = arguments

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


        :return: The artifact_volume_info_list of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: list[ResponseRunExecutionArtifactVolume]
        """
        return self._artifact_volume_info_list

    @artifact_volume_info_list.setter
    def artifact_volume_info_list(self, artifact_volume_info_list):
        """Sets the artifact_volume_info_list of this ResponseRunExecutionInfo.


        :param artifact_volume_info_list: The artifact_volume_info_list of this ResponseRunExecutionInfo.  # noqa: E501
        :type artifact_volume_info_list: list[ResponseRunExecutionArtifactVolume]
        """

        self._artifact_volume_info_list = artifact_volume_info_list

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


        :return: The create_dt of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: datetime
        """
        return self._create_dt

    @create_dt.setter
    def create_dt(self, create_dt):
        """Sets the create_dt of this ResponseRunExecutionInfo.


        :param create_dt: The create_dt of this ResponseRunExecutionInfo.  # noqa: E501
        :type create_dt: datetime
        """

        self._create_dt = create_dt

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


        :return: The created_by of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: ResponseUser
        """
        return self._created_by

    @created_by.setter
    def created_by(self, created_by):
        """Sets the created_by of this ResponseRunExecutionInfo.


        :param created_by: The created_by of this ResponseRunExecutionInfo.  # noqa: E501
        :type created_by: ResponseUser
        """

        self._created_by = created_by

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


        :return: The endpoints of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: ResponseWorkloadEndpoints
        """
        return self._endpoints

    @endpoints.setter
    def endpoints(self, endpoints):
        """Sets the endpoints of this ResponseRunExecutionInfo.


        :param endpoints: The endpoints of this ResponseRunExecutionInfo.  # noqa: E501
        :type endpoints: ResponseWorkloadEndpoints
        """

        self._endpoints = endpoints

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


        :return: The histories of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: list[ResponseWorkloadHistoryInfo]
        """
        return self._histories

    @histories.setter
    def histories(self, histories):
        """Sets the histories of this ResponseRunExecutionInfo.


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

        self._histories = histories

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


        :return: The id of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: int
        """
        return self._id

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


        :param id: The id of this ResponseRunExecutionInfo.  # noqa: E501
        :type id: int
        """
        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 immutable_slug(self):
        """Gets the immutable_slug of this ResponseRunExecutionInfo.  # noqa: E501


        :return: The immutable_slug of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: str
        """
        return self._immutable_slug

    @immutable_slug.setter
    def immutable_slug(self, immutable_slug):
        """Sets the immutable_slug of this ResponseRunExecutionInfo.


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

        self._immutable_slug = immutable_slug

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


        :return: The interactive_end_dt of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: datetime
        """
        return self._interactive_end_dt

    @interactive_end_dt.setter
    def interactive_end_dt(self, interactive_end_dt):
        """Sets the interactive_end_dt of this ResponseRunExecutionInfo.


        :param interactive_end_dt: The interactive_end_dt of this ResponseRunExecutionInfo.  # noqa: E501
        :type interactive_end_dt: datetime
        """

        self._interactive_end_dt = interactive_end_dt

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


        :return: The is_starred of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: bool
        """
        return self._is_starred

    @is_starred.setter
    def is_starred(self, is_starred):
        """Sets the is_starred of this ResponseRunExecutionInfo.


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

        self._is_starred = is_starred

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


        :return: The message of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: str
        """
        return self._message

    @message.setter
    def message(self, message):
        """Sets the message of this ResponseRunExecutionInfo.


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

        self._message = message

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


        :return: The metric_summary of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: V1LatestPlots
        """
        return self._metric_summary

    @metric_summary.setter
    def metric_summary(self, metric_summary):
        """Sets the metric_summary of this ResponseRunExecutionInfo.


        :param metric_summary: The metric_summary of this ResponseRunExecutionInfo.  # noqa: E501
        :type metric_summary: V1LatestPlots
        """

        self._metric_summary = metric_summary

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


        :return: The organization of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: ResponseOrganization
        """
        return self._organization

    @organization.setter
    def organization(self, organization):
        """Sets the organization of this ResponseRunExecutionInfo.


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

        self._organization = organization

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


        :return: The pipeline_step_execution of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: ResponseReducedPipelineStepExecution
        """
        return self._pipeline_step_execution

    @pipeline_step_execution.setter
    def pipeline_step_execution(self, pipeline_step_execution):
        """Sets the pipeline_step_execution of this ResponseRunExecutionInfo.


        :param pipeline_step_execution: The pipeline_step_execution of this ResponseRunExecutionInfo.  # noqa: E501
        :type pipeline_step_execution: ResponseReducedPipelineStepExecution
        """

        self._pipeline_step_execution = pipeline_step_execution

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


        :return: The progress_percent of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: int
        """
        return self._progress_percent

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


        :param progress_percent: The progress_percent of this ResponseRunExecutionInfo.  # noqa: E501
        :type progress_percent: int
        """

        self._progress_percent = progress_percent

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


        :return: The project of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: ResponseProject
        """
        return self._project

    @project.setter
    def project(self, project):
        """Sets the project of this ResponseRunExecutionInfo.


        :param project: The project of this ResponseRunExecutionInfo.  # noqa: E501
        :type project: ResponseProject
        """

        self._project = project

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


        :return: The run_spec of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: ResponseRunSpec
        """
        return self._run_spec

    @run_spec.setter
    def run_spec(self, run_spec):
        """Sets the run_spec of this ResponseRunExecutionInfo.


        :param run_spec: The run_spec of this ResponseRunExecutionInfo.  # noqa: E501
        :type run_spec: ResponseRunSpec
        """

        self._run_spec = run_spec

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


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

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


        :param status: The status of this ResponseRunExecutionInfo.  # noqa: E501
        :type status: 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 = ["queued", "pending", "running", "idle", "stopping", "failed", "completed", "terminated", "initializing", "waitToBeKilled"]  # 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 status_last_updated(self):
        """Gets the status_last_updated of this ResponseRunExecutionInfo.  # noqa: E501


        :return: The status_last_updated of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: datetime
        """
        return self._status_last_updated

    @status_last_updated.setter
    def status_last_updated(self, status_last_updated):
        """Sets the status_last_updated of this ResponseRunExecutionInfo.


        :param status_last_updated: The status_last_updated of this ResponseRunExecutionInfo.  # noqa: E501
        :type status_last_updated: datetime
        """

        self._status_last_updated = status_last_updated

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


        :return: The status_reason of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: str
        """
        return self._status_reason

    @status_reason.setter
    def status_reason(self, status_reason):
        """Sets the status_reason of this ResponseRunExecutionInfo.


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

        self._status_reason = status_reason

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


        :return: The tags of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: list[ResponseTagResponse]
        """
        return self._tags

    @tags.setter
    def tags(self, tags):
        """Sets the tags of this ResponseRunExecutionInfo.


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

        self._tags = tags

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


        :return: The volume_info_list of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: list[ResponseRunExecutionArtifactVolume]
        """
        return self._volume_info_list

    @volume_info_list.setter
    def volume_info_list(self, volume_info_list):
        """Sets the volume_info_list of this ResponseRunExecutionInfo.


        :param volume_info_list: The volume_info_list of this ResponseRunExecutionInfo.  # noqa: E501
        :type volume_info_list: list[ResponseRunExecutionArtifactVolume]
        """

        self._volume_info_list = volume_info_list

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


        :return: The volume_operations of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: list[ResponsePathOperation]
        """
        return self._volume_operations

    @volume_operations.setter
    def volume_operations(self, volume_operations):
        """Sets the volume_operations of this ResponseRunExecutionInfo.


        :param volume_operations: The volume_operations of this ResponseRunExecutionInfo.  # noqa: E501
        :type volume_operations: list[ResponsePathOperation]
        """

        self._volume_operations = volume_operations

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


        :return: The volume_v2_operations of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: list[ResponseWorkloadVolumeV2PathOperation]
        """
        return self._volume_v2_operations

    @volume_v2_operations.setter
    def volume_v2_operations(self, volume_v2_operations):
        """Sets the volume_v2_operations of this ResponseRunExecutionInfo.


        :param volume_v2_operations: The volume_v2_operations of this ResponseRunExecutionInfo.  # noqa: E501
        :type volume_v2_operations: list[ResponseWorkloadVolumeV2PathOperation]
        """

        self._volume_v2_operations = volume_v2_operations

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


        :return: The workload of this ResponseRunExecutionInfo.  # noqa: E501
        :rtype: ResponseWorkloadInfo
        """
        return self._workload

    @workload.setter
    def workload(self, workload):
        """Sets the workload of this ResponseRunExecutionInfo.


        :param workload: The workload of this ResponseRunExecutionInfo.  # noqa: E501
        :type workload: ResponseWorkloadInfo
        """

        self._workload = workload

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

        def convert(x):
            if hasattr(x, "to_dict"):
                args = getfullargspec(x.to_dict).args
                if len(args) == 1:
                    return x.to_dict()
                else:
                    return x.to_dict(serialize)
            else:
                return x

        for attr, _ in six.iteritems(self.openapi_types):
            value = getattr(self, attr)
            attr = self.attribute_map.get(attr, attr) if serialize else attr
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: convert(x),
                    value
                ))
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], convert(item[1])),
                    value.items()
                ))
            else:
                result[attr] = convert(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, ResponseRunExecutionInfo):
            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, ResponseRunExecutionInfo):
            return True

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