$onClose $onClose : callback Emitted when the other end of the socket sends a FIN packet. Type callback
$protocol $protocol : \Workerman\Protocols\ProtocolInterface Application layer protocol. The format is like this Workerman\Protocols\Http. Type \Workerman\Protocols\ProtocolInterface
send() send(string $send_buffer, boolean $raw = false) : void|boolean Sends data on the connection. Parameters string $send_buffer boolean $raw Returns void|boolean
close() close(mixed $data = null, boolean $raw = false) : boolean Close connection. Parameters mixed $data boolean $raw Returns boolean
__construct() __construct(resource $socket, string $remote_address) Construct. Parameters resource $socket string $remote_address