|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.servlet.jsp.tagext.TagSupport
javax.servlet.jsp.tagext.BodyTagSupport
org.opencms.jsp.CmsJspScopedVarBodyTagSuport
public class CmsJspScopedVarBodyTagSuport
Parent for body tags that require support for setting scoped variables to the JSP page context.
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 | |
---|---|
CmsJspScopedVarBodyTagSuport()
|
Method Summary | |
---|---|
java.lang.String |
getScope()
Returns the scope under which the content access bean is saved in the page context. |
protected static int |
getScopeAsInt(java.lang.String scope)
Returns the int value of the specified scope string. |
protected static java.lang.String |
getScopeAsString(int scope)
Returns the String value of the specified scope integer. |
protected int |
getScopeInt()
Returns the scope as int usable for setting the JSP page context with JspContext.setAttribute(String, Object, int) . |
java.lang.String |
getVar()
Returns the name of the variable under which the content access bean is saved in the page context. |
protected boolean |
isScopeVarSet()
Returns true in case the scoped variable has been set for this Tag. |
void |
release()
|
void |
setScope(java.lang.String scope)
Sets the scope under which the content access bean is saved in the page context. |
void |
setVar(java.lang.String var)
Sets the name of the variable under which the content access bean is saved in the page context. |
protected void |
storeAttribute(java.lang.Object obj)
Stores the provided Object as attribute in the JSP page context. |
Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport |
---|
doAfterBody, doEndTag, doInitBody, doStartTag, getBodyContent, getPreviousOut, 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 Detail |
---|
public CmsJspScopedVarBodyTagSuport()
Method Detail |
---|
protected static int getScopeAsInt(java.lang.String scope)
The default value is PageContext.PAGE_SCOPE
.
scope
- the string name of the desired scope, e.g. "application", "request"
protected static java.lang.String getScopeAsString(int scope)
Valid values for the scope int parameter are 1 to 4 only.
scope
- integer that describes the scope according to getScopeInt()
.
public java.lang.String getScope()
public java.lang.String getVar()
public void release()
release
in interface javax.servlet.jsp.tagext.Tag
release
in class javax.servlet.jsp.tagext.BodyTagSupport
Tag.release()
public void setScope(java.lang.String scope)
scope
- the scope under which the content access bean is saved in the page contextpublic void setVar(java.lang.String var)
var
- the name of the variable under which the content access bean is saved in the page contextprotected int getScopeInt()
JspContext.setAttribute(String, Object, int)
.
protected boolean isScopeVarSet()
true
in case the scoped variable has been set for this Tag.
true
in case the scoped variable has been set for this Tagprotected void storeAttribute(java.lang.Object obj)
The values of getVar()
and getScope()
are used to determine how the Object is stored.
obj
- the Object to store in the JSP page context.
|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |