Annotation Type DomainEvent


@Retention(RUNTIME) @Target(TYPE) @Documented public @interface DomainEvent
A domain event is a full-fledged part of the domain model, a representation of something that happened in the domain. It allows making the events that the domain experts want to track or be notified of explicit, or which are associated with state change in the other model objects.
See Also:
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    An identifier for the name of the event used to abstract away from the type system and to guard against refactorings.
    An identifier for the namespace of the event to group multiple events and let clients express their interest in all events of a specific namespace.
  • Element Details

    • namespace

      String namespace
      An identifier for the namespace of the event to group multiple events and let clients express their interest in all events of a specific namespace. If not set, external tooling may default this to the fully-qualified package name of the annotated type.
      Since:
      1.1
      Default:
      ""
    • name

      String name
      An identifier for the name of the event used to abstract away from the type system and to guard against refactorings. If not set, external tooling may default this to the simple class name of the annotated type.
      Since:
      1.1
      Default:
      ""