PSR-7 — API
localzet\PSR7\AppendStream
Section titled “localzet\PSR7\AppendStream”function __construct(array $streams = [])
function __toString(): string
function addStream(StreamInterface $stream): void
function getContents(): string
function close(): void
function detach()
function tell(): int
function getSize(): ?int
function eof(): bool
function rewind(): void
function seek($offset, $whence = SEEK_SET): void
function read($length): string
function isReadable(): bool
function isWritable(): bool
function isSeekable(): bool
function write($string): int
function getMetadata($key = null)localzet\PSR7\BufferStream
Section titled “localzet\PSR7\BufferStream”function __construct(int $hwm = 16384)
function __toString(): string
function getContents(): string
function close(): void
function detach()
function getSize(): ?int
function isReadable(): bool
function isWritable(): bool
function isSeekable(): bool
function rewind(): void
function seek($offset, $whence = SEEK_SET): void
function eof(): bool
function tell(): int
function read($length): string
function write($string): int
function getMetadata($key = null)localzet\PSR7\CachingStream
Section titled “localzet\PSR7\CachingStream”function __construct(StreamInterface $stream, StreamInterface $target = null)
function getSize(): ?int
function rewind(): void
function seek($offset, $whence = SEEK_SET): void
function read($length): string
function write($string): int
function eof(): bool
function close(): voidlocalzet\PSR7\DroppingStream
Section titled “localzet\PSR7\DroppingStream”function __construct(StreamInterface $stream, int $maxLength)
function write($string): intlocalzet\PSR7\FnStream
Section titled “localzet\PSR7\FnStream”function __construct(array $methods)
function __get($name)
function __destruct()
function __wakeup()
static function decorate(StreamInterface $stream, array $methods): FnStream
function __toString(): string
function close(): void
function detach()
function getSize(): ?int
function tell(): int
function eof(): bool
function isSeekable(): bool
function rewind(): void
function seek($offset, $whence = SEEK_SET): void
function isWritable(): bool
function write($string): int
function isReadable(): bool
function read($length): string
function getContents(): string
function getMetadata($key = null)localzet\PSR7\InflateStream
Section titled “localzet\PSR7\InflateStream”function __construct(StreamInterface $stream)localzet\PSR7\LazyOpenStream
Section titled “localzet\PSR7\LazyOpenStream”function __construct($filename, $mode)localzet\PSR7\LimitStream
Section titled “localzet\PSR7\LimitStream”function __construct(StreamInterface $stream, $limit = -1, $offset = 0)
function eof(): bool
function getSize(): ?int
function seek($offset, $whence = SEEK_SET): void
function tell(): int
function setOffset($offset)
function setLimit($limit)
function read($length): stringlocalzet\PSR7\MessageTrait
Section titled “localzet\PSR7\MessageTrait”function getProtocolVersion(): string
function withProtocolVersion($version): MessageInterface
function getHeaders(): array
function hasHeader($header): bool
function getHeader($header): array
function getHeaderLine($header): string
function withHeader($header, $value): MessageInterface
function withHeaders(array $headers): MessageInterface
function withAddedHeader($header, $value): MessageInterface
function withoutHeader($header): MessageInterface
function getBody(): StreamInterface|Stream|PumpStream
function withBody(StreamInterface $body): MessageInterface
function setHeaders(array $headers): Response|Requestlocalzet\PSR7\MultipartStream
Section titled “localzet\PSR7\MultipartStream”function __construct(array $elements = [], $boundary = null)
function getBoundary()
function isWritable(): falselocalzet\PSR7\NoSeekStream
Section titled “localzet\PSR7\NoSeekStream”function seek($offset, $whence = SEEK_SET): void
function isSeekable(): falselocalzet\PSR7\PumpStream
Section titled “localzet\PSR7\PumpStream”function __construct(callable $source, array $options = [])
function __toString(): string
function close(): void
function detach()
function getSize(): ?int
function tell(): int
function eof(): bool
function isSeekable(): bool
function rewind(): void
function seek($offset, $whence = SEEK_SET): void
function isWritable(): bool
function write($string): int
function isReadable(): bool
function read($length): string
function getContents(): string
function getMetadata($key = null)localzet\PSR7\Request
Section titled “localzet\PSR7\Request”function __construct(string $method, UriInterface|string $uri, array $headers = [], StreamInterface|string $body = null, string $version = '1.1')
function getRequestTarget(): string
function withRequestTarget($requestTarget): Request|static
function getMethod(): string
function withMethod($method): Request|static
function getUri(): UriInterface
function withUri(UriInterface $uri, $preserveHost = false): Request|staticlocalzet\PSR7\Response
Section titled “localzet\PSR7\Response”function __construct(int $status = 200, array $headers = [], StreamInterface|string $body = null, string $version = '1.1', string $reason = null)
function getStatusCode(): int
function getReasonPhrase(): string
function withStatus($code, $reasonPhrase = ''): Response|static
function __toString()localzet\PSR7\Rfc7230
Section titled “localzet\PSR7\Rfc7230”const HEADER_REGEX
const HEADER_FOLD_REGEXlocalzet\PSR7\ServerRequest
Section titled “localzet\PSR7\ServerRequest”function __construct(string $http_buffer)
static function normalizeFiles(array $files): array
static function fromGlobals(): ServerRequest|ServerRequestInterface
static function getUriFromGlobals(): UriInterface
function getServerParams(): array
function getUploadedFiles(): array
function withUploadedFiles(array $uploadedFiles): ServerRequest|ServerRequestInterface|static
function getCookieParams(): array
function withCookieParams(array $cookies): ServerRequest|ServerRequestInterface|static
function getQueryParams(): array
function withQueryParams(array $query): ServerRequest|ServerRequestInterface|static
function getParsedBody(): object|array|null
function withParsedBody($data): ServerRequest|ServerRequestInterface|static
function getAttributes(): array
function getAttribute($name, $default = null)
function withAttribute($name, $value): ServerRequest|ServerRequestInterface|static
function withoutAttribute($name): ServerRequest|ServerRequestInterface|staticlocalzet\PSR7\Stream
Section titled “localzet\PSR7\Stream”function __construct($stream, array $options = [])
function __destruct()
function __toString(): string
function getContents(): string
function close(): void
function detach()
function getSize(): ?int
function isReadable(): bool
function isWritable(): bool
function isSeekable(): bool
function eof(): bool
function tell(): int
function rewind(): void
function seek($offset, $whence = SEEK_SET): void
function read($length): string
function write($string): int
function getMetadata($key = null)localzet\PSR7\StreamDecoratorTrait
Section titled “localzet\PSR7\StreamDecoratorTrait”function __construct(StreamInterface $stream)
function __get(string $name)
function __toString(): string
function getContents(): string
function __call(string $method, array $args)
function close(): void
function getMetadata($key = null)
function detach()
function getSize(): ?int
function eof(): bool
function tell(): int
function isReadable(): bool
function isWritable(): bool
function isSeekable(): bool
function rewind(): void
function seek($offset, $whence = SEEK_SET): void
function read($length): string
function write($string): intlocalzet\PSR7\StreamWrapper
Section titled “localzet\PSR7\StreamWrapper”static function getResource(StreamInterface $stream)
static function createStreamContext(StreamInterface $stream)
static function register(): void
function stream_open($path, $mode, $options, &$opened_path): bool
function stream_read($count): string
function stream_write($data): int
function stream_tell(): int
function stream_eof(): bool
function stream_seek($offset, $whence): true
function stream_cast($cast_as)
function stream_stat(): array
function url_stat($path, $flags): arraylocalzet\PSR7\UploadedFile
Section titled “localzet\PSR7\UploadedFile”function __construct(StreamInterface|string $streamOrFile, int $size, int $errorStatus, string $clientFilename = null, string $clientMediaType = null)
function isMoved(): bool
function getStream(): StreamInterface
function moveTo(string $targetPath): void
function getSize(): ?int
function getError(): int
function getClientFilename(): ?string
function getClientMediaType(): ?stringlocalzet\PSR7\Uri
Section titled “localzet\PSR7\Uri”function __construct(string $uri = '')
function __toString(): string
static function composeComponents(string $scheme, string $authority, string $path, string $query, string $fragment): string
static function isDefaultPort(UriInterface $uri): bool
static function isAbsolute(UriInterface $uri): bool
static function isNetworkPathReference(UriInterface $uri): bool
static function isAbsolutePathReference(UriInterface $uri): bool
static function isRelativePathReference(UriInterface $uri): bool
static function isSameDocumentReference(UriInterface $uri, UriInterface $base = null): bool
static function removeDotSegments(string $path): string
static function resolve(UriInterface $base, UriInterface|string $rel): UriInterface
static function withoutQueryValue(UriInterface $uri, string $key): UriInterface
static function withQueryValue(UriInterface $uri, string $key, ?string $value): UriInterface
static function fromParts(array $parts): UriInterface
function getScheme(): string
function getAuthority(): string
function getUserInfo(): string
function getHost(): string
function getPort(): ?int
function getPath(): string
function getQuery(): string
function getFragment(): string
function withScheme($scheme): Uri|static
function withUserInfo($user, $password = null): Uri|static
function withHost($host): Uri|static
function withPort($port): Uri|static
function withPath($path): Uri|static
function withQuery($query): Uri|static
function withFragment($fragment): Uri|static
const HTTP_DEFAULT_HOSTlocalzet\PSR7\UriNormalizer
Section titled “localzet\PSR7\UriNormalizer”static function normalize(UriInterface $uri, int $flags = self::PRESERVING_NORMALIZATIONS): UriInterface
static function isEquivalent(UriInterface $uri1, UriInterface $uri2, int $normalizations = self::PRESERVING_NORMALIZATIONS): bool
const PRESERVING_NORMALIZATIONS
const CAPITALIZE_PERCENT_ENCODING
const DECODE_UNRESERVED_CHARACTERS
const CONVERT_EMPTY_PATH
const REMOVE_DEFAULT_HOST
const REMOVE_DEFAULT_PORT
const REMOVE_DOT_SEGMENTS
const REMOVE_DUPLICATE_SLASHES
const SORT_QUERY_PARAMETERSlocalzet\PSR7\UriResolver
Section titled “localzet\PSR7\UriResolver”static function removeDotSegments(string $path): string
static function resolve(UriInterface $base, UriInterface $rel): UriInterface|Uri
static function relativize(UriInterface $base, UriInterface $target): UriInterface