2013-05-08 21:42:13 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace GeoIP2\Exception;
|
|
|
|
|
2013-05-10 17:47:11 +00:00
|
|
|
/**
|
|
|
|
* This class represents an error returned by MaxMind's GeoIP2 Precision
|
|
|
|
* web service.
|
|
|
|
*/
|
2013-05-08 21:42:13 +00:00
|
|
|
class WebserviceException extends HttpException
|
|
|
|
{
|
2013-05-10 17:47:11 +00:00
|
|
|
/**
|
|
|
|
* The code returned by the MaxMind web service
|
|
|
|
*/
|
|
|
|
public $error;
|
2013-05-08 21:42:13 +00:00
|
|
|
|
2013-05-09 14:29:29 +00:00
|
|
|
public function __construct(
|
|
|
|
$message,
|
2013-05-10 17:47:11 +00:00
|
|
|
$error,
|
2013-05-09 14:29:29 +00:00
|
|
|
$httpStatus,
|
|
|
|
$uri,
|
|
|
|
Exception $previous = null
|
|
|
|
) {
|
2013-05-10 17:47:11 +00:00
|
|
|
$this->error = $error;
|
|
|
|
parent::__construct($message, $httpStatus, $uri, $previous);
|
2013-05-09 14:29:29 +00:00
|
|
|
}
|
|
|
|
}
|