PHP Class PHPDaemon\Servers\HTTP\Connection

Author: Vasily Zorin ([email protected])
Inheritance: extends PHPDaemon\Network\Connection, implements PHPDaemon\Request\IRequestUpstream
Afficher le fichier Open project: kakserpom/phpdaemon

Protected Properties

Свойство Type Description
$EOL
$currentHeader
$freedBeforeProcessing
$initialHighMark initial value of the maximum amout of bytes in buffer
$initialLowMark
$keepaliveTimer
$policyReqNotFound
$req
$timeout

Méthodes publiques

Méthode Description
badRequest ( $req ) : void Send Bad request
checkChunkedEncCap ( ) : boolean Check if Chunked encoding is supported here.
checkSendfileCap ( ) : boolean Check if Sendfile is supported here.
endRequest ( $req, $appStatus, $protoStatus ) : void End request
freeRequest ( $req ) : void Frees this request
getKeepaliveTimeout ( ) : integer
onFinish ( ) : void Called when connection is finished
requestOut ( object $req, string $s ) : boolean Handles the output from downstream requests.

Méthodes protégées

Méthode Description
httpProcessHeaders ( ) : boolean Process HTTP headers
httpReadFirstline ( ) : boolean | null Read first line of HTTP request
httpReadHeaders ( ) : boolean | null Read headers line-by-line
newRequest ( ) : stdClass Creates new Request object
onRead ( ) : void onRead

Method Details

badRequest() public méthode

Send Bad request
public badRequest ( $req ) : void
Résultat void

checkChunkedEncCap() public méthode

Check if Chunked encoding is supported here.
public checkChunkedEncCap ( ) : boolean
Résultat boolean Succes

checkSendfileCap() public méthode

Check if Sendfile is supported here.
public checkSendfileCap ( ) : boolean
Résultat boolean Succes

endRequest() public méthode

End request
public endRequest ( $req, $appStatus, $protoStatus ) : void
Résultat void

freeRequest() public méthode

Frees this request
public freeRequest ( $req ) : void
Résultat void

getKeepaliveTimeout() public méthode

public getKeepaliveTimeout ( ) : integer
Résultat integer

httpProcessHeaders() protected méthode

Process HTTP headers
protected httpProcessHeaders ( ) : boolean
Résultat boolean Success

httpReadFirstline() protected méthode

Read first line of HTTP request
protected httpReadFirstline ( ) : boolean | null
Résultat boolean | null Success

httpReadHeaders() protected méthode

Read headers line-by-line
protected httpReadHeaders ( ) : boolean | null
Résultat boolean | null Success

newRequest() protected méthode

Creates new Request object
protected newRequest ( ) : stdClass
Résultat stdClass

onFinish() public méthode

Called when connection is finished
public onFinish ( ) : void
Résultat void

onRead() protected méthode

onRead
protected onRead ( ) : void
Résultat void

requestOut() public méthode

Handles the output from downstream requests.
public requestOut ( object $req, string $s ) : boolean
$req object \PHPDaemon\Request\Generic.
$s string The output.
Résultat boolean Success

Property Details

$EOL protected_oe property

protected $EOL

$currentHeader protected_oe property

protected $currentHeader

$freedBeforeProcessing protected_oe property

protected $freedBeforeProcessing

$initialHighMark protected_oe property

initial value of the maximum amout of bytes in buffer
protected $initialHighMark

$initialLowMark protected_oe property

protected $initialLowMark

$keepaliveTimer protected_oe property

protected $keepaliveTimer

$policyReqNotFound protected_oe property

protected $policyReqNotFound

$req protected_oe property

protected $req

$timeout protected_oe property

protected $timeout