Emitter { public void on(String event, Callback callback) { logger.debug("Added callback for event {}", event); getEvents(event).add(callback); }  void on(String event, Callback callback); void off(String event, Callback callback); void off(String event); void trigger(String name, Event arg); boolean hasCallbacks(String name);  }
@Test public void testOn() { emitter.on("assertTrue", new Emitter.Callback() { @Override public void run(Event event) { assertTrue(true); } }); emitter.trigger("assertTrue", new AbstractEvent() { }); }