Package fr.becpg.repo.audit.model
Class AuditScope
java.lang.Object
fr.becpg.repo.audit.model.AuditScope
- All Implemented Interfaces:
AutoCloseable
AuditScope class.
- Version:
- $Id: $Id
- Author:
- matthieu
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate AuditScopeListenerprivate DatabaseAuditScopeprivate AuditScopeprivate StopWatchScope -
Constructor Summary
ConstructorsConstructorDescriptionAuditScope(AuditPlugin plugin, DatabaseAuditService databaseAuditService, AuditScopeListener auditScopeListener, Class<?> callerClass, String scopeName) Constructor for AuditScope. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddCheckpoint(String checkpointName) addCheckpoint.voidclose()voidHand the completion of the entry over to the thread that actually runs the operation.voiddisable()disable.Getter for the fieldparentScope.voidputAttribute(String key, Object attribute) putAttribute.voidRecord the entry of an operation that may never complete, before running it.voidsetParentScope(AuditScope parentScope) Setter for the fieldparentScope.start()start.
-
Field Details
-
databaseScope
-
stopWatchScope
-
auditScopeListener
-
parentScope
-
-
Constructor Details
-
AuditScope
public AuditScope(AuditPlugin plugin, DatabaseAuditService databaseAuditService, AuditScopeListener auditScopeListener, Class<?> callerClass, String scopeName) Constructor for AuditScope.
- Parameters:
plugin- aAuditPluginobjectdatabaseAuditService- aDatabaseAuditServiceobjectauditScopeListener- aAuditScopeListenerobjectcallerClass- aClassobjectscopeName- aStringobject
-
-
Method Details
-
setParentScope
Setter for the field
parentScope.- Parameters:
parentScope- aAuditScopeobject
-
getParentScope
Getter for the field
parentScope.- Returns:
- a
AuditScopeobject
-
start
start.
- Returns:
- a
AuditScopeobject
-
close
public void close()- Specified by:
closein interfaceAutoCloseable
-
putAttribute
putAttribute.
-
addCheckpoint
addCheckpoint.
- Parameters:
checkpointName- aStringobject
-
recordStart
public void recordStart()Record the entry of an operation that may never complete, before running it.- See Also:
-
deferCompletion
public void deferCompletion()Hand the completion of the entry over to the thread that actually runs the operation.- See Also:
-
disable
public void disable()disable.
-