# 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 PaymentMethodTypeResource(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 = {
        'id': 'int',
        'invoice_processing_hours': 'int',
        'name': 'str',
        'supports_capture': 'bool',
        'supports_partial': 'bool',
        'supports_rebill': 'bool',
        'supports_refunds': 'bool'
    }

    attribute_map = {
        'id': 'id',
        'invoice_processing_hours': 'invoice_processing_hours',
        'name': 'name',
        'supports_capture': 'supports_capture',
        'supports_partial': 'supports_partial',
        'supports_rebill': 'supports_rebill',
        'supports_refunds': 'supports_refunds'
    }

    def __init__(self, id=None, invoice_processing_hours=None, name=None, supports_capture=None, supports_partial=None, supports_rebill=None, supports_refunds=None):
        """
        PaymentMethodTypeResource - a model defined in Swagger
        """

        self._id = None
        self._invoice_processing_hours = None
        self._name = None
        self._supports_capture = None
        self._supports_partial = None
        self._supports_rebill = None
        self._supports_refunds = None
        self.discriminator = None

        self.id = id
        if invoice_processing_hours is not None:
          self.invoice_processing_hours = invoice_processing_hours
        self.name = name
        if supports_capture is not None:
          self.supports_capture = supports_capture
        if supports_partial is not None:
          self.supports_partial = supports_partial
        if supports_rebill is not None:
          self.supports_rebill = supports_rebill
        if supports_refunds is not None:
          self.supports_refunds = supports_refunds

    @property
    def id(self):
        """
        Gets the id of this PaymentMethodTypeResource.
        The id of the payment method type

        :return: The id of this PaymentMethodTypeResource.
        :rtype: int
        """
        return self._id

    @id.setter
    def id(self, id):
        """
        Sets the id of this PaymentMethodTypeResource.
        The id of the payment method type

        :param id: The id of this PaymentMethodTypeResource.
        :type: int
        """
        if id is None:
            raise ValueError("Invalid value for `id`, must not be `None`")

        self._id = id

    @property
    def invoice_processing_hours(self):
        """
        Gets the invoice_processing_hours of this PaymentMethodTypeResource.
        The maximum timelimit in hours for an invoice in the processing status while waiting on this payment method type. Defaults to the global config invoice.processing_expiration_hours if null

        :return: The invoice_processing_hours of this PaymentMethodTypeResource.
        :rtype: int
        """
        return self._invoice_processing_hours

    @invoice_processing_hours.setter
    def invoice_processing_hours(self, invoice_processing_hours):
        """
        Sets the invoice_processing_hours of this PaymentMethodTypeResource.
        The maximum timelimit in hours for an invoice in the processing status while waiting on this payment method type. Defaults to the global config invoice.processing_expiration_hours if null

        :param invoice_processing_hours: The invoice_processing_hours of this PaymentMethodTypeResource.
        :type: int
        """

        self._invoice_processing_hours = invoice_processing_hours

    @property
    def name(self):
        """
        Gets the name of this PaymentMethodTypeResource.
        The name of the payment method type

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

    @name.setter
    def name(self, name):
        """
        Sets the name of this PaymentMethodTypeResource.
        The name of the payment method type

        :param name: The name of this PaymentMethodTypeResource.
        :type: str
        """
        if name is None:
            raise ValueError("Invalid value for `name`, must not be `None`")

        self._name = name

    @property
    def supports_capture(self):
        """
        Gets the supports_capture of this PaymentMethodTypeResource.
        Whether the payment handler supports the authorize and capture flow

        :return: The supports_capture of this PaymentMethodTypeResource.
        :rtype: bool
        """
        return self._supports_capture

    @supports_capture.setter
    def supports_capture(self, supports_capture):
        """
        Sets the supports_capture of this PaymentMethodTypeResource.
        Whether the payment handler supports the authorize and capture flow

        :param supports_capture: The supports_capture of this PaymentMethodTypeResource.
        :type: bool
        """

        self._supports_capture = supports_capture

    @property
    def supports_partial(self):
        """
        Gets the supports_partial of this PaymentMethodTypeResource.
        Whether the payment handler supports paying for part of an invoice, rather than the full grand_total

        :return: The supports_partial of this PaymentMethodTypeResource.
        :rtype: bool
        """
        return self._supports_partial

    @supports_partial.setter
    def supports_partial(self, supports_partial):
        """
        Sets the supports_partial of this PaymentMethodTypeResource.
        Whether the payment handler supports paying for part of an invoice, rather than the full grand_total

        :param supports_partial: The supports_partial of this PaymentMethodTypeResource.
        :type: bool
        """

        self._supports_partial = supports_partial

    @property
    def supports_rebill(self):
        """
        Gets the supports_rebill of this PaymentMethodTypeResource.
        Whether the payment handler supports rebilling the method later (for saved payments or subscriptions)

        :return: The supports_rebill of this PaymentMethodTypeResource.
        :rtype: bool
        """
        return self._supports_rebill

    @supports_rebill.setter
    def supports_rebill(self, supports_rebill):
        """
        Sets the supports_rebill of this PaymentMethodTypeResource.
        Whether the payment handler supports rebilling the method later (for saved payments or subscriptions)

        :param supports_rebill: The supports_rebill of this PaymentMethodTypeResource.
        :type: bool
        """

        self._supports_rebill = supports_rebill

    @property
    def supports_refunds(self):
        """
        Gets the supports_refunds of this PaymentMethodTypeResource.
        Whether the payment handler supports refunding

        :return: The supports_refunds of this PaymentMethodTypeResource.
        :rtype: bool
        """
        return self._supports_refunds

    @supports_refunds.setter
    def supports_refunds(self, supports_refunds):
        """
        Sets the supports_refunds of this PaymentMethodTypeResource.
        Whether the payment handler supports refunding

        :param supports_refunds: The supports_refunds of this PaymentMethodTypeResource.
        :type: bool
        """

        self._supports_refunds = supports_refunds

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

        return self.__dict__ == other.__dict__

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