Package org.springframework.data.domain
Interface Auditable<U,ID,T extends TemporalAccessor>
- Type Parameters:
U
- the auditing type. Typically some kind of user.ID
- the type of the audited type's identifier
- All Superinterfaces:
Persistable<ID>
Interface for auditable entities. Allows storing and retrieving creation and modification information. The changing
instance (typically some user) is to be defined by a generics definition.
- Author:
- Oliver Gierke
-
Method Summary
Modifier and TypeMethodDescriptionReturns the user who created this entity.Returns the creation date of the entity.Returns the user who modified the entity lastly.Returns the date of the last modification.void
setCreatedBy
(U createdBy) Sets the user who created this entity.void
setCreatedDate
(T creationDate) Sets the creation date of the entity.void
setLastModifiedBy
(U lastModifiedBy) Sets the user who modified the entity lastly.void
setLastModifiedDate
(T lastModifiedDate) Sets the date of the last modification.Methods inherited from interface org.springframework.data.domain.Persistable
getId, isNew
-
Method Details
-
getCreatedBy
Returns the user who created this entity.- Returns:
- the createdBy
-
setCreatedBy
Sets the user who created this entity.- Parameters:
createdBy
- the creating entity to set
-
getCreatedDate
Returns the creation date of the entity.- Returns:
- the createdDate
-
setCreatedDate
Sets the creation date of the entity.- Parameters:
creationDate
- the creation date to set
-
getLastModifiedBy
Returns the user who modified the entity lastly.- Returns:
- the lastModifiedBy
-
setLastModifiedBy
Sets the user who modified the entity lastly.- Parameters:
lastModifiedBy
- the last modifying entity to set
-
getLastModifiedDate
Returns the date of the last modification.- Returns:
- the lastModifiedDate
-
setLastModifiedDate
Sets the date of the last modification.- Parameters:
lastModifiedDate
- the date of the last modification to set
-