# coding: utf-8

"""
    Metadata API

    The Metadata API has operations that retrieve configuration details pertaining to the different eBay marketplaces. In addition to marketplace information, the API also has operations that get information that helps sellers list items on eBay.  # noqa: E501

    OpenAPI spec version: v1.11.0
    
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""

import pprint
import re  # noqa: F401

import six

class CategoryPolicy(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 = {
        'auto_pay_enabled': 'bool',
        'b2b_vat_enabled': 'bool',
        'category_id': 'str',
        'category_tree_id': 'str',
        'ean_support': 'str',
        'expired': 'bool',
        'intangible_enabled': 'bool',
        'isbn_support': 'str',
        'lsd': 'bool',
        'minimum_reserve_price': 'float',
        'orpa': 'bool',
        'orra': 'bool',
        'payment_methods': 'list[str]',
        'reduce_reserve_allowed': 'bool',
        'upc_support': 'str',
        'virtual': 'bool'
    }

    attribute_map = {
        'auto_pay_enabled': 'autoPayEnabled',
        'b2b_vat_enabled': 'b2bVatEnabled',
        'category_id': 'categoryId',
        'category_tree_id': 'categoryTreeId',
        'ean_support': 'eanSupport',
        'expired': 'expired',
        'intangible_enabled': 'intangibleEnabled',
        'isbn_support': 'isbnSupport',
        'lsd': 'lsd',
        'minimum_reserve_price': 'minimumReservePrice',
        'orpa': 'orpa',
        'orra': 'orra',
        'payment_methods': 'paymentMethods',
        'reduce_reserve_allowed': 'reduceReserveAllowed',
        'upc_support': 'upcSupport',
        'virtual': 'virtual'
    }

    def __init__(self, auto_pay_enabled=None, b2b_vat_enabled=None, category_id=None, category_tree_id=None, ean_support=None, expired=None, intangible_enabled=None, isbn_support=None, lsd=None, minimum_reserve_price=None, orpa=None, orra=None, payment_methods=None, reduce_reserve_allowed=None, upc_support=None, virtual=None):  # noqa: E501
        """CategoryPolicy - a model defined in Swagger"""  # noqa: E501
        self._auto_pay_enabled = None
        self._b2b_vat_enabled = None
        self._category_id = None
        self._category_tree_id = None
        self._ean_support = None
        self._expired = None
        self._intangible_enabled = None
        self._isbn_support = None
        self._lsd = None
        self._minimum_reserve_price = None
        self._orpa = None
        self._orra = None
        self._payment_methods = None
        self._reduce_reserve_allowed = None
        self._upc_support = None
        self._virtual = None
        self.discriminator = None
        if auto_pay_enabled is not None:
            self.auto_pay_enabled = auto_pay_enabled
        if b2b_vat_enabled is not None:
            self.b2b_vat_enabled = b2b_vat_enabled
        if category_id is not None:
            self.category_id = category_id
        if category_tree_id is not None:
            self.category_tree_id = category_tree_id
        if ean_support is not None:
            self.ean_support = ean_support
        if expired is not None:
            self.expired = expired
        if intangible_enabled is not None:
            self.intangible_enabled = intangible_enabled
        if isbn_support is not None:
            self.isbn_support = isbn_support
        if lsd is not None:
            self.lsd = lsd
        if minimum_reserve_price is not None:
            self.minimum_reserve_price = minimum_reserve_price
        if orpa is not None:
            self.orpa = orpa
        if orra is not None:
            self.orra = orra
        if payment_methods is not None:
            self.payment_methods = payment_methods
        if reduce_reserve_allowed is not None:
            self.reduce_reserve_allowed = reduce_reserve_allowed
        if upc_support is not None:
            self.upc_support = upc_support
        if virtual is not None:
            self.virtual = virtual

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

        If this field is returned as <code>true</code>, the corresponding category supports immediate payment for listings. The immediate payment feature is applicable to fixed-price listings, to auction listings with the 'Buy It Now' option enabled, and for a motor vehicle listing that requires an initial deposit. If the immediate payment feature is enabled for a listing, the buyer must pay immediately after clicking the 'Buy it Now' button. <p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :return: The auto_pay_enabled of this CategoryPolicy.  # noqa: E501
        :rtype: bool
        """
        return self._auto_pay_enabled

    @auto_pay_enabled.setter
    def auto_pay_enabled(self, auto_pay_enabled):
        """Sets the auto_pay_enabled of this CategoryPolicy.

        If this field is returned as <code>true</code>, the corresponding category supports immediate payment for listings. The immediate payment feature is applicable to fixed-price listings, to auction listings with the 'Buy It Now' option enabled, and for a motor vehicle listing that requires an initial deposit. If the immediate payment feature is enabled for a listing, the buyer must pay immediately after clicking the 'Buy it Now' button. <p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :param auto_pay_enabled: The auto_pay_enabled of this CategoryPolicy.  # noqa: E501
        :type: bool
        """

        self._auto_pay_enabled = auto_pay_enabled

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

        If this field is returned as <code>true</code>, the corresponding category supports business-to-business (B2B) VAT listings. If this field is not present, the category does not have B2B VAT listings. This feature is applicable to the eBay Germany (DE), Austria (AT), and Switzerland (CH) sites only.<p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :return: The b2b_vat_enabled of this CategoryPolicy.  # noqa: E501
        :rtype: bool
        """
        return self._b2b_vat_enabled

    @b2b_vat_enabled.setter
    def b2b_vat_enabled(self, b2b_vat_enabled):
        """Sets the b2b_vat_enabled of this CategoryPolicy.

        If this field is returned as <code>true</code>, the corresponding category supports business-to-business (B2B) VAT listings. If this field is not present, the category does not have B2B VAT listings. This feature is applicable to the eBay Germany (DE), Austria (AT), and Switzerland (CH) sites only.<p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :param b2b_vat_enabled: The b2b_vat_enabled of this CategoryPolicy.  # noqa: E501
        :type: bool
        """

        self._b2b_vat_enabled = b2b_vat_enabled

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

        The unique identifier of the eBay leaf category for which metadata is being returned.  # noqa: E501

        :return: The category_id of this CategoryPolicy.  # noqa: E501
        :rtype: str
        """
        return self._category_id

    @category_id.setter
    def category_id(self, category_id):
        """Sets the category_id of this CategoryPolicy.

        The unique identifier of the eBay leaf category for which metadata is being returned.  # noqa: E501

        :param category_id: The category_id of this CategoryPolicy.  # noqa: E501
        :type: str
        """

        self._category_id = category_id

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

        The unique identifier of the category tree.  # noqa: E501

        :return: The category_tree_id of this CategoryPolicy.  # noqa: E501
        :rtype: str
        """
        return self._category_tree_id

    @category_tree_id.setter
    def category_tree_id(self, category_tree_id):
        """Sets the category_tree_id of this CategoryPolicy.

        The unique identifier of the category tree.  # noqa: E501

        :param category_tree_id: The category_tree_id of this CategoryPolicy.  # noqa: E501
        :type: str
        """

        self._category_tree_id = category_tree_id

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

        This enumerated value indicates whether or not European Article Numbers (EANs) are supported/required when listing products in the category. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/metadata/types/sel:ProductIdentiferEnabledEnum'>eBay API documentation</a>  # noqa: E501

        :return: The ean_support of this CategoryPolicy.  # noqa: E501
        :rtype: str
        """
        return self._ean_support

    @ean_support.setter
    def ean_support(self, ean_support):
        """Sets the ean_support of this CategoryPolicy.

        This enumerated value indicates whether or not European Article Numbers (EANs) are supported/required when listing products in the category. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/metadata/types/sel:ProductIdentiferEnabledEnum'>eBay API documentation</a>  # noqa: E501

        :param ean_support: The ean_support of this CategoryPolicy.  # noqa: E501
        :type: str
        """

        self._ean_support = ean_support

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

        If this field is returned as <code>true</code>, the corresponding category is no longer a valid eBay category on the site, and items may not be listed in this category. You can use the <a href=\"/api-docs/sell/taxonomy/resources/category_tree/methods/getExpiredCategories\" target=\"_blank\">getExpiredCategories</a> method (of the <b>Taxonomy API</b>) to find the leaf category that replaced the expired category. <p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :return: The expired of this CategoryPolicy.  # noqa: E501
        :rtype: bool
        """
        return self._expired

    @expired.setter
    def expired(self, expired):
        """Sets the expired of this CategoryPolicy.

        If this field is returned as <code>true</code>, the corresponding category is no longer a valid eBay category on the site, and items may not be listed in this category. You can use the <a href=\"/api-docs/sell/taxonomy/resources/category_tree/methods/getExpiredCategories\" target=\"_blank\">getExpiredCategories</a> method (of the <b>Taxonomy API</b>) to find the leaf category that replaced the expired category. <p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :param expired: The expired of this CategoryPolicy.  # noqa: E501
        :type: bool
        """

        self._expired = expired

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

        If this field is returned as <code>true</code>, the category supports the listing of intangible goods or services.  # noqa: E501

        :return: The intangible_enabled of this CategoryPolicy.  # noqa: E501
        :rtype: bool
        """
        return self._intangible_enabled

    @intangible_enabled.setter
    def intangible_enabled(self, intangible_enabled):
        """Sets the intangible_enabled of this CategoryPolicy.

        If this field is returned as <code>true</code>, the category supports the listing of intangible goods or services.  # noqa: E501

        :param intangible_enabled: The intangible_enabled of this CategoryPolicy.  # noqa: E501
        :type: bool
        """

        self._intangible_enabled = intangible_enabled

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

        This enumerated value indicates whether or not International Standard Book Numbers (ISBNs) are supported/required when listing products in the specified category. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/metadata/types/sel:ProductIdentiferEnabledEnum'>eBay API documentation</a>  # noqa: E501

        :return: The isbn_support of this CategoryPolicy.  # noqa: E501
        :rtype: str
        """
        return self._isbn_support

    @isbn_support.setter
    def isbn_support(self, isbn_support):
        """Sets the isbn_support of this CategoryPolicy.

        This enumerated value indicates whether or not International Standard Book Numbers (ISBNs) are supported/required when listing products in the specified category. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/metadata/types/sel:ProductIdentiferEnabledEnum'>eBay API documentation</a>  # noqa: E501

        :param isbn_support: The isbn_support of this CategoryPolicy.  # noqa: E501
        :type: str
        """

        self._isbn_support = isbn_support

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

        If this field (Lot Size Disabled) is returned as <code>true</code>, the corresponding category does not support lot listings. A lot listing is a listing that features multiple related items that must be purchased by one buyer in one transaction. <p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :return: The lsd of this CategoryPolicy.  # noqa: E501
        :rtype: bool
        """
        return self._lsd

    @lsd.setter
    def lsd(self, lsd):
        """Sets the lsd of this CategoryPolicy.

        If this field (Lot Size Disabled) is returned as <code>true</code>, the corresponding category does not support lot listings. A lot listing is a listing that features multiple related items that must be purchased by one buyer in one transaction. <p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :param lsd: The lsd of this CategoryPolicy.  # noqa: E501
        :type: bool
        """

        self._lsd = lsd

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

        Indicates the Minimum Reserve Price for an auction listing in this category. If there is no Minimum Reserve Price, a value of <code>0.0</code> is returned in this field.  # noqa: E501

        :return: The minimum_reserve_price of this CategoryPolicy.  # noqa: E501
        :rtype: float
        """
        return self._minimum_reserve_price

    @minimum_reserve_price.setter
    def minimum_reserve_price(self, minimum_reserve_price):
        """Sets the minimum_reserve_price of this CategoryPolicy.

        Indicates the Minimum Reserve Price for an auction listing in this category. If there is no Minimum Reserve Price, a value of <code>0.0</code> is returned in this field.  # noqa: E501

        :param minimum_reserve_price: The minimum_reserve_price of this CategoryPolicy.  # noqa: E501
        :type: float
        """

        self._minimum_reserve_price = minimum_reserve_price

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

        If this field (Override Reserve Price Allowed) is returned as <code>true</code>, all leaf categories on the site allow the seller to completely remove the reserve price for an active auction listing. For information on removing or reducing reserve prices, see <a href=\"https://www.ebay.com/help/selling/listings/selling-auctions/reserve-prices?id=4143\"  target=\"_blank\">Setting a reserve price</a>.  # noqa: E501

        :return: The orpa of this CategoryPolicy.  # noqa: E501
        :rtype: bool
        """
        return self._orpa

    @orpa.setter
    def orpa(self, orpa):
        """Sets the orpa of this CategoryPolicy.

        If this field (Override Reserve Price Allowed) is returned as <code>true</code>, all leaf categories on the site allow the seller to completely remove the reserve price for an active auction listing. For information on removing or reducing reserve prices, see <a href=\"https://www.ebay.com/help/selling/listings/selling-auctions/reserve-prices?id=4143\"  target=\"_blank\">Setting a reserve price</a>.  # noqa: E501

        :param orpa: The orpa of this CategoryPolicy.  # noqa: E501
        :type: bool
        """

        self._orpa = orpa

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

        If this field (Override Reduce Reserve Allowed) is returned as <code>true</code>, the seller can reduce or remove a reserve price that had already been reduced for an active auction listing.  # noqa: E501

        :return: The orra of this CategoryPolicy.  # noqa: E501
        :rtype: bool
        """
        return self._orra

    @orra.setter
    def orra(self, orra):
        """Sets the orra of this CategoryPolicy.

        If this field (Override Reduce Reserve Allowed) is returned as <code>true</code>, the seller can reduce or remove a reserve price that had already been reduced for an active auction listing.  # noqa: E501

        :param orra: The orra of this CategoryPolicy.  # noqa: E501
        :type: bool
        """

        self._orra = orra

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

        An array that indicates the acceptable offline payment methods that can be used when listing an item for sale in the corresponding category.  # noqa: E501

        :return: The payment_methods of this CategoryPolicy.  # noqa: E501
        :rtype: list[str]
        """
        return self._payment_methods

    @payment_methods.setter
    def payment_methods(self, payment_methods):
        """Sets the payment_methods of this CategoryPolicy.

        An array that indicates the acceptable offline payment methods that can be used when listing an item for sale in the corresponding category.  # noqa: E501

        :param payment_methods: The payment_methods of this CategoryPolicy.  # noqa: E501
        :type: list[str]
        """

        self._payment_methods = payment_methods

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

        If this field (Reduce Reserve Allowed) is <code>true</code>, the corresponding leaf category allows the seller to reduce an item's reserve price. If false, this field is not returned in the response and the corresponding leaf category on the site do not normally allow sellers to reduce an item's reserve price.<p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :return: The reduce_reserve_allowed of this CategoryPolicy.  # noqa: E501
        :rtype: bool
        """
        return self._reduce_reserve_allowed

    @reduce_reserve_allowed.setter
    def reduce_reserve_allowed(self, reduce_reserve_allowed):
        """Sets the reduce_reserve_allowed of this CategoryPolicy.

        If this field (Reduce Reserve Allowed) is <code>true</code>, the corresponding leaf category allows the seller to reduce an item's reserve price. If false, this field is not returned in the response and the corresponding leaf category on the site do not normally allow sellers to reduce an item's reserve price.<p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :param reduce_reserve_allowed: The reduce_reserve_allowed of this CategoryPolicy.  # noqa: E501
        :type: bool
        """

        self._reduce_reserve_allowed = reduce_reserve_allowed

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

        This enumerated value indicates whether or not the category on the specified eBay site supports the use of Universal Product Codes (UPCs) to help create a listing. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/metadata/types/sel:ProductIdentiferEnabledEnum'>eBay API documentation</a>  # noqa: E501

        :return: The upc_support of this CategoryPolicy.  # noqa: E501
        :rtype: str
        """
        return self._upc_support

    @upc_support.setter
    def upc_support(self, upc_support):
        """Sets the upc_support of this CategoryPolicy.

        This enumerated value indicates whether or not the category on the specified eBay site supports the use of Universal Product Codes (UPCs) to help create a listing. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/metadata/types/sel:ProductIdentiferEnabledEnum'>eBay API documentation</a>  # noqa: E501

        :param upc_support: The upc_support of this CategoryPolicy.  # noqa: E501
        :type: str
        """

        self._upc_support = upc_support

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

        If this field is returned as <code>true</code>, the corresponding category is an eBay virtual category, a category in which items may not be listed.<p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :return: The virtual of this CategoryPolicy.  # noqa: E501
        :rtype: bool
        """
        return self._virtual

    @virtual.setter
    def virtual(self, virtual):
        """Sets the virtual of this CategoryPolicy.

        If this field is returned as <code>true</code>, the corresponding category is an eBay virtual category, a category in which items may not be listed.<p>This field is only returned when <code>true</code> (not returned when false).</p>  # noqa: E501

        :param virtual: The virtual of this CategoryPolicy.  # noqa: E501
        :type: bool
        """

        self._virtual = virtual

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

        return self.__dict__ == other.__dict__

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