# coding: utf-8

"""
    ARLAS Tagger API

    (Un)Tag fields of ARLAS collections

    OpenAPI spec version: 11.0.1
    Contact: contact@gisaia.com
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""


from pprint import pformat
from six import iteritems
import re


class UpdateResponse(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 = {
        'failures': 'list[Failure]',
        'failed': 'int',
        'updated': 'int',
        'progress': 'float',
        'id': 'str',
        'action': 'str',
        'propagated': 'int',
        'start_time': 'int',
        'end_time': 'int',
        'processing_time_ms': 'int',
        'label': 'str'
    }

    attribute_map = {
        'failures': 'failures',
        'failed': 'failed',
        'updated': 'updated',
        'progress': 'progress',
        'id': 'id',
        'action': 'action',
        'propagated': 'propagated',
        'start_time': 'startTime',
        'end_time': 'endTime',
        'processing_time_ms': 'processingTimeMs',
        'label': 'label'
    }

    def __init__(self, failures=None, failed=None, updated=None, progress=None, id=None, action=None, propagated=None, start_time=None, end_time=None, processing_time_ms=None, label=None):
        """
        UpdateResponse - a model defined in Swagger
        """

        self._failures = None
        self._failed = None
        self._updated = None
        self._progress = None
        self._id = None
        self._action = None
        self._propagated = None
        self._start_time = None
        self._end_time = None
        self._processing_time_ms = None
        self._label = None

        if failures is not None:
          self.failures = failures
        if failed is not None:
          self.failed = failed
        if updated is not None:
          self.updated = updated
        if progress is not None:
          self.progress = progress
        if id is not None:
          self.id = id
        if action is not None:
          self.action = action
        if propagated is not None:
          self.propagated = propagated
        if start_time is not None:
          self.start_time = start_time
        if end_time is not None:
          self.end_time = end_time
        if processing_time_ms is not None:
          self.processing_time_ms = processing_time_ms
        if label is not None:
          self.label = label

    @property
    def failures(self):
        """
        Gets the failures of this UpdateResponse.

        :return: The failures of this UpdateResponse.
        :rtype: list[Failure]
        """
        return self._failures

    @failures.setter
    def failures(self, failures):
        """
        Sets the failures of this UpdateResponse.

        :param failures: The failures of this UpdateResponse.
        :type: list[Failure]
        """

        self._failures = failures

    @property
    def failed(self):
        """
        Gets the failed of this UpdateResponse.

        :return: The failed of this UpdateResponse.
        :rtype: int
        """
        return self._failed

    @failed.setter
    def failed(self, failed):
        """
        Sets the failed of this UpdateResponse.

        :param failed: The failed of this UpdateResponse.
        :type: int
        """

        self._failed = failed

    @property
    def updated(self):
        """
        Gets the updated of this UpdateResponse.

        :return: The updated of this UpdateResponse.
        :rtype: int
        """
        return self._updated

    @updated.setter
    def updated(self, updated):
        """
        Sets the updated of this UpdateResponse.

        :param updated: The updated of this UpdateResponse.
        :type: int
        """

        self._updated = updated

    @property
    def progress(self):
        """
        Gets the progress of this UpdateResponse.

        :return: The progress of this UpdateResponse.
        :rtype: float
        """
        return self._progress

    @progress.setter
    def progress(self, progress):
        """
        Sets the progress of this UpdateResponse.

        :param progress: The progress of this UpdateResponse.
        :type: float
        """

        self._progress = progress

    @property
    def id(self):
        """
        Gets the id of this UpdateResponse.

        :return: The id of this UpdateResponse.
        :rtype: str
        """
        return self._id

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

        :param id: The id of this UpdateResponse.
        :type: str
        """

        self._id = id

    @property
    def action(self):
        """
        Gets the action of this UpdateResponse.

        :return: The action of this UpdateResponse.
        :rtype: str
        """
        return self._action

    @action.setter
    def action(self, action):
        """
        Sets the action of this UpdateResponse.

        :param action: The action of this UpdateResponse.
        :type: str
        """
        allowed_values = ["ADD", "REMOVE", "REMOVEALL"]
        if action not in allowed_values:
            raise ValueError(
                "Invalid value for `action` ({0}), must be one of {1}"
                .format(action, allowed_values)
            )

        self._action = action

    @property
    def propagated(self):
        """
        Gets the propagated of this UpdateResponse.

        :return: The propagated of this UpdateResponse.
        :rtype: int
        """
        return self._propagated

    @propagated.setter
    def propagated(self, propagated):
        """
        Sets the propagated of this UpdateResponse.

        :param propagated: The propagated of this UpdateResponse.
        :type: int
        """

        self._propagated = propagated

    @property
    def start_time(self):
        """
        Gets the start_time of this UpdateResponse.

        :return: The start_time of this UpdateResponse.
        :rtype: int
        """
        return self._start_time

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

        :param start_time: The start_time of this UpdateResponse.
        :type: int
        """

        self._start_time = start_time

    @property
    def end_time(self):
        """
        Gets the end_time of this UpdateResponse.

        :return: The end_time of this UpdateResponse.
        :rtype: int
        """
        return self._end_time

    @end_time.setter
    def end_time(self, end_time):
        """
        Sets the end_time of this UpdateResponse.

        :param end_time: The end_time of this UpdateResponse.
        :type: int
        """

        self._end_time = end_time

    @property
    def processing_time_ms(self):
        """
        Gets the processing_time_ms of this UpdateResponse.

        :return: The processing_time_ms of this UpdateResponse.
        :rtype: int
        """
        return self._processing_time_ms

    @processing_time_ms.setter
    def processing_time_ms(self, processing_time_ms):
        """
        Sets the processing_time_ms of this UpdateResponse.

        :param processing_time_ms: The processing_time_ms of this UpdateResponse.
        :type: int
        """

        self._processing_time_ms = processing_time_ms

    @property
    def label(self):
        """
        Gets the label of this UpdateResponse.

        :return: The label of this UpdateResponse.
        :rtype: str
        """
        return self._label

    @label.setter
    def label(self, label):
        """
        Sets the label of this UpdateResponse.

        :param label: The label of this UpdateResponse.
        :type: str
        """

        self._label = label

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

        for attr, _ in 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

        return result

    def to_str(self):
        """
        Returns the string representation of the model
        """
        return 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, UpdateResponse):
            return False

        return self.__dict__ == other.__dict__

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