@MappedSuperclass public abstract class TimestampedEntity<I extends Comparable<I> & Serializable> extends BaseEntity<I> implements Timestamped
ID
Constructor and Description |
---|
TimestampedEntity() |
Modifier and Type | Method and Description |
---|---|
Instant |
getCreated() |
Instant |
getLastModified() |
void |
onPrePersist() |
void |
onPreUpdate() |
void |
setCreated(Instant created) |
void |
setLastModified(Instant lastModified) |
void |
skipAdjustLastModified()
Invoke this method if you need to skip adjusting the "last modified" timestamp during any update event on this
instance.
|
public void onPrePersist()
public void onPreUpdate()
public void skipAdjustLastModified()
public void setCreated(Instant created)
setCreated
in interface Timestamped
public Instant getCreated()
getCreated
in interface Timestamped
public void setLastModified(Instant lastModified)
setLastModified
in interface Timestamped
public Instant getLastModified()
getLastModified
in interface Timestamped
Copyright © 2015–2017 OmniFaces. All rights reserved.