/home/fresvfqn/waterdamagerestorationgerritsenbeach.com/Exception.tar
error_log 0000644 00000002110 15053163647 0006465 0 ustar 00 [25-Aug-2025 12:24:12 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/ArgumentCount.php:20
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/ArgumentCount.php on line 20
[25-Aug-2025 15:36:06 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Transport.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Transport.php on line 17
[25-Aug-2025 17:13:24 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http.php:18
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http.php on line 18
Transport/error_log 0000644 00000000602 15053163647 0010465 0 ustar 00 [25-Aug-2025 16:39:50 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Transport" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Transport/Curl.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Transport/Curl.php on line 17
Transport/Curl.php 0000644 00000002565 15053163647 0010200 0 ustar 00 <?php
/**
* CURL Transport Exception.
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Transport;
use WpOrg\Requests\Exception\Transport;
/**
* CURL Transport Exception.
*
* @package Requests\Exceptions
*/
final class Curl extends Transport {
const EASY = 'cURLEasy';
const MULTI = 'cURLMulti';
const SHARE = 'cURLShare';
/**
* cURL error code
*
* @var integer
*/
protected $code = -1;
/**
* Which type of cURL error
*
* EASY|MULTI|SHARE
*
* @var string
*/
protected $type = 'Unknown';
/**
* Clear text error message
*
* @var string
*/
protected $reason = 'Unknown';
/**
* Create a new exception.
*
* @param string $message Exception message.
* @param string $type Exception type.
* @param mixed $data Associated data, if applicable.
* @param int $code Exception numerical code, if applicable.
*/
public function __construct($message, $type, $data = null, $code = 0) {
if ($type !== null) {
$this->type = $type;
}
if ($code !== null) {
$this->code = (int) $code;
}
if ($message !== null) {
$this->reason = $message;
}
$message = sprintf('%d %s', $this->code, $this->reason);
parent::__construct($message, $this->type, $data, $this->code);
}
/**
* Get the error message.
*
* @return string
*/
public function getReason() {
return $this->reason;
}
}
InvalidArgument.php 0000644 00000002122 15053163647 0010355 0 ustar 00 <?php
namespace WpOrg\Requests\Exception;
use InvalidArgumentException;
/**
* Exception for an invalid argument passed.
*
* @package Requests\Exceptions
* @since 2.0.0
*/
final class InvalidArgument extends InvalidArgumentException {
/**
* Create a new invalid argument exception with a standardized text.
*
* @param int $position The argument position in the function signature. 1-based.
* @param string $name The argument name in the function signature.
* @param string $expected The argument type expected as a string.
* @param string $received The actual argument type received.
*
* @return \WpOrg\Requests\Exception\InvalidArgument
*/
public static function create($position, $name, $expected, $received) {
// phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_debug_backtrace
$stack = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 2);
return new self(
sprintf(
'%s::%s(): Argument #%d (%s) must be of type %s, %s given',
$stack[1]['class'],
$stack[1]['function'],
$position,
$name,
$expected,
$received
)
);
}
}
Http/Status501.php 0000644 00000000725 15053163647 0007723 0 ustar 00 <?php
/**
* Exception for 501 Not Implemented responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 501 Not Implemented responses
*
* @package Requests\Exceptions
*/
final class Status501 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 501;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Not Implemented';
}
Http/Status412.php 0000644 00000000741 15053163647 0007722 0 ustar 00 <?php
/**
* Exception for 412 Precondition Failed responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 412 Precondition Failed responses
*
* @package Requests\Exceptions
*/
final class Status412 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 412;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Precondition Failed';
}
Http/error_log 0000644 00000030445 15053163647 0007420 0 ustar 00 [25-Aug-2025 16:00:30 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status511.php:21
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status511.php on line 21
[25-Aug-2025 16:00:41 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status414.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status414.php on line 17
[25-Aug-2025 16:01:12 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status400.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status400.php on line 17
[25-Aug-2025 16:02:14 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status505.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status505.php on line 17
[25-Aug-2025 16:03:20 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status411.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status411.php on line 17
[25-Aug-2025 16:04:25 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status404.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status404.php on line 17
[25-Aug-2025 16:05:27 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status418.php:21
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status418.php on line 21
[25-Aug-2025 16:06:32 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status503.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status503.php on line 17
[25-Aug-2025 16:08:34 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status500.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status500.php on line 17
[25-Aug-2025 16:09:38 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status413.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status413.php on line 17
[25-Aug-2025 16:10:40 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status402.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status402.php on line 17
[25-Aug-2025 16:11:43 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status431.php:21
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status431.php on line 21
[25-Aug-2025 16:12:44 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status401.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status401.php on line 17
[25-Aug-2025 16:13:46 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status409.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status409.php on line 17
[25-Aug-2025 16:14:52 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status305.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status305.php on line 17
[25-Aug-2025 16:15:53 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status306.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status306.php on line 17
[25-Aug-2025 16:16:53 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status416.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status416.php on line 17
[25-Aug-2025 16:17:55 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status412.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status412.php on line 17
[25-Aug-2025 16:19:00 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status504.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status504.php on line 17
[25-Aug-2025 16:20:03 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status407.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status407.php on line 17
[25-Aug-2025 16:21:08 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status428.php:21
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status428.php on line 21
[25-Aug-2025 16:22:10 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status408.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status408.php on line 17
[25-Aug-2025 16:23:11 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status429.php:21
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status429.php on line 21
[25-Aug-2025 16:24:15 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status501.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status501.php on line 17
[25-Aug-2025 16:25:18 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status417.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status417.php on line 17
[25-Aug-2025 16:26:23 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status405.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status405.php on line 17
[25-Aug-2025 16:27:26 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status502.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status502.php on line 17
[25-Aug-2025 16:28:30 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status406.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status406.php on line 17
[25-Aug-2025 16:29:34 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status403.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status403.php on line 17
[25-Aug-2025 16:30:35 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status410.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status410.php on line 17
[25-Aug-2025 16:31:35 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status415.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status415.php on line 17
[25-Aug-2025 16:32:38 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status304.php:17
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/Status304.php on line 17
[25-Aug-2025 16:42:41 UTC] PHP Fatal error: Uncaught Error: Class "WpOrg\Requests\Exception\Http" not found in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/StatusUnknown.php:18
Stack trace:
#0 {main}
thrown in /home/fresvfqn/waterdamagerestorationgerritsenbeach.com/wp-includes/Requests/src/Exception/Http/StatusUnknown.php on line 18
Http/Status405.php 0000644 00000000736 15053163647 0007730 0 ustar 00 <?php
/**
* Exception for 405 Method Not Allowed responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 405 Method Not Allowed responses
*
* @package Requests\Exceptions
*/
final class Status405 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 405;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Method Not Allowed';
}
Http/Status411.php 0000644 00000000725 15053163647 0007723 0 ustar 00 <?php
/**
* Exception for 411 Length Required responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 411 Length Required responses
*
* @package Requests\Exceptions
*/
final class Status411 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 411;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Length Required';
}
Http/Status410.php 0000644 00000000664 15053163647 0007724 0 ustar 00 <?php
/**
* Exception for 410 Gone responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 410 Gone responses
*
* @package Requests\Exceptions
*/
final class Status410 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 410;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Gone';
}
Http/Status409.php 0000644 00000000700 15053163647 0007723 0 ustar 00 <?php
/**
* Exception for 409 Conflict responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 409 Conflict responses
*
* @package Requests\Exceptions
*/
final class Status409 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 409;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Conflict';
}
Http/Status416.php 0000644 00000001005 15053163647 0007720 0 ustar 00 <?php
/**
* Exception for 416 Requested Range Not Satisfiable responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 416 Requested Range Not Satisfiable responses
*
* @package Requests\Exceptions
*/
final class Status416 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 416;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Requested Range Not Satisfiable';
}
Http/Status431.php 0000644 00000001145 15053163647 0007722 0 ustar 00 <?php
/**
* Exception for 431 Request Header Fields Too Large responses
*
* @link https://tools.ietf.org/html/rfc6585
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 431 Request Header Fields Too Large responses
*
* @link https://tools.ietf.org/html/rfc6585
*
* @package Requests\Exceptions
*/
final class Status431 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 431;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Request Header Fields Too Large';
}
Http/Status406.php 0000644 00000000722 15053163647 0007724 0 ustar 00 <?php
/**
* Exception for 406 Not Acceptable responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 406 Not Acceptable responses
*
* @package Requests\Exceptions
*/
final class Status406 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 406;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Not Acceptable';
}
Http/Status503.php 0000644 00000000741 15053163647 0007723 0 ustar 00 <?php
/**
* Exception for 503 Service Unavailable responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 503 Service Unavailable responses
*
* @package Requests\Exceptions
*/
final class Status503 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 503;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Service Unavailable';
}
Http/Status403.php 0000644 00000000703 15053163647 0007720 0 ustar 00 <?php
/**
* Exception for 403 Forbidden responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 403 Forbidden responses
*
* @package Requests\Exceptions
*/
final class Status403 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 403;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Forbidden';
}
Http/Status305.php 0000644 00000000703 15053163647 0007721 0 ustar 00 <?php
/**
* Exception for 305 Use Proxy responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 305 Use Proxy responses
*
* @package Requests\Exceptions
*/
final class Status305 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 305;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Use Proxy';
}
Http/Status500.php 0000644 00000000747 15053163647 0007726 0 ustar 00 <?php
/**
* Exception for 500 Internal Server Error responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 500 Internal Server Error responses
*
* @package Requests\Exceptions
*/
final class Status500 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 500;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Internal Server Error';
}
Http/Status407.php 0000644 00000000777 15053163647 0007737 0 ustar 00 <?php
/**
* Exception for 407 Proxy Authentication Required responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 407 Proxy Authentication Required responses
*
* @package Requests\Exceptions
*/
final class Status407 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 407;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Proxy Authentication Required';
}
Http/Status400.php 0000644 00000000711 15053163647 0007714 0 ustar 00 <?php
/**
* Exception for 400 Bad Request responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 400 Bad Request responses
*
* @package Requests\Exceptions
*/
final class Status400 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 400;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Bad Request';
}
Http/Status511.php 0000644 00000001145 15053163647 0007721 0 ustar 00 <?php
/**
* Exception for 511 Network Authentication Required responses
*
* @link https://tools.ietf.org/html/rfc6585
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 511 Network Authentication Required responses
*
* @link https://tools.ietf.org/html/rfc6585
*
* @package Requests\Exceptions
*/
final class Status511 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 511;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Network Authentication Required';
}
Http/Status418.php 0000644 00000001054 15053163647 0007726 0 ustar 00 <?php
/**
* Exception for 418 I'm A Teapot responses
*
* @link https://tools.ietf.org/html/rfc2324
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 418 I'm A Teapot responses
*
* @link https://tools.ietf.org/html/rfc2324
*
* @package Requests\Exceptions
*/
final class Status418 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 418;
/**
* Reason phrase
*
* @var string
*/
protected $reason = "I'm A Teapot";
}
Http/Status304.php 0000644 00000000714 15053163647 0007722 0 ustar 00 <?php
/**
* Exception for 304 Not Modified responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 304 Not Modified responses
*
* @package Requests\Exceptions
*/
final class Status304 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 304;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Not Modified';
}
Http/Status417.php 0000644 00000000736 15053163647 0007733 0 ustar 00 <?php
/**
* Exception for 417 Expectation Failed responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 417 Expectation Failed responses
*
* @package Requests\Exceptions
*/
final class Status417 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 417;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Expectation Failed';
}
Http/Status306.php 0000644 00000000714 15053163647 0007724 0 ustar 00 <?php
/**
* Exception for 306 Switch Proxy responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 306 Switch Proxy responses
*
* @package Requests\Exceptions
*/
final class Status306 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 306;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Switch Proxy';
}
Http/Status414.php 0000644 00000000747 15053163647 0007732 0 ustar 00 <?php
/**
* Exception for 414 Request-URI Too Large responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 414 Request-URI Too Large responses
*
* @package Requests\Exceptions
*/
final class Status414 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 414;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Request-URI Too Large';
}
Http/Status415.php 0000644 00000000752 15053163647 0007727 0 ustar 00 <?php
/**
* Exception for 415 Unsupported Media Type responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 415 Unsupported Media Type responses
*
* @package Requests\Exceptions
*/
final class Status415 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 415;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Unsupported Media Type';
}
Http/Status429.php 0000644 00000001163 15053163647 0007731 0 ustar 00 <?php
/**
* Exception for 429 Too Many Requests responses
*
* @link https://tools.ietf.org/html/draft-nottingham-http-new-status-04
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 429 Too Many Requests responses
*
* @link https://tools.ietf.org/html/draft-nottingham-http-new-status-04
*
* @package Requests\Exceptions
*/
final class Status429 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 429;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Too Many Requests';
}
Http/Status404.php 0000644 00000000703 15053163647 0007721 0 ustar 00 <?php
/**
* Exception for 404 Not Found responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 404 Not Found responses
*
* @package Requests\Exceptions
*/
final class Status404 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 404;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Not Found';
}
Http/Status408.php 0000644 00000000725 15053163647 0007731 0 ustar 00 <?php
/**
* Exception for 408 Request Timeout responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 408 Request Timeout responses
*
* @package Requests\Exceptions
*/
final class Status408 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 408;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Request Timeout';
}
Http/Status413.php 0000644 00000000760 15053163647 0007724 0 ustar 00 <?php
/**
* Exception for 413 Request Entity Too Large responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 413 Request Entity Too Large responses
*
* @package Requests\Exceptions
*/
final class Status413 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 413;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Request Entity Too Large';
}
Http/Status428.php 0000644 00000001107 15053163647 0007726 0 ustar 00 <?php
/**
* Exception for 428 Precondition Required responses
*
* @link https://tools.ietf.org/html/rfc6585
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 428 Precondition Required responses
*
* @link https://tools.ietf.org/html/rfc6585
*
* @package Requests\Exceptions
*/
final class Status428 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 428;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Precondition Required';
}
Http/Status502.php 0000644 00000000711 15053163647 0007717 0 ustar 00 <?php
/**
* Exception for 502 Bad Gateway responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 502 Bad Gateway responses
*
* @package Requests\Exceptions
*/
final class Status502 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 502;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Bad Gateway';
}
Http/Status505.php 0000644 00000000766 15053163647 0007734 0 ustar 00 <?php
/**
* Exception for 505 HTTP Version Not Supported responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 505 HTTP Version Not Supported responses
*
* @package Requests\Exceptions
*/
final class Status505 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 505;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'HTTP Version Not Supported';
}
Http/StatusUnknown.php 0000644 00000001712 15053163647 0011052 0 ustar 00 <?php
/**
* Exception for unknown status responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Response;
/**
* Exception for unknown status responses
*
* @package Requests\Exceptions
*/
final class StatusUnknown extends Http {
/**
* HTTP status code
*
* @var integer|bool Code if available, false if an error occurred
*/
protected $code = 0;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Unknown';
/**
* Create a new exception
*
* If `$data` is an instance of {@see \WpOrg\Requests\Response}, uses the status
* code from it. Otherwise, sets as 0
*
* @param string|null $reason Reason phrase
* @param mixed $data Associated data
*/
public function __construct($reason = null, $data = null) {
if ($data instanceof Response) {
$this->code = (int) $data->status_code;
}
parent::__construct($reason, $data);
}
}
Http/Status402.php 0000644 00000000730 15053163647 0007717 0 ustar 00 <?php
/**
* Exception for 402 Payment Required responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 402 Payment Required responses
*
* @package Requests\Exceptions
*/
final class Status402 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 402;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Payment Required';
}
Http/Status504.php 0000644 00000000725 15053163647 0007726 0 ustar 00 <?php
/**
* Exception for 504 Gateway Timeout responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 504 Gateway Timeout responses
*
* @package Requests\Exceptions
*/
final class Status504 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 504;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Gateway Timeout';
}
Http/Status401.php 0000644 00000000714 15053163647 0007720 0 ustar 00 <?php
/**
* Exception for 401 Unauthorized responses
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception\Http;
use WpOrg\Requests\Exception\Http;
/**
* Exception for 401 Unauthorized responses
*
* @package Requests\Exceptions
*/
final class Status401 extends Http {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 401;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Unauthorized';
}
ArgumentCount.php 0000644 00000002664 15053163647 0010072 0 ustar 00 <?php
namespace WpOrg\Requests\Exception;
use WpOrg\Requests\Exception;
/**
* Exception for when an incorrect number of arguments are passed to a method.
*
* Typically, this exception is used when all arguments for a method are optional,
* but certain arguments need to be passed together, i.e. a method which can be called
* with no arguments or with two arguments, but not with one argument.
*
* Along the same lines, this exception is also used if a method expects an array
* with a certain number of elements and the provided number of elements does not comply.
*
* @package Requests\Exceptions
* @since 2.0.0
*/
final class ArgumentCount extends Exception {
/**
* Create a new argument count exception with a standardized text.
*
* @param string $expected The argument count expected as a phrase.
* For example: `at least 2 arguments` or `exactly 1 argument`.
* @param int $received The actual argument count received.
* @param string $type Exception type.
*
* @return \WpOrg\Requests\Exception\ArgumentCount
*/
public static function create($expected, $received, $type) {
// phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_debug_backtrace
$stack = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 2);
return new self(
sprintf(
'%s::%s() expects %s, %d given',
$stack[1]['class'],
$stack[1]['function'],
$expected,
$received
),
$type
);
}
}
Transport.php 0000644 00000000364 15053163647 0007266 0 ustar 00 <?php
/**
* Transport Exception
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception;
use WpOrg\Requests\Exception;
/**
* Transport Exception
*
* @package Requests\Exceptions
*/
class Transport extends Exception {}
Http.php 0000644 00000003006 15053163647 0006205 0 ustar 00 <?php
/**
* Exception based on HTTP response
*
* @package Requests\Exceptions
*/
namespace WpOrg\Requests\Exception;
use WpOrg\Requests\Exception;
use WpOrg\Requests\Exception\Http\StatusUnknown;
/**
* Exception based on HTTP response
*
* @package Requests\Exceptions
*/
class Http extends Exception {
/**
* HTTP status code
*
* @var integer
*/
protected $code = 0;
/**
* Reason phrase
*
* @var string
*/
protected $reason = 'Unknown';
/**
* Create a new exception
*
* There is no mechanism to pass in the status code, as this is set by the
* subclass used. Reason phrases can vary, however.
*
* @param string|null $reason Reason phrase
* @param mixed $data Associated data
*/
public function __construct($reason = null, $data = null) {
if ($reason !== null) {
$this->reason = $reason;
}
$message = sprintf('%d %s', $this->code, $this->reason);
parent::__construct($message, 'httpresponse', $data, $this->code);
}
/**
* Get the status message.
*
* @return string
*/
public function getReason() {
return $this->reason;
}
/**
* Get the correct exception class for a given error code
*
* @param int|bool $code HTTP status code, or false if unavailable
* @return string Exception class name to use
*/
public static function get_class($code) {
if (!$code) {
return StatusUnknown::class;
}
$class = sprintf('\WpOrg\Requests\Exception\Http\Status%d', $code);
if (class_exists($class)) {
return $class;
}
return StatusUnknown::class;
}
}