Class AnnotationBasedEntityIdResolver<T>

java.lang.Object
org.axonframework.modelling.annotation.AnnotationBasedEntityIdResolver<T>
Type Parameters:
T - The type of the identifier to resolve.
All Implemented Interfaces:
EntityIdResolver<T>

public class AnnotationBasedEntityIdResolver<T> extends Object implements EntityIdResolver<T>
Implementation of a EntityIdResolver that inspects the payload of a Message for fields or methods annotated with TargetEntityId.

Multiple fields may be annotated, but only exactly one must resolve one distinct non-null value.

If no ids or multiple ids are found, an EntityIdResolutionException is thrown.

For performance reasons, the resolved identifier members are cached per payload type.

Since:
5.0.0
Author:
Mitchell Herrijgers
See Also:
  • Constructor Details

    • AnnotationBasedEntityIdResolver

      public AnnotationBasedEntityIdResolver()
  • Method Details