com.dtolabs.rundeck.core.execution.impl.local
Class LocalFileCopier

java.lang.Object
  extended by com.dtolabs.rundeck.core.execution.impl.common.BaseFileCopier
      extended by com.dtolabs.rundeck.core.execution.impl.local.LocalFileCopier
All Implemented Interfaces:
DestinationFileCopier, FileCopier

public class LocalFileCopier
extends BaseFileCopier
implements FileCopier, DestinationFileCopier

LocalFileCopier is ...


Field Summary
static java.lang.String SERVICE_PROVIDER_TYPE
           
 
Fields inherited from class com.dtolabs.rundeck.core.execution.impl.common.BaseFileCopier
FILE_COPY_DESTINATION_DIR
 
Constructor Summary
LocalFileCopier(Framework framework)
           
 
Method Summary
 java.lang.String copyFile(ExecutionContext context, java.io.File scriptfile, INodeEntry node)
          Copy the contents of an input stream to the node
 java.lang.String copyFile(ExecutionContext context, java.io.File file, INodeEntry node, java.lang.String destination)
          Copy the contents of an input stream to the node
 java.lang.String copyFileStream(ExecutionContext context, java.io.InputStream input, INodeEntry node)
          Copy the contents of an input stream to the node
 java.lang.String copyFileStream(ExecutionContext context, java.io.InputStream input, INodeEntry node, java.lang.String destination)
          Copy the contents of an input stream to the node
 java.lang.String copyScriptContent(ExecutionContext context, java.lang.String script, INodeEntry node)
          Copy the contents of an input stream to the node
 java.lang.String copyScriptContent(ExecutionContext context, java.lang.String script, INodeEntry node, java.lang.String destination)
          Copy the contents of an input stream to the node
 
Methods inherited from class com.dtolabs.rundeck.core.execution.impl.common.BaseFileCopier
appendRemoteFileExtensionForNode, generateRemoteFilepathForNode, getRemoteDirForNode, writeLocalFile, writeScriptTempFile, writeTempFile
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SERVICE_PROVIDER_TYPE

public static final java.lang.String SERVICE_PROVIDER_TYPE
See Also:
Constant Field Values
Constructor Detail

LocalFileCopier

public LocalFileCopier(Framework framework)
Method Detail

copyScriptContent

public java.lang.String copyScriptContent(ExecutionContext context,
                                          java.lang.String script,
                                          INodeEntry node)
                                   throws FileCopierException
Description copied from interface: FileCopier
Copy the contents of an input stream to the node

Specified by:
copyScriptContent in interface FileCopier
Parameters:
context - context
script - file content string
Returns:
File path of the file after copying to the node
Throws:
FileCopierException - if an error occurs

copyFileStream

public java.lang.String copyFileStream(ExecutionContext context,
                                       java.io.InputStream input,
                                       INodeEntry node)
                                throws FileCopierException
Description copied from interface: FileCopier
Copy the contents of an input stream to the node

Specified by:
copyFileStream in interface FileCopier
Parameters:
context - context
input - the input stream
Returns:
File path of the file after copying to the node
Throws:
FileCopierException - if an error occurs

copyFile

public java.lang.String copyFile(ExecutionContext context,
                                 java.io.File scriptfile,
                                 INodeEntry node)
                          throws FileCopierException
Description copied from interface: FileCopier
Copy the contents of an input stream to the node

Specified by:
copyFile in interface FileCopier
Parameters:
context - context
scriptfile - local file tocopy
Returns:
File path of the file after copying to the node
Throws:
FileCopierException - if an error occurs

copyFileStream

public java.lang.String copyFileStream(ExecutionContext context,
                                       java.io.InputStream input,
                                       INodeEntry node,
                                       java.lang.String destination)
                                throws FileCopierException
Description copied from interface: DestinationFileCopier
Copy the contents of an input stream to the node

Specified by:
copyFileStream in interface DestinationFileCopier
Parameters:
context - context
input - the input stream
destination - 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

public java.lang.String copyFile(ExecutionContext context,
                                 java.io.File file,
                                 INodeEntry node,
                                 java.lang.String destination)
                          throws FileCopierException
Description copied from interface: DestinationFileCopier
Copy the contents of an input stream to the node

Specified by:
copyFile in interface DestinationFileCopier
Parameters:
context - context
file - local file tocopy
destination - 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

public java.lang.String copyScriptContent(ExecutionContext context,
                                          java.lang.String script,
                                          INodeEntry node,
                                          java.lang.String destination)
                                   throws FileCopierException
Description copied from interface: DestinationFileCopier
Copy the contents of an input stream to the node

Specified by:
copyScriptContent in interface DestinationFileCopier
Parameters:
context - context
script - file content string
destination - the full path destination for the file
Returns:
File path of the file after copying to the node
Throws:
FileCopierException - if an error occurs