Package com.google.gwt.xml.client
Interface Document
-
-
Field Summary
-
Fields inherited from interface com.google.gwt.xml.client.Node
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description CDATASectioncreateCDATASection(java.lang.String data)This method creates a newCDATASection.CommentcreateComment(java.lang.String data)This method creates a newComment.DocumentFragmentcreateDocumentFragment()This method creates a newDocumentFragment.ElementcreateElement(java.lang.String tagName)This method creates a newElement.ProcessingInstructioncreateProcessingInstruction(java.lang.String target, java.lang.String data)This method creates a newProcessingInstruction.TextcreateTextNode(java.lang.String data)This method creates a newText.ElementgetDocumentElement()This method retrieves the document element.ElementgetElementById(java.lang.String elementId)This method retrieves the unique descendent elements which has an id ofelementId.NodeListgetElementsByTagName(java.lang.String tagname)This method retrieves any descendent elements which have a tag name oftagname.NodeimportNode(Node importedNode, boolean deep)This method imports a node into the currentDocument.-
Methods inherited from interface com.google.gwt.xml.client.Node
appendChild, cloneNode, getAttributes, getChildNodes, getFirstChild, getLastChild, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, hasAttributes, hasChildNodes, insertBefore, normalize, removeChild, replaceChild, setNodeValue
-
-
-
-
Method Detail
-
createCDATASection
CDATASection createCDATASection(java.lang.String data)
This method creates a newCDATASection.- Parameters:
data- the data of the newCDATASection- Returns:
- the newly created
CDATASection
-
createComment
Comment createComment(java.lang.String data)
This method creates a newComment.- Parameters:
data- the data of the newComment- Returns:
- the newly created
Comment
-
createDocumentFragment
DocumentFragment createDocumentFragment()
This method creates a newDocumentFragment.- Returns:
- the newly created
DocumentFragment
-
createElement
Element createElement(java.lang.String tagName)
This method creates a newElement.- Parameters:
tagName- the tag name of the newElement- Returns:
- the newly created
Element
-
createProcessingInstruction
ProcessingInstruction createProcessingInstruction(java.lang.String target, java.lang.String data)
This method creates a newProcessingInstruction.- Parameters:
target- the target of the newProcessingInstructiondata- the data of the newProcessingInstruction- Returns:
- the newly created
ProcessingInstruction
-
createTextNode
Text createTextNode(java.lang.String data)
This method creates a newText.- Parameters:
data- the data of the newText- Returns:
- the newly created
Text
-
getDocumentElement
Element getDocumentElement()
This method retrieves the document element. Each document has at most oneElementas its direct child, and this node is returned if it exists.nullis returned otherwise.- Returns:
- the document element of this
Document
-
getElementById
Element getElementById(java.lang.String elementId)
This method retrieves the unique descendent elements which has an id ofelementId. Note the attribute which is used as an ID must be supplied in the DTD of the document. It is not sufficient to give theElementto be retrieved an attribute named 'id'.- Returns:
- the
Elementwhich has an id ofelementIdand belongs to thisDocument
-
getElementsByTagName
NodeList getElementsByTagName(java.lang.String tagname)
This method retrieves any descendent elements which have a tag name oftagname.- Returns:
- the
NodeListof elements which has a tag name oftagnameand belong to thisDocument
-
-