PaymentTokenRepositoryInterface.php 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\Vault\Api;
  7. /**
  8. * Gateway vault payment token repository interface.
  9. *
  10. * @api
  11. * @since 100.1.0
  12. */
  13. interface PaymentTokenRepositoryInterface
  14. {
  15. /**
  16. * Lists payment tokens that match specified search criteria.
  17. *
  18. * @param \Magento\Framework\Api\SearchCriteriaInterface $searchCriteria The search criteria.
  19. * @return \Magento\Vault\Api\Data\PaymentTokenSearchResultsInterface Payment token search result interface.
  20. * @since 100.1.0
  21. */
  22. public function getList(\Magento\Framework\Api\SearchCriteriaInterface $searchCriteria);
  23. /**
  24. * Loads a specified payment token.
  25. *
  26. * @param int $entityId The payment token entity ID.
  27. * @return \Magento\Vault\Api\Data\PaymentTokenInterface Payment token interface.
  28. * @since 100.1.0
  29. */
  30. public function getById($entityId);
  31. /**
  32. * Deletes a specified payment token.
  33. *
  34. * @param \Magento\Vault\Api\Data\PaymentTokenInterface $paymentToken The invoice.
  35. * @return bool
  36. * @since 100.1.0
  37. */
  38. public function delete(Data\PaymentTokenInterface $paymentToken);
  39. /**
  40. * Performs persist operations for a specified payment token.
  41. *
  42. * @param \Magento\Vault\Api\Data\PaymentTokenInterface $paymentToken The payment token.
  43. * @return \Magento\Vault\Api\Data\PaymentTokenInterface Payment token interface.
  44. * @since 100.1.0
  45. */
  46. public function save(Data\PaymentTokenInterface $paymentToken);
  47. }