PaymentMethodListInterface.php 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. <?php
  2. /**
  3. * This file is part of the Klarna Kp module
  4. *
  5. * (c) Klarna Bank AB (publ)
  6. *
  7. * For the full copyright and license information, please view the NOTICE
  8. * and LICENSE files that were distributed with this source code.
  9. */
  10. namespace Klarna\Kp\Api;
  11. use Klarna\Kp\Model\Payment\Kp;
  12. use Magento\Payment\Model\MethodInterface;
  13. use Magento\Quote\Api\Data\CartInterface;
  14. /**
  15. * Interface PaymentMethodListInterface
  16. * @api
  17. * @package Klarna\Kp\Api
  18. */
  19. interface PaymentMethodListInterface
  20. {
  21. /**
  22. * Get list of Klarna payment types
  23. *
  24. * @param CartInterface $quote
  25. * @return string[]
  26. * @deprecated 5.3.0
  27. * @see getKlarnaMethodInfo
  28. */
  29. public function getKlarnaMethodCodes(CartInterface $quote = null);
  30. /**
  31. * Get list of Klarna payment types
  32. *
  33. * @param CartInterface $quote
  34. * @return string[]
  35. */
  36. public function getKlarnaMethodInfo(CartInterface $quote);
  37. /**
  38. * Get payment instance for specified Klarna payment method
  39. *
  40. * @param string $method
  41. * @return MethodInterface|Kp
  42. */
  43. public function getPaymentMethod($method);
  44. }