org.htmlparser.tags

Class OptionTag

public class OptionTag extends CompositeTag

An option tag within a form.
Constructor Summary
OptionTag()
Create a new option tag.
Method Summary
String[]getEnders()
Return the set of tag names that cause this tag to finish.
String[]getEndTagEnders()
Return the set of end tag names that cause this tag to finish.
String[]getIds()
Return the set of names handled by this tag.
StringgetOptionText()
Get the text of this option.
StringgetValue()
Get the VALUE attribute, if any.
voidsetValue(String value)
Set the value of the value attribute.
StringtoString()
Return a string representation of this node suitable for debugging.

Constructor Detail

OptionTag

public OptionTag()
Create a new option tag.

Method Detail

getEnders

public String[] getEnders()
Return the set of tag names that cause this tag to finish.

Returns: The names of following tags that stop further scanning.

getEndTagEnders

public String[] getEndTagEnders()
Return the set of end tag names that cause this tag to finish.

Returns: The names of following end tags that stop further scanning.

getIds

public String[] getIds()
Return the set of names handled by this tag.

Returns: The names to be matched that create tags of this type.

getOptionText

public String getOptionText()
Get the text of this option.

Returns: The textual contents of this OPTION tag.

getValue

public String getValue()
Get the VALUE attribute, if any.

Returns: The value of the VALUE attribute, or null if the attribute doesn't exist.

setValue

public void setValue(String value)
Set the value of the value attribute.

Parameters: value The new value of the VALUE attribute.

toString

public String toString()
Return a string representation of this node suitable for debugging.

Returns: The value and text of this tag in a string.

HTML Parser is an open source library released under LGPL. SourceForge.net