Package org.opencms.jsp
Class CmsJspTagMap
java.lang.Object
javax.servlet.jsp.tagext.TagSupport
javax.servlet.jsp.tagext.BodyTagSupport
org.opencms.jsp.CmsJspTagMap
- All Implemented Interfaces:
Serializable
,javax.servlet.jsp.tagext.BodyTag
,javax.servlet.jsp.tagext.IterationTag
,javax.servlet.jsp.tagext.JspTag
,javax.servlet.jsp.tagext.Tag
,I_CmsJspTagParamParent
public class CmsJspTagMap
extends javax.servlet.jsp.tagext.BodyTagSupport
implements I_CmsJspTagParamParent
Builds a java.util.Map isntance with string keys and values from nested param tags, then stores it in a page context variable whose name is supplied by the user.
- See Also:
-
Field Summary
Fields inherited from class javax.servlet.jsp.tagext.BodyTagSupport
bodyContent
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
Fields inherited from interface javax.servlet.jsp.tagext.BodyTag
EVAL_BODY_BUFFERED, EVAL_BODY_TAG
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
ConstructorsConstructorDescriptionEmpty constructor, required for attribute value initialization. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addParameter
(String name, String value) Add a parameter to this tag.int
doEndTag()
int
Returns
.BodyTag.EVAL_BODY_BUFFERED
void
Sets the variable name in which the map should be stored.Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
doAfterBody, doInitBody, getBodyContent, getPreviousOut, release, setBodyContent
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
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
Methods inherited from interface javax.servlet.jsp.tagext.Tag
getParent, setPageContext, setParent
-
Constructor Details
-
CmsJspTagMap
public CmsJspTagMap()Empty constructor, required for attribute value initialization.
-
-
Method Details
-
addParameter
Description copied from interface:I_CmsJspTagParamParent
Add a parameter to this tag. The intent is that the <param> subtag will call this to register parameters. Assumes that 'name' and 'value' are appropriately encoded and do not contain any meaningful metacharacters; in order words, escaping is the responsibility of the caller.- Specified by:
addParameter
in interfaceI_CmsJspTagParamParent
- Parameters:
name
- the name of the parametervalue
- the value of the parameter- See Also:
-
doEndTag
- Specified by:
doEndTag
in interfacejavax.servlet.jsp.tagext.Tag
- Overrides:
doEndTag
in classjavax.servlet.jsp.tagext.BodyTagSupport
- Returns:
EVAL_PAGE
- Throws:
javax.servlet.jsp.JspException
- by interface default- See Also:
-
Tag.doEndTag()
-
doStartTag
Returns
.BodyTag.EVAL_BODY_BUFFERED
- Specified by:
doStartTag
in interfacejavax.servlet.jsp.tagext.Tag
- Overrides:
doStartTag
in classjavax.servlet.jsp.tagext.BodyTagSupport
- Returns:
BodyTag.EVAL_BODY_BUFFERED
- See Also:
-
Tag.doStartTag()
-
setVar
Sets the variable name in which the map should be stored.- Parameters:
var
- the name of the variable
-