2 namespace TYPO3\CMS\Core\Http;
48 101 =>
'Switching Protocols',
54 203 =>
'Non-Authoritative Information',
56 205 =>
'Reset Content',
57 206 =>
'Partial Content',
58 207 =>
'Multi-status',
59 208 =>
'Already Reported',
61 300 =>
'Multiple Choices',
62 301 =>
'Moved Permanently',
65 304 =>
'Not Modified',
67 306 =>
'Switch Proxy',
68 307 =>
'Temporary Redirect',
71 401 =>
'Unauthorized',
72 402 =>
'Payment Required',
75 405 =>
'Method Not Allowed',
76 406 =>
'Not Acceptable',
77 407 =>
'Proxy Authentication Required',
78 408 =>
'Request Time-out',
81 411 =>
'Length Required',
82 412 =>
'Precondition Failed',
83 413 =>
'Request Entity Too Large',
84 414 =>
'Request-URI Too Large',
85 415 =>
'Unsupported Media Type',
86 416 =>
'Requested range not satisfiable',
87 417 =>
'Expectation Failed',
88 418 =>
'I\'m a teapot',
89 422 =>
'Unprocessable Entity',
91 424 =>
'Failed Dependency',
92 425 =>
'Unordered Collection',
93 426 =>
'Upgrade Required',
94 428 =>
'Precondition Required',
95 429 =>
'Too Many Requests',
96 431 =>
'Request Header Fields Too Large',
98 500 =>
'Internal Server Error',
99 501 =>
'Not Implemented',
100 502 =>
'Bad Gateway',
101 503 =>
'Service Unavailable',
102 504 =>
'Gateway Time-out',
103 505 =>
'HTTP Version not supported',
104 506 =>
'Variant Also Negotiates',
105 507 =>
'Insufficient Storage',
106 508 =>
'Loop Detected',
107 509 =>
'Bandwidth Limit Exceeded',
108 511 =>
'Network Authentication Required'
123 throw new \InvalidArgumentException(
'Body must be a string stream resource identifier, a stream resource, or a StreamInterface instance', 1436717277);
126 if (!
$body instanceof StreamInterface) {
131 if (\TYPO3\CMS\Core\Utility\MathUtility::canBeInterpretedAsInteger(
$statusCode) ===
false || !array_key_exists((
int)
$statusCode, $this->availableStatusCodes)) {
132 throw new \InvalidArgumentException(
'The given status code is not a valid HTTP status code.', 1436717278);
134 $this->statusCode = (int)$statusCode;
178 if (\TYPO3\CMS\Core\Utility\MathUtility::canBeInterpretedAsInteger($code) ===
false || !array_key_exists((
int)$code, $this->availableStatusCodes)) {
179 throw new \InvalidArgumentException(
'The given status code is not a valid HTTP status code', 1436717279);
181 $clonedObject = clone $this;
182 $clonedObject->statusCode = $code;
184 return $clonedObject;