net.sourceforge.pebble.web.tagext
Class SelectTag

java.lang.Object
  extended by TagSupport
      extended by net.sourceforge.pebble.web.tagext.SelectTag

public class SelectTag
extends TagSupport

Given a Collection or array, this tag produces a HTML select (dropdown) list based upon the items contained within.

Author:
Simon Brown

Constructor Summary
SelectTag()
           
 
Method Summary
 int doStartTag()
          Called when the starting tag is encountered.
 void setItems(java.lang.Object items)
          Sets the items over which this tag should iterate.
 void setLabel(java.lang.String label)
          Sets the name of the property to display.
 void setMultiple(boolean multiple)
          Sets the multiple attribute on the underlying select control.
 void setName(java.lang.String name)
          Sets the name for the generated select control.
 void setSelected(java.lang.Object selected)
          Sets the selected value.
 void setSize(int size)
          Sets the size of the generated select control.
 void setValue(java.lang.String value)
          Sets the name of the property to use as the hidden value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SelectTag

public SelectTag()
Method Detail

doStartTag

public int doStartTag()
               throws JspException
Called when the starting tag is encountered.

Throws:
JspException

setItems

public void setItems(java.lang.Object items)
Sets the items over which this tag should iterate.

Parameters:
items - a Collection or array

setName

public void setName(java.lang.String name)
Sets the name for the generated select control.

Parameters:
name - the name as a String

setSize

public void setSize(int size)
Sets the size of the generated select control.

Parameters:
size - the size

setMultiple

public void setMultiple(boolean multiple)
Sets the multiple attribute on the underlying select control.

Parameters:
multiple - a boolean

setLabel

public void setLabel(java.lang.String label)
Sets the name of the property to display.

Parameters:
label - the name of the label property

setValue

public void setValue(java.lang.String value)
Sets the name of the property to use as the hidden value.

Parameters:
value - the name of the value property

setSelected

public void setSelected(java.lang.Object selected)
Sets the selected value.

Parameters:
selected - the selected value


Copyright © 2003-2006, Simon Brown. All Rights Reserved.