Package org.imixs.workflow.office.util
Class ErrorHandler
- java.lang.Object
-
- org.imixs.workflow.office.util.ErrorHandler
-
public class ErrorHandler extends Object
-
-
Constructor Summary
Constructors Constructor Description ErrorHandler()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidaddErrorMessage(org.imixs.workflow.exceptions.WorkflowException pe)This helper method adds a error message to the faces context, based on the data in a WorkflowException.static voidhandleModelException(org.imixs.workflow.exceptions.ModelException me)The Method expects a ModelException and adds the corresponding Faces Error Message into the FacesContext.static voidhandlePluginException(org.imixs.workflow.exceptions.PluginException pe)The Method expects a PluginException and adds the corresponding Faces Error Message into the FacesContext.
-
-
-
Method Detail
-
handlePluginException
public static void handlePluginException(org.imixs.workflow.exceptions.PluginException pe)
The Method expects a PluginException and adds the corresponding Faces Error Message into the FacesContext. If the PluginException was thrown from the RulePLugin then the method test this exception for ErrorParams and generate separate Faces Error Messages for each param.
-
addErrorMessage
public static void addErrorMessage(org.imixs.workflow.exceptions.WorkflowException pe)
This helper method adds a error message to the faces context, based on the data in a WorkflowException. This kind of error message can be displayed in a page using:If a PluginException or ValidationException contains an optional object array the message is parsed for params to be replaced Example:ERROR_MESSAGE=Value should not be greater than {0} or lower as {1}.- Parameters:
pe-
-
handleModelException
public static void handleModelException(org.imixs.workflow.exceptions.ModelException me)
The Method expects a ModelException and adds the corresponding Faces Error Message into the FacesContext. In case of a model exception, the exception message will become part of the error message. ErrorParams are not supported by a ModelException.
-
-