com.gargoylesoftware.htmlunit.html
Class HtmlRadioButtonInput

java.lang.Object
  extended by com.gargoylesoftware.htmlunit.html.DomNode
      extended by com.gargoylesoftware.htmlunit.html.DomNamespaceNode
          extended by com.gargoylesoftware.htmlunit.html.HtmlElement
              extended by com.gargoylesoftware.htmlunit.html.StyledElement
                  extended by com.gargoylesoftware.htmlunit.html.ClickableElement
                      extended by com.gargoylesoftware.htmlunit.html.FocusableElement
                          extended by com.gargoylesoftware.htmlunit.html.HtmlInput
                              extended by com.gargoylesoftware.htmlunit.html.HtmlRadioButtonInput
All Implemented Interfaces:
DisabledElement, SubmittableElement, java.io.Serializable, java.lang.Cloneable

public class HtmlRadioButtonInput
extends HtmlInput

Wrapper for the html element "input"

Version:
$Revision: 1.3 $
Author:
Mike Bowler, David K. Taylor, Christian Sell, Marc Guillemot, Mike Bresnahan, Daniel Gredler, Bruce Faulkner, Ahmed Ashour
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class com.gargoylesoftware.htmlunit.html.HtmlElement
HtmlElement.MapEntryWrappingIterator
 
Field Summary
 
Fields inherited from class com.gargoylesoftware.htmlunit.html.HtmlInput
TAG_NAME
 
Fields inherited from class com.gargoylesoftware.htmlunit.html.HtmlElement
ATTRIBUTE_NOT_DEFINED, ATTRIBUTE_VALUE_EMPTY
 
Fields inherited from class com.gargoylesoftware.htmlunit.html.DomNode
PROPERTY_ELEMENT, READY_STATE_COMPLETE, READY_STATE_INTERACTIVE, READY_STATE_LOADED, READY_STATE_LOADING, READY_STATE_UNINITIALIZED
 
Method Summary
 java.lang.String asText()
 A radio button does not have a textual representation, but we invent one for it because it is useful for testing.
 boolean isDefaultChecked()
 Returns the default checked state to use when this element gets reset, if applicable. The default implementation returns false; only checkboxes and radio buttons really care what the default checked value is.
 void reset()
 Return the value of this element to the default value or checked state (usually what it was at the time the page was loaded, unless it has been modified via JavaScript).
 Page setChecked(boolean isChecked)
 Set the "checked" attribute
 void setDefaultChecked(boolean defaultChecked)
 Sets the default checked state to use when this element gets reset, if applicable. The default implementation is empty; only checkboxes and radio buttons really care what the default checked value is.
 void setDefaultValue(java.lang.String defaultValue)
 Sets the default value to use when this element gets reset, if applicable. Also sets the value attribute when emulating Netscape browsers. Also sets the value to the new default value.
 
Methods inherited from class com.gargoylesoftware.htmlunit.html.HtmlInput
click, getAcceptAttribute, getAccessKeyAttribute, getAlignAttribute, getAltAttribute, getCheckedAttribute, getDefaultValue, getDisabledAttribute, getMaxLengthAttribute, getNameAttribute, getOnBlurAttribute, getOnChangeAttribute, getOnFocusAttribute, getOnSelectAttribute, getReadOnlyAttribute, getSizeAttribute, getSrcAttribute, getSubmitKeyValuePairs, getTabIndexAttribute, getTypeAttribute, getUseMapAttribute, getValueAttribute, isChecked, isDisabled, setValueAttribute
 
Methods inherited from class com.gargoylesoftware.htmlunit.html.FocusableElement
blur, focus
 
Methods inherited from class com.gargoylesoftware.htmlunit.html.ClickableElement
click, click, dblClick, dblClick, getLangAttribute, getOnClickAttribute, getOnDblClickAttribute, getOnKeyDownAttribute, getOnKeyPressAttribute, getOnKeyUpAttribute, getOnMouseDownAttribute, getOnMouseMoveAttribute, getOnMouseOutAttribute, getOnMouseOverAttribute, getOnMouseUpAttribute, getTextDirectionAttribute, getXmlLangAttribute
 
