com.mindbright.sshcommon
public interface SSHConsoleRemote
Modifier and Type | Method and Description |
---|---|
void |
changeStdOut(NonBlockingOutput out)
Changes the output stream where stdout is written to in the underlying
session channel.
|
void |
changeStdOut(java.io.OutputStream out)
Changes the output stream where stdout is written to in the underlying
session channel.
|
void |
close()
Closes the session channel.
|
void |
close(boolean waitforcloseconfirm)
Closes the session channel.
|
boolean |
command(java.lang.String command)
Runs single command on server.
|
NonBlockingOutput |
getNBStdIn()
Gets the stdin stream of the underlying session channel.
|
NonBlockingInput |
getNBStdOut()
Gets the stdout stream of the underlying session channel.
|
java.io.OutputStream |
getStdIn()
Gets the stdin stream of the underlying session channel.
|
java.io.InputStream |
getStdOut()
Gets the stdout stream of the underlying session channel.
|
boolean |
shell()
Starts an interactive shell on the server, note that no PTY is
allocated.
|
boolean command(java.lang.String command)
Note, this will create an extra pair of threads to handle the data.
command
- command line to runboolean shell()
void close()
void close(boolean waitforcloseconfirm)
void changeStdOut(java.io.OutputStream out) throws java.lang.IllegalArgumentException
Note that this method only works if the underlying session uses blocking streams and threads.
out
- new stdout streamIllegalArgumetExcpetion
- if the underlying session uses
non-blocking IOjava.lang.IllegalArgumentException
java.io.OutputStream getStdIn()
Note that this method returns null if the underlying stream uses non-blocking io
java.io.InputStream getStdOut()
Note that this method returns null if the underlying stream uses non-blocking io
void changeStdOut(NonBlockingOutput out) throws java.lang.IllegalArgumentException
Note that this method only works if the underlying session uses non-blocking io.
out
- new stdout streamIllegalArgumetExcpetion
- if the underlying session uses
blocking IOjava.lang.IllegalArgumentException
NonBlockingOutput getNBStdIn()
Note that this method returns null if the underlying stream uses blocking io
NonBlockingInput getNBStdOut()
Note that this method returns null if the underlying stream uses blocking io