- Type Parameters:
ID- Entity ID type.
- All Known Subinterfaces:
AggregateRoot<ID>
- All Known Implementing Classes:
AbstractAggregateRoot,AbstractEntity
public interface Entity<ID extends EntityId>
An object that is not defined by its attributes, but rather by a thread of continuity and its identity.
-
Method Details
-
getType
EntityType getType()Returns the unique type.- Returns:
- Type of the entity that is unique in the context.
-
getId
ID getId()Returns the unique entity identifier.- Returns:
- Identifier.
-