Class RemoteCommandRunner
- java.lang.Object
-
- nl.esciencecenter.xenon.adaptors.schedulers.RemoteCommandRunner
-
public class RemoteCommandRunner extends java.lang.Object
Runs a command. Constructor waits for command to finish.
-
-
Constructor Summary
Constructors Constructor Description RemoteCommandRunner(Scheduler scheduler, java.lang.String stdin, java.lang.String executable, java.lang.String... arguments)
Run a command remotely, and save stdout, stderr, and exit code for later processing.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getExitCode()
java.lang.String
getStderr()
java.lang.String
getStdout()
boolean
success()
boolean
successIgnoreError()
java.lang.String
toString()
-
-
-
Constructor Detail
-
RemoteCommandRunner
public RemoteCommandRunner(Scheduler scheduler, java.lang.String stdin, java.lang.String executable, java.lang.String... arguments) throws XenonException
Run a command remotely, and save stdout, stderr, and exit code for later processing.- Parameters:
scheduler
- the scheduler to submit the job tostdin
- input to feed to the commandexecutable
- command to runarguments
- arguments for the command- Throws:
XenonException
- if the job could not be run successfully.
-
-
Method Detail
-
getStdout
public java.lang.String getStdout()
-
getStderr
public java.lang.String getStderr()
-
getExitCode
public int getExitCode()
-
success
public boolean success()
-
successIgnoreError
public boolean successIgnoreError()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-