public function listenOn(ZMQConnection $connection) : self
    {
        $connection->subscribe([$this->topic], function ($message) {
            return $this->onSuccess($message);
        });

        return $this;
    }
public function listenOn(ZMQConnection $connection) : self
    {
        $connection->subscribe([$this->topic], function ($message) {
            return $this->onSuccess($message);
        });

        return $this;
    }
public function listenOn ( ZMQConnection $ connection ) : self { $ connection -> subscribe ( [ $ this -> topic ] , function ( $ message ) { return $ this -> onSuccess ( $ message ) ; } ) ; return $ this ; }
Attach listener to connection.

@param  \Denpa\ZeroMQ\Connection  $connection

@return self
Attach listener to connection .