public class OutcomeManager
extends java.lang.Object
implements java.io.Serializable
Constructor and Description |
---|
OutcomeManager(Behaviour bh) |
Modifier and Type | Method and Description |
---|---|
void |
error(java.lang.String msg,
java.lang.Exception e)
Mark the behaviour holding this OutcomeManager as failed and store the error-message that can then be retrieved by means of the
getErrorMsg() method |
java.lang.String |
getErrorMsg()
Retrieve the error-message providing details about the reason of failure of the behaviour holding this OutcomeManager .
|
int |
getExitCode()
Retrieve the exit-code that indicates whether the behaviour holding this OutcomeManager succeeded (
OK ) or failed (KO ) |
boolean |
isSuccessful() |
void |
propagateError(java.lang.String msg)
Used to propagate an already logged error through a hierarchy of behaviours
|
public static final int OK
public static final int KO
public OutcomeManager(Behaviour bh)
public int getExitCode()
OK
) or failed (KO
)OK
) or failed (KO
)public boolean isSuccessful()
public java.lang.String getErrorMsg()
public void error(java.lang.String msg, java.lang.Exception e)
getErrorMsg()
methodmsg
- The error message.e
- The Exception, if any, that caused the behaviour to failpublic void propagateError(java.lang.String msg)