Class AggregateAlreadyExistsException

All Implemented Interfaces:
Serializable, org.fuin.objects4j.common.ExceptionShortIdentifable

public final class AggregateAlreadyExistsException extends AbstractVersionedAggregateException implements org.fuin.objects4j.common.ExceptionShortIdentifable
An aggregate already existed when trying to create it.
See Also:
  • Field Details

    • ELEMENT_NAME

      public static final String ELEMENT_NAME
      Unique name of the element to use for XML and JSON marshalling/unmarshalling.
      See Also:
    • SHORT_ID

      public static final String SHORT_ID
      Unique short identifier of this exception.
      See Also:
  • Constructor Details

    • AggregateAlreadyExistsException

      public AggregateAlreadyExistsException(@NotNull @NotNull EntityType type, @NotNull @NotNull AggregateRootId id, int version)
      Constructor with typed data.
      Parameters:
      type - Type of the aggregate.
      id - Unique identifier of the aggregate.
      version - Actual version.
    • AggregateAlreadyExistsException

      public AggregateAlreadyExistsException(@NotNull @NotNull String type, @NotNull @NotNull String id, int version)
      Constructor with string data.
      Parameters:
      type - Type of the aggregate.
      id - Unique identifier of the aggregate.
      version - Actual version.
  • Method Details

    • getShortId

      public String getShortId()
      Specified by:
      getShortId in interface org.fuin.objects4j.common.ExceptionShortIdentifable