@Immutable @Loggable(value=1) public final class SSHServer extends Object implements Shell
| Constructor and Description |
|---|
SSHServer(Environment environ,
String user,
PrivateKey priv)
Public ctor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
badge(String name,
String value)
Add a new badge.
|
void |
close() |
int |
exec(String command,
InputStream stdin,
OutputStream stdout,
OutputStream stderr)
Exec one command.
|
public SSHServer(@NotNull(message="env can\'t be NULL") Environment environ, @NotNull(message="user name can\'t be NULL") String user, @NotNull(message="private key can\'t be NULL") PrivateKey priv)
environ - Environmentuser - Loginpriv - Private SSH key@Loggable(value=1, limit=1, unit=HOURS) public int exec(@NotNull(message="command can\'t be NULL") String command, @NotNull(message="stdin can\'t be NULL") InputStream stdin, @NotNull(message="stdout can\'t be NULL") OutputStream stdout, @NotNull(message="stderr can\'t be NULL") OutputStream stderr) throws IOException
exec in interface Shellcommand - Command to executestdin - Input streamstdout - Output streamstderr - Error output streamIOException - If failspublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableIOExceptionCopyright © 2009–2014 Rultor Inc.. All rights reserved.