|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.izforge.izpack.installer.CompileResult
This class describes the result of the compilation. This class is here because error handling is not straight-forward with regard to compilation. The error condition consists of an error message, the full command line which failed to execute plus it's stdout and stderr. The reason for this class to exist is that there are three possible reactions to the error (chosen by the user).
Field Summary | |
private int |
action
|
static int |
ACTION_ABORT
|
static int |
ACTION_CONTINUE
|
static int |
ACTION_RECONFIGURE
|
private java.lang.String[] |
cmdline
the command line |
static int |
FAILED
|
private java.lang.String |
message
the error message |
private int |
status
|
private java.lang.String |
stderr
the stderr of the command |
private java.lang.String |
stdout
the stdout of the command |
static int |
SUCCESS
|
Constructor Summary | |
CompileResult()
constructor, create a new successful result |
|
CompileResult(java.lang.String message,
java.lang.String[] cmdline,
java.lang.String stdout,
java.lang.String stderr)
creates a new CompileResult with status FAILED |
Method Summary | |
int |
getAction()
|
java.lang.String |
getCmdline()
get command line of failed command as a string |
java.lang.String[] |
getCmdlineArray()
get command line of failed command as an array of strings |
java.lang.String |
getMessage()
return error message |
int |
getStatus()
|
java.lang.String |
getStderr()
|
java.lang.String |
getStdout()
|
boolean |
isAbort()
check whether to abort (convenience function) |
boolean |
isContinue()
check whether to continue (convenience function) |
boolean |
isReconfigure()
check whether to reconfigure (convenience function) |
boolean |
isSuccess()
check for success (convenience function) |
void |
setAction(int action)
|
void |
setStatus(int status)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int SUCCESS
public static final int FAILED
public static final int ACTION_ABORT
public static final int ACTION_CONTINUE
public static final int ACTION_RECONFIGURE
private int status
private int action
private java.lang.String message
private java.lang.String[] cmdline
private java.lang.String stdout
private java.lang.String stderr
Constructor Detail |
public CompileResult()
public CompileResult(java.lang.String message, java.lang.String[] cmdline, java.lang.String stdout, java.lang.String stderr)
message
- description of the exceptioncmdline
- full command line of failed commandstdout
- standard output of failed commandstderr
- standard error of failed commandMethod Detail |
public void setStatus(int status)
public int getStatus()
public void setAction(int action)
public int getAction()
public boolean isSuccess()
public boolean isAbort()
public boolean isContinue()
public boolean isReconfigure()
public java.lang.String getMessage()
public java.lang.String getCmdline()
public java.lang.String[] getCmdlineArray()
public java.lang.String getStdout()
public java.lang.String getStderr()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |