public function onSubscribe(ConnectionInterface $conn, $topic)
    {
        $this->console->info("onSubscribe: {$conn->WAMP->sessionId} topic: $topic {$topic->count()}");

        if (!array_key_exists($topic->getId(), $this->subscribedTopics)) {
            $this->subscribedTopics[$topic->getId()] = $topic;
            $this->console->info("subscribed to topic $topic");
        }
    }
public function onSubscribe(ConnectionInterface $conn, $topic)
    {
        $this->console->info("onSubscribe: {$conn->WAMP->sessionId} topic: $topic {$topic->count()}");

        if (!array_key_exists($topic->getId(), $this->subscribedTopics)) {
            $this->subscribedTopics[$topic->getId()] = $topic;
            $this->console->info("subscribed to topic $topic");
        }
    }
public function onSubscribe ( ConnectionInterface $ conn , $ topic ) { $ this -> console -> info ( "onSubscribe: {$conn->WAMP->sessionId} topic: $topic {$topic->count()}" ) ; if ( ! array_key_exists ( $ topic -> getId ( ) , $ this -> subscribedTopics ) ) { $ this -> subscribedTopics [ $ topic -> getId ( ) ] = $ topic ; $ this -> console -> info ( "subscribed to topic $topic" ) ; } }
A request to subscribe to a topic has been made.

@param \Ratchet\ConnectionInterface $conn
@param string|Topic                 $topic The topic to subscribe to
A request to subscribe to a topic has been made .