org.apache.struts.taglib.template
Class GetTag
java.lang.Object
|
+--javax.servlet.jsp.tagext.TagSupport
|
+--org.apache.struts.taglib.template.GetTag
- All Implemented Interfaces:
- javax.servlet.jsp.tagext.IterationTag, java.io.Serializable, javax.servlet.jsp.tagext.Tag
- public class GetTag
- extends javax.servlet.jsp.tagext.TagSupport
This is the tag handler for <template:get>, which gets
content from the request scope and either includes the content or prints
it, depending upon the value of the content's direct attribute.
- Version:
- $Revision: 1.1 $ $Date: 2001/09/17 20:11:40 $
- Author:
- David Geary
- See Also:
- Serialized Form
Field Summary |
private boolean |
flush
Should we flush before including this text? |
private java.lang.String |
name
The name of the content that this tag includes (or prints). |
private java.lang.String |
role
The role that the user must be in to retrieve content. |
Fields inherited from class javax.servlet.jsp.tagext.TagSupport |
id, pageContext, parent, values |
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 |
Method Summary |
int |
doStartTag()
Print content named by setName() or include it, depending
on the content's direct attribute. |
boolean |
getFlush()
Get the flush-before-include attribute. |
java.lang.String |
getName()
Get the name attribute. |
java.lang.String |
getRole()
Get the role attribute. |
void |
release()
Reset member values for reuse. |
private void |
saveException(java.lang.Throwable exception)
Save the specified exception in request scope if there is not already
one present. |
void |
setFlush(boolean flush)
Set the flush-before-include property |
void |
setName(java.lang.String name)
Set the name attribute |
void |
setRole(java.lang.String role)
Set the role 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, registerNatives, toString, wait, wait, wait |
flush
private boolean flush
- Should we flush before including this text?
name
private java.lang.String name
- The name of the content that this tag includes (or prints).
role
private java.lang.String role
- The role that the user must be in to retrieve content.
GetTag
public GetTag()
setFlush
public void setFlush(boolean flush)
- Set the flush-before-include property
- Parameters:
flush
- The new flush property
setName
public void setName(java.lang.String name)
- Set the name attribute
- Parameters:
name
- The name of the content to get.
setRole
public void setRole(java.lang.String role)
- Set the role attribute
- Parameters:
name
- The role the user must be in to retrieve content.
getFlush
public boolean getFlush()
- Get the flush-before-include attribute.
getName
public java.lang.String getName()
- Get the name attribute.
getRole
public java.lang.String getRole()
- Get the role attribute.
doStartTag
public int doStartTag()
throws javax.servlet.jsp.JspException
- Print content named by setName() or include it, depending
on the content's direct attribute.
- Overrides:
doStartTag
in class javax.servlet.jsp.tagext.TagSupport
release
public void release()
- Reset member values for reuse. This method calls super.release(),
which invokes TagSupport.release(), which typically does nothing.
- Overrides:
release
in class javax.servlet.jsp.tagext.TagSupport
saveException
private void saveException(java.lang.Throwable exception)
- Save the specified exception in request scope if there is not already
one present.
- Parameters:
exception
- Exception to be conditionally saved
Copyright © 2000-2001 - Apache Software Foundation