Class AbstractAuditableEntity
java.lang.Object
de.xima.fc.certificate.ms.impl.dao.entities.AbstractAuditableEntity
- All Implemented Interfaces:
IAuditableEntity
- Direct Known Subclasses:
CertificateEntity, KeyPairEntity, KeyStoreEntity
@MappedSuperclass
public abstract class AbstractAuditableEntity
extends Object
implements IAuditableEntity
Abstract base class for auditable entities.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the creation date of the entity.Gets the last modification date of the entity.protected voidonCreate()Pre persist hook to set the creation date.protected voidonUpdate()Pre update hook to set the last modification date.voidsetCreatedAt(Instant createdAt) voidsetUpdatedAt(Instant updatedAt)
-
Constructor Details
-
AbstractAuditableEntity
public AbstractAuditableEntity()
-
-
Method Details
-
onCreate
protected void onCreate()Pre persist hook to set the creation date. -
onUpdate
protected void onUpdate()Pre update hook to set the last modification date. -
getCreatedAt
Description copied from interface:IAuditableEntityGets the creation date of the entity.- Specified by:
getCreatedAtin interfaceIAuditableEntity- Returns:
- the creation date
-
getUpdatedAt
Description copied from interface:IAuditableEntityGets the last modification date of the entity.- Specified by:
getUpdatedAtin interfaceIAuditableEntity- Returns:
- the last modification date
-
setCreatedAt
-
setUpdatedAt
-