@DOMObjectAttribute @DOMNameAttribute(name="HTMLSelectElement") public class HTMLSelectElement extends HTMLElement
Node.Flags
OnAbort, OnAbortDelegate, OnBlur, OnBlurDelegate, OnCancel, OnCancelDelegate, OnCanplay, OnCanplayDelegate, OnCanPlayThrough, OnCanPlayThroughDelegate, OnChange, OnChangeDelegate, OnClick, OnClickDelegate, OnCueChange, OnCueChangeDelegate, OnDblClick, OnDblClickDelegate, OnDurationChange, OnDurationChangeDelegate, OnEmptied, OnEmptiedDelegate, OnEnded, OnEndedDelegate, OnError, OnErrorDelegate, OnFocus, OnFocusDelegate, OnInput, OnInputDelegate, OnInvalid, OnInvalidDelegate, OnKeyDown, OnKeyDownDelegate, OnKeyPress, OnKeyPressDelegate, OnKeyUp, OnKeyUpDelegate, OnLoad, OnLoadDelegate, OnLoadedData, OnLoadedDataDelegate, OnLoadedMetadata, OnLoadedMetadataDelegate, OnLoadStart, OnLoadStartDelegate, OnMouseDown, OnMouseDownDelegate, OnMouseEnter, OnMouseEnterDelegate, OnMouseLeave, OnMouseLeaveDelegate, OnMouseMove, OnMouseMoveDelegate, OnMouseOut, OnMouseOutDelegate, OnMouseOver, OnMouseOverDelegate, OnMouseUp, OnMouseUpDelegate, OnMouseWheel, OnMouseWheelDelegate, OnPause, OnPauseDelegate, OnPlay, OnPlayDelegate, OnPlaying, OnPlayingDelegate, OnProgress, OnProgressDelegate, OnRateChange, OnRateChangeDelegate, OnReset, OnResetDelegate, OnResize, OnResizeDelegate, OnScroll, OnScrollDelegate, OnSeeked, OnSeekedDelegate, OnSeeking, OnSeekingDelegate, OnSelect, OnSelectDelegate, OnShow, OnShowDelegate, OnStalled, OnStalledDelegate, OnSubmit, OnSubmitDelegate, OnSuspend, OnSuspendDelegate, OnTimeUpdate, OnTimeUpdateDelegate, OnToggle, OnToggleDelegate, OnVolumeChange, OnVolumeChangeDelegate, OnWaiting, OnWaitingDelegate
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, flags, nodeDocument, NOTATION_NODE, parent, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
EventMap
PropertyChanged, PropertyChangedDelegate
Constructor and Description |
---|
HTMLSelectElement(com.aspose.html.dom.DOMName name,
Document doc)
Initializes a new instance of the
HTMLSelectElement class. |
Modifier and Type | Method and Description |
---|---|
void |
add(HTMLElement element,
HTMLElement before)
Add a new element to the collection of
OPTION elements for
this SELECT . |
void |
blur()
Removes keyboard focus from this element.
|
void |
focus()
Gives keyboard focus to this element.
|
boolean |
getDisabled()
The control is unavailable in this context.
|
HTMLFormElement |
getForm()
The number of options in this
SELECT . |
int |
getLength()
The number of options in this
SELECT . |
boolean |
getMultiple()
If true, multiple
OPTION elements may be selected in this SELECT . |
java.lang.String |
getName()
Form control or object name when submitted with a form.
|
IHTMLOptionsCollection |
getOptions()
The collection of
OPTION elements contained by this
element. |
int |
getSelectedIndex()
The ordinal index of the selected option, starting from 0.
|
int |
getSize()
Number of visible rows.
|
int |
getTabIndex()
Index that represents the element's position in the tabbing order.
|
java.lang.String |
getType()
The type of this form control.
|
java.lang.String |
getValue()
The current form control value (i.e. the value of the currently
selected option), if multiple options are selected this is the value
of the first selected option.
|
void |
remove(int index)
Remove an element from the collection of
OPTION elements
for this SELECT . |
void |
setDisabled(boolean value)
The control is unavailable in this context.
|
void |
setLength(int value)
The number of options in this
SELECT . |
void |
setMultiple(boolean value)
If true, multiple
OPTION elements may be selected in this SELECT . |
void |
setName(java.lang.String value)
Form control or object name when submitted with a form.
|
void |
setSelectedIndex(int value)
The ordinal index of the selected option, starting from 0.
|
void |
setSize(int value)
Number of visible rows.
|
void |
setTabIndex(int value)
Index that represents the element's position in the tabbing order.
|
void |
setValue(java.lang.String value)
The current form control value (i.e. the value of the currently
selected option), if multiple options are selected this is the value
of the first selected option.
|
getAttributeOrDefault, getAttributeOrDefault, getAttributeOrDefault, getAttributeOrDefault, getAttributeOrDefault, getAttributeOrDefault, getAttributeOrDefault, getAttributeOrDefault, getAttributeOrDefault, getAttributeOrDefault, getAttributeOrDefault, getChildOfType, getClassName_Rename_Namesake, getDir, getId_Rename_Namesake, getLang, getParentOfType, getRowIndexInScopeOfCollection, getStyle, getTitle, setAttribute, setAttribute, setAttribute, setClassName_Rename_Namesake, setDir, setId_Rename_Namesake, setLang, setTitle, toggleAttribute
attachShadow, dispose, equals, getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getAttributes, getChildElementCount, getChildren, getClassName, getComputedStyle, getComputedStyle, getData, getElementsByClassName, getElementsByTagName, getElementsByTagNameNS, getFirstElementChild, getId, getInnerHTML, getLastElementChild, getLocalName, getNamespaceURI, getNextElementSibling, getNodeName, getNodeType, getOuterHTML, getPrefix, getPreviousElementSibling, getSchemaTypeInfo, getShadowRoot, getStyleContainer, getTag, getTagName, getTextContent, hasAttribute, hasAttributeNS, hasAttributes, querySelector, querySelectorAll, remove, removeAttribute, removeAttributeNode, removeAttributeNS, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setClassName, setData, setId, setIdAttribute, setIdAttributeNode, setIdAttributeNS, setInnerHTML, setOuterHTML, setTextContent
adoptNode, appendChild, cloneNode, deepClone, finalize, getBaseURI, getChildNodes, getChildNodesInternal, getFirstChild, getLastChild, getNextSibling, getNodeValue, getOwnerDocument, getParentElement, getParentNode, getPreviousSibling, getRegisteredObservers, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceAll, replaceChild, setLocalName, setNamespaceURI, setNodeValue, setParentNode, setPrefix, toString
addEventListener, addEventListener, addEventListener, addEventListener, dispatchEvent, dispose, removeEventListener, removeEventListener, removeEventListener
fireNotifyPropertyChanged, getCurrentValues, getRuntimesBinding, setCurrentValues, setField, setRuntimesBinding
public HTMLSelectElement(com.aspose.html.dom.DOMName name, Document doc)
Initializes a new instance of the HTMLSelectElement
class.
name
- The DOM name.doc
- The document.@DOMNameAttribute(name="type") public java.lang.String getType()
The type of this form control. This is the string "select-multiple" when the multiple attribute is true
and the string "select-one" when false
.
@DOMNameAttribute(name="selectedIndex") public int getSelectedIndex()
The ordinal index of the selected option, starting from 0. The value -1 is returned if no element is selected. If multiple options are selected, the index of the first selected option is returned.
@DOMNameAttribute(name="selectedIndex") public void setSelectedIndex(int value)
The ordinal index of the selected option, starting from 0. The value -1 is returned if no element is selected. If multiple options are selected, the index of the first selected option is returned.
@DOMNameAttribute(name="value") public java.lang.String getValue()
The current form control value (i.e. the value of the currently selected option), if multiple options are selected this is the value of the first selected option.
@DOMNameAttribute(name="value") public void setValue(java.lang.String value)
The current form control value (i.e. the value of the currently selected option), if multiple options are selected this is the value of the first selected option.
@DOMNameAttribute(name="length") public int getLength()
The number of options in this SELECT
.
@DOMNameAttribute(name="length") public void setLength(int value)
The number of options in this SELECT
.
@DOMNameAttribute(name="form") @DOMNullableAttribute public HTMLFormElement getForm()
The number of options in this SELECT
.
Returns the FORM
element containing this control. Returns
null
if this control is not within the context of a
form.
DOMException
- NOT_SUPPORTED_ERR: if setting the length is not allowed by the
implementation.@DOMNameAttribute(name="options") public IHTMLOptionsCollection getOptions()
The collection of OPTION
elements contained by this
element.
@DOMNameAttribute(name="disabled") public boolean getDisabled()
The control is unavailable in this context. See the disabled attribute definition in HTML 4.01.
@DOMNameAttribute(name="disabled") public void setDisabled(boolean value)
The control is unavailable in this context. See the disabled attribute definition in HTML 4.01.
@DOMNameAttribute(name="multiple") public boolean getMultiple()
If true, multiple OPTION
elements may be selected in this SELECT
. See the multiple attribute definition in HTML 4.01.
@DOMNameAttribute(name="multiple") public void setMultiple(boolean value)
If true, multiple OPTION
elements may be selected in this SELECT
. See the multiple attribute definition in HTML 4.01.
@DOMNameAttribute(name="name") public java.lang.String getName()
Form control or object name when submitted with a form. See the name attribute definition in HTML 4.01.
@DOMNameAttribute(name="name") public void setName(java.lang.String value)
Form control or object name when submitted with a form. See the name attribute definition in HTML 4.01.
@DOMNameAttribute(name="size") public int getSize()
Number of visible rows. See the size attribute definition in HTML 4.01.
@DOMNameAttribute(name="size") public void setSize(int value)
Number of visible rows. See the size attribute definition in HTML 4.01.
@DOMNameAttribute(name="tabIndex") public int getTabIndex()
Index that represents the element's position in the tabbing order. See the tabindex attribute definition in HTML 4.01.
@DOMNameAttribute(name="tabIndex") public void setTabIndex(int value)
Index that represents the element's position in the tabbing order. See the tabindex attribute definition in HTML 4.01.
@DOMNameAttribute(name="add") public void add(HTMLElement element, HTMLElement before)
Add a new element to the collection of OPTION
elements for
this SELECT
. This method is the equivalent of the
appendChild
method of the Node
interface if
the before
parameter is null
. It is
equivalent to the insertBefore
method on the parent of
before
in all other cases. This method may have no
effect if the new element is not an OPTION
or an
OPTGROUP
.
element
- The element to add.before
- The element to insert before, or null
for
the tail of the list.DOMException
- NOT_FOUND_ERR: Raised if beforeis not a descendant of the
SELECTelement.
@DOMNameAttribute(name="remove") public void remove(int index)
Remove an element from the collection of OPTION
elements
for this SELECT
. Does nothing if no element has the
given index.
index
- The index of the item to remove, starting from 0.@DOMNameAttribute(name="blur") public void blur()
Removes keyboard focus from this element.
@DOMNameAttribute(name="focus") public void focus()
Gives keyboard focus to this element.