CaseRepositoryInterface.php 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\Signifyd\Api;
  7. /**
  8. * Signifyd Case repository interface
  9. *
  10. * @api
  11. * @since 100.2.0
  12. */
  13. interface CaseRepositoryInterface
  14. {
  15. /**
  16. * Saves case entity.
  17. *
  18. * @param \Magento\Signifyd\Api\Data\CaseInterface $case
  19. * @return \Magento\Signifyd\Api\Data\CaseInterface
  20. * @since 100.2.0
  21. */
  22. public function save(\Magento\Signifyd\Api\Data\CaseInterface $case);
  23. /**
  24. * Gets case entity by order id.
  25. *
  26. * @param int $id
  27. * @return \Magento\Signifyd\Api\Data\CaseInterface
  28. * @since 100.2.0
  29. */
  30. public function getById($id);
  31. /**
  32. * Gets entity by Signifyd case id.
  33. *
  34. * @param int $caseId
  35. * @return \Magento\Signifyd\Api\Data\CaseInterface|null
  36. * @since 100.2.0
  37. */
  38. public function getByCaseId($caseId);
  39. /**
  40. * Deletes case entity.
  41. *
  42. * @param \Magento\Signifyd\Api\Data\CaseInterface $case
  43. * @return bool
  44. * @since 100.2.0
  45. */
  46. public function delete(\Magento\Signifyd\Api\Data\CaseInterface $case);
  47. /**
  48. * Gets list of case entities.
  49. *
  50. * @param \Magento\Framework\Api\SearchCriteriaInterface $searchCriteria
  51. * @return \Magento\Signifyd\Api\Data\CaseSearchResultsInterface
  52. * @since 100.2.0
  53. */
  54. public function getList(\Magento\Framework\Api\SearchCriteriaInterface $searchCriteria);
  55. }