Annotation Interface EventHandler


@Target(METHOD) @Retention(RUNTIME) @Documented public @interface EventHandler
Annotation for marking a method under EventSourced entities as handlers for events of such entity.

A method marked with this annotation needs to:

  • be public
  • have exactly one parameter
  • have a return type that matches the state type of the enclosing entity