CustomEventListener

since v12.20

The extension point CustomEventListener is a java interface that can be implemented to listen to specific custom events from other plugins and take any actions when the events occurs.

Please annotate your implementation of CustomEventListener with at least one of these runtime annotations:

to ensure, that your plugin will be loaded during runtime within the desired novomind iAGENT process.

Additionally annotate your plugin class with the runtime annotation CustomEventFilter and specify the names of the events in the annotation parameter that your plugin should listen to.

Example:

@MailAgentPlugin
@ChatAgentPlugin
@RoutingPlugin
@CorePlugin
@CustomEventFilter(names = { "myTestEvent", "myTestEvent2" } )
public class MyCustomEventListener implements CustomEventListener {

  @Inject
  Logger log;


  @Override
  public void processEvent(CustomEvent customEvent) {
    log.info("Processed {}", customEvent);
  }
}