AggregateExceptionInterface.php 774 B

123456789101112131415161718192021222324252627
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\Framework\Exception;
  7. /**
  8. * AggregateExceptionInterface Extension Point introduced to support Multiple Errors returned as a result of Validation
  9. * not mandating to inherit from AbstractAggregateException class
  10. *
  11. * @api
  12. * @since 101.0.7
  13. */
  14. interface AggregateExceptionInterface
  15. {
  16. /**
  17. * Returns LocalizedException[] array to be compatible with current Implementation in Web API which relies on
  18. * this behavior
  19. *
  20. * @see the \Magento\Framework\Webapi\Exception which receives $errors as a set of Localized Exceptions
  21. *
  22. * @return LocalizedException[]
  23. * @since 101.0.7
  24. */
  25. public function getErrors();
  26. }