jaxcent
Class HtmlOption

java.lang.Object
  extended byjaxcent.JaxcentObject
      extended byjaxcent.JaxcentHtmlElement
          extended byjaxcent.HtmlOption

public class HtmlOption
extends JaxcentHtmlElement

The class HtmlOption corresponds to OPTION tags on the page, i.e. to individual elements of SELECT tags. Objects of this class can also be obtained by calling the getOption method of HtmlSelect objects. To add new options, call the insertOption method of HtmlSelect.


Constructor Summary
HtmlOption(JaxcentPage page, SearchType searchType, java.lang.String str)
          Search for HTML element on page by specified search type and search string.
HtmlOption(JaxcentPage page, SearchType searchType, java.lang.String str, int index)
          Search for HTML Element on page by specified search type and search string, and search index.
HtmlOption(JaxcentPage page, java.lang.String id)
          Search for HTML element on page by specified ID
 
Method Summary
 void delete()
          Delete this element.
 boolean getDefaultSelected()
          Retrieve the "defaultSelected" property
 int getIndex()
          Retrieve the "index" property
 boolean getSelected()
          Retrieve the "selected" property
 java.lang.String getText()
          Retrieve the "text" property
 java.lang.String getValue()
          Retrieve the "value" property
 void setIndex(int value)
          Set the "index" property
 void setSelected(boolean value)
          Set the "selected" property
 void setText(java.lang.String value)
          Set the "text" property
 void setValue(java.lang.String value)
          Set the "value" property
 
Methods inherited from class jaxcent.JaxcentHtmlElement
getAttribute, getID, getInnerText, getStyle, getTag, hide, insertAfter, insertAtBeginning, insertAtBeginning, insertAtEnd, insertAtEnd, insertBefore, setAttribute, setInnerText, setStyle, setStyle, setStyle, setStyle, setVisible, show
 
Methods inherited from class jaxcent.JaxcentObject
addJavaScriptVerification, getId, getProperty, setId, setProperty, setProperty, setProperty, setProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HtmlOption

public HtmlOption(JaxcentPage page,
                  java.lang.String id)
Search for HTML element on page by specified ID


HtmlOption

public HtmlOption(JaxcentPage page,
                  SearchType searchType,
                  java.lang.String str)
Search for HTML element on page by specified search type and search string. If the search returns multiple objects, use the first one.


HtmlOption

public HtmlOption(JaxcentPage page,
                  SearchType searchType,
                  java.lang.String str,
                  int index)
Search for HTML Element on page by specified search type and search string, and search index. The search is expected to return multiple results. The search index is 0-based, and specifies the index in the multiple results. This constructor is not for use with createNew.

Method Detail

getDefaultSelected

public boolean getDefaultSelected()
                           throws Jaxception
Retrieve the "defaultSelected" property

Throws:
Jaxception

setIndex

public void setIndex(int value)
              throws Jaxception
Set the "index" property

Throws:
Jaxception

getIndex

public int getIndex()
             throws Jaxception
Retrieve the "index" property

Throws:
Jaxception

delete

public void delete()
            throws Jaxception
Delete this element.

Throws:
Jaxception

setSelected

public void setSelected(boolean value)
                 throws Jaxception
Set the "selected" property

Throws:
Jaxception

getSelected

public boolean getSelected()
                    throws Jaxception
Retrieve the "selected" property

Throws:
Jaxception

setText

public void setText(java.lang.String value)
             throws Jaxception
Set the "text" property

Throws:
Jaxception

getText

public java.lang.String getText()
                         throws Jaxception
Retrieve the "text" property

Throws:
Jaxception

setValue

public void setValue(java.lang.String value)
              throws Jaxception
Set the "value" property

Throws:
Jaxception

getValue

public java.lang.String getValue()
                          throws Jaxception
Retrieve the "value" property

Throws:
Jaxception