ameliabooking
/
vendor
/
mailgun
/
mailgun-php
/
src
/
Mailgun
/
Connection
/
Exceptions
/
GenericHTTPError.php
ameliabooking
/
vendor
/
mailgun
/
mailgun-php
/
src
/
Mailgun
/
Connection
/
Exceptions
Last commit date
GenericHTTPError.php
7 years ago
InvalidCredentials.php
7 years ago
MissingEndpoint.php
7 years ago
MissingRequiredParameters.php
7 years ago
NoDomainsConfigured.php
7 years ago
GenericHTTPError.php
41 lines
| 1 | <?php |
| 2 | |
| 3 | /* |
| 4 | * Copyright (C) 2013 Mailgun |
| 5 | * |
| 6 | * This software may be modified and distributed under the terms |
| 7 | * of the MIT license. See the LICENSE file for details. |
| 8 | */ |
| 9 | |
| 10 | namespace Mailgun\Connection\Exceptions; |
| 11 | |
| 12 | use Mailgun\Exception; |
| 13 | |
| 14 | /** |
| 15 | * @deprecated Will be removed in 3.0 |
| 16 | */ |
| 17 | class GenericHTTPError extends \Exception implements Exception |
| 18 | { |
| 19 | protected $httpResponseCode; |
| 20 | |
| 21 | protected $httpResponseBody; |
| 22 | |
| 23 | public function __construct($message = null, $response_code = null, $response_body = null, $code = 0, \Exception $previous = null) |
| 24 | { |
| 25 | parent::__construct($message, $code, $previous); |
| 26 | |
| 27 | $this->httpResponseCode = $response_code; |
| 28 | $this->httpResponseBody = $response_body; |
| 29 | } |
| 30 | |
| 31 | public function getHttpResponseCode() |
| 32 | { |
| 33 | return $this->httpResponseCode; |
| 34 | } |
| 35 | |
| 36 | public function getHttpResponseBody() |
| 37 | { |
| 38 | return $this->httpResponseBody; |
| 39 | } |
| 40 | } |
| 41 |