NetworkExceptionInterface.php 658 B

123456789101112131415161718192021222324
  1. <?php
  2. namespace Psr\Http\Client;
  3. use Psr\Http\Message\RequestInterface;
  4. /**
  5. * Thrown when the request cannot be completed because of network issues.
  6. *
  7. * There is no response object as this exception is thrown when no response has been received.
  8. *
  9. * Example: the target host name can not be resolved or the connection failed.
  10. */
  11. interface NetworkExceptionInterface extends ClientExceptionInterface
  12. {
  13. /**
  14. * Returns the request.
  15. *
  16. * The request object MAY be a different object from the one passed to ClientInterface::sendRequest()
  17. *
  18. * @return RequestInterface
  19. */
  20. public function getRequest(): RequestInterface;
  21. }