Package lumis.portal.serialization
Class FileCopyTransactionObserver
- java.lang.Object
-
- lumis.portal.serialization.FileCopyTransactionObserver
-
- All Implemented Interfaces:
ITransactionObserver
public class FileCopyTransactionObserver extends java.lang.Object implements ITransactionObserver
Implementation ofITransactionObserver
that performs a file copy operation that can be rolled back. The file copy operation will be executed only at the first transaction´s commit and/or rollback.- Since:
- 4.0.8
- Version:
- $Revision$ $Date$
-
-
Constructor Summary
Constructors Constructor Description FileCopyTransactionObserver(java.lang.String sourceFilePath, IDirectory sourceDirectory, java.lang.String destinationFilePath, IPortalBaseFolder destinationRelativePathType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
afterCommit()
Called by the observed transaction just after the commit operation.void
afterRollback()
Called by the observed transaction just after the rollback operation.boolean
beforeCommit()
Called by the observed transaction just before the commit operation.void
beforeRollback()
Called by the observed transaction just before the rollback operation.
-
-
-
Constructor Detail
-
FileCopyTransactionObserver
public FileCopyTransactionObserver(java.lang.String sourceFilePath, IDirectory sourceDirectory, java.lang.String destinationFilePath, IPortalBaseFolder destinationRelativePathType)
-
-
Method Detail
-
beforeCommit
public boolean beforeCommit() throws PortalException
Description copied from interface:ITransactionObserver
Called by the observed transaction just before the commit operation.- Specified by:
beforeCommit
in interfaceITransactionObserver
- Returns:
- true to indicate success; false to indicate fail, and cause the transaction to cancel commiting.
- Throws:
PortalException
-
afterCommit
public void afterCommit() throws PortalException
Description copied from interface:ITransactionObserver
Called by the observed transaction just after the commit operation.- Specified by:
afterCommit
in interfaceITransactionObserver
- Throws:
PortalException
-
beforeRollback
public void beforeRollback() throws PortalException
Description copied from interface:ITransactionObserver
Called by the observed transaction just before the rollback operation.- Specified by:
beforeRollback
in interfaceITransactionObserver
- Throws:
PortalException
-
afterRollback
public void afterRollback() throws PortalException
Description copied from interface:ITransactionObserver
Called by the observed transaction just after the rollback operation.- Specified by:
afterRollback
in interfaceITransactionObserver
- Throws:
PortalException
-
-