java.lang.Object | +--gnu.xml.dom.DomNode | +--gnu.xml.dom.DomDocumentAll Implemented Interfaces:
Constructs a Document node, associating it with an instance of the DomImpl class. |
DomDocument(DOMImplementation impl) Constructs a Document node, associating it with the specified implementation. |
appendChild(Node newChild) DOM L1 Appends the specified node to this node's list of children, enforcing the constraints that there be only one root element and one document type child. | |
createAttribute(java.lang.String name) DOM L1 Returns a newly created attribute with the specified name. | |
createAttributeNS(java.lang.String namespaceURI, java.lang.String name) DOM L2 Returns a newly created attribute with the specified name and namespace information. | |
createCDATASection(java.lang.String value) DOM L1 Returns a newly created CDATA section node with the specified value. | |
createCDATASection(char buf[] , int off, int len) Returns a newly created CDATA section node with the specified value. | |
createComment(java.lang.String value) DOM L1 Returns a newly created comment node with the specified value. | |
DOM L1 Returns a newly created document fragment. | |
createElement(java.lang.String name) DOM L1 Returns a newly created element with the specified name. | |
createElementNS(java.lang.String namespaceURI, java.lang.String name) DOM L2 Returns a newly created element with the specified name and namespace information. | |
createEntityReference(java.lang.String name) DOM L1 Returns a newly created reference to the specified entity. | |
NodeIterator | createNodeIterator(Node root, int whatToShow, NodeFilter filter, boolean expandEntities) DOM L2 (Traversal) Returns a newly created node iterator. |
createProcessingInstruction(java.lang.String target, java.lang.String data) DOM L1 Returns a newly created processing instruction. | |
createTextNode(java.lang.String value) DOM L1 Returns a newly created text node with the specified value. | |
createTextNode(char buf[] , int off, int len) Returns a newly created text node with the specified value. | |
TreeWalker | createTreeWalker(Node root, int whatToShow, NodeFilter filter, boolean entityReferenceExpansion) |
DOM L1 Returns the document's DocumentType, or null. | |
DOM L1 Returns the document's root element, or null. | |
getElementById(java.lang.String id) DOM L1 (relocated in DOM L2) Returns the element with the specified "ID" attribute, or null. | |
DOM L1 Returns the document's DOMImplementation. | |
java.lang.String | DOM L1 Returns the constant "#document". |
short | DOM L1 Returns the constant DOCUMENT_NODE. |
importNode(Node copiedNode, boolean deep) DOM L2 Makes a copy of the specified node, with all nodes "owned" by this document and with children optionally copied. | |
insertBefore(Node newChild, Node refChild) DOM L1 Inserts the specified node in this node's list of children, enforcing the constraints that there be only one root element and one document type child. | |
boolean | Returns true if certain expensive checks are performed. |
replaceChild(Node newChild, Node refChild) DOM L1 Replaces the specified node in this node's list of children, enforcing the constraints that there be only one root element and one document type child. | |
void | setCheckingCharacters(boolean value) Controls whether certain expensive checks, duplicating those that conformant XML parsers must perform, are made. |
static void | verifyXmlName(java.lang.String name) Throws a DOM exception if the specified name is not a legal XML 1.0 name. |
public DomDocument()
setCheckingCharacters
protected DomDocument(DOMImplementation impl)
DomImpl
setCheckingCharacters
public Node appendChild(Node newChild)
public Attr createAttribute(java.lang.String name)
public Attr createAttributeNS(java.lang.String namespaceURI, java.lang.String name)
public CDATASection createCDATASection(char buf[] , int off, int len)
public CDATASection createCDATASection(java.lang.String value)
public Comment createComment(java.lang.String value)
public DocumentFragment createDocumentFragment()
public Element createElement(java.lang.String name)
public Element createElementNS(java.lang.String namespaceURI, java.lang.String name)
public EntityReference createEntityReference(java.lang.String name)
DomNode.makeReadonly
public NodeIterator createNodeIterator(Node root, int whatToShow, NodeFilter filter, boolean expandEntities)
DomIterator
public ProcessingInstruction createProcessingInstruction(java.lang.String target, java.lang.String data)
public Text createTextNode(char buf[] , int off, int len)
public Text createTextNode(java.lang.String value)
public TreeWalker createTreeWalker(Node root, int whatToShow, NodeFilter filter, boolean entityReferenceExpansion)
public final DocumentType getDoctype()
public final Element getDocumentElement()
public Element getElementById(java.lang.String id)
public final DOMImplementation getImplementation()
public final String getNodeName()
public final short getNodeType()
public Node importNode(Node copiedNode, boolean deep)
public Node insertBefore(Node newChild, Node refChild)
public final boolean isCheckingCharacters()
public Node replaceChild(Node newChild, Node refChild)
public final void setCheckingCharacters(boolean value)
public static void verifyXmlName(java.lang.String name)
- INVALID_CHARACTER_ERR if the name isn't
legal as an XML name.