public class CatchTag extends TagSupport implements TryCatchFinally
Tag handler for <catch> in JSTL 1.0.
<catch> simply catches any Throwables that occur in its body and optionally exposes them.
id, pageContextEVAL_BODY_AGAINEVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE| Constructor and Description |
|---|
CatchTag() |
| Modifier and Type | Method and Description |
|---|---|
void |
doCatch(Throwable t)
Invoked if a Throwable occurs while evaluating the BODY
inside a tag or in any of the following methods:
Tag.doStartTag(), Tag.doEndTag(),
IterationTag.doAfterBody() and BodyTag.doInitBody().
|
void |
doFinally()
Invoked in all cases after doEndTag() for any class implementing
Tag, IterationTag or BodyTag.
|
int |
doStartTag()
Default processing of the start tag, returning SKIP_BODY.
|
void |
release()
Release state.
|
void |
setVar(String var) |
doAfterBody, doEndTag, findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValuepublic void release()
TagSupportrelease in interface Tagrelease in class TagSupportTag.release()public int doStartTag()
TagSupportdoStartTag in interface TagdoStartTag in class TagSupportTag.doStartTag()public void doCatch(Throwable t)
TryCatchFinallyThis method is not invoked if the Throwable occurs during one of the setter methods.
This method may throw an exception (the same or a new one) that will be propagated further up the nest chain. If an exception is thrown, doFinally() will be invoked.
This method is intended to be used to respond to an exceptional condition.
doCatch in interface TryCatchFinallyt - The throwable exception navigating through this tag.public void doFinally()
TryCatchFinallyThis method is not invoked if the Throwable occurs during one of the setter methods.
This method should not throw an Exception.
This method is intended to maintain per-invocation data integrity and resource management actions.
doFinally in interface TryCatchFinallypublic void setVar(String var)
Copyright © 2018 JBoss by Red Hat. All rights reserved.