All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.abc.templates.HtmlSelect

java.lang.Object
   |
   +----com.abc.templates.HtmlControl
           |
           +----com.abc.templates.HtmlSelect

public class HtmlSelect
extends HtmlControl
implements Serializable

 

Object represent dopdown box on html page.

All properties:
<select name="Select" size="10" visible="0" mulitple .....(additional property)> 
    <option value="value1" selected>Display Value</option>    ----- please note </option> is optional you can ommit it.
    <option value="value2" selected>Display Value
</selected>

Control has exactly the same signature as pure html( except visible property). All additional properties will be combined in one string. If you provide "multiple" it means that control allows multiple selections.


 o addAdditionalOptions(String)

Allows you to append additional property to chaeck box.
 o addOptions(String sValue, String sDispValue, boolean bSelected)
Adds new "option" to control.
 o getDisplayValue()
Retrives "Dispaly Value" property for selected item.
 o getDisplayValue(int)
retirves "Display Value" property for specific item.
 o getMultiple()
return true if control allows multiple selection and false if not.
 o getSelected()
retrived array of indexes of selected items.
 o getValue()
retrive selected item or "" if not selected item.
 o getValue(int)
retrive "Value"of specific item.
 o resetAllValues()
resets all items to non selected state.
 o resetValue(String sValue )
resets item with "Value" == sValue to non selected state.
 o setMultiple(boolean)
set "Multiple" property.
 o setValue(String sValue)
sets item with "Value" == sValue to selected state.

 o addAdditionalOptions

 public final void addAdditionalOptions(String s)

 o addOptions

 public final void addOptions(String sValue,
                              String sDispValue,
                              boolean bSelected)
 o  getDisplayValue 
 public final String getDisplayValue()

 o getDisplayValue

 public final String getDisplayValue(int iIndex)

 o getMultiple

 public final boolean getMultiple()

 o getSelected

 public int[] getSelected()

 o getValue

 public final String getValue()
Overrides:
getValue in class HtmlControl

 o getValue

 public final String getValue(int iIndex)
 

 o resetAllValues

 public final void resetAllValue()

 o resetValue

 public final void resetValue(String sValue)

 o setMultiple

 public final void setMultiple(boolean bMultiple)
 

 o setValue

 public final void setValue(String sValue)
Overrides:
setValue in class HtmlControl

All Packages  Class Hierarchy  This Package  Previous  Next  Index