WebSocket Interface update
This commit is contained in:
parent
e412f574e7
commit
551888aa3c
@ -1,22 +1,20 @@
|
|||||||
<?php
|
<?php
|
||||||
namespace Ratchet\Application\WebSocket;
|
namespace Ratchet\Application\WebSocket;
|
||||||
use Ratchet\ObserverInterface;
|
use Ratchet\Application\ApplicationInterface;
|
||||||
use Ratchet\SocketInterface;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @todo App interfaces this (optionally) if is meant for WebSocket
|
* @todo App interfaces this (optionally) if is meant for WebSocket
|
||||||
* @todo WebSocket checks if instanceof AppInterface, if so uses getSubProtocol() when doing handshake
|
* @todo WebSocket checks if instanceof AppInterface, if so uses getSubProtocol() when doing handshake
|
||||||
|
* @todo Pick a better name for this...
|
||||||
*/
|
*/
|
||||||
interface AppInterface extends ObserverInterface {
|
interface WebSocketAppInterface extends ApplicationInterface {
|
||||||
|
/**
|
||||||
|
* @param string
|
||||||
|
*/
|
||||||
|
function setHeaders($headers);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return string
|
* @return string
|
||||||
*/
|
*/
|
||||||
function getSubProtocol();
|
function getSubProtocol();
|
||||||
|
|
||||||
/**
|
|
||||||
* @param Ratchet\SocketInterface
|
|
||||||
* @param string
|
|
||||||
* @return Ratchet\Resource\Command\CommandInterface|null
|
|
||||||
*/
|
|
||||||
function onOpen(SocketInterface $conn, $headers);
|
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user