Esempio n. 1
0
 /**
  * @override
  */
 public function handleDisconnect(IoConnectionInterface $conn)
 {
     if ($this->connectionCollection->contains($conn)) {
         $decor = $this->connectionCollection[$conn];
         $this->connectionCollection->detach($conn);
         $this->wsServer->handleDisconnect($decor);
     }
 }
Esempio n. 2
0
 /**
  * Handler triggered when an existing connection is being closed.
  *
  * @param SocketInterface $socket
  */
 public function handleDisconnect($socket)
 {
     try {
         $this->component->handleDisconnect($socket->conn);
     } catch (Error $ex) {
         $this->handleError($socket, $ex);
     } catch (Exception $ex) {
         $this->handleError($socket, $ex);
     }
     unset($socket->conn);
 }
Esempio n. 3
0
 /**
  * @override
  * @inheritDoc
  */
 public function handleDisconnect(IoConnectionInterface $conn)
 {
     if (!$this->isBlocked($conn->getHost())) {
         $this->component->handleDisconnect($conn);
     }
 }
Esempio n. 4
0
 /**
  * @override
  */
 public function handleDisconnect(IoConnectionInterface $conn)
 {
     if ($conn->httpHeadersReceived) {
         $this->httpServer->handleDisconnect($conn);
     }
 }
Esempio n. 5
0
 /**
  * @override
  * @inheritDoc
  */
 public function handleDisconnect(IoConnectionInterface $conn)
 {
     return $this->component->handleDisconnect($conn);
 }