# coding: utf-8

"""
    Rate Table API

    This API allows sellers to retrieve and manage their custom shipping rate tables. In addition, this API also provides sellers in mainland China methods to configure split-payouts between two separate payment instruments.  # noqa: E501

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

import pprint
import re  # noqa: F401

import six

class PayoutInstrument(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 = {
        'account_last_four_digits': 'str',
        'instrument_id': 'str',
        'instrument_status': 'str',
        'instrument_type': 'str',
        'nickname': 'str',
        'payout_percentage': 'str'
    }

    attribute_map = {
        'account_last_four_digits': 'accountLastFourDigits',
        'instrument_id': 'instrumentId',
        'instrument_status': 'instrumentStatus',
        'instrument_type': 'instrumentType',
        'nickname': 'nickname',
        'payout_percentage': 'payoutPercentage'
    }

    def __init__(self, account_last_four_digits=None, instrument_id=None, instrument_status=None, instrument_type=None, nickname=None, payout_percentage=None):  # noqa: E501
        """PayoutInstrument - a model defined in Swagger"""  # noqa: E501
        self._account_last_four_digits = None
        self._instrument_id = None
        self._instrument_status = None
        self._instrument_type = None
        self._nickname = None
        self._payout_percentage = None
        self.discriminator = None
        if account_last_four_digits is not None:
            self.account_last_four_digits = account_last_four_digits
        if instrument_id is not None:
            self.instrument_id = instrument_id
        if instrument_status is not None:
            self.instrument_status = instrument_status
        if instrument_type is not None:
            self.instrument_type = instrument_type
        if nickname is not None:
            self.nickname = nickname
        if payout_percentage is not None:
            self.payout_percentage = payout_percentage

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

        The last four digits of the account that the seller uses to receive payouts. This may be the last four digits of a bank account or a payment processor account such as Payoneer.  # noqa: E501

        :return: The account_last_four_digits of this PayoutInstrument.  # noqa: E501
        :rtype: str
        """
        return self._account_last_four_digits

    @account_last_four_digits.setter
    def account_last_four_digits(self, account_last_four_digits):
        """Sets the account_last_four_digits of this PayoutInstrument.

        The last four digits of the account that the seller uses to receive payouts. This may be the last four digits of a bank account or a payment processor account such as Payoneer.  # noqa: E501

        :param account_last_four_digits: The account_last_four_digits of this PayoutInstrument.  # noqa: E501
        :type: str
        """

        self._account_last_four_digits = account_last_four_digits

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

        The unique reference identifier for a payout instrument. The <b>instrumentId</b> is needed to change the split-payout percentages through an <b>updatePayoutPercentage</b> request.  # noqa: E501

        :return: The instrument_id of this PayoutInstrument.  # noqa: E501
        :rtype: str
        """
        return self._instrument_id

    @instrument_id.setter
    def instrument_id(self, instrument_id):
        """Sets the instrument_id of this PayoutInstrument.

        The unique reference identifier for a payout instrument. The <b>instrumentId</b> is needed to change the split-payout percentages through an <b>updatePayoutPercentage</b> request.  # noqa: E501

        :param instrument_id: The instrument_id of this PayoutInstrument.  # noqa: E501
        :type: str
        """

        self._instrument_id = instrument_id

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

        The status of a payout instrument. Valid payout instrument statuses include:<br/><ul><li><code>PENDING:</code> This status indicates that the account must be verified before it can be used.</li><li><code>ACTIVE:</code>This status indicates that payouts are enabled on this account.</li><li><code>VERIFICATION_FAILED:</code> This status indicates that verification has failed for this account and payouts are disabled.</li><li><code>INACTIVE:</code> This status indicates that this account has become inactive and payouts are disabled.</li></ul><br/>See <b>InstrumentStatusEnum</b> for more details on each instrument status value.<br><br><span class=\"tablenote\"><b>Note:</b> Payment accounts can only receive payouts if the status of a payout instrument is <code>ACTIVE</code>.</span> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/account/types/sel:InstrumentStatusEnum'>eBay API documentation</a>  # noqa: E501

        :return: The instrument_status of this PayoutInstrument.  # noqa: E501
        :rtype: str
        """
        return self._instrument_status

    @instrument_status.setter
    def instrument_status(self, instrument_status):
        """Sets the instrument_status of this PayoutInstrument.

        The status of a payout instrument. Valid payout instrument statuses include:<br/><ul><li><code>PENDING:</code> This status indicates that the account must be verified before it can be used.</li><li><code>ACTIVE:</code>This status indicates that payouts are enabled on this account.</li><li><code>VERIFICATION_FAILED:</code> This status indicates that verification has failed for this account and payouts are disabled.</li><li><code>INACTIVE:</code> This status indicates that this account has become inactive and payouts are disabled.</li></ul><br/>See <b>InstrumentStatusEnum</b> for more details on each instrument status value.<br><br><span class=\"tablenote\"><b>Note:</b> Payment accounts can only receive payouts if the status of a payout instrument is <code>ACTIVE</code>.</span> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/account/types/sel:InstrumentStatusEnum'>eBay API documentation</a>  # noqa: E501

        :param instrument_status: The instrument_status of this PayoutInstrument.  # noqa: E501
        :type: str
        """

        self._instrument_status = instrument_status

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

        The type of account that received payouts. The value returned in this field may be:<br/><ul><li><code>BANK</code>: Indicates that the payout was made to a seller's bank account.</li><li><code>CARD</code> (<b>Not Currently Available</b>): Indicates that the payout went to a seller's debit card.</li><li>The name of a digital wallet provider or payment processor (e.g., <code>PAYONEER</code>)</li></ul><br><span class=\"tablenote\"><b>Note:</b> Only Payoneer is currently supported for sellers in mainland China. Card payouts are not currently available for sellers in mainland China.</span>   # noqa: E501

        :return: The instrument_type of this PayoutInstrument.  # noqa: E501
        :rtype: str
        """
        return self._instrument_type

    @instrument_type.setter
    def instrument_type(self, instrument_type):
        """Sets the instrument_type of this PayoutInstrument.

        The type of account that received payouts. The value returned in this field may be:<br/><ul><li><code>BANK</code>: Indicates that the payout was made to a seller's bank account.</li><li><code>CARD</code> (<b>Not Currently Available</b>): Indicates that the payout went to a seller's debit card.</li><li>The name of a digital wallet provider or payment processor (e.g., <code>PAYONEER</code>)</li></ul><br><span class=\"tablenote\"><b>Note:</b> Only Payoneer is currently supported for sellers in mainland China. Card payouts are not currently available for sellers in mainland China.</span>   # noqa: E501

        :param instrument_type: The instrument_type of this PayoutInstrument.  # noqa: E501
        :type: str
        """

        self._instrument_type = instrument_type

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

        When <b>instrumentType</b> returns <code>BANK</code>, this value is the seller-provided nickname that the seller uses to represent the bank account that receives the payout.<br/><br/>When <b>instrumentType</b> returns <code>CARD</code>, this value is the debit card network for the debit card that receives the payout.<br/><br/>When <b>instrumentType</b> returns a provider of digital wallet or payment processing services, the value returned is the name of the service provider (e.g., <code>PAYONEER</code>)<br><br><span class=\"tablenote\"><b>Note:</b> Only Payoneer is currently supported for sellers in mainland China. Card payouts are not currently available for sellers in mainland China.</span>  # noqa: E501

        :return: The nickname of this PayoutInstrument.  # noqa: E501
        :rtype: str
        """
        return self._nickname

    @nickname.setter
    def nickname(self, nickname):
        """Sets the nickname of this PayoutInstrument.

        When <b>instrumentType</b> returns <code>BANK</code>, this value is the seller-provided nickname that the seller uses to represent the bank account that receives the payout.<br/><br/>When <b>instrumentType</b> returns <code>CARD</code>, this value is the debit card network for the debit card that receives the payout.<br/><br/>When <b>instrumentType</b> returns a provider of digital wallet or payment processing services, the value returned is the name of the service provider (e.g., <code>PAYONEER</code>)<br><br><span class=\"tablenote\"><b>Note:</b> Only Payoneer is currently supported for sellers in mainland China. Card payouts are not currently available for sellers in mainland China.</span>  # noqa: E501

        :param nickname: The nickname of this PayoutInstrument.  # noqa: E501
        :type: str
        """

        self._nickname = nickname

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

        The current payout percentage allocated to an instrument. For example, <code>50</code> indicates that 50% of the payout goes to the instrument.  # noqa: E501

        :return: The payout_percentage of this PayoutInstrument.  # noqa: E501
        :rtype: str
        """
        return self._payout_percentage

    @payout_percentage.setter
    def payout_percentage(self, payout_percentage):
        """Sets the payout_percentage of this PayoutInstrument.

        The current payout percentage allocated to an instrument. For example, <code>50</code> indicates that 50% of the payout goes to the instrument.  # noqa: E501

        :param payout_percentage: The payout_percentage of this PayoutInstrument.  # noqa: E501
        :type: str
        """

        self._payout_percentage = payout_percentage

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

        return self.__dict__ == other.__dict__

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