on

abstract fun on(channel: String, listener: Function<Unit>)(source)

Listens to channel, when a new message arrives listener would be called with listener(event, args...).