SearchRequest.php 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. <?php
  2. /**
  3. * Refer to LICENSE.txt distributed with the Temando Shipping module for notice of license
  4. */
  5. namespace Temando\Shipping\Model\CollectionPoint;
  6. use Magento\Framework\DataObject;
  7. use Temando\Shipping\Api\Data\CollectionPoint\SearchRequestInterface;
  8. /**
  9. * Temando Collection Point Search Request
  10. *
  11. * @deprecated since 1.4.0
  12. * @see \Temando\Shipping\Model\Delivery\CollectionPointSearchRequest
  13. *
  14. * @package Temando\Shipping\Model
  15. * @author Christoph Aßmann <christoph.assmann@netresearch.de>
  16. * @license https://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
  17. * @link https://www.temando.com/
  18. */
  19. class SearchRequest extends DataObject implements SearchRequestInterface
  20. {
  21. /**
  22. * @return int
  23. */
  24. public function getShippingAddressId()
  25. {
  26. return $this->getData(SearchRequestInterface::SHIPPING_ADDRESS_ID);
  27. }
  28. /**
  29. * @return string
  30. */
  31. public function getCountryId()
  32. {
  33. return $this->getData(SearchRequestInterface::COUNTRY_ID);
  34. }
  35. /**
  36. * @return string
  37. */
  38. public function getPostcode()
  39. {
  40. return $this->getData(SearchRequestInterface::POSTCODE);
  41. }
  42. /**
  43. * @return bool
  44. */
  45. public function isPending()
  46. {
  47. return (bool)$this->getData(SearchRequestInterface::PENDING);
  48. }
  49. }