org.jenkinsci.main.modules.sshd
Class AsynchronousCommand
java.lang.Object
org.jenkinsci.main.modules.sshd.AsynchronousCommand
- All Implemented Interfaces:
- org.apache.sshd.server.Command, org.apache.sshd.server.SessionAware
public abstract class AsynchronousCommand
- extends Object
- implements org.apache.sshd.server.Command, org.apache.sshd.server.SessionAware
Partial Command implementation that uses a thread to run a command.
- Author:
- Kohsuke Kawaguchi
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AsynchronousCommand
protected AsynchronousCommand(SshCommandFactory.CommandLine cmdLine)
setInputStream
public void setInputStream(InputStream in)
- Specified by:
setInputStream in interface org.apache.sshd.server.Command
setOutputStream
public void setOutputStream(OutputStream out)
- Specified by:
setOutputStream in interface org.apache.sshd.server.Command
setErrorStream
public void setErrorStream(OutputStream err)
- Specified by:
setErrorStream in interface org.apache.sshd.server.Command
getInputStream
public InputStream getInputStream()
getOutputStream
public OutputStream getOutputStream()
getErrorStream
public OutputStream getErrorStream()
getCmdLine
public SshCommandFactory.CommandLine getCmdLine()
setExitCallback
public void setExitCallback(org.apache.sshd.server.ExitCallback callback)
- Specified by:
setExitCallback in interface org.apache.sshd.server.Command
getSession
public org.apache.sshd.server.session.ServerSession getSession()
setSession
public void setSession(org.apache.sshd.server.session.ServerSession session)
- Specified by:
setSession in interface org.apache.sshd.server.SessionAware
getCurrentUser
protected hudson.model.User getCurrentUser()
getEnvironment
public org.apache.sshd.server.Environment getEnvironment()
start
public void start(org.apache.sshd.server.Environment env)
throws IOException
- Specified by:
start in interface org.apache.sshd.server.Command
- Throws:
IOException
run
protected abstract int run()
throws Exception
- Throws:
Exception
destroy
public void destroy()
- Specified by:
destroy in interface org.apache.sshd.server.Command
Copyright © 2004-2012. All Rights Reserved.