|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.stericson.RootTools.execution.Command
public abstract class Command
Constructor Summary | |
---|---|
Command(int id,
boolean handlerEnabled,
boolean javaCommand,
android.content.Context context,
java.lang.String... command)
Constructor for executing Java commands rather than binaries |
|
Command(int id,
boolean javaCommand,
android.content.Context context,
java.lang.String... command)
Constructor for executing Java commands rather than binaries |
|
Command(int id,
boolean handlerEnabled,
java.lang.String... command)
Constructor for executing a normal shell command |
|
Command(int id,
int timeout,
boolean javaCommand,
android.content.Context context,
java.lang.String... command)
Constructor for executing Java commands rather than binaries |
|
Command(int id,
int timeout,
java.lang.String... command)
Constructor for executing a normal shell command |
|
Command(int id,
java.lang.String... command)
Constructor for executing a normal shell command |
Method Summary | |
---|---|
abstract void |
commandCompleted(int id,
int exitCode)
|
protected void |
commandFinished()
|
abstract void |
commandOutput(int id,
java.lang.String line)
|
abstract void |
commandTerminated(int id,
java.lang.String reason)
|
protected void |
finishCommand()
|
java.lang.String |
getCommand()
|
int |
getExitCode()
|
boolean |
isExecuting()
|
boolean |
isFinished()
|
boolean |
isHandlerEnabled()
|
protected void |
output(int id,
java.lang.String line)
|
protected void |
setExitCode(int code)
|
protected void |
startExecution()
|
void |
terminate(java.lang.String reason)
|
protected void |
terminated(java.lang.String reason)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Command(int id, java.lang.String... command)
id
- the id of the command being executedcommand
- the command, or commands, to be executed.public Command(int id, boolean handlerEnabled, java.lang.String... command)
id
- the id of the command being executedhandlerEnabled
- when true the handler will be used to call the
callback methods if possible.command
- the command, or commands, to be executed.public Command(int id, int timeout, java.lang.String... command)
id
- the id of the command being executedtimeout
- the time allowed before the shell will give up executing the command
and throw a TimeoutException.command
- the command, or commands, to be executed.public Command(int id, boolean javaCommand, android.content.Context context, java.lang.String... command)
javaCommand
- when True, it is a java command.context
- needed to execute java command.public Command(int id, boolean handlerEnabled, boolean javaCommand, android.content.Context context, java.lang.String... command)
javaCommand
- when True, it is a java command.context
- needed to execute java command.public Command(int id, int timeout, boolean javaCommand, android.content.Context context, java.lang.String... command)
javaCommand
- when True, it is a java command.context
- needed to execute java command.Method Detail |
---|
public abstract void commandOutput(int id, java.lang.String line)
public abstract void commandTerminated(int id, java.lang.String reason)
public abstract void commandCompleted(int id, int exitCode)
protected void finishCommand()
protected void commandFinished()
public java.lang.String getCommand()
public boolean isExecuting()
public boolean isHandlerEnabled()
public boolean isFinished()
public int getExitCode()
protected void setExitCode(int code)
protected void startExecution()
public void terminate(java.lang.String reason)
protected void terminated(java.lang.String reason)
protected void output(int id, java.lang.String line)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |