Interface Entity
- All Superinterfaces:
HasDateRange,HasId,HasName,HasOid,HasText
- All Known Subinterfaces:
EntityExtended,MutableEntity,MutableEntityExtended
- All Known Implementing Classes:
EntityExtendedImp,MutableEntityExtendedImp
The named interface defines a powerful abstraction for entities of a domain model. The features are:
texta human readable documentation of the instance. We recommend using markdown syntax for the text.
- oid
- An internal identifier owned by the domain. The internal identifier should never visible to external systems or users. The internal identifier should be set during construction through the new operator and never changed again.
- id
- An external identifier used to identify the entity inside and outside the domain. The external identifier should be set during construction. A good approach would be a factory method. The ownership fo the external identifier could be an external system.
- name
- A human readable name used to identify the entity when humans are involved. The uniqueness of the name is not required or guaranteed.
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.tangly.core.HasDateRange
HasDateRange.RangeFilter<T extends HasDateRange> -
Field Summary
Fields inherited from interface net.tangly.core.HasDateRange
FROM, TOFields inherited from interface net.tangly.core.HasOid
OID, UNDEFINED_OID -
Method Summary
Modifier and TypeMethodDescriptiondefault booleanvalidate()Checks if the entity is consistent based on the field values and business rules.
-
Method Details
-
validate
default boolean validate()Checks if the entity is consistent based on the field values and business rules.- Returns:
- true if the entity is consistent otherwise false
-