public interface ServerSessionCallback
Runnable object which will be executed
in a new thread after the acknowledgment has been sent back to the client.
If a method does not allow you to return a Runnable, then the
SSH protocol does not allow to send a status back to the client (more exactly, the client cannot
request an acknowledgment). In these cases, if you need to invoke
methods on the ServerSession or plan to execute long-running activity, then please do this from within a new Thread.
If you want to signal a fatal error, then please throw an IOException. Currently, this will
tear down the whole SSH connection.ServerSession| Modifier and Type | Method and Description |
|---|---|
Runnable |
requestEnv(ServerSession ss,
String name,
String value) |
Runnable |
requestExec(ServerSession ss,
String command) |
Runnable |
requestPtyReq(ServerSession ss,
PtySettings pty) |
Runnable |
requestShell(ServerSession ss) |
Runnable |
requestSubsystem(ServerSession ss,
String subsystem) |
void |
requestWindowChange(ServerSession ss,
int term_width_columns,
int term_height_rows,
int term_width_pixels,
int term_height_pixels)
When the window (terminal) size changes on the client side, it MAY send a message to the other side to inform it of the new dimensions.
|
Runnable requestPtyReq(ServerSession ss, PtySettings pty) throws IOException
IOExceptionRunnable requestEnv(ServerSession ss, String name, String value) throws IOException
IOExceptionRunnable requestShell(ServerSession ss) throws IOException
IOExceptionRunnable requestExec(ServerSession ss, String command) throws IOException
IOExceptionRunnable requestSubsystem(ServerSession ss, String subsystem) throws IOException
IOExceptionvoid requestWindowChange(ServerSession ss, int term_width_columns, int term_height_rows, int term_width_pixels, int term_height_pixels) throws IOException
ss - the corresponding sessionterm_width_columns - term_height_rows - term_width_pixels - IOExceptionCopyright © 2014. All Rights Reserved.