
Server accepts single Observable object (was Chain of Responsibility) WebSocket is decorator of application implementing Observable Observable interface returns Command pattern object Interfaced all the things Code is a mess Unit tests are broken
13 lines
295 B
PHP
13 lines
295 B
PHP
<?php
|
|
namespace Ratchet;
|
|
|
|
class SocketCollection extends \SplQueue {
|
|
public function __construct() {
|
|
// parent::__construct();
|
|
$this->setIteratorMode(static::IT_MODE_DELETE);
|
|
}
|
|
|
|
public function enqueue(SocketInterface $value) {
|
|
parent::enqueue($value);
|
|
}
|
|
} |