PHP Class Protocol\FCGI\Record\EndRequest

Inheritance: extends Protocol\FCGI\Record
Show file Open project: lisachenko/protocol-fcgi Class Usage Examples

Protected Properties

Property Type Description
$appStatus integer The appStatus component is an application-level status code. Each role documents its usage of appStatus.
$protocolStatus integer The possible protocolStatus values are: FCGI_REQUEST_COMPLETE: normal end of request. FCGI_CANT_MPX_CONN: rejecting a new request. This happens when a Web server sends concurrent requests over one connection to an application that is designed to process one request at a time per connection. FCGI_OVERLOADED: rejecting a new request. This happens when the application runs out of some resource, e.g. database connections. FCGI_UNKNOWN_ROLE: rejecting a new request. This happens when the Web server has specified a role that is unknown to the application.
$reserved1 string Reserved data, 3 bytes maximum

Public Methods

Method Description
__construct ( $protocolStatus = FCGI::REQUEST_COMPLETE, $appStatus, $reserved = '' )
getAppStatus ( ) : integer Returns app status
getProtocolStatus ( ) : integer Returns the protocol status

Protected Methods

Method Description
packPayload ( ) : string Implementation of packing the payload
unpackPayload ( Record $self, string $data ) : Record Method to unpack the payload for the record

Method Details

__construct() public method

public __construct ( $protocolStatus = FCGI::REQUEST_COMPLETE, $appStatus, $reserved = '' )

getAppStatus() public method

The appStatus component is an application-level status code. Each role documents its usage of appStatus.
public getAppStatus ( ) : integer
return integer

getProtocolStatus() public method

The possible protocolStatus values are: FCGI_REQUEST_COMPLETE: normal end of request. FCGI_CANT_MPX_CONN: rejecting a new request. This happens when a Web server sends concurrent requests over one connection to an application that is designed to process one request at a time per connection. FCGI_OVERLOADED: rejecting a new request. This happens when the application runs out of some resource, e.g. database connections. FCGI_UNKNOWN_ROLE: rejecting a new request. This happens when the Web server has specified a role that is unknown to the application.
public getProtocolStatus ( ) : integer
return integer

packPayload() protected method

Implementation of packing the payload
protected packPayload ( ) : string
return string

unpackPayload() protected static method

Method to unpack the payload for the record
protected static unpackPayload ( Record $self, string $data ) : Record
$self Protocol\FCGI\Record Instance of current frame
$data string Binary data
return Protocol\FCGI\Record

Property Details

$appStatus protected property

The appStatus component is an application-level status code. Each role documents its usage of appStatus.
protected int $appStatus
return integer

$protocolStatus protected property

The possible protocolStatus values are: FCGI_REQUEST_COMPLETE: normal end of request. FCGI_CANT_MPX_CONN: rejecting a new request. This happens when a Web server sends concurrent requests over one connection to an application that is designed to process one request at a time per connection. FCGI_OVERLOADED: rejecting a new request. This happens when the application runs out of some resource, e.g. database connections. FCGI_UNKNOWN_ROLE: rejecting a new request. This happens when the Web server has specified a role that is unknown to the application.
protected int $protocolStatus
return integer

$reserved1 protected property

Reserved data, 3 bytes maximum
protected string $reserved1
return string