mini\Dispatcher\HttpDispatcher::parseRangeHeader() Method

private

Signature

private function parseRangeHeader(string $header, int $size): array|false|null

Parameters

Name Type Default Description
$header string required Documentation missing
$size int required Documentation missing

Returns

array|false|null

Documentation

Parse a Range: bytes=... header against a known total size.

Returns [start, end] (inclusive) on a satisfiable single range, false when unsatisfiable (caller must respond 416), null when unparseable or multi-range (caller falls back to 200 full body).

Source

src/Dispatcher/HttpDispatcher.php:470-505