PHP Class Phly\Http\AbstractSerializer

Datei anzeigen Open project: phly/http

Protected Methods

Method Description
filterHeader ( string $header ) : string Filter a header name to wordcase
getLine ( Psr\Http\Message\StreamInterface $stream ) : string Retrieve a single line from the stream.
serializeHeaders ( array $headers ) : string Serialize headers to string values.
splitStream ( Psr\Http\Message\StreamInterface $stream ) : array Split the stream into headers and body content.

Method Details

filterHeader() protected static method

Filter a header name to wordcase
protected static filterHeader ( string $header ) : string
$header string
return string

getLine() protected static method

Retrieves a line from the stream; a line is defined as a sequence of characters ending in a CRLF sequence.
protected static getLine ( Psr\Http\Message\StreamInterface $stream ) : string
$stream Psr\Http\Message\StreamInterface
return string

serializeHeaders() protected static method

Serialize headers to string values.
protected static serializeHeaders ( array $headers ) : string
$headers array
return string

splitStream() protected static method

Returns an array containing two elements - The first is an array of headers - The second is a StreamInterface containing the body content
protected static splitStream ( Psr\Http\Message\StreamInterface $stream ) : array
$stream Psr\Http\Message\StreamInterface
return array