# coding: utf-8

"""
    Selling Partner API for Retail Procurement Orders

    The Selling Partner API for Retail Procurement Orders provides programmatic access to vendor orders data.

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

    Do not edit the class manually.
"""  # noqa: E501


import pprint
import re  # noqa: F401

import six

from spapi.configuration import Configuration


class OrderItemStatusReceivingStatus(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 = {
        'receive_status': 'str',
        'received_quantity': 'ItemQuantity',
        'last_receive_date': 'datetime',
    }

    attribute_map = {
        'receive_status': 'receiveStatus',
        'received_quantity': 'receivedQuantity',
        'last_receive_date': 'lastReceiveDate',
    }

    def __init__(self, receive_status=None, received_quantity=None, last_receive_date=None, _configuration=None):  # noqa: E501
        """OrderItemStatusReceivingStatus - a model defined in Swagger"""  # noqa: E501
        if _configuration is None:
            _configuration = Configuration()
        self._configuration = _configuration

        self._receive_status = None
        self._received_quantity = None
        self._last_receive_date = None
        self.discriminator = None

        if receive_status is not None:
            self.receive_status = receive_status
        if received_quantity is not None:
            self.received_quantity = received_quantity
        if last_receive_date is not None:
            self.last_receive_date = last_receive_date

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

        Receive status of the line item.  # noqa: E501

        :return: The receive_status of this OrderItemStatusReceivingStatus.  # noqa: E501
        :rtype: str
        """
        return self._receive_status

    @receive_status.setter
    def receive_status(self, receive_status):
        """Sets the receive_status of this OrderItemStatusReceivingStatus.

        Receive status of the line item.  # noqa: E501

        :param receive_status: The receive_status of this OrderItemStatusReceivingStatus.  # noqa: E501
        :type: str
        """
        allowed_values = ["NOT_RECEIVED", "PARTIALLY_RECEIVED", "RECEIVED"]  # noqa: E501
        if (self._configuration.client_side_validation and
                receive_status not in allowed_values):
            raise ValueError(
                "Invalid value for `receive_status` ({0}), must be one of {1}"  # noqa: E501
                .format(receive_status, allowed_values)
            )

        self._receive_status = receive_status

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


        :return: The received_quantity of this OrderItemStatusReceivingStatus.  # noqa: E501
        :rtype: ItemQuantity
        """
        return self._received_quantity

    @received_quantity.setter
    def received_quantity(self, received_quantity):
        """Sets the received_quantity of this OrderItemStatusReceivingStatus.


        :param received_quantity: The received_quantity of this OrderItemStatusReceivingStatus.  # noqa: E501
        :type: ItemQuantity
        """

        self._received_quantity = received_quantity

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

        The date when the most recent item was received at the buyer's warehouse. Must be in ISO-8601 date/time format.  # noqa: E501

        :return: The last_receive_date of this OrderItemStatusReceivingStatus.  # noqa: E501
        :rtype: datetime
        """
        return self._last_receive_date

    @last_receive_date.setter
    def last_receive_date(self, last_receive_date):
        """Sets the last_receive_date of this OrderItemStatusReceivingStatus.

        The date when the most recent item was received at the buyer's warehouse. Must be in ISO-8601 date/time format.  # noqa: E501

        :param last_receive_date: The last_receive_date of this OrderItemStatusReceivingStatus.  # noqa: E501
        :type: datetime
        """

        self._last_receive_date = last_receive_date

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

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