public class XMLDocument extends Document
XMLDocument.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 |
|---|
XMLDocument()
Creates a new instance.
|
XMLDocument(WebWindow enclosingWindow)
Creates a new instance, with associated XmlPage.
|
| Modifier and Type | Method and Description |
|---|---|
Object |
createCDATASection(String data)
Creates a new createCDATASection.
|
Object |
createProcessingInstruction(String target,
String data)
Creates a new ProcessingInstruction.
|
Object |
getElementById(String id)
Returns the element with the specified ID, as long as it is an HTML element;
null otherwise. |
HTMLCollection |
getElementsByTagName(String tagName)
Returns all the descendant elements with the specified tag name.
|
protected void |
initParentScope(DomNode domNode,
SimpleScriptable scriptable)
Initialize the parent scope of a newly created scriptable.
|
boolean |
isAsync()
Returns Whether or not to send the request to the server asynchronously.
|
boolean |
load(String xmlSource)
Loads an XML document from the specified location.
|
boolean |
loadXML(String strXML)
Loads an XML document using the supplied string.
|
SimpleScriptable |
makeScriptableFor(DomNode domNode)
Builds a new the JavaScript object that corresponds to the specified object.
|
void |
setAsync(boolean async)
Sets the
async attribute. |
adoptNode, captureEvents, close, createAttribute, createComment, createDocumentFragment, createElement, createElementNS, createEvent, createNodeIterator, createNSResolver, createRange, createTextNode, createTreeWalker, elementFromPoint, evaluate, execCommand, forceDocumentMode, get, getActiveElement, getAlinkColor, getAnchors, getApplets, getBgColor, getBody, getCharacterSet, getCharset, getChildElementCount, getChildren, getCompatMode, getContentType, getCookie, getCurrentScript, getDefaultCharset, getDefaultView, getDesignMode, getDoctype, getDocumentElement, getDocumentMode, getDocumentURI, getDomain, getElementsByClassName, getElementsByName, getElementsByTagNameNS, getEmbeds, getFgColor, getFirstElementChild, getFonts, getForms, getFrames, getHead, getHidden, getImages, getImplementation, getInputEncoding, getLastElementChild, getLastModified, getLinkColor, getLinks, getLocation, getOnabort, getOnactivate, getOnafterscriptexecute, getOnanimationend, getOnanimationiteration, getOnanimationstart, getOnauxclick, getOnbeforeactivate, getOnbeforecopy, getOnbeforecut, getOnbeforedeactivate, getOnbeforepaste, getOnbeforescriptexecute, getOnblur, getOncancel, getOncanplay, getOncanplaythrough, getOnchange, getOnclick, getOnclose, getOncontextmenu, getOncopy, getOncuechange, getOncut, getOndblclick, getOndeactivate, getOndrag, getOndragend, getOndragenter, getOndragexit, getOndragleave, getOndragover, getOndragstart, getOndrop, getOndurationchange, getOnemptied, getOnended, getOnerror, getOnfocus, getOnfocusin, getOnfocusout, getOngotpointercapture, getOnhelp, getOninput, getOninvalid, getOnkeydown, getOnkeypress, getOnkeyup, getOnload, getOnloadeddata, getOnloadedmetadata, getOnloadend, getOnloadstart, getOnlostpointercapture, getOnmousedown, getOnmouseenter, getOnmouseleave, getOnmousemove, getOnmouseout, getOnmouseover, getOnmouseup, getOnmousewheel, getOnmozfullscreenchange, getOnmozfullscreenerror, getOnmozpointerlockchange, getOnmozpointerlockerror, getOnmscontentzoom, getOnmsfullscreenchange, getOnmsfullscreenerror, getOnmsgesturechange, getOnmsgesturedoubletap, getOnmsgestureend, getOnmsgesturehold, getOnmsgesturestart, getOnmsgesturetap, getOnmsinertiastart, getOnmsmanipulationstatechanged, getOnmspointercancel, getOnmspointerdown, getOnmspointerenter, getOnmspointerleave, getOnmspointermove, getOnmspointerout, getOnmspointerover, getOnmspointerup, getOnmssitemodejumplistitemremoved, getOnmsthumbnailclick, getOnpaste, getOnpause, getOnplay, getOnplaying, getOnpointercancel, getOnpointerdown, getOnpointerenter, getOnpointerleave, getOnpointerlockchange, getOnpointerlockerror, getOnpointermove, getOnpointerout, getOnpointerover, getOnpointerup, getOnprogress, getOnratechange, getOnreadystatechange, getOnreset, getOnresize, getOnscroll, getOnsearch, getOnseeked, getOnseeking, getOnselect, getOnselectionchange, getOnselectstart, getOnshow, getOnstalled, getOnstop, getOnstoragecommit, getOnsubmit, getOnsuspend, getOntimeupdate, getOntoggle, getOntransitionend, getOnvolumechange, getOnwaiting, getOnwebkitanimationend, getOnwebkitanimationiteration, getOnwebkitanimationstart, getOnwebkitfullscreenchange, getOnwebkitfullscreenerror, getOnwebkittransitionend, getOnwheel, getPage, getPlugins, getReadyState, getReferrer, getRootElement, getScripts, getSelection, getStyleSheets, getTitle, getUniqueID, getURL, getURLUnencoded, getVlinkColor, getXmlEncoding, getXmlVersion, hasFocus, importNode, isXmlStandalone, queryCommandEnabled, queryCommandSupported, querySelector, querySelectorAll, releaseCapture, releaseEvents, setAlinkColor, setBgColor, setCurrentScript, setDesignMode, setDomain, setFgColor, setLinkColor, setLocation, setOnabort, setOnactivate, setOnafterscriptexecute, setOnanimationend, setOnanimationiteration, setOnanimationstart, setOnauxclick, setOnbeforeactivate, setOnbeforecopy, setOnbeforecut, setOnbeforedeactivate, setOnbeforepaste, setOnbeforescriptexecute, setOnblur, setOncancel, setOncanplay, setOncanplaythrough, setOnchange, setOnclick, setOnclose, setOncontextmenu, setOncopy, setOncuechange, setOncut, setOndblclick, setOndeactivate, setOndrag, setOndragend, setOndragenter, setOndragexit, setOndragleave, setOndragover, setOndragstart, setOndrop, setOndurationchange, setOnemptied, setOnended, setOnerror, setOnfocus, setOnfocusin, setOnfocusout, setOngotpointercapture, setOnhelp, setOninput, setOninvalid, setOnkeydown, setOnkeypress, setOnkeyup, setOnload, setOnloadeddata, setOnloadedmetadata, setOnloadend, setOnloadstart, setOnlostpointercapture, setOnmousedown, setOnmouseenter, setOnmouseleave, setOnmousemove, setOnmouseout, setOnmouseover, setOnmouseup, setOnmousewheel, setOnmozfullscreenchange, setOnmozfullscreenerror, setOnmozpointerlockchange, setOnmozpointerlockerror, setOnmscontentzoom, setOnmsfullscreenchange, setOnmsfullscreenerror, setOnmsgesturechange, setOnmsgesturedoubletap, setOnmsgestureend, setOnmsgesturehold, setOnmsgesturestart, setOnmsgesturetap, setOnmsinertiastart, setOnmsmanipulationstatechanged, setOnmspointercancel, setOnmspointerdown, setOnmspointerenter, setOnmspointerleave, setOnmspointermove, setOnmspointerout, setOnmspointerover, setOnmspointerup, setOnmssitemodejumplistitemremoved, setOnmsthumbnailclick, setOnpaste, setOnpause, setOnplay, setOnplaying, setOnpointercancel, setOnpointerdown, setOnpointerenter, setOnpointerleave, setOnpointerlockchange, setOnpointerlockerror, setOnpointermove, setOnpointerout, setOnpointerover, setOnpointerup, setOnprogress, setOnratechange, setOnreadystatechange, setOnreset, setOnresize, setOnscroll, setOnsearch, setOnseeked, setOnseeking, setOnselect, setOnselectionchange, setOnselectstart, setOnshow, setOnstalled, setOnstop, setOnstoragecommit, setOnsubmit, setOnsuspend, setOntimeupdate, setOntoggle, setOntransitionend, setOnvolumechange, setOnwaiting, setOnwebkitanimationend, setOnwebkitanimationiteration, setOnwebkitanimationstart, setOnwebkitfullscreenchange, setOnwebkitfullscreenerror, setOnwebkittransitionend, setOnwheel, setTitle, setVlinkColor, setWindowafter, appendChild, asJavaScriptException, before, cloneNode, compareDocumentPosition, contains, getAttributes, getBaseURI, getChildNodes, getFirstChild, getJavaScriptNode, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParent, getParentElement, getParentNode, getPrefix, getPreviousSibling, getTextContent, hasAttributes, hasChildNodes, insertBefore, insertBeforeImpl, isSameNode, normalize, remove, removeChild, replaceChild, replaceWith, setNodeValue, setTextContentaddEventListener, clearEventListenersContainer, dispatchEvent, executeEventLocally, fireEvent, getEventHandler, getEventListenersContainer, hasEventHandlers, isEventHandlerOnWindow, removeEventListener, setEventHandlerclone, equivalentValues, getBrowserVersion, getDefaultValue, getDomNodeOrDie, getDomNodeOrNull, getPrototype, getScriptableFor, getStartingScope, getWindow, getWindow, getWithPreemption, has, hasInstance, isReadOnlySettable, setCaseSensitive, setDomNode, setDomNode, setHtmlElementdefineFunctionProperties, defineProperty, getClassName, put, setClassName, setParentScopeapplyDescriptorToAttributeBitset, associateValue, avoidObjectDetection, buildDataDescriptor, callMethod, callMethod, checkPropertyChange, checkPropertyDefinition, defineClass, defineClass, defineClass, defineConst, defineConstProperty, defineOwnProperties, defineOwnProperty, defineOwnProperty, defineProperty, defineProperty, defineProperty, defineProperty, delete, delete, delete, deleteProperty, deleteProperty, ensureScriptable, ensureScriptableObject, ensureSymbolScriptable, get, get, get, getAllIds, getArrayPrototype, getAssociatedValue, getAttributes, getAttributes, getAttributes, getAttributes, getAttributes, getClassPrototype, getDefaultValue, getExternalArrayData, getExternalArrayLength, getFunctionPrototype, getGetterOrSetter, getIds, getObjectPrototype, getOwnPropertyDescriptor, getParentScope, getProperty, getProperty, getProperty, getPropertyIds, getPrototype, getSlot, getTopLevelScope, getTopScopeValue, getTypedProperty, getTypedProperty, getTypeOf, has, has, hasProperty, hasProperty, hasProperty, isAccessorDescriptor, isConst, isDataDescriptor, isEmpty, isExtensible, isFalse, isGenericDescriptor, isGetterOrSetter, isSealed, isTrue, preventExtensions, put, put, putConst, putConstProperty, putProperty, putProperty, putProperty, redefineProperty, sameValue, sealObject, setAttributes, setAttributes, setAttributes, setAttributes, setAttributes, setExternalArrayData, setGetterOrSetter, setPrototype, sizepublic XMLDocument()
public XMLDocument(WebWindow enclosingWindow)
enclosingWindow - the windowpublic void setAsync(boolean async)
async attribute.async - Whether or not to send the request to the server asynchronouslypublic boolean isAsync()
async attributepublic boolean load(String xmlSource)
xmlSource - a string containing a URL that specifies the location of the XML filepublic boolean loadXML(String strXML)
strXML - A string containing the XML string to load into this XML document object
This string can contain an entire XML document or a well-formed fragment.public SimpleScriptable makeScriptableFor(DomNode domNode)
makeScriptableFor in class SimpleScriptabledomNode - the DOM node for which a JS object should be createdprotected void initParentScope(DomNode domNode, SimpleScriptable scriptable)
initParentScope in class SimpleScriptabledomNode - the DOM node for the script objectscriptable - the script object to initializepublic HTMLCollection getElementsByTagName(String tagName)
getElementsByTagName in class DocumenttagName - the name to search forpublic Object getElementById(String id)
null otherwise.id - the ID to search fornull otherwisepublic Object createProcessingInstruction(String target, String data)
target - the targetdata - the dataCopyright © 2002–2019 Gargoyle Software Inc.. All rights reserved.