PHPDaemon\SockJS\WebSocketConnectionProxy::sendFrame PHP Method

sendFrame() public method

Sends a frame.
public sendFrame ( string $data, integer $type = null, callback $cb = null ) : boolean
$data string Frame's data.
$type integer Frame's type. See the constants.
$cb callback Optional. Callback called when the frame is received by client.
return boolean Success.
    public function sendFrame($data, $type = null, $cb = null)
    {
        $this->realConn->sendFrame('a' . $this->toJson([$data]), $type, $cb);
        return true;
    }