public class HTMLOptionElement extends FormChild
HTMLElement.ProxyDomNode
BEHAVIOR_ID_CLIENT_CAPS, BEHAVIOR_ID_DOWNLOAD, BEHAVIOR_ID_HOMEPAGE
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
Constructor and Description |
---|
HTMLOptionElement() |
Modifier and Type | Method and Description |
---|---|
boolean |
getDefaultSelected()
Returns the value of the
defaultSelected property. |
boolean |
getDisabled()
Returns true if this element is disabled.
|
int |
getIndex()
Returns the
index property. |
String |
getLabel()
Returns the value of the
label property. |
boolean |
getSelected()
Returns the value of the
selected property. |
String |
getText()
Returns the value of the
text property. |
String |
getValue()
Returns the value of the
value property. |
void |
jsConstructor(String newText,
String newValue,
boolean defaultSelected,
boolean selected)
JavaScript constructor.
|
void |
removeAttribute(String name)
Removes the specified attribute.
|
void |
setAttribute(String name,
String value)
Sets an attribute.
|
void |
setDisabled(boolean disabled)
Sets whether or not to disable this element.
|
void |
setLabel(String label)
Sets the value of the
label property. |
void |
setSelected(boolean selected)
Sets the value of the
selected property. |
void |
setText(String newText)
Sets the value of the
text property. |
void |
setValue(String newValue)
Sets the value of the
value property. |
addBehavior, addComponentRequest, blur, clearAttributes, clearComponentRequest, click, compareVersions, createTextRange, doComponentRequest, focus, getAccessKey, getAlign, getAttributeNode, getAttributeNodeNS, getAvailHeight, getAvailWidth, getBoundingClientRect, getBufferDepth, getCh, getChildren, getChOff, getClassList, getClassName_js, getClientHeight, getClientLeft, getClientRects, getClientTop, getClientWidth, getColorDepth, getComponentVersion, getConnectionType, getContentEditable, getCookieEnabled, getCpuClass, getDataset, getDefaultStyleDisplay, getDir, getDomNodeOrDie, getDomNodeOrNull, getElementsByClassName, getHeight, getId, getInnerHTML, getInnerText, getIsContentEditable, getJavaEnabled, getLang, getLanguage, getLocalName, getNodeName, getOffsetHeight, getOffsetLeft, getOffsetParent_js, getOffsetTop, getOffsetWidth, getOnchange, getOnsubmit, getOuterHTML, getParentElement, getParentHTMLElement, getPlatform, getPosX, getPosY, getPrefix, getScrollHeight, getScrollLeft, getScrollTop, getScrollWidth, getSpellcheck, getSystemLanguage, getTabIndex, getTitle, getUniqueID, getUserLanguage, getVAlign, getWidth, getWidthOrHeight, getWithFallback, hasAttribute, insertAdjacentElement, insertAdjacentHTML, insertAdjacentText, isAncestorOfEventTarget, isComponentInstalled, isDisplayNone, isEndTagForbidden, isHomePage, isLowerCaseInOuterHtml, mergeAttributes, navigateHomePage, readAttributes, releaseCapture, removeAttributeNode, removeBehavior, removeNode, scrollIntoView, setAccessKey, setActive, setAlign, setCapture, setCh, setChOff, setClassName_js, setColorAttribute, setContentEditable, setDir, setDomNode, setHomePage, setId, setInnerHTML, setInnerText, setInnerTextImpl, setLang, setLanguage, setOnchange, setOnsubmit, setOuterHTML, setScrollLeft, setScrollTop, setSpellcheck, setTabIndex, setTagUrn, setTextContent, setTitle, setVAlign, setWidthOrHeight, startDownload, toString
createAttributesObject, createEventHandler, get, getAttribute, getAttributeNS, getAttributes, getBaseURI, getChildElementCount, getCurrentStyle, getElementsByTagName, getElementsByTagNameNS, getFirstElementChild, getLastElementChild, getNextElementSibling, getPreviousElementSibling, getRuntimeStyle, getStyle, getTagName, hasAttributeNS, querySelector, querySelectorAll, removeAttributeNS, setAttributeNode, setAttributeNS, setDefaults, setStyle
fireEvent, getOnblur, getOnclick, getOncontextmenu, getOndblclick, getOnerror, getOnfocus, getOnfocusin, getOnfocusout, getOninput, getOnkeydown, getOnkeypress, getOnkeyup, getOnmousedown, getOnmousemove, getOnmouseout, getOnmouseover, getOnmouseup, getOnpropertychange, getOnresize, setOnblur, setOnclick, setOncontextmenu, setOndblclick, setOnerror, setOnfocus, setOnfocusin, setOnfocusout, setOninput, setOnkeydown, setOnkeypress, setOnkeyup, setOnmousedown, setOnmousemove, setOnmouseout, setOnmouseover, setOnmouseup, setOnpropertychange, setOnresize
appendChild, asJavaScriptException, cloneNode, compareDocumentPosition, contains, detachEvent, getChildNodes, getFirstChild, getJavaScriptNode, getLastChild, getNamespaceURI, getNextSibling, getNodeType, getNodeValue, getOwnerDocument, getParent, getParentNode, getPreviousSibling, getTextContent, hasChildNodes, insertBefore, insertBeforeImpl, isSameNode, normalize, remove, removeChild, replaceChild, setNodeValue
addEventListener, clearEventListenersContainer, dispatchEvent, executeEventLocally, fireEvent, getEventHandler, getEventHandlerProp, getEventListenersContainer, hasEventHandlers, removeEventListener, setEventHandler, setEventHandlerProp
clone, equivalentValues, getBrowserVersion, getDefaultValue, getPrototype, getScriptableFor, getStartingScope, getWindow, getWindow, getWithPreemption, has, hasInstance, initParentScope, isReadOnlySettable, makeScriptableFor, setCaseSensitive, setDomNode, setHtmlElement
defineFunctionProperties, defineProperty, getClassName, setClassName, setParentScope
applyDescriptorToAttributeBitset, associateValue, avoidObjectDetection, buildDataDescriptor, callMethod, callMethod, checkPropertyChange, checkPropertyDefinition, defineClass, defineClass, defineClass, defineConst, defineConstProperty, defineOwnProperties, defineOwnProperty, defineOwnProperty, defineProperty, defineProperty, defineProperty, delete, delete, deleteProperty, deleteProperty, ensureScriptable, ensureScriptableObject, get, get, getAllIds, getArrayPrototype, getAssociatedValue, getAttributes, getAttributes, getAttributes, getAttributes, getClassPrototype, getDefaultValue, getExternalArrayData, getExternalArrayLength, getFunctionPrototype, getGetterOrSetter, getIds, getObjectPrototype, getOwnPropertyDescriptor, getParentScope, getProperty, getProperty, getPropertyIds, getPrototype, getSlot, getTopLevelScope, getTopScopeValue, getTypedProperty, getTypedProperty, getTypeOf, has, hasProperty, hasProperty, isAccessorDescriptor, isConst, isDataDescriptor, isEmpty, isExtensible, isFalse, isGenericDescriptor, isGetterOrSetter, isSealed, isTrue, preventExtensions, put, put, putConst, putConstProperty, putProperty, putProperty, redefineProperty, sameValue, sealObject, setAttributes, setAttributes, setAttributes, setAttributes, setExternalArrayData, setGetterOrSetter, setPrototype, size
public void jsConstructor(String newText, String newValue, boolean defaultSelected, boolean selected)
newText
- the textnewValue
- the valuedefaultSelected
- Whether the option is initially selectedselected
- the current selection state of the optionpublic String getValue()
value
property.public void setValue(String newValue)
value
property.newValue
- the value propertypublic String getText()
text
property.public void setText(String newText)
text
property.newText
- the text propertypublic boolean getSelected()
selected
property.public void setSelected(boolean selected)
selected
property.selected
- the new selected propertypublic boolean getDefaultSelected()
defaultSelected
property.public String getLabel()
label
property.public void setLabel(String label)
label
property.label
- the new label propertypublic boolean getDisabled()
getDisabled
in class HTMLElement
public void setDisabled(boolean disabled)
setDisabled
in class HTMLElement
disabled
- True if this is to be disabledpublic int getIndex()
index
property.index
propertypublic void setAttribute(String name, String value)
setAttribute
in class HTMLElement
name
- Name of the attribute to setvalue
- Value to set the attribute topublic void removeAttribute(String name)
removeAttribute
in class Element
name
- the name of the attribute to removeCopyright © 2002–2016 Gargoyle Software Inc.. All rights reserved.