|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javax.servlet.jsp.tagext.TagSupport | +--javax.servlet.jsp.jstl.core.ConditionalTagSupport
ConditionalTagSupport is an abstract class that facilitates implementation of conditional tags -- specifically, tags in the style of <if>.
In particular, this base class provides support for:
Since this method implements the behavior anticipated to be recommended by the standard (with respect to tags that support boolean logic), it is expected that it will be part of the JSTL API.
Field Summary |
Fields inherited from class javax.servlet.jsp.tagext.TagSupport |
id, pageContext |
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag |
EVAL_BODY_AGAIN |
Fields inherited from interface javax.servlet.jsp.tagext.Tag |
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE |
Constructor Summary | |
ConditionalTagSupport()
Base constructor to initialize local state. |
Method Summary | |
protected abstract boolean |
condition()
Returns a boolean representing the condition that a particular subclass uses to drive its conditional logic. |
int |
doStartTag()
Includes its body if condition() evalutes to true. |
void |
release()
Releases any resources this ConditionalTagSupport may have (or inherit). |
void |
setScope(java.lang.String scope)
Sets the 'scope' attribute. |
void |
setVar(java.lang.String var)
Sets the 'var' attribute. |
Methods inherited from class javax.servlet.jsp.tagext.TagSupport |
doAfterBody, doEndTag, findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ConditionalTagSupport()
Method Detail |
protected abstract boolean condition() throws javax.servlet.jsp.JspTagException
Returns a boolean representing the condition that a particular subclass uses to drive its conditional logic.
javax.servlet.jsp.JspTagException
public int doStartTag() throws javax.servlet.jsp.JspException
doStartTag
in interface javax.servlet.jsp.tagext.Tag
doStartTag
in class javax.servlet.jsp.tagext.TagSupport
javax.servlet.jsp.JspException
public void release()
release
in interface javax.servlet.jsp.tagext.Tag
release
in class javax.servlet.jsp.tagext.TagSupport
public void setVar(java.lang.String var)
var
- Name of the exported scoped variable storing the result of
condition().public void setScope(java.lang.String scope)
scope
- Scope of the 'var' attribute
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |