Interface AuditWorkUnit
-
- All Superinterfaces:
WorkUnitMergeDispatcher,WorkUnitMergeVisitor
- All Known Implementing Classes:
AbstractAuditWorkUnit,AddWorkUnit,CollectionChangeWorkUnit,DelWorkUnit,FakeBidirectionalRelationWorkUnit,ModWorkUnit,PersistentCollectionChangeWorkUnit
public interface AuditWorkUnit extends WorkUnitMergeVisitor, WorkUnitMergeDispatcher
TODO: refactor constructors into factory methods
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleancontainsWork()Map<String,Object>generateData(Object revisionData)ObjectgetEntityId()StringgetEntityName()RevisionTypegetRevisionType()booleanisPerformed()voidperform(Session session, Object revisionData)Perform this work unit in the given session.voidundo(Session session)-
Methods inherited from interface org.hibernate.envers.internal.synchronization.work.WorkUnitMergeDispatcher
dispatch
-
-
-
-
Method Detail
-
getEntityId
Object getEntityId()
-
getEntityName
String getEntityName()
-
containsWork
boolean containsWork()
-
isPerformed
boolean isPerformed()
-
perform
void perform(Session session, Object revisionData)
Perform this work unit in the given session.- Parameters:
session- Session, in which the work unit should be performed.revisionData- The current revision data, which will be used to populate the work unit with the correct revision relation.
-
undo
void undo(Session session)
-
generateData
Map<String,Object> generateData(Object revisionData)
- Parameters:
revisionData- The current revision data, which will be used to populate the work unit with the correct revision relation.- Returns:
- Generates data that should be saved when performing this work unit.
-
getRevisionType
RevisionType getRevisionType()
- Returns:
- Performed modification type.
-
-