public function onOpen(ConnectionInterface $connection)
    {
        // Resolve the session upon connection.
        $session_manager = new SessionManager($connection);
        $session_manager->resolveSession();

        // Create the client and add it.
        $client = new Client($connection, $session_manager);
        $this->clients->add($client);

        $this->command->info('Client connected');

        // Fire the event.
        Event::fire(new ClientConnected($this->server, $this->clients, $client));
    }
public function onOpen(ConnectionInterface $connection)
    {
        // Resolve the session upon connection.
        $session_manager = new SessionManager($connection);
        $session_manager->resolveSession();

        // Create the client and add it.
        $client = new Client($connection, $session_manager);
        $this->clients->add($client);

        $this->command->info('Client connected');

        // Fire the event.
        Event::fire(new ClientConnected($this->server, $this->clients, $client));
    }
public function onOpen ( ConnectionInterface $ connection ) { // Resolve the session upon connection. $ session_manager = new SessionManager ( $ connection ) ; $ session_manager -> resolveSession ( ) ; // Create the client and add it. $ client = new Client ( $ connection , $ session_manager ) ; $ this -> clients -> add ( $ client ) ; $ this -> command -> info ( 'Client connected' ) ; // Fire the event. Event :: fire ( new ClientConnected ( $ this -> server , $ this -> clients , $ client ) ) ; }
Client connected.
Client connected .