protected function closeClient(
        Net_Notifier_WebSocket_Connection $client
    ) {
        $this->log(
            sprintf(
                'closing client %s ... ',
                $client->getIPAddress()
            ),
            Net_Notifier_Logger::VERBOSITY_CLIENT
        );

        if ($client->getState() < Net_Notifier_WebSocket_Connection::STATE_CLOSED) {
            $client->close();
        }

        $key = array_search($client, $this->clients);
        unset($this->clients[$key]);

        $key = array_search($client, $this->listenClients);
        if ($key !== false) {
            unset($this->listenClients[$key]);
        }

        $this->log(
            'done' . PHP_EOL,
            Net_Notifier_Logger::VERBOSITY_CLIENT,
            false
        );
    }