PHP Class PHPDaemon\Clients\WebSocket\Connection

Author: Kozin Denis ([email protected])
Author: Vasily Zorin ([email protected])
Inheritance: extends PHPDaemon\Network\ClientConnection
Afficher le fichier Open project: kakserpom/phpdaemon

Méthodes publiques

Свойство Type Description
$headers array
$type string

Protected Properties

Свойство Type Description
$isMasked string
$key string
$opCodes array
$pctLength integer
$state integer

Méthodes publiques

Méthode Description
onFinish ( ) : void
onRead ( ) : void Called when new data received
onReady ( ) : void Called when the connection is handshaked (at low-level), and peer is ready to recv. data
sendFrame ( string $payload, string $type = Pool::TYPE_TEXT, boolean $isMasked = true ) Send frame to WebSocket server

Méthodes protégées

Méthode Description
mask ( string $mask, string $str ) : string

Method Details

mask() protected static méthode

protected static mask ( string $mask, string $str ) : string
$mask string
$str string
Résultat string

onFinish() public méthode

public onFinish ( ) : void
Résultat void

onRead() public méthode

Called when new data received
public onRead ( ) : void
Résultat void

onReady() public méthode

Called when the connection is handshaked (at low-level), and peer is ready to recv. data
public onReady ( ) : void
Résultat void

sendFrame() public méthode

Send frame to WebSocket server
public sendFrame ( string $payload, string $type = Pool::TYPE_TEXT, boolean $isMasked = true )
$payload string
$type string
$isMasked boolean

Property Details

$headers public_oe property

public array $headers
Résultat array

$isMasked protected_oe property

protected string $isMasked
Résultat string

$key protected_oe property

protected string $key
Résultat string

$opCodes protected_oe property

protected array $opCodes
Résultat array

$pctLength protected_oe property

protected int $pctLength
Résultat integer

$state protected_oe property

protected int $state
Résultat integer

$type public_oe property

public string $type
Résultat string