Class StorageFactoryService.FileOperationHelper
java.lang.Object
org.apache.derby.impl.services.monitor.StorageFactoryService.FileOperationHelper
- Enclosing class:
StorageFactoryService
Helper class for common file operations on the service properties files.
Introduced to take care of error reporting for common file operations carried out in StorageFactoryService.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) booleandelete(StorageFile file, boolean mustSucceed) (package private) booleanexists(StorageFile file, boolean mustSucceed) private voidhandleSecPrivException(StorageFile file, boolean mustSucceed, SecurityException se) Handles security exceptions caused by missing privileges on the files being accessed.(package private) booleanrenameTo(StorageFile from, StorageFile to, boolean mustSucceed)
-
Field Details
-
operation
Name of the most recently performed operation.
-
-
Constructor Details
-
FileOperationHelper
private FileOperationHelper()
-
-
Method Details
-
exists
- Throws:
StandardException
-
delete
- Throws:
StandardException
-
renameTo
- Throws:
StandardException
-
handleSecPrivException
private void handleSecPrivException(StorageFile file, boolean mustSucceed, SecurityException se) throws StandardException Handles security exceptions caused by missing privileges on the files being accessed.- Parameters:
file- the file that was accessedmustSucceed- iftrueaStandardExceptionwill be thrown, iffalsea warning is written to the logse- the security exception raised- Throws:
StandardException- ifmustSucceedistrueNullPointerException- iffileorseis null
-