EventRepositoryInterface.php 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <?php
  2. /**
  3. * Refer to LICENSE.txt distributed with the Temando Shipping module for notice of license
  4. */
  5. namespace Temando\Shipping\Model\ResourceModel\EventStream;
  6. use Magento\Framework\Exception\CouldNotDeleteException;
  7. /**
  8. * Temando Shipment Event Stream Repository Interface.
  9. *
  10. * For cases where the Temando shipment was externally created,
  11. * we have to ask for shipments which have to synced with Magento.
  12. *
  13. * After processing these events, it has to be deleted.
  14. *
  15. * @package Temando\Shipping\Model
  16. * @author Benjamin Heuer <benjamin.heuer@netresearch.de>
  17. * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
  18. * @link http://www.temando.com/
  19. */
  20. interface EventRepositoryInterface
  21. {
  22. /**
  23. * @param string $streamId
  24. * @param int|null $offset
  25. * @param int|null $limit
  26. *
  27. * @return \Temando\Shipping\Model\StreamEventInterface[]
  28. */
  29. public function getEventList($streamId, $offset = null, $limit = null);
  30. /**
  31. * @param string $streamId
  32. * @param string $eventId
  33. *
  34. * @return void
  35. * @throws CouldNotDeleteException
  36. */
  37. public function delete($streamId, $eventId);
  38. }