public class SftpSubsystem extends java.lang.Object implements Command, SessionAware, FileSystemAware, SftpSession, ChannelDataReceiver, ChannelSessionAware
| Modifier and Type | Class and Description |
|---|---|
static class |
SftpSubsystem.Factory |
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
ALL_SFTP_IMPL |
static int |
HIGHER_SFTP_IMPL |
protected static org.slf4j.Logger |
LOG |
static int |
LOWER_SFTP_IMPL |
static java.lang.String |
MAX_OPEN_HANDLES_PER_SESSION
Properties key for the maximum of available open handles per session.
|
static int |
MAX_PACKET_LENGTH |
| Constructor and Description |
|---|
SftpSubsystem() |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
Handle |
createDirectoryHandle(SshFile file) |
Handle |
createFileHandle(SshFile file,
int flags) |
int |
data(ChannelSession channel,
byte[] buf,
int start,
int len) |
void |
destroy() |
protected Reply |
doProcess(Request request) |
Handle |
getHandle(java.lang.String id) |
Session |
getSession() |
int |
getVersion() |
void |
process(Buffer buffer) |
protected boolean |
receive(Buffer incoming) |
protected void |
send(Buffer buffer) |
protected SshFxpNameReply |
sendName(int id,
java.util.Iterator<SshFile> files) |
void |
setChannelSession(ChannelSession channel) |
void |
setErrorStream(java.io.OutputStream err) |
void |
setExitCallback(ExitCallback callback) |
void |
setFileSystemView(FileSystemView view) |
void |
setInputStream(java.io.InputStream in) |
void |
setOutputStream(java.io.OutputStream out) |
void |
setSession(ServerSession session) |
void |
setSftpLet(Sftplet sftpLet) |
void |
start(Environment env) |
protected static final org.slf4j.Logger LOG
public static final int LOWER_SFTP_IMPL
public static final int HIGHER_SFTP_IMPL
public static final java.lang.String ALL_SFTP_IMPL
public static final int MAX_PACKET_LENGTH
public static final java.lang.String MAX_OPEN_HANDLES_PER_SESSION
public void setSftpLet(Sftplet sftpLet)
public int getVersion()
getVersion in interface SftpSessionpublic Session getSession()
getSession in interface SftpSessionpublic Handle getHandle(java.lang.String id)
getHandle in interface SftpSessionpublic Handle createFileHandle(SshFile file, int flags)
createFileHandle in interface SftpSessionpublic Handle createDirectoryHandle(SshFile file)
createDirectoryHandle in interface SftpSessionpublic void setChannelSession(ChannelSession channel)
setChannelSession in interface ChannelSessionAwarepublic void setSession(ServerSession session)
setSession in interface SessionAwarepublic void setFileSystemView(FileSystemView view)
setFileSystemView in interface FileSystemAwarepublic void setExitCallback(ExitCallback callback)
setExitCallback in interface Commandpublic void setInputStream(java.io.InputStream in)
setInputStream in interface Commandpublic void setOutputStream(java.io.OutputStream out)
setOutputStream in interface Commandpublic void setErrorStream(java.io.OutputStream err)
setErrorStream in interface Commandpublic void start(Environment env) throws java.io.IOException
public int data(ChannelSession channel, byte[] buf, int start, int len) throws java.io.IOException
data in interface ChannelDataReceiverjava.io.IOExceptionprotected boolean receive(Buffer incoming) throws java.io.IOException
java.io.IOExceptionpublic void close()
throws java.io.IOException
close in interface java.io.Closeableclose in interface java.lang.AutoCloseableclose in interface ChannelDataReceiverjava.io.IOExceptionpublic void process(Buffer buffer) throws java.io.IOException
java.io.IOExceptionprotected Reply doProcess(Request request) throws java.io.IOException
java.io.IOExceptionprotected SshFxpNameReply sendName(int id, java.util.Iterator<SshFile> files) throws java.io.IOException
java.io.IOExceptionprotected void send(Buffer buffer) throws java.io.IOException
java.io.IOExceptionCopyright © 2008-2014 The Apache Software Foundation. All Rights Reserved.