# coding: utf-8

"""
    Camunda Platform REST API

    OpenApi Spec for Camunda Platform REST API.  # noqa: E501

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


import pprint
import re  # noqa: F401

import six

from generic_camunda_client.configuration import Configuration


class HistoricVariableInstanceDtoAllOf(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',
        'name': 'str',
        'process_definition_key': 'str',
        'process_definition_id': 'str',
        'process_instance_id': 'str',
        'execution_id': 'str',
        'activity_instance_id': 'str',
        'case_definition_key': 'str',
        'case_definition_id': 'str',
        'case_instance_id': 'str',
        'case_execution_id': 'str',
        'task_id': 'str',
        'tenant_id': 'str',
        'error_message': 'str',
        'state': 'str',
        'create_time': 'datetime',
        'removal_time': 'datetime',
        'root_process_instance_id': 'str'
    }

    attribute_map = {
        'id': 'id',
        'name': 'name',
        'process_definition_key': 'processDefinitionKey',
        'process_definition_id': 'processDefinitionId',
        'process_instance_id': 'processInstanceId',
        'execution_id': 'executionId',
        'activity_instance_id': 'activityInstanceId',
        'case_definition_key': 'caseDefinitionKey',
        'case_definition_id': 'caseDefinitionId',
        'case_instance_id': 'caseInstanceId',
        'case_execution_id': 'caseExecutionId',
        'task_id': 'taskId',
        'tenant_id': 'tenantId',
        'error_message': 'errorMessage',
        'state': 'state',
        'create_time': 'createTime',
        'removal_time': 'removalTime',
        'root_process_instance_id': 'rootProcessInstanceId'
    }

    def __init__(self, id=None, name=None, process_definition_key=None, process_definition_id=None, process_instance_id=None, execution_id=None, activity_instance_id=None, case_definition_key=None, case_definition_id=None, case_instance_id=None, case_execution_id=None, task_id=None, tenant_id=None, error_message=None, state=None, create_time=None, removal_time=None, root_process_instance_id=None, local_vars_configuration=None):  # noqa: E501
        """HistoricVariableInstanceDtoAllOf - 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._name = None
        self._process_definition_key = None
        self._process_definition_id = None
        self._process_instance_id = None
        self._execution_id = None
        self._activity_instance_id = None
        self._case_definition_key = None
        self._case_definition_id = None
        self._case_instance_id = None
        self._case_execution_id = None
        self._task_id = None
        self._tenant_id = None
        self._error_message = None
        self._state = None
        self._create_time = None
        self._removal_time = None
        self._root_process_instance_id = None
        self.discriminator = None

        self.id = id
        self.name = name
        self.process_definition_key = process_definition_key
        self.process_definition_id = process_definition_id
        self.process_instance_id = process_instance_id
        self.execution_id = execution_id
        self.activity_instance_id = activity_instance_id
        self.case_definition_key = case_definition_key
        self.case_definition_id = case_definition_id
        self.case_instance_id = case_instance_id
        self.case_execution_id = case_execution_id
        self.task_id = task_id
        self.tenant_id = tenant_id
        self.error_message = error_message
        self.state = state
        self.create_time = create_time
        self.removal_time = removal_time
        self.root_process_instance_id = root_process_instance_id

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

        The id of the variable instance.  # noqa: E501

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

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

        The id of the variable instance.  # noqa: E501

        :param id: The id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._id = id

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

        The name of the variable instance.  # noqa: E501

        :return: The name of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._name

    @name.setter
    def name(self, name):
        """Sets the name of this HistoricVariableInstanceDtoAllOf.

        The name of the variable instance.  # noqa: E501

        :param name: The name of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._name = name

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

        The key of the process definition the variable instance belongs to.  # noqa: E501

        :return: The process_definition_key of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._process_definition_key

    @process_definition_key.setter
    def process_definition_key(self, process_definition_key):
        """Sets the process_definition_key of this HistoricVariableInstanceDtoAllOf.

        The key of the process definition the variable instance belongs to.  # noqa: E501

        :param process_definition_key: The process_definition_key of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._process_definition_key = process_definition_key

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

        The id of the process definition the variable instance belongs to.  # noqa: E501

        :return: The process_definition_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._process_definition_id

    @process_definition_id.setter
    def process_definition_id(self, process_definition_id):
        """Sets the process_definition_id of this HistoricVariableInstanceDtoAllOf.

        The id of the process definition the variable instance belongs to.  # noqa: E501

        :param process_definition_id: The process_definition_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._process_definition_id = process_definition_id

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

        The process instance id the variable instance belongs to.  # noqa: E501

        :return: The process_instance_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._process_instance_id

    @process_instance_id.setter
    def process_instance_id(self, process_instance_id):
        """Sets the process_instance_id of this HistoricVariableInstanceDtoAllOf.

        The process instance id the variable instance belongs to.  # noqa: E501

        :param process_instance_id: The process_instance_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._process_instance_id = process_instance_id

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

        The execution id the variable instance belongs to.  # noqa: E501

        :return: The execution_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._execution_id

    @execution_id.setter
    def execution_id(self, execution_id):
        """Sets the execution_id of this HistoricVariableInstanceDtoAllOf.

        The execution id the variable instance belongs to.  # noqa: E501

        :param execution_id: The execution_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._execution_id = execution_id

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

        The id of the activity instance in which the variable is valid.  # noqa: E501

        :return: The activity_instance_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._activity_instance_id

    @activity_instance_id.setter
    def activity_instance_id(self, activity_instance_id):
        """Sets the activity_instance_id of this HistoricVariableInstanceDtoAllOf.

        The id of the activity instance in which the variable is valid.  # noqa: E501

        :param activity_instance_id: The activity_instance_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._activity_instance_id = activity_instance_id

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

        The key of the case definition the variable instance belongs to.  # noqa: E501

        :return: The case_definition_key of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._case_definition_key

    @case_definition_key.setter
    def case_definition_key(self, case_definition_key):
        """Sets the case_definition_key of this HistoricVariableInstanceDtoAllOf.

        The key of the case definition the variable instance belongs to.  # noqa: E501

        :param case_definition_key: The case_definition_key of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._case_definition_key = case_definition_key

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

        The id of the case definition the variable instance belongs to.  # noqa: E501

        :return: The case_definition_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._case_definition_id

    @case_definition_id.setter
    def case_definition_id(self, case_definition_id):
        """Sets the case_definition_id of this HistoricVariableInstanceDtoAllOf.

        The id of the case definition the variable instance belongs to.  # noqa: E501

        :param case_definition_id: The case_definition_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._case_definition_id = case_definition_id

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

        The case instance id the variable instance belongs to.  # noqa: E501

        :return: The case_instance_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._case_instance_id

    @case_instance_id.setter
    def case_instance_id(self, case_instance_id):
        """Sets the case_instance_id of this HistoricVariableInstanceDtoAllOf.

        The case instance id the variable instance belongs to.  # noqa: E501

        :param case_instance_id: The case_instance_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._case_instance_id = case_instance_id

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

        The case execution id the variable instance belongs to.  # noqa: E501

        :return: The case_execution_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._case_execution_id

    @case_execution_id.setter
    def case_execution_id(self, case_execution_id):
        """Sets the case_execution_id of this HistoricVariableInstanceDtoAllOf.

        The case execution id the variable instance belongs to.  # noqa: E501

        :param case_execution_id: The case_execution_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._case_execution_id = case_execution_id

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

        The id of the task the variable instance belongs to.  # noqa: E501

        :return: The task_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._task_id

    @task_id.setter
    def task_id(self, task_id):
        """Sets the task_id of this HistoricVariableInstanceDtoAllOf.

        The id of the task the variable instance belongs to.  # noqa: E501

        :param task_id: The task_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._task_id = task_id

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

        The id of the tenant that this variable instance belongs to.  # noqa: E501

        :return: The tenant_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._tenant_id

    @tenant_id.setter
    def tenant_id(self, tenant_id):
        """Sets the tenant_id of this HistoricVariableInstanceDtoAllOf.

        The id of the tenant that this variable instance belongs to.  # noqa: E501

        :param tenant_id: The tenant_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._tenant_id = tenant_id

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

        An error message in case a Java Serialized Object could not be de-serialized.  # noqa: E501

        :return: The error_message of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._error_message

    @error_message.setter
    def error_message(self, error_message):
        """Sets the error_message of this HistoricVariableInstanceDtoAllOf.

        An error message in case a Java Serialized Object could not be de-serialized.  # noqa: E501

        :param error_message: The error_message of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._error_message = error_message

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

        The current state of the variable. Can be 'CREATED' or 'DELETED'.  # noqa: E501

        :return: The state of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._state

    @state.setter
    def state(self, state):
        """Sets the state of this HistoricVariableInstanceDtoAllOf.

        The current state of the variable. Can be 'CREATED' or 'DELETED'.  # noqa: E501

        :param state: The state of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._state = state

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

        The time the variable was inserted. [Default format](https://docs.camunda.org/manual/7.16/reference/rest/overview/date-format/) `yyyy-MM-dd'T'HH:mm:ss.SSSZ`.  # noqa: E501

        :return: The create_time of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: datetime
        """
        return self._create_time

    @create_time.setter
    def create_time(self, create_time):
        """Sets the create_time of this HistoricVariableInstanceDtoAllOf.

        The time the variable was inserted. [Default format](https://docs.camunda.org/manual/7.16/reference/rest/overview/date-format/) `yyyy-MM-dd'T'HH:mm:ss.SSSZ`.  # noqa: E501

        :param create_time: The create_time of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: datetime
        """

        self._create_time = create_time

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

        The time after which the variable should be removed by the History Cleanup job. [Default format](https://docs.camunda.org/manual/7.16/reference/rest/overview/date-format/) `yyyy-MM-dd'T'HH:mm:ss.SSSZ`.  # noqa: E501

        :return: The removal_time of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: datetime
        """
        return self._removal_time

    @removal_time.setter
    def removal_time(self, removal_time):
        """Sets the removal_time of this HistoricVariableInstanceDtoAllOf.

        The time after which the variable should be removed by the History Cleanup job. [Default format](https://docs.camunda.org/manual/7.16/reference/rest/overview/date-format/) `yyyy-MM-dd'T'HH:mm:ss.SSSZ`.  # noqa: E501

        :param removal_time: The removal_time of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: datetime
        """

        self._removal_time = removal_time

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

        The process instance id of the root process instance that initiated the process containing this variable.  # noqa: E501

        :return: The root_process_instance_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :rtype: str
        """
        return self._root_process_instance_id

    @root_process_instance_id.setter
    def root_process_instance_id(self, root_process_instance_id):
        """Sets the root_process_instance_id of this HistoricVariableInstanceDtoAllOf.

        The process instance id of the root process instance that initiated the process containing this variable.  # noqa: E501

        :param root_process_instance_id: The root_process_instance_id of this HistoricVariableInstanceDtoAllOf.  # noqa: E501
        :type: str
        """

        self._root_process_instance_id = root_process_instance_id

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

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