org.apache.struts.taglib.tiles
Class PutListTag

java.lang.Object
  |
  +--javax.servlet.jsp.tagext.TagSupport
        |
        +--org.apache.struts.taglib.tiles.PutListTag
All Implemented Interfaces:
AddTagParent, ComponentConstants, javax.servlet.jsp.tagext.IterationTag, PutListTagParent, java.io.Serializable, javax.servlet.jsp.tagext.Tag

public class PutListTag
extends javax.servlet.jsp.tagext.TagSupport
implements ComponentConstants, AddTagParent, PutListTagParent

PutList tag implementation.

See Also:
Serialized Form

Field Summary
private  java.lang.String attributeName
          Name of this attribute
private  java.util.List list
          The list itself
private  java.lang.String role
          Role attribute
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface org.apache.struts.taglib.tiles.ComponentConstants
COMPONENT_CONTEXT, COMPONENT_SCOPE, EXCEPTION_KEY, LOCALE_KEY
 
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
PutListTag()
          default constructor
 
Method Summary
 void addElement(java.lang.Object value)
          Set property
 int doEndTag()
          Do end tag.
 int doStartTag()
          Do start tag.
protected  PutListTagParent findEnclosingParent()
          Find enclosing parent tag accepting this tag.
 java.util.List getList()
          Get list defined in tag.
 java.lang.String getName()
          Get property
 java.lang.String getRole()
          Get role attribute
 void processNestedTag(AddTag nestedTag)
          Process nested ≶add> tag.
 void processNestedTag(PutListTag nestedTag)
          Process nested ≶putList> tag.
 void release()
          Release all allocated resources.
protected  void releaseInternal()
          Release all internal resources.
 void setName(java.lang.String name)
          Set property
 void setRole(java.lang.String role)
          Set role attribute
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, 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.IterationTag
 

Field Detail

attributeName

private java.lang.String attributeName
Name of this attribute


list

private java.util.List list
The list itself


role

private java.lang.String role
Role attribute

Constructor Detail

PutListTag

public PutListTag()
default constructor

Method Detail

release

public void release()
Release all allocated resources.

Specified by:
release in interface javax.servlet.jsp.tagext.Tag
Overrides:
release in class javax.servlet.jsp.tagext.TagSupport

releaseInternal

protected void releaseInternal()
Release all internal resources.


setName

public void setName(java.lang.String name)
Set property


getName

public java.lang.String getName()
Get property


setRole

public void setRole(java.lang.String role)
Set role attribute


getRole

public java.lang.String getRole()
Get role attribute


getList

public java.util.List getList()
Get list defined in tag.


addElement

public void addElement(java.lang.Object value)
Set property


processNestedTag

public void processNestedTag(PutListTag nestedTag)
                      throws javax.servlet.jsp.JspException
Process nested ≶putList> tag. Method calls by nested ≶putList> tags. Nested list is added to current list. If role is defined, nested attribute is wrapped into an untypped definition containing attribute value and role.

Specified by:
processNestedTag in interface PutListTagParent
Parameters:
nestedTag - Nested PutTag defining the attribute.
javax.servlet.jsp.JspException

processNestedTag

public void processNestedTag(AddTag nestedTag)
                      throws javax.servlet.jsp.JspException
Process nested ≶add> tag. Method calls by nested ≶add> tags. Nested attribute is added to current list. If role is defined, nested attribute is wrapped into an untypped definition containing attribute value and role.

Specified by:
processNestedTag in interface AddTagParent
Parameters:
nestedTag - Nested to process.
javax.servlet.jsp.JspException

doStartTag

public int doStartTag()
               throws javax.servlet.jsp.JspException
Do start tag.

Specified by:
doStartTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doStartTag in class javax.servlet.jsp.tagext.TagSupport
javax.servlet.jsp.JspException

doEndTag

public int doEndTag()
             throws javax.servlet.jsp.JspException
Do end tag.

Specified by:
doEndTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doEndTag in class javax.servlet.jsp.tagext.TagSupport
javax.servlet.jsp.JspException

findEnclosingParent

protected PutListTagParent findEnclosingParent()
                                        throws javax.servlet.jsp.JspException
Find enclosing parent tag accepting this tag.

Throws:
javax.servlet.jsp.JspException - If we can't find an appropriate enclosing tag.


Copyright 2000-2002 - Cedric Dumoulin and Apache Software Foundation