mxmbsocket/lib/Ratchet/Command/CloseConnection.php
Chris Boden a6073a87eb Communication between versions
HyBi-10 and Hixie-76 can now talk to each other!
2011-11-01 15:19:03 -04:00

21 lines
424 B
PHP

<?php
namespace Ratchet\Command;
use Ratchet\SocketInterface;
/**
* Close the connection to the sockets passed in the constructor
*/
class CloseConnection implements CommandInterface {
/**
* @var SocketInterface
*/
protected $_socket;
public function __construct(SocketInterface $sockets) {
$this->_socket = $sockets;
}
function execute() {
$this->_socket->close();
}
}