once

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

Adds a one time listener function for the event. This listener is invoked only the next time a message is sent to channel, after which it is removed.