PHP Class Protocol\FCGI\FrameParser

Show file Open project: lisachenko/protocol-fcgi Class Usage Examples

Protected Properties

Property Type Description
$classMapping array Mapping of constants to the classes

Public Methods

Method Description
hasFrame ( string $buffer ) : boolean Checks if the buffer contains a valid frame to parse
parseFrame ( string &$buffer ) : Record Parses a frame from the binary buffer

Method Details

hasFrame() public static method

Checks if the buffer contains a valid frame to parse
public static hasFrame ( string $buffer ) : boolean
$buffer string Binary buffer
return boolean

parseFrame() public static method

Parses a frame from the binary buffer
public static parseFrame ( string &$buffer ) : Record
$buffer string Binary buffer
return Record One of the corresponding FCGI record

Property Details

$classMapping protected static property

Mapping of constants to the classes
protected static array $classMapping
return array