CartPickupLocationManagementInterface.php 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. /**
  3. * Refer to LICENSE.txt distributed with the Temando Shipping module for notice of license
  4. */
  5. namespace Temando\Shipping\Api\Checkout;
  6. use Magento\Framework\Exception\CouldNotSaveException;
  7. /**
  8. * Process "pickup location" delivery option.
  9. *
  10. * @api
  11. * @package Temando\Shipping\Api
  12. * @author Sebastian Ertner <sebastian.ertner@netresearch.de>
  13. * @license https://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
  14. * @link https://www.temando.com/
  15. */
  16. interface CartPickupLocationManagementInterface
  17. {
  18. /**
  19. * Retrieve pickup locations matching the customer's search parameters.
  20. *
  21. * @param int $cartId
  22. * @return \Temando\Shipping\Api\Data\Delivery\QuotePickupLocationInterface[]
  23. */
  24. public function getPickupLocations(int $cartId): array;
  25. /**
  26. * Select a given pickup location for checkout.
  27. *
  28. * @param int $cartId
  29. * @param string $pickupLocationId
  30. * @return bool
  31. * @throws CouldNotSaveException
  32. */
  33. public function selectPickupLocation(int $cartId, string $pickupLocationId): bool;
  34. }