public class DefaultScpClient extends AbstractScpClient
AbstractScpClient.ScpOperationExecutor<T>
ScpClient.Option
Modifier and Type | Field and Description |
---|---|
private ClientSession |
clientSession |
protected ScpTransferEventListener |
listener |
protected ScpFileOpener |
opener |
COMMAND_WAIT_EVENTS
log
DEFAULT_EXEC_CHANNEL_EXIT_STATUS_TIMEOUT, DEFAULT_EXEC_CHANNEL_OPEN_TIMEOUT, SCP_EXEC_CHANNEL_EXIT_STATUS_TIMEOUT, SCP_EXEC_CHANNEL_OPEN_TIMEOUT
Constructor and Description |
---|
DefaultScpClient(ClientSession clientSession,
ScpFileOpener fileOpener,
ScpTransferEventListener eventListener) |
Modifier and Type | Method and Description |
---|---|
protected void |
download(java.lang.String remote,
java.nio.file.FileSystem fs,
java.nio.file.Path local,
java.util.Collection<ScpClient.Option> options) |
void |
download(java.lang.String remote,
java.io.OutputStream local) |
ClientSession |
getClientSession() |
protected <T> void |
runUpload(java.lang.String remote,
java.util.Collection<ScpClient.Option> options,
java.util.Collection<T> local,
AbstractScpClient.ScpOperationExecutor<T> executor) |
void |
upload(java.io.InputStream local,
java.lang.String remote,
long size,
java.util.Collection<java.nio.file.attribute.PosixFilePermission> perms,
ScpTimestamp time) |
addTargetIsDirectory, download, download, download, download, getSession, handleCommandExitStatus, handleCommandExitStatus, isOpen, openCommandChannel, upload, upload
getSimplifiedLogger
protected final ScpFileOpener opener
protected final ScpTransferEventListener listener
private final ClientSession clientSession
public DefaultScpClient(ClientSession clientSession, ScpFileOpener fileOpener, ScpTransferEventListener eventListener)
public ClientSession getClientSession()
ClientSession
usedpublic void download(java.lang.String remote, java.io.OutputStream local) throws java.io.IOException
java.io.IOException
protected void download(java.lang.String remote, java.nio.file.FileSystem fs, java.nio.file.Path local, java.util.Collection<ScpClient.Option> options) throws java.io.IOException
download
in class AbstractScpClient
java.io.IOException
public void upload(java.io.InputStream local, java.lang.String remote, long size, java.util.Collection<java.nio.file.attribute.PosixFilePermission> perms, ScpTimestamp time) throws java.io.IOException
java.io.IOException
protected <T> void runUpload(java.lang.String remote, java.util.Collection<ScpClient.Option> options, java.util.Collection<T> local, AbstractScpClient.ScpOperationExecutor<T> executor) throws java.io.IOException
runUpload
in class AbstractScpClient
java.io.IOException