EventEmitter::Base
Inherits Reference / Object
Instance methods
all(once = false, &block : Any -> )
Listen to all events and run the specified block. This is the
same as doing emitter.on(/.*/) { ... }
on(event, *, once = false, &block : Any -> )
Listen for a particular event and fire the block
every time that event is called. If once is true
the event will be removed after it is fired the
first time.
once(event, &block : Any -> )
Sugar for on(event, once: true). Will fire the
event once and then remove the listener.