org.apache.taglibs.standard.tag.common.core
Class SetSupport

java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by javax.servlet.jsp.tagext.BodyTagSupport
          extended by org.apache.taglibs.standard.tag.common.core.SetSupport
All Implemented Interfaces:
Serializable, javax.servlet.jsp.tagext.BodyTag, javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.JspTag, javax.servlet.jsp.tagext.Tag
Direct Known Subclasses:
SetTag

public abstract class SetSupport
extends javax.servlet.jsp.tagext.BodyTagSupport

Support for handlers of the <set> tag.

Author:
Shawn Bayern
See Also:
Serialized Form

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
protected SetSupport()
          Constructs a new handler.
 
Method Summary
 int doEndTag()
           
protected abstract  String evalProperty()
          Evaluate the property attribute.
protected abstract  Object evalTarget()
          Evaluate the target attribute.
protected abstract  Object evalValue()
          Evaluate the value attribute.
protected  javax.el.ExpressionFactory getExpressionFactory()
           
protected abstract  boolean isValueSpecified()
          Indicates that the value attribute was specified.
 void release()
           
 void setScope(String scope)
          Scope for var.
 void setVar(String var)
          Name of the exported scoped variable to hold the value specified in the action.
 
Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
doAfterBody, 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

SetSupport

protected SetSupport()
Constructs a new handler. As with TagSupport, subclasses should not provide other constructors and are expected to call the superclass constructor.

Method Detail

release

public void release()
Specified by:
release in interface javax.servlet.jsp.tagext.Tag
Overrides:
release in class javax.servlet.jsp.tagext.BodyTagSupport

doEndTag

public int doEndTag()
             throws javax.servlet.jsp.JspException
Specified by:
doEndTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doEndTag in class javax.servlet.jsp.tagext.BodyTagSupport
Throws:
javax.servlet.jsp.JspException

isValueSpecified

protected abstract boolean isValueSpecified()
Indicates that the value attribute was specified. If no value attribute is supplied then the value is taken from the tag's body content.

Returns:
true if the value attribute was specified

evalValue

protected abstract Object evalValue()
                             throws javax.servlet.jsp.JspException
Evaluate the value attribute.

Returns:
the result of evaluating the value attribute
Throws:
javax.servlet.jsp.JspException - if there was a problem evaluating the expression

evalTarget

protected abstract Object evalTarget()
                              throws javax.servlet.jsp.JspException
Evaluate the target attribute.

Returns:
the result of evaluating the target attribute
Throws:
javax.servlet.jsp.JspException - if there was a problem evaluating the expression

evalProperty

protected abstract String evalProperty()
                                throws javax.servlet.jsp.JspException
Evaluate the property attribute.

Returns:
the result of evaluating the property attribute
Throws:
javax.servlet.jsp.JspException - if there was a problem evaluating the expression

getExpressionFactory

protected javax.el.ExpressionFactory getExpressionFactory()

setVar

public void setVar(String var)
Name of the exported scoped variable to hold the value specified in the action. The type of the scoped variable is whatever type the value expression evaluates to.

Parameters:
var - name of the exported scoped variable

setScope

public void setScope(String scope)
Scope for var. Values are verified by TLV.

Parameters:
scope - the variable scope


Copyright © 2001-2015 The Apache Software Foundation. All Rights Reserved.