Errors.php 1008 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <?php
  2. /**
  3. * Refer to LICENSE.txt distributed with the Temando Shipping module for notice of license
  4. */
  5. namespace Temando\Shipping\Rest\Response\Document;
  6. /**
  7. * Temando API Error Collection Document
  8. *
  9. * @package Temando\Shipping\Rest
  10. * @author Christoph Aßmann <christoph.assmann@netresearch.de>
  11. * @license https://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
  12. * @link https://www.temando.com/
  13. */
  14. class Errors implements ErrorsInterface
  15. {
  16. /**
  17. * @var \Temando\Shipping\Rest\Response\DataObject\Error[]
  18. */
  19. private $errors = [];
  20. /**
  21. * Obtain error entities
  22. *
  23. * @return \Temando\Shipping\Rest\Response\DataObject\Error[]
  24. */
  25. public function getErrors()
  26. {
  27. return $this->errors;
  28. }
  29. /**
  30. * Set error entities
  31. *
  32. * @param \Temando\Shipping\Rest\Response\DataObject\Error[] $errors
  33. * @return void
  34. */
  35. public function setErrors(array $errors)
  36. {
  37. $this->errors = $errors;
  38. }
  39. }