com.parabon.client
Interface TaskExceptionEvent

All Superinterfaces:
TaskEvent

public interface TaskExceptionEvent
extends TaskEvent

A TaskExceptionEvent is generated when execution of a task completes in an exceptional state, either caused by the task itself throwing a user (non-system) exception, or by an external condition such as a malformed task specification or resource limitation preventing the successful completion of a task which the system is unable to mitigate by relaunching a task. Once a task enters an exception state, it is guaranteed that at least one TaskExceptionEvent will be generated and propogated back to the client application representing the final state of the task.


Method Summary
 TaskExceptionCode getCode()
          Returns the code giving this exception's category.
 java.lang.String getDescription()
          Accesses a string containing as much information as is available regarding the cause of the exception and the state of the task when the exception occurred.
 TaskExceptionSubcode getSubcode()
          Returns the subcode giving this exception's subcategory.
 boolean isUserException()
          Examines the exception code and reports whether this exception was thrown explicitely by the task rather than generated externally (for instance because of a resource limitation or malformed task).
 
Methods inherited from interface com.parabon.client.TaskEvent
getProgress, getRunMode, getTaskAttributes, getTaskProxy, isActive, isComplete
 

Method Detail

getCode

TaskExceptionCode getCode()
Returns the code giving this exception's category.


getSubcode

TaskExceptionSubcode getSubcode()
Returns the subcode giving this exception's subcategory.


getDescription

java.lang.String getDescription()
Accesses a string containing as much information as is available regarding the cause of the exception and the state of the task when the exception occurred. For a user exception (that is, one thrown explicitely by the task itself rather than the runtime), this string consists of the result of calling the toString() method on the thrown exception, as well as a possible stack trace.


isUserException

boolean isUserException()
Examines the exception code and reports whether this exception was thrown explicitely by the task rather than generated externally (for instance because of a resource limitation or malformed task).