More inline docs
This commit is contained in:
@ -25,8 +25,10 @@ class WebSocketConnection implements WebSocketInterface
|
||||
const OP_PING = 0x9;
|
||||
const OP_PONG = 0xA;
|
||||
|
||||
/** @var string|null The name of the group that this connection has joined, or null */
|
||||
private ?string $groupName = null;
|
||||
|
||||
/** @var WebSocketCodec The frame encoder/decoder */
|
||||
private WebSocketCodec $codec;
|
||||
|
||||
private ?ConnectionGroup $group = null;
|
||||
@ -171,32 +173,50 @@ class WebSocketConnection implements WebSocketInterface
|
||||
return $this->request->getServerParams()['SERVER_ADDR'];
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function isReadable()
|
||||
{
|
||||
return $this->inStream->isReadable();
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function pause()
|
||||
{
|
||||
$this->inStream->pause();
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function resume()
|
||||
{
|
||||
$this->inStream->resume();
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function isWritable()
|
||||
{
|
||||
return $this->outStream->isWritable();
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function pipe(WritableStreamInterface $dest, array $options = array())
|
||||
{
|
||||
// TODO implement
|
||||
return $dest;
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function write($data)
|
||||
{
|
||||
return $this->send(self::OP_FRAME_TEXT, $data);
|
||||
@ -225,12 +245,18 @@ class WebSocketConnection implements WebSocketInterface
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function close()
|
||||
{
|
||||
$this->outStream->close();
|
||||
$this->inStream->close();
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function end($data = null)
|
||||
{
|
||||
|
||||
|
Reference in New Issue
Block a user