# coding: utf-8

"""
    Selling Partner API for Direct Fulfillment Shipping

    Use the Selling Partner API for Direct Fulfillment Shipping to access a direct fulfillment vendor's shipping data.

    The version of the OpenAPI document: 2021-12-28
    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 StatusUpdateDetails(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 = {
        'tracking_number': 'str',
        'status_code': 'str',
        'reason_code': 'str',
        'status_date_time': 'datetime',
        'status_location_address': 'Address',
        'shipment_schedule': 'ShipmentSchedule',
    }

    attribute_map = {
        'tracking_number': 'trackingNumber',
        'status_code': 'statusCode',
        'reason_code': 'reasonCode',
        'status_date_time': 'statusDateTime',
        'status_location_address': 'statusLocationAddress',
        'shipment_schedule': 'shipmentSchedule',
    }

    def __init__(self, tracking_number=None, status_code=None, reason_code=None, status_date_time=None, status_location_address=None, shipment_schedule=None, _configuration=None):  # noqa: E501
        """StatusUpdateDetails - a model defined in Swagger"""  # noqa: E501
        if _configuration is None:
            _configuration = Configuration()
        self._configuration = _configuration

        self._tracking_number = None
        self._status_code = None
        self._reason_code = None
        self._status_date_time = None
        self._status_location_address = None
        self._shipment_schedule = None
        self.discriminator = None

        self.tracking_number = tracking_number
        self.status_code = status_code
        self.reason_code = reason_code
        self.status_date_time = status_date_time
        self.status_location_address = status_location_address
        if shipment_schedule is not None:
            self.shipment_schedule = shipment_schedule

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

        The shipment tracking number is required for every package and should match the `trackingNumber` sent for the shipment confirmation.  # noqa: E501

        :return: The tracking_number of this StatusUpdateDetails.  # noqa: E501
        :rtype: str
        """
        return self._tracking_number

    @tracking_number.setter
    def tracking_number(self, tracking_number):
        """Sets the tracking_number of this StatusUpdateDetails.

        The shipment tracking number is required for every package and should match the `trackingNumber` sent for the shipment confirmation.  # noqa: E501

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

        self._tracking_number = tracking_number

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

        Indicates the shipment status code of the package that provides transportation information for Amazon tracking systems and ultimately for the final customer. For more information, refer to the [Additional Fields Explanation](https://developer-docs.amazon.com/sp-api/docs/vendor-direct-fulfillment-shipping-api-use-case-guide#additional-fields-explanation).  # noqa: E501

        :return: The status_code of this StatusUpdateDetails.  # noqa: E501
        :rtype: str
        """
        return self._status_code

    @status_code.setter
    def status_code(self, status_code):
        """Sets the status_code of this StatusUpdateDetails.

        Indicates the shipment status code of the package that provides transportation information for Amazon tracking systems and ultimately for the final customer. For more information, refer to the [Additional Fields Explanation](https://developer-docs.amazon.com/sp-api/docs/vendor-direct-fulfillment-shipping-api-use-case-guide#additional-fields-explanation).  # noqa: E501

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

        self._status_code = status_code

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

        Provides a reason code for the status of the package that will provide additional information about the transportation status. For more information, refer to the [Additional Fields Explanation](https://developer-docs.amazon.com/sp-api/docs/vendor-direct-fulfillment-shipping-api-use-case-guide#additional-fields-explanation).  # noqa: E501

        :return: The reason_code of this StatusUpdateDetails.  # noqa: E501
        :rtype: str
        """
        return self._reason_code

    @reason_code.setter
    def reason_code(self, reason_code):
        """Sets the reason_code of this StatusUpdateDetails.

        Provides a reason code for the status of the package that will provide additional information about the transportation status. For more information, refer to the [Additional Fields Explanation](https://developer-docs.amazon.com/sp-api/docs/vendor-direct-fulfillment-shipping-api-use-case-guide#additional-fields-explanation).  # noqa: E501

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

        self._reason_code = reason_code

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

        The date and time when the shipment status was updated. Values are in [ISO 8601](https://developer-docs.amazon.com/sp-api/docs/iso-8601) date-time format, with UTC time zone or UTC offset. For example, 2020-07-16T23:00:00Z or 2020-07-16T23:00:00+01:00.  # noqa: E501

        :return: The status_date_time of this StatusUpdateDetails.  # noqa: E501
        :rtype: datetime
        """
        return self._status_date_time

    @status_date_time.setter
    def status_date_time(self, status_date_time):
        """Sets the status_date_time of this StatusUpdateDetails.

        The date and time when the shipment status was updated. Values are in [ISO 8601](https://developer-docs.amazon.com/sp-api/docs/iso-8601) date-time format, with UTC time zone or UTC offset. For example, 2020-07-16T23:00:00Z or 2020-07-16T23:00:00+01:00.  # noqa: E501

        :param status_date_time: The status_date_time of this StatusUpdateDetails.  # noqa: E501
        :type: datetime
        """
        if self._configuration.client_side_validation and status_date_time is None:
            raise ValueError("Invalid value for `status_date_time`, must not be `None`")  # noqa: E501

        self._status_date_time = status_date_time

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


        :return: The status_location_address of this StatusUpdateDetails.  # noqa: E501
        :rtype: Address
        """
        return self._status_location_address

    @status_location_address.setter
    def status_location_address(self, status_location_address):
        """Sets the status_location_address of this StatusUpdateDetails.


        :param status_location_address: The status_location_address of this StatusUpdateDetails.  # noqa: E501
        :type: Address
        """
        if self._configuration.client_side_validation and status_location_address is None:
            raise ValueError("Invalid value for `status_location_address`, must not be `None`")  # noqa: E501

        self._status_location_address = status_location_address

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


        :return: The shipment_schedule of this StatusUpdateDetails.  # noqa: E501
        :rtype: ShipmentSchedule
        """
        return self._shipment_schedule

    @shipment_schedule.setter
    def shipment_schedule(self, shipment_schedule):
        """Sets the shipment_schedule of this StatusUpdateDetails.


        :param shipment_schedule: The shipment_schedule of this StatusUpdateDetails.  # noqa: E501
        :type: ShipmentSchedule
        """

        self._shipment_schedule = shipment_schedule

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

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