PluginProbe
Media Cloud Sync / 1.3.11
Media Cloud Sync v1.3.11
1.4.0 1.3.12 1.3.11 1.3.10 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.1.0 1.1.1 1.2.0 1.2.10 1.2.11 1.2.12 1.2.13 1.2.2 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 1.2.9 1.3.0 All 34 releases
media-cloud-sync / includes / sdk / s3 / GuzzleHttp / Exception / ConnectException.php

ConnectException.php in Media Cloud Sync 1.3.11, at includes/sdk/s3/GuzzleHttp/Exception/ConnectException.php

48 lines 1.4 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace Dudlewebs\WPMCS\s3\GuzzleHttp\Exception;
4
5 use Dudlewebs\WPMCS\s3\Psr\Http\Client\NetworkExceptionInterface;
6 use Dudlewebs\WPMCS\s3\Psr\Http\Message\RequestInterface;
7 /**
8 * Exception thrown when a connection cannot be established.
9 *
10 * Note that no response is present for a ConnectException
11 */
12 class ConnectException extends TransferException implements NetworkExceptionInterface
13 {
14 /**
15 * @var RequestInterface
16 */
17 private $request;
18 /**
19 * @var array
20 */
21 private $handlerContext;
22 public function __construct(string $message, RequestInterface $request, ?\Throwable $previous = null, array $handlerContext = [])
23 {
24 parent::__construct($message, 0, $previous);
25 $this->request = $request;
26 $this->handlerContext = $handlerContext;
27 }
28 /**
29 * Get the request that caused the exception
30 */
31 public function getRequest() : RequestInterface
32 {
33 return $this->request;
34 }
35 /**
36 * Get contextual information about the error from the underlying handler.
37 *
38 * The contents of this array will vary depending on which handler you are
39 * using. It may also be just an empty array. Relying on this data will
40 * couple you to a specific handler, but can give more debug information
41 * when needed.
42 */
43 public function getHandlerContext() : array
44 {
45 return $this->handlerContext;
46 }
47 }
48