# 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 CreateContainerLabelRequest(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 = {
        'selling_party': 'PartyIdentification',
        'ship_from_party': 'PartyIdentification',
        'carrier_id': 'CarrierId',
        'vendor_container_id': 'str',
        'packages': 'List[Package]',
    }

    attribute_map = {
        'selling_party': 'sellingParty',
        'ship_from_party': 'shipFromParty',
        'carrier_id': 'carrierId',
        'vendor_container_id': 'vendorContainerId',
        'packages': 'packages',
    }

    def __init__(self, selling_party=None, ship_from_party=None, carrier_id=None, vendor_container_id=None, packages=None, _configuration=None):  # noqa: E501
        """CreateContainerLabelRequest - a model defined in Swagger"""  # noqa: E501
        if _configuration is None:
            _configuration = Configuration()
        self._configuration = _configuration

        self._selling_party = None
        self._ship_from_party = None
        self._carrier_id = None
        self._vendor_container_id = None
        self._packages = None
        self.discriminator = None

        self.selling_party = selling_party
        self.ship_from_party = ship_from_party
        self.carrier_id = carrier_id
        self.vendor_container_id = vendor_container_id
        self.packages = packages

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


        :return: The selling_party of this CreateContainerLabelRequest.  # noqa: E501
        :rtype: PartyIdentification
        """
        return self._selling_party

    @selling_party.setter
    def selling_party(self, selling_party):
        """Sets the selling_party of this CreateContainerLabelRequest.


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

        self._selling_party = selling_party

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


        :return: The ship_from_party of this CreateContainerLabelRequest.  # noqa: E501
        :rtype: PartyIdentification
        """
        return self._ship_from_party

    @ship_from_party.setter
    def ship_from_party(self, ship_from_party):
        """Sets the ship_from_party of this CreateContainerLabelRequest.


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

        self._ship_from_party = ship_from_party

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


        :return: The carrier_id of this CreateContainerLabelRequest.  # noqa: E501
        :rtype: CarrierId
        """
        return self._carrier_id

    @carrier_id.setter
    def carrier_id(self, carrier_id):
        """Sets the carrier_id of this CreateContainerLabelRequest.


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

        self._carrier_id = carrier_id

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

        The unique, vendor-provided identifier for the container.  # noqa: E501

        :return: The vendor_container_id of this CreateContainerLabelRequest.  # noqa: E501
        :rtype: str
        """
        return self._vendor_container_id

    @vendor_container_id.setter
    def vendor_container_id(self, vendor_container_id):
        """Sets the vendor_container_id of this CreateContainerLabelRequest.

        The unique, vendor-provided identifier for the container.  # noqa: E501

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

        self._vendor_container_id = vendor_container_id

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

        An array of package objects in a container.  # noqa: E501

        :return: The packages of this CreateContainerLabelRequest.  # noqa: E501
        :rtype: List[Package]
        """
        return self._packages

    @packages.setter
    def packages(self, packages):
        """Sets the packages of this CreateContainerLabelRequest.

        An array of package objects in a container.  # noqa: E501

        :param packages: The packages of this CreateContainerLabelRequest.  # noqa: E501
        :type: List[Package]
        """
        if self._configuration.client_side_validation and packages is None:
            raise ValueError("Invalid value for `packages`, must not be `None`")  # noqa: E501

        self._packages = packages

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

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