Class IOHandlerImpl
- java.lang.Object
-
- science.aist.gtf.template.impl.handler.IOHandlerImpl
-
- All Implemented Interfaces:
IOHandler<GeneratorTemplate>
public class IOHandlerImpl extends Object implements IOHandler<GeneratorTemplate>
Implementation of
IOHandler- Since:
- 1.0
- Author:
- Andreas Schuler
-
-
Constructor Summary
Constructors Constructor Description IOHandlerImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidhandleDirectoryCopy(GeneratorTemplate context, String src, String target, boolean overwrite, String... exclude)Copies the full directly treevoidhandleDirectoryCreate(GeneratorTemplate context, String directoryPath)Creates a directoryvoidhandleFileCopy(GeneratorTemplate context, String sourceFile, String targetFile)Copies a file from source to targetvoidunzipFile(GeneratorTemplate context, String sourceFile, String targetDirectory)Unzips a file
-
-
-
Method Detail
-
handleDirectoryCopy
public void handleDirectoryCopy(GeneratorTemplate context, String src, String target, boolean overwrite, String... exclude)
Description copied from interface:IOHandlerCopies the full directly tree- Specified by:
handleDirectoryCopyin interfaceIOHandler<GeneratorTemplate>- Parameters:
context- the context in which this happenssrc- the source directorytarget- the target directoryoverwrite- flag whether there target directory should be overwritten if it already existsexclude- the files to exclude
-
handleFileCopy
public void handleFileCopy(GeneratorTemplate context, String sourceFile, String targetFile)
Description copied from interface:IOHandlerCopies a file from source to target- Specified by:
handleFileCopyin interfaceIOHandler<GeneratorTemplate>- Parameters:
context- the context in which this happenssourceFile- the source file pathtargetFile- the target file path
-
handleDirectoryCreate
public void handleDirectoryCreate(GeneratorTemplate context, String directoryPath)
Description copied from interface:IOHandlerCreates a directory- Specified by:
handleDirectoryCreatein interfaceIOHandler<GeneratorTemplate>- Parameters:
context- the context in which this should happendirectoryPath- the directory that should be created
-
unzipFile
public void unzipFile(GeneratorTemplate context, String sourceFile, String targetDirectory)
Description copied from interface:IOHandlerUnzips a file- Specified by:
unzipFilein interfaceIOHandler<GeneratorTemplate>- Parameters:
context- the context in which this should happensourceFile- the source file that should be unzippedtargetDirectory- the target directory where to unzip the file to
-
-