Methods inherited from class com.gargoylesoftware.htmlunit.html.StyledElement
getClassAttribute, getIdAttribute, getStyleAttribute, getTitleAttribute
 
Methods inherited from class com.gargoylesoftware.htmlunit.html.HtmlElement
addHtmlAttributeChangeListener, appendChildIfNoneExists, cloneDomNode, fireEvent, fireEvent, getAttributeEntriesIterator, getAttributeValue, getChildElementsIterator, getEnclosingElement, getEnclosingForm, getEnclosingFormOrDie, getEventHandler, getHtmlElementById, getHtmlElementsByAttribute, getHtmlElementsByTagName, getHtmlElementsByTagNames, getId, getNodeName, getNodeType, getOneHtmlElementByAttribute, getTagName, hasHtmlElementWithId, isAttributeDefined, keyDown, keyDown, mouseDown, mouseDown, mouseMove, mouseMove, mouseOut, mouseOut, mouseOver, mouseOver, mouseUp, mouseUp, removeAttribute, removeChild, removeEventHandler, removeHtmlAttributeChangeListener, rightClick, rightClick, setAttributeValue, setEventHandler, setEventHandler, setId, toString
 
Methods inherited from class com.gargoylesoftware.htmlunit.html.DomNamespaceNode
getLocalName, getNamespaceURI, getPrefix, getQualifiedName, setPrefix
 
Methods inherited from class com.gargoylesoftware.htmlunit.html.DomNode
addDomChangeListener, appendDomChild, asXml, getAllHtmlChildElements, getByXPath, getChildIterator, getEndColumnNumber, getEndLineNumber, getFirstDomChild, getLastDomChild, getNextDomSibling, getNodeValue, getPage, getParentDomNode, getPreviousDomSibling, getReadyState, getScriptObject, getStartColumnNumber, getStartLineNumber, insertBefore, remove, removeAllChildren, removeDomChangeListener, replace, setNodeValue, setReadyState, setScriptObject
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

asText

public java.lang.String asText()
A radio button does not have a textual representation, but we invent one for it because it is useful for testing.

Overrides:
asText in class HtmlInput
Returns:
"checked" or "unchecked" according to the radio state

isDefaultChecked

public boolean isDefaultChecked()
Returns the default checked state to use when this element gets reset, if applicable. The default implementation returns false; only checkboxes and radio buttons really care what the default checked value is.

Specified by:
isDefaultChecked in interface SubmittableElement
Overrides:
isDefaultChecked in class HtmlInput
Returns:
The default checked state to use when this element gets reset, if applicable.
See Also:
SubmittableElement.isDefaultChecked()

reset

public void reset()
Return the value of this element to the default value or checked state (usually what it was at the time the page was loaded, unless it has been modified via JavaScript).

Specified by:
reset in interface SubmittableElement
Overrides:
reset in class HtmlInput
See Also:
SubmittableElement.reset()

setChecked

public Page setChecked(boolean isChecked)
Set the "checked" attribute

Overrides:
setChecked in class HtmlInput
Parameters:
isChecked - true if this element is to be selected
Returns:
The page that occupies this window after setting checked status. It may be the same window or it may be a freshly loaded one.

setDefaultChecked

public void setDefaultChecked(boolean defaultChecked)
Sets the default checked state to use when this element gets reset, if applicable. The default implementation is empty; only checkboxes and radio buttons really care what the default checked value is.

Specified by:
setDefaultChecked in interface SubmittableElement
Overrides:
setDefaultChecked in class HtmlInput
Parameters:
defaultChecked - The default checked state to use when this element gets reset, if applicable.
See Also:
SubmittableElement.setDefaultChecked(boolean)

setDefaultValue

public void setDefaultValue(java.lang.String defaultValue)
Sets the default value to use when this element gets reset, if applicable. Also sets the value attribute when emulating Netscape browsers. Also sets the value to the new default value.

Specified by:
setDefaultValue in interface SubmittableElement
Overrides:
setDefaultValue in class HtmlInput
Parameters:
defaultValue - The default value to use when this element gets reset, if applicable.
See Also:
SubmittableElement.setDefaultValue(String)


Copyright © 2003-2016 AppPerfect Corporation. All Rights Reserved.