# coding: utf-8

"""
    Knetik Platform API Documentation latest 

    This is the spec for the Knetik API.  Use this in conjunction with the documentation found at https://knetikcloud.com.

    OpenAPI spec version: latest 
    Contact: support@knetik.com
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""


from pprint import pformat
from six import iteritems
import re


class CartLineItem(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 = {
        'currency_code': 'str',
        'description': 'str',
        'discount': 'Discount',
        'line_total': 'float',
        'name': 'str',
        'original_line_total': 'float',
        'original_unit_price': 'float',
        'qty': 'int',
        'sale_name': 'str',
        'sku': 'str',
        'sku_description': 'str',
        'store_item_id': 'int',
        'tags': 'list[str]',
        'thumb_url': 'str',
        'unique_key': 'str',
        'unit_price': 'float',
        'vendor_id': 'int',
        'vendor_name': 'str'
    }

    attribute_map = {
        'currency_code': 'currency_code',
        'description': 'description',
        'discount': 'discount',
        'line_total': 'line_total',
        'name': 'name',
        'original_line_total': 'original_line_total',
        'original_unit_price': 'original_unit_price',
        'qty': 'qty',
        'sale_name': 'sale_name',
        'sku': 'sku',
        'sku_description': 'sku_description',
        'store_item_id': 'store_item_id',
        'tags': 'tags',
        'thumb_url': 'thumb_url',
        'unique_key': 'unique_key',
        'unit_price': 'unit_price',
        'vendor_id': 'vendor_id',
        'vendor_name': 'vendor_name'
    }

    def __init__(self, currency_code=None, description=None, discount=None, line_total=None, name=None, original_line_total=None, original_unit_price=None, qty=None, sale_name=None, sku=None, sku_description=None, store_item_id=None, tags=None, thumb_url=None, unique_key=None, unit_price=None, vendor_id=None, vendor_name=None):
        """
        CartLineItem - a model defined in Swagger
        """

        self._currency_code = None
        self._description = None
        self._discount = None
        self._line_total = None
        self._name = None
        self._original_line_total = None
        self._original_unit_price = None
        self._qty = None
        self._sale_name = None
        self._sku = None
        self._sku_description = None
        self._store_item_id = None
        self._tags = None
        self._thumb_url = None
        self._unique_key = None
        self._unit_price = None
        self._vendor_id = None
        self._vendor_name = None
        self.discriminator = None

        if currency_code is not None:
          self.currency_code = currency_code
        if description is not None:
          self.description = description
        if discount is not None:
          self.discount = discount
        if line_total is not None:
          self.line_total = line_total
        if name is not None:
          self.name = name
        if original_line_total is not None:
          self.original_line_total = original_line_total
        if original_unit_price is not None:
          self.original_unit_price = original_unit_price
        if qty is not None:
          self.qty = qty
        if sale_name is not None:
          self.sale_name = sale_name
        if sku is not None:
          self.sku = sku
        if sku_description is not None:
          self.sku_description = sku_description
        if store_item_id is not None:
          self.store_item_id = store_item_id
        if tags is not None:
          self.tags = tags
        if thumb_url is not None:
          self.thumb_url = thumb_url
        if unique_key is not None:
          self.unique_key = unique_key
        if unit_price is not None:
          self.unit_price = unit_price
        if vendor_id is not None:
          self.vendor_id = vendor_id
        if vendor_name is not None:
          self.vendor_name = vendor_name

    @property
    def currency_code(self):
        """
        Gets the currency_code of this CartLineItem.

        :return: The currency_code of this CartLineItem.
        :rtype: str
        """
        return self._currency_code

    @currency_code.setter
    def currency_code(self, currency_code):
        """
        Sets the currency_code of this CartLineItem.

        :param currency_code: The currency_code of this CartLineItem.
        :type: str
        """

        self._currency_code = currency_code

    @property
    def description(self):
        """
        Gets the description of this CartLineItem.

        :return: The description of this CartLineItem.
        :rtype: str
        """
        return self._description

    @description.setter
    def description(self, description):
        """
        Sets the description of this CartLineItem.

        :param description: The description of this CartLineItem.
        :type: str
        """

        self._description = description

    @property
    def discount(self):
        """
        Gets the discount of this CartLineItem.

        :return: The discount of this CartLineItem.
        :rtype: Discount
        """
        return self._discount

    @discount.setter
    def discount(self, discount):
        """
        Sets the discount of this CartLineItem.

        :param discount: The discount of this CartLineItem.
        :type: Discount
        """

        self._discount = discount

    @property
    def line_total(self):
        """
        Gets the line_total of this CartLineItem.

        :return: The line_total of this CartLineItem.
        :rtype: float
        """
        return self._line_total

    @line_total.setter
    def line_total(self, line_total):
        """
        Sets the line_total of this CartLineItem.

        :param line_total: The line_total of this CartLineItem.
        :type: float
        """

        self._line_total = line_total

    @property
    def name(self):
        """
        Gets the name of this CartLineItem.

        :return: The name of this CartLineItem.
        :rtype: str
        """
        return self._name

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

        :param name: The name of this CartLineItem.
        :type: str
        """

        self._name = name

    @property
    def original_line_total(self):
        """
        Gets the original_line_total of this CartLineItem.

        :return: The original_line_total of this CartLineItem.
        :rtype: float
        """
        return self._original_line_total

    @original_line_total.setter
    def original_line_total(self, original_line_total):
        """
        Sets the original_line_total of this CartLineItem.

        :param original_line_total: The original_line_total of this CartLineItem.
        :type: float
        """

        self._original_line_total = original_line_total

    @property
    def original_unit_price(self):
        """
        Gets the original_unit_price of this CartLineItem.

        :return: The original_unit_price of this CartLineItem.
        :rtype: float
        """
        return self._original_unit_price

    @original_unit_price.setter
    def original_unit_price(self, original_unit_price):
        """
        Sets the original_unit_price of this CartLineItem.

        :param original_unit_price: The original_unit_price of this CartLineItem.
        :type: float
        """

        self._original_unit_price = original_unit_price

    @property
    def qty(self):
        """
        Gets the qty of this CartLineItem.

        :return: The qty of this CartLineItem.
        :rtype: int
        """
        return self._qty

    @qty.setter
    def qty(self, qty):
        """
        Sets the qty of this CartLineItem.

        :param qty: The qty of this CartLineItem.
        :type: int
        """

        self._qty = qty

    @property
    def sale_name(self):
        """
        Gets the sale_name of this CartLineItem.

        :return: The sale_name of this CartLineItem.
        :rtype: str
        """
        return self._sale_name

    @sale_name.setter
    def sale_name(self, sale_name):
        """
        Sets the sale_name of this CartLineItem.

        :param sale_name: The sale_name of this CartLineItem.
        :type: str
        """

        self._sale_name = sale_name

    @property
    def sku(self):
        """
        Gets the sku of this CartLineItem.

        :return: The sku of this CartLineItem.
        :rtype: str
        """
        return self._sku

    @sku.setter
    def sku(self, sku):
        """
        Sets the sku of this CartLineItem.

        :param sku: The sku of this CartLineItem.
        :type: str
        """

        self._sku = sku

    @property
    def sku_description(self):
        """
        Gets the sku_description of this CartLineItem.

        :return: The sku_description of this CartLineItem.
        :rtype: str
        """
        return self._sku_description

    @sku_description.setter
    def sku_description(self, sku_description):
        """
        Sets the sku_description of this CartLineItem.

        :param sku_description: The sku_description of this CartLineItem.
        :type: str
        """

        self._sku_description = sku_description

    @property
    def store_item_id(self):
        """
        Gets the store_item_id of this CartLineItem.

        :return: The store_item_id of this CartLineItem.
        :rtype: int
        """
        return self._store_item_id

    @store_item_id.setter
    def store_item_id(self, store_item_id):
        """
        Sets the store_item_id of this CartLineItem.

        :param store_item_id: The store_item_id of this CartLineItem.
        :type: int
        """

        self._store_item_id = store_item_id

    @property
    def tags(self):
        """
        Gets the tags of this CartLineItem.

        :return: The tags of this CartLineItem.
        :rtype: list[str]
        """
        return self._tags

    @tags.setter
    def tags(self, tags):
        """
        Sets the tags of this CartLineItem.

        :param tags: The tags of this CartLineItem.
        :type: list[str]
        """

        self._tags = tags

    @property
    def thumb_url(self):
        """
        Gets the thumb_url of this CartLineItem.

        :return: The thumb_url of this CartLineItem.
        :rtype: str
        """
        return self._thumb_url

    @thumb_url.setter
    def thumb_url(self, thumb_url):
        """
        Sets the thumb_url of this CartLineItem.

        :param thumb_url: The thumb_url of this CartLineItem.
        :type: str
        """

        self._thumb_url = thumb_url

    @property
    def unique_key(self):
        """
        Gets the unique_key of this CartLineItem.

        :return: The unique_key of this CartLineItem.
        :rtype: str
        """
        return self._unique_key

    @unique_key.setter
    def unique_key(self, unique_key):
        """
        Sets the unique_key of this CartLineItem.

        :param unique_key: The unique_key of this CartLineItem.
        :type: str
        """

        self._unique_key = unique_key

    @property
    def unit_price(self):
        """
        Gets the unit_price of this CartLineItem.

        :return: The unit_price of this CartLineItem.
        :rtype: float
        """
        return self._unit_price

    @unit_price.setter
    def unit_price(self, unit_price):
        """
        Sets the unit_price of this CartLineItem.

        :param unit_price: The unit_price of this CartLineItem.
        :type: float
        """

        self._unit_price = unit_price

    @property
    def vendor_id(self):
        """
        Gets the vendor_id of this CartLineItem.

        :return: The vendor_id of this CartLineItem.
        :rtype: int
        """
        return self._vendor_id

    @vendor_id.setter
    def vendor_id(self, vendor_id):
        """
        Sets the vendor_id of this CartLineItem.

        :param vendor_id: The vendor_id of this CartLineItem.
        :type: int
        """

        self._vendor_id = vendor_id

    @property
    def vendor_name(self):
        """
        Gets the vendor_name of this CartLineItem.

        :return: The vendor_name of this CartLineItem.
        :rtype: str
        """
        return self._vendor_name

    @vendor_name.setter
    def vendor_name(self, vendor_name):
        """
        Sets the vendor_name of this CartLineItem.

        :param vendor_name: The vendor_name of this CartLineItem.
        :type: str
        """

        self._vendor_name = vendor_name

    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, CartLineItem):
            return False

        return self.__dict__ == other.__dict__

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