Interface FileCopier
-
- All Known Subinterfaces:
DestinationFileCopier,MultiFileCopier
- All Known Implementing Classes:
LocalFileCopier,ScriptPluginFileCopier
public interface FileCopierFileCopier copies a file or its contents to a local or remote node. The destination on the node is not predetermined, but some utility methods ofBaseFileCopiercan be used to generate a destination file path.- See Also:
MultiFileCopier
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.StringcopyFile(ExecutionContext context, java.io.File file, INodeEntry node, java.lang.String destination)Copy the contents of an input stream to the nodejava.lang.StringcopyFileStream(ExecutionContext context, java.io.InputStream input, INodeEntry node, java.lang.String destination)Copy the contents of an input stream to the nodejava.lang.StringcopyScriptContent(ExecutionContext context, java.lang.String script, INodeEntry node, java.lang.String destination)Copy the contents of an input stream to the node
-
-
-
Method Detail
-
copyFileStream
java.lang.String copyFileStream(ExecutionContext context, java.io.InputStream input, INodeEntry node, java.lang.String destination) throws FileCopierException
Copy the contents of an input stream to the node- Parameters:
context- contextinput- the input streamnode- nodedestination- the full path destination for the file- Returns:
- File path of the file after copying to the node
- Throws:
FileCopierException- if an error occurs
-
copyFile
java.lang.String copyFile(ExecutionContext context, java.io.File file, INodeEntry node, java.lang.String destination) throws FileCopierException
Copy the contents of an input stream to the node- Parameters:
context- contextfile- local file tocopynode- nodedestination- the full path destination for the file- Returns:
- File path of the file after copying to the node
- Throws:
FileCopierException- if an error occurs
-
copyScriptContent
java.lang.String copyScriptContent(ExecutionContext context, java.lang.String script, INodeEntry node, java.lang.String destination) throws FileCopierException
Copy the contents of an input stream to the node- Parameters:
context- contextscript- file content stringnode- nodedestination- the full path destination for the file- Returns:
- File path of the file after copying to the node
- Throws:
FileCopierException- if an error occurs
-
-