public interface FileUploadPlugin
| Modifier and Type | Interface and Description |
|---|---|
static class |
FileUploadPlugin.ExternalState
Represents file states known to rundeck
|
static class |
FileUploadPlugin.InternalState
Represents file states known to the plugin
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
hasFile(java.lang.String ref)
Return true if the file can be retrieved via
retrieveFile(String, OutputStream) or retrieveFile(String) |
void |
initialize()
Initializes the plugin before use
|
boolean |
removeFile(java.lang.String reference)
Remove the file
|
java.io.InputStream |
retrieveFile(java.lang.String ref)
Retrieve the file by reference
|
void |
retrieveFile(java.lang.String ref,
java.io.OutputStream out)
Retrieve the file by reference
|
java.io.File |
retrieveLocalFile(java.lang.String ref)
Retrieve the file if it is available locally, otherwise return null
|
FileUploadPlugin.InternalState |
transitionState(java.lang.String reference,
FileUploadPlugin.ExternalState state)
Transition between states, allows plugin to determine behavior
|
java.lang.String |
uploadFile(java.io.InputStream content,
long length,
java.lang.String refid,
java.util.Map<java.lang.String,java.lang.String> config)
Upload a file for the given job and file input name, and return an identifier to reference the
uploaded file.
|
void initialize()
java.lang.String uploadFile(java.io.InputStream content,
long length,
java.lang.String refid,
java.util.Map<java.lang.String,java.lang.String> config)
throws java.io.IOException
content - contentlength - data lengthrefid - unique identifier for the filejava.io.IOExceptionvoid retrieveFile(java.lang.String ref,
java.io.OutputStream out)
throws java.io.IOException
ref - refout - outputstream to write it tojava.io.IOExceptionboolean hasFile(java.lang.String ref)
retrieveFile(String, OutputStream) or retrieveFile(String)ref - refjava.io.File retrieveLocalFile(java.lang.String ref)
throws java.io.IOException
ref - refjava.io.IOExceptionjava.io.InputStream retrieveFile(java.lang.String ref)
ref - refboolean removeFile(java.lang.String reference)
reference - FileUploadPlugin.InternalState transitionState(java.lang.String reference, FileUploadPlugin.ExternalState state)
reference - referencestate - the new external state of the file