This is automatic generated document for things in Swow\Http\Http class

Class Http

Constants

public DEFAULT_PROTOCOL_VERSION = "1.1"

Methods

Static method packRequest

public static function packRequest ( string $method , \Stringable|string $uri , array $headers , \Stringable|string $body , string $protocolVersion ) : string

Build a request string.

The method adds no headers. An array header value writes one line per item.

Returns string the request

Static method packResponse

public static function packResponse ( int $statusCode , string $reasonPhrase , array $headers , \Stringable|string $body , string $protocolVersion ) : string

Build a response string.

An empty reason phrase uses the standard phrase. The status code is not checked.

Returns string the response


Copyright 2022 the Swow contributors

This site uses Just the Docs, a documentation theme for Jekyll.