|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.jolene.dom.Option
public final class Option
A select option object.
Constructor Summary | |
---|---|
Option()
Creates a new Option object. |
|
Option(int value,
java.lang.String text)
Creates an Option object using an int value and String text parameters. |
|
Option(java.lang.String value,
java.lang.String text)
Creates an Option object using the String value and text parameters. |
Method Summary | |
---|---|
int |
getIndex()
Return the index of this option in the list of selections. |
java.lang.String |
getText()
Get the option text. |
java.lang.String |
getValue()
Get the option value. |
boolean |
isSelected()
Determines if the option is currently selected. |
void |
setSelected(boolean selected)
Sets the option as currently selected. |
void |
setText(java.lang.String string)
Sets the text to display in the option. |
void |
setValue(java.lang.String string)
Sets the value which would be submitted when the form is submitted. |
java.lang.String |
toString()
Renders the option. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Option()
public Option(java.lang.String value, java.lang.String text)
value
- The value of the optiontext
- The display text of the optionpublic Option(int value, java.lang.String text)
value
- The value of the optiontext
- The display text of the optionMethod Detail |
---|
public int getIndex()
public java.lang.String getText()
public java.lang.String getValue()
public boolean isSelected()
public void setSelected(boolean selected)
selected
- booleanpublic void setText(java.lang.String string)
string
- text to display.public void setValue(java.lang.String string)
string
- value of the option.public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |