Package com.mku.salmonfs.drive.utils
Class AesFileCommander
java.lang.Object
com.mku.fs.drive.utils.FileCommander
com.mku.salmonfs.drive.utils.AesFileCommander
Facade class for encrypted file operations in batch.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.mku.fs.drive.utils.FileCommander
FileCommander.BatchCopyOptions, FileCommander.BatchDeleteOptions, FileCommander.BatchExportOptions, FileCommander.BatchImportOptions, FileCommander.RealFileTaskProgress, FileCommander.VirtualFileTaskProgress -
Constructor Summary
ConstructorsConstructorDescriptionAesFileCommander(int importBufferSize, int exportBufferSize, int threads) Instantiate a new file commander object. -
Method Summary
Modifier and TypeMethodDescriptionIFile[]exportFiles(IVirtualFile[] filesToExport, IFile exportDir, FileCommander.BatchExportOptions options) Export AesFile(s) from the drive.AesFile[]importFiles(IFile[] filesToImport, IVirtualFile importDir) Import IFile(s) into the drive.AesFile[]importFiles(IFile[] filesToImport, IVirtualFile importDir, FileCommander.BatchImportOptions options) Import IFile(s) into the drive.protected booleanHandle the errorMethods inherited from class com.mku.fs.drive.utils.FileCommander
areJobsStopped, cancel, close, copyFiles, deleteFiles, deleteFiles, exportFiles, getFileExporter, getFileImporter, getFileSearcher, isFileSearcherRunning, isFileSearcherStopped, isRunning, renameFile, search, search, stopFileSearch
-
Constructor Details
-
AesFileCommander
public AesFileCommander(int importBufferSize, int exportBufferSize, int threads) Instantiate a new file commander object.- Parameters:
importBufferSize- The buffer size to use for importing files.exportBufferSize- The buffer size to use for exporting files.threads- The threads to use for import and export
-
-
Method Details
-
importFiles
Import IFile(s) into the drive.- Overrides:
importFilesin classFileCommander- Parameters:
filesToImport- The files to import.importDir- The target directory.- Returns:
- The imported files.
- Throws:
Exception- Thrown if error occurs during import
-
importFiles
public AesFile[] importFiles(IFile[] filesToImport, IVirtualFile importDir, FileCommander.BatchImportOptions options) throws Exception Import IFile(s) into the drive.- Overrides:
importFilesin classFileCommander- Parameters:
filesToImport- The files to import.importDir- The target directory.options- The options- Returns:
- The imported files.
- Throws:
Exception- Thrown if error occurs during import
-
exportFiles
public IFile[] exportFiles(IVirtualFile[] filesToExport, IFile exportDir, FileCommander.BatchExportOptions options) throws Exception Export AesFile(s) from the drive.- Overrides:
exportFilesin classFileCommander- Parameters:
filesToExport- The files to export.exportDir- The export target directoryoptions- The options- Returns:
- The exported files
- Throws:
Exception- Thrown if error occurs during export
-
onError
Handle the error- Overrides:
onErrorin classFileCommander- Parameters:
ex- The exception- Returns:
- True if recoverable
- Throws:
Exception- If error occurs
-