PHP Class Swoole\Protocol\Base

Inheritance: implements Swoole\IFace\Protocol
Mostra file Open project: matyhtf/swoole_framework

Public Properties

Property Type Description
$default_host
$default_port
$log Swoole\IFace\Log
$server Swoole\Server

Protected Properties

Property Type Description
$clients array

Public Methods

Method Description
daemonize ( )
log ( $msg ) 打印Log信息
onClose ( $server, $client_id, $from_id )
onConnect ( $server, $client_id, $from_id )
onShutdown ( $server )
onStart ( $server )
run ( $array )
setLogger ( $log ) 设置Logger
task ( $task, $dstWorkerId, $callback = null )

Method Details

daemonize() public method

public daemonize ( )

log() public method

打印Log信息
public log ( $msg )
$msg

onClose() public method

public onClose ( $server, $client_id, $from_id )

onConnect() public method

public onConnect ( $server, $client_id, $from_id )

onShutdown() public method

public onShutdown ( $server )

onStart() public method

public onStart ( $server )

run() public method

public run ( $array )

setLogger() public method

设置Logger
public setLogger ( $log )
$log

task() public method

public task ( $task, $dstWorkerId, $callback = null )

Property Details

$clients protected_oe property

protected array $clients
return array

$default_host public_oe property

public $default_host

$default_port public_oe property

public $default_port

$log public_oe property

public Log,Swoole\IFace $log
return Swoole\IFace\Log

$server public_oe property

public Server,Swoole $server
return Swoole\Server