Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.batik.dom
Class AbstractDocument

    java.lang.Object
      org.apache.batik.dom.AbstractNode
          org.apache.batik.dom.AbstractParentNode
              org.apache.batik.dom.AbstractDocument

All Implemented Interfaces:
  Serializable, NodeEventTarget, ExtendedNode, NodeXBL, XBLManagerData, Localizable, Document, DocumentEvent, EventTarget, Node, DocumentTraversal, org.w3c.dom.xpath.XPathEvaluator

Direct Known Subclasses:
  AbstractStylableDocument, GenericDocument

    public abstract class AbstractDocument

extends AbstractParentNode
implements Document, DocumentEvent, DocumentTraversal, Localizable, org.w3c.dom.xpath.XPathEvaluator

This class implements the `Document` interface.

See Also:
  Serialized Form

Nested Class Summary
`protected class` | `AbstractDocument.DocumentConfiguration` DOMConfiguration for this document.
`protected class` | `AbstractDocument.DocumentError` DOMError implementation.
`protected class` | `AbstractDocument.IdSoftRef`
`protected class` | `AbstractDocument.XPathExpr` A compiled XPath expression.
`protected class` | `AbstractDocument.XPathNodeNSResolver` An XPathNSResolver that uses Node.lookupNamespaceURI.

Nested classes/interfaces inherited from class org.apache.batik.dom.AbstractParentNode
`AbstractParentNode.ChildNodes, AbstractParentNode.ElementsByTagName, AbstractParentNode.ElementsByTagNameNS`

Field Summary
`protected DocumentEventSupport` | `documentEventSupport` The DocumentEventSupport.
`protected String` | `documentURI` The document URI.
`protected AbstractDocument.DocumentConfiguration` | `domConfig` The DOMConfiguration object for this document.
`protected Map` | `elementsById` The elementsById lists.
`protected WeakHashMap` | `elementsByTagNames` The ElementsByTagName lists.
`protected WeakHashMap` | `elementsByTagNamesNS` The ElementsByTagNameNS lists.
`protected boolean` | `eventsEnabled` Whether the event dispatching must be done.
`protected DOMImplementation` | `implementation` The DOM implementation.
`protected String` | `inputEncoding` Input encoding of this document.
`protected LocalizableSupport` | `localizableSupport` The localizable support for the error messages.
`protected static String` | `RESOURCES` The error messages bundle class name.
`protected boolean` | `strictErrorChecking` Whether strict error checking is in force.
`protected TraversalSupport` | `traversalSupport` The traversal support.
`protected XBLManager` | `xblManager` The XBL manager for this document.
`protected String` | `xmlEncoding` XML encoding of this document.
`protected boolean` | `xmlStandalone` Whether this document is standalone.
`protected String` | `xmlVersion` XML version of this document.

Fields inherited from class org.apache.batik.dom.AbstractParentNode
`childNodes`

Fields inherited from class org.apache.batik.dom.AbstractNode
`DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, EMPTY_NODE_LIST, eventSupport, managerData, ownerDocument, userData, userDataHandlers`

Fields inherited from interface org.w3c.dom.Node
`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 Summary
`protected` | `AbstractDocument()` Creates a new document.
`` | `AbstractDocument(DocumentType dt, DOMImplementation impl)` Creates a new document.

Method Summary
`void` | `addIdEntry(Element e, String id)`
`Node` | `adoptNode(Node n)` DOM: Implements `Document.adoptNode(Node)`.
`protected void` | `adoptNode1(AbstractNode n)` Helper function for `adoptNode(Node)`.
`boolean` | `canDispatch(String ns, String eventType)` DOM: Implements `DocumentEvent.canDispatch(String,String)`.
`protected boolean` | `checkChars(String s)` Checks that the characters in the given string are all valid content characters.
`protected void` | `checkChildType(Node n, boolean replace)` Checks the validity of a node to be inserted.
`protected boolean` | `checkName(String s)` Checks that the given string is a valid XML name.
`Node` | `cloneNode(boolean deep)` DOM: Implements `Node.cloneNode(boolean)`.
`protected Node` | `copyInto(Node n)` Copy the fields of the current node into the given node.
`protected DOMError` | `createDOMError(String type, short severity, String key, Object[] args, Node related, Exception e)` Creates a DOMError object with the given parameters.
`Event` | `createEvent(String eventType)` DOM: Implements `DocumentEvent.createEvent(String)`.
`org.w3c.dom.xpath.XPathExpression` | `createExpression(String expression, org.w3c.dom.xpath.XPathNSResolver resolver)` DOM: Implements `XPathEvaluator.createExpression(String,XPathNSResolver)`.
`NodeIterator` | `createNodeIterator(Node root, int whatToShow, NodeFilter filter, boolean entityReferenceExpansion)` DOM: Implements `DocumentTraversal.createNodeIterator(Node,int,NodeFilter,boolean)`.
`org.w3c.dom.xpath.XPathNSResolver` | `createNSResolver(Node n)` DOM: Implements `XPathEvaluator.createNSResolver(Node)`.
`TreeWalker` | `createTreeWalker(Node root, int whatToShow, NodeFilter filter, boolean entityReferenceExpansion)` DOM: Implements `DocumentTraversal.createTreeWalker(Node,int,NodeFilter,boolean)`.
`org.w3c.dom.xpath.XPathException` | `createXPathException(short type, String key, Object[] args)` Creates an exception with the appropriate error message.
`protected Node` | `deepCopyInto(Node n)` Deeply copy the fields of the current node into the given node.
`protected Node` | `deepExport(Node n, Document d)` Deeply exports this node to the given document.
`void` | `detachNodeIterator(NodeIterator it)` Detaches the given node iterator from this document.
`Object` | `evaluate(String expression, Node contextNode, org.w3c.dom.xpath.XPathNSResolver resolver, short type, Object result)` DOM: Implements `XPathEvaluator.evaluate(String,Node,XPathNSResolver,short,Object)`.
`protected Node` | `export(Node n, Document d)` Exports this node to the given document.
`String` | `formatMessage(String key, Object[] args)` Implements `Localizable.formatMessage(String,Object[])`.
`Element` | `getChildElementById(Node requestor, String id)` Finds an element that is in the same document fragment as 'requestor' that has 'id'.
`protected AbstractDocument` | `getCurrentDocument()` Returns the current document.
`DocumentType` | `getDoctype()` DOM: Implements `Document.getDoctype()`.
`Element` | `getDocumentElement()` DOM: Implements `Document.getDocumentElement()`.
`String` | `getDocumentURI()` DOM: Implements `Document.getDocumentURI()`.
`DOMConfiguration` | `getDomConfig()` DOM: Implements `Document.getDomConfig()`.
`Element` | `getElementById(String id)` DOM: Implements `Document.getElementById(String)`.
`AbstractParentNode.ElementsByTagName` | `getElementsByTagName(Node n, String ln)` Returns an ElementsByTagName object from the cache, if any.
`AbstractParentNode.ElementsByTagNameNS` | `getElementsByTagNameNS(Node n, String ns, String ln)` Returns an ElementsByTagNameNS object from the cache, if any.
`boolean` | `getEventsEnabled()` Tests whether the event dispatching must be done.
`DOMImplementation` | `getImplementation()` DOM: Implements `Document.getImplementation()`.
`String` | `getInputEncoding()` DOM: Implements `Document.getInputEncoding()`.
`Locale` | `getLocale()` Implements `Localizable.getLocale()`.
`String` | `getNodeName()` DOM: Implements `Node.getNodeName()`.
`short` | `getNodeType()` DOM: Implements `Node.getNodeType()`.
`protected Node` | `getRoot(Node n)`
`boolean` | `getStrictErrorChecking()` DOM: Implements `Document.getStrictErrorChecking()`.
`Element` | `getXblBoundElement()` Get the bound element whose shadow tree this current node resides in.
`NodeList` | `getXblChildNodes()` Get the list of child nodes of this node in the fully flattened tree.
`NodeList` | `getXblDefinitions()` Get the xbl:definition elements currently binding this element.
`Node` | `getXblFirstChild()` Get the first child node of this node in the fully flattened tree.
`Element` | `getXblFirstElementChild()` Get the first element child of this node in the fully flattened tree.
`Node` | `getXblLastChild()` Get the last child node of this node in the fully flattened tree.
`Element` | `getXblLastElementChild()` Get the last element child of this node in the fully flattened tree.
`XBLManager` | `getXBLManager()` Returns the XBLManager used for this document.
`Element` | `getXblNextElementSibling()` Get the first element that follows the current node in the xblParentNode's xblChildNodes list.
`Node` | `getXblNextSibling()` Get the node which directly follows the current node in the xblParentNode's xblChildNodes list.
`Node` | `getXblParentNode()` Get the parent of this node in the fully flattened tree.
`Element` | `getXblPreviousElementSibling()` Get the first element that precedes the current node in the xblParentNode's xblChildNodes list.
`Node` | `getXblPreviousSibling()` Get the node which directly precedes the current node in the xblParentNode's xblChildNodes list.
`NodeList` | `getXblScopedChildNodes()` Get the list of child nodes of this node in the fully flattened tree that are within the same shadow scope.
`Element` | `getXblShadowTree()` Get the shadow tree of this node.
`String` | `getXmlEncoding()` DOM: Implements `Document.getXmlEncoding()`.
`boolean` | `getXmlStandalone()` DOM: Implements `Document.getXmlStandalone()`.
`String` | `getXmlVersion()` DOM: Implements `Document.getXmlVersion()`.
`Node` | `importNode(Node importedNode, boolean deep)` DOM: Implements `Document.importNode(Node,boolean)`.
`Node` | `importNode(Node importedNode, boolean deep, boolean trimId)` Imports the given node into this document.
`abstract boolean` | `isId(Attr node)` Returns whether the given attribute node is an ID attribute.
`void` | `nodeToBeRemoved(Node node)` Notifies this document that a node will be removed.
`void` | `normalizeDocument()` DOM: Implements `Document.normalizeDocument()`.
`protected boolean` | `normalizeDocument(Element e, boolean cdataSections, boolean comments, boolean elementContentWhitepace, boolean namespaceDeclarations, boolean namespaces, boolean splitCdataSections, DOMErrorHandler errorHandler)` Helper function for `normalizeDocument()`.
`void` | `putElementsByTagName(Node n, String ln, AbstractParentNode.ElementsByTagName l)` Puts an ElementsByTagName object in the cache.
`void` | `putElementsByTagNameNS(Node n, String ns, String ln, AbstractParentNode.ElementsByTagNameNS l)` Puts an ElementsByTagNameNS object in the cache.
`void` | `removeIdEntry(Element e, String id)` Remove the mapping for `element` to `id`
`Node` | `renameNode(Node n, String ns, String qn)` DOM: Implements `Document.renameNode(Node,String,String)`.
`void` | `setDoctype(DocumentType dt)` Sets the document type node.
`void` | `setDocumentInputEncoding(String ie)` Sets the input encoding that was used when the document was being parsed.
`void` | `setDocumentURI(String uri)` DOM: Implements `Document.setDocumentURI(String)`.
`void` | `setDocumentXmlEncoding(String xe)` Sets the XML encoding that was found in the XML prolog.
`void` | `setEventsEnabled(boolean b)` Sets the eventsEnabled property.
`void` | `setLocale(Locale l)` Implements `Localizable.setLocale(Locale)`.
`void` | `setStrictErrorChecking(boolean b)` DOM: Implements `Document.setStrictErrorChecking(boolean)`.
`void` | `setTextContent(String s)` DOM: Implements `Node.setTextContent(String)`.
`void` | `setXBLManager(XBLManager m)` Sets the XBLManager used for this document.
`void` | `setXmlStandalone(boolean b)` DOM: Implements `Document.setXmlStandalone(boolean)`.
`void` | `setXmlVersion(String v)` DOM: Implements `Document.setXmlVersion(String)`.
`protected boolean` | `splitCdata(Element e, Node n, DOMErrorHandler errorHandler)` Splits the given CDATA node if required.
`void` | `updateIdEntry(Element e, String oldId, String newId)`

Methods inherited from class org.apache.batik.dom.AbstractParentNode
`appendChild, checkAndRemove, deepExport, fireDOMNodeInsertedEvent, fireDOMNodeInsertedIntoDocumentEvent, fireDOMNodeRemovedEvent, fireDOMNodeRemovedFromDocumentEvent, fireDOMSubtreeModifiedEvent, getChildNodes, getElementsByTagName, getElementsByTagNameNS, getFirstChild, getLastChild, getTextContent, hasChildNodes, insertBefore, nodeAdded, normalize, removeChild, replaceChild`

Methods inherited from class org.apache.batik.dom.AbstractNode
`addEventListener, addEventListenerNS, compareDocumentPosition, compareNamedNodeMaps, compareStrings, createDOMException, dispatchEvent, export, fireDOMCharacterDataModifiedEvent, fireUserDataHandlers, getAttributes, getBaseURI, getBaseURI, getCascadedXMLBase, getEventSupport, getFeature, getLocalName, getManagerData, getNamespaceURI, getNextSibling, getNodeValue, getOwnerDocument, getParentNode, getParentNodeEventTarget, getPrefix, getPreviousSibling, getUserData, hasAttributes, hasEventListenerNS, initializeEventSupport, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespacePrefix, lookupNamespaceURI, lookupPrefix, newNode, removeEventListener, removeEventListenerNS, setManagerData, setNextSibling, setNodeName, setNodeValue, setOwnerDocument, setParentNode, setPrefix, setPreviousSibling, setSpecified, setUserData, willTriggerNS`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface org.w3c.dom.Document
`createAttribute, createAttributeNS, createCDATASection, createComment, createDocumentFragment, createElement, createElementNS, createEntityReference, createProcessingInstruction, createTextNode, getElementsByTagName, getElementsByTagNameNS`

Methods inherited from interface org.w3c.dom.Node
`appendChild, compareDocumentPosition, getAttributes, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getTextContent, getUserData, hasAttributes, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setNodeValue, setPrefix, setUserData`

Methods inherited from interface org.apache.batik.dom.ExtendedNode
`isReadonly, setReadonly`

Field Detail

### RESOURCES

    protected static final String RESOURCES

  The error messages bundle class name.

  See Also:
    Constant Field Values

### localizableSupport

    protected transient LocalizableSupport localizableSupport

  The localizable support for the error messages.

### implementation

    protected transient DOMImplementation implementation

  The DOM implementation.

### traversalSupport

    protected transient TraversalSupport traversalSupport

  The traversal support.

### documentEventSupport

    protected transient DocumentEventSupport documentEventSupport

  The DocumentEventSupport.

### eventsEnabled

    protected transient boolean eventsEnabled

  Whether the event dispatching must be done.

### elementsByTagNames

    protected transient WeakHashMap elementsByTagNames

  The ElementsByTagName lists.

### elementsByTagNamesNS

    protected transient WeakHashMap elementsByTagNamesNS

  The ElementsByTagNameNS lists.

### inputEncoding

    protected String inputEncoding

  Input encoding of this document.

### xmlEncoding

    protected String xmlEncoding

  XML encoding of this document.

### xmlVersion

    protected String xmlVersion

  XML version of this document.

### xmlStandalone

    protected boolean xmlStandalone

  Whether this document is standalone.

### documentURI

    protected String documentURI

  The document URI.

### strictErrorChecking

    protected boolean strictErrorChecking

  Whether strict error checking is in force.

### domConfig

    protected AbstractDocument.DocumentConfiguration domConfig

  The DOMConfiguration object for this document.

### xblManager

    protected transient XBLManager xblManager

  The XBL manager for this document.

### elementsById

    protected transient Map elementsById

  The elementsById lists. This is keyed on 'id'. the entry is either a IdSoftReference to the element or a List of IdSoftReferences (if there is more than one element owned by this document with a particular 'id').

Constructor Detail

### AbstractDocument

    protected AbstractDocument()

  Creates a new document.

### AbstractDocument

    public AbstractDocument(DocumentType dt,
                            DOMImplementation impl)

  Creates a new document.

Method Detail

### setDocumentInputEncoding

    public void setDocumentInputEncoding(String ie)

  Sets the input encoding that was used when the document was being parsed.

### setDocumentXmlEncoding

    public void setDocumentXmlEncoding(String xe)

  Sets the XML encoding that was found in the XML prolog.

### setLocale

    public void setLocale(Locale l)

  Implements `Localizable.setLocale(Locale)`.

  Specified by:
    `setLocale` in interface `Localizable`
  Parameters:
    `l` - The locale to set.

### getLocale

    public Locale getLocale()

  Implements `Localizable.getLocale()`.

  Specified by:
    `getLocale` in interface `Localizable`

### formatMessage

    public String formatMessage(String key,
                                Object[] args)
                         throws MissingResourceException

  Implements `Localizable.formatMessage(String,Object[])`.

  Specified by:
    `formatMessage` in interface `Localizable`
  Parameters:
    `key` - The key used to retreive the message from the resource bundle.
    `args` - The objects that compose the message.
  Throws:
    `MissingResourceException` - if the key is not in the bundle.

### getEventsEnabled

    public boolean getEventsEnabled()

  Tests whether the event dispatching must be done.

### setEventsEnabled

    public void setEventsEnabled(boolean b)

  Sets the eventsEnabled property.

### getNodeName

    public String getNodeName()

  DOM: Implements `Node.getNodeName()`.

  Specified by:
    `getNodeName` in interface `Node`
  Returns:
    "#document".

### getNodeType

    public short getNodeType()

  DOM: Implements `Node.getNodeType()`.

  Specified by:
    `getNodeType` in interface `Node`
  Returns:
    `Node.DOCUMENT_NODE`

### getDoctype

    public DocumentType getDoctype()

  DOM: Implements `Document.getDoctype()`.

  Specified by:
    `getDoctype` in interface `Document`

### setDoctype

    public void setDoctype(DocumentType dt)

  Sets the document type node.

### getImplementation

    public DOMImplementation getImplementation()

  DOM: Implements `Document.getImplementation()`.

  Specified by:
    `getImplementation` in interface `Document`
  Returns:
    `implementation`

### getDocumentElement

    public Element getDocumentElement()

  DOM: Implements `Document.getDocumentElement()`.

  Specified by:
    `getDocumentElement` in interface `Document`

### importNode

    public Node importNode(Node importedNode,
                           boolean deep)
                    throws DOMException

  DOM: Implements `Document.importNode(Node,boolean)`.

  Specified by:
    `importNode` in interface `Document`
  Throws:
    `DOMException`

### importNode

    public Node importNode(Node importedNode,
                           boolean deep,
                           boolean trimId)

  Imports the given node into this document. It does so deeply if `deep` is set to true. It will not mark ID attributes as IDs if `trimId` is set to true. This is used primarily for the shadow trees of the 'use' elements so they don't clutter the hash table.

  Parameters:
    `importedNode` - The node to import into this document.
    `deep` - Whether to perform a deep importation.
    `trimId` - Whether to make all cloned attributes not be ID attributes.

### cloneNode

    public Node cloneNode(boolean deep)

  DOM: Implements `Node.cloneNode(boolean)`.

  Specified by:
    `cloneNode` in interface `Node`
  Overrides:
    `cloneNode` in class `AbstractNode`

### isId

    public abstract boolean isId(Attr node)

  Returns whether the given attribute node is an ID attribute.

### getElementById

    public Element getElementById(String id)

  DOM: Implements `Document.getElementById(String)`.

  Specified by:
    `getElementById` in interface `Document`

### getChildElementById

    public Element getChildElementById(Node requestor,
                                       String id)

  Finds an element that is in the same document fragment as 'requestor' that has 'id'.

### getRoot

    protected Node getRoot(Node n)

### removeIdEntry

    public void removeIdEntry(Element e,
                              String id)

  Remove the mapping for `element` to `id`

### addIdEntry

    public void addIdEntry(Element e,
                           String id)

### updateIdEntry

    public void updateIdEntry(Element e,
                              String oldId,
                              String newId)

### getElementsByTagName

    public AbstractParentNode.ElementsByTagName getElementsByTagName(Node n,
                                                                     String ln)

  Returns an ElementsByTagName object from the cache, if any.

### putElementsByTagName

    public void putElementsByTagName(Node n,
                                     String ln,
                                     AbstractParentNode.ElementsByTagName l)

  Puts an ElementsByTagName object in the cache.

### getElementsByTagNameNS

    public AbstractParentNode.ElementsByTagNameNS getElementsByTagNameNS(Node n,
                                                                         String ns,
                                                                         String ln)

  Returns an ElementsByTagNameNS object from the cache, if any.

### putElementsByTagNameNS

    public void putElementsByTagNameNS(Node n,
                                       String ns,
                                       String ln,
                                       AbstractParentNode.ElementsByTagNameNS l)

  Puts an ElementsByTagNameNS object in the cache.

### createEvent

    public Event createEvent(String eventType)
                      throws DOMException

  DOM: Implements `DocumentEvent.createEvent(String)`.

  Specified by:
    `createEvent` in interface `DocumentEvent`
  Parameters:
    `eventType` - The `eventType` parameter specifies the name of the DOM Events interface to be supported by the created event object, e.g. `"Event"`, `"MouseEvent"`, `"MutationEvent"` and so on. If the `Event` is to be dispatched via the `EventTarget.dispatchEvent()` method the appropriate event init method must be called after creation in order to initialize the `Event`'s values. As an example, a user wishing to synthesize some kind of `UIEvent` would invoke `DocumentEvent.createEvent("UIEvent")`. The `UIEvent.initUIEventNS()` method could then be called on the newly created `UIEvent` object to set the specific type of user interface event to be dispatched, DOMActivate for example, and set its context information, e.g. `UIEvent.detail` in this example.

    Note: For backward compatibility reason, "UIEvents", "MouseEvents", "MutationEvents", and "HTMLEvents" feature names are valid values for the parameter `eventType` and represent respectively the interfaces "UIEvent", "MouseEvent", "MutationEvent", and "Event".

  Returns:
    The newly created event object.
  Throws:
    `DOMException` - NOT_SUPPORTED_ERR: Raised if the implementation does not support the `Event` interface requested.

### canDispatch

    public boolean canDispatch(String ns,
                               String eventType)

  DOM: Implements `DocumentEvent.canDispatch(String,String)`.

  Specified by:
    `canDispatch` in interface `DocumentEvent`
  Parameters:
    `ns` - Specifies the `Event.namespaceURI` of the event.
    `eventType` - Specifies the `Event.type` of the event.
  Returns:
    `true` if the implementation can generate and dispatch this event type, `false` otherwise.

### createNodeIterator

    public NodeIterator createNodeIterator(Node root,
                                           int whatToShow,
                                           NodeFilter filter,
                                           boolean entityReferenceExpansion)
                                    throws DOMException

  DOM: Implements `DocumentTraversal.createNodeIterator(Node,int,NodeFilter,boolean)`.

  Specified by:
    `createNodeIterator` in interface `DocumentTraversal`
  Throws:
    `DOMException`

### createTreeWalker

    public TreeWalker createTreeWalker(Node root,
                                       int whatToShow,
                                       NodeFilter filter,
                                       boolean entityReferenceExpansion)
                                throws DOMException

  DOM: Implements `DocumentTraversal.createTreeWalker(Node,int,NodeFilter,boolean)`.

  Specified by:
    `createTreeWalker` in interface `DocumentTraversal`
  Throws:
    `DOMException`

### detachNodeIterator

    public void detachNodeIterator(NodeIterator it)

  Detaches the given node iterator from this document.

### nodeToBeRemoved

    public void nodeToBeRemoved(Node node)

  Notifies this document that a node will be removed.

  Overrides:
    `nodeToBeRemoved` in class `AbstractParentNode`

### getCurrentDocument

    protected AbstractDocument getCurrentDocument()

  Returns the current document.

  Overrides:
    `getCurrentDocument` in class `AbstractNode`

### export

    protected Node export(Node n,
                          Document d)

  Exports this node to the given document.

  Parameters:
    `n` - The clone node.
    `d` - The destination document.

### deepExport

    protected Node deepExport(Node n,
                              Document d)

  Deeply exports this node to the given document.

  Parameters:
    `n` - The clone node.
    `d` - The destination document.

### copyInto

    protected Node copyInto(Node n)

  Copy the fields of the current node into the given node.

  Overrides:
    `copyInto` in class `AbstractNode`
  Parameters:
    `n` - a node of the type of this.

### deepCopyInto

    protected Node deepCopyInto(Node n)

  Deeply copy the fields of the current node into the given node.

  Overrides:
    `deepCopyInto` in class `AbstractParentNode`
  Parameters:
    `n` - a node of the type of this.

### checkChildType

    protected void checkChildType(Node n,
                                  boolean replace)

  Checks the validity of a node to be inserted.

  Overrides:
    `checkChildType` in class `AbstractNode`

### getInputEncoding

    public String getInputEncoding()

  DOM: Implements `Document.getInputEncoding()`.

  Specified by:
    `getInputEncoding` in interface `Document`

### getXmlEncoding

    public String getXmlEncoding()

  DOM: Implements `Document.getXmlEncoding()`.

  Specified by:
    `getXmlEncoding` in interface `Document`

### getXmlStandalone

    public boolean getXmlStandalone()

  DOM: Implements `Document.getXmlStandalone()`.

  Specified by:
    `getXmlStandalone` in interface `Document`

### setXmlStandalone

    public void setXmlStandalone(boolean b)
                          throws DOMException

  DOM: Implements `Document.setXmlStandalone(boolean)`.

  Specified by:
    `setXmlStandalone` in interface `Document`
  Throws:
    `DOMException`

### getXmlVersion

    public String getXmlVersion()

  DOM: Implements `Document.getXmlVersion()`.

  Specified by:
    `getXmlVersion` in interface `Document`

### setXmlVersion

    public void setXmlVersion(String v)
                       throws DOMException

  DOM: Implements `Document.setXmlVersion(String)`.

  Specified by:
    `setXmlVersion` in interface `Document`
  Throws:
    `DOMException`

### getStrictErrorChecking

    public boolean getStrictErrorChecking()

  DOM: Implements `Document.getStrictErrorChecking()`.

  Specified by:
    `getStrictErrorChecking` in interface `Document`

### setStrictErrorChecking

    public void setStrictErrorChecking(boolean b)

  DOM: Implements `Document.setStrictErrorChecking(boolean)`.

  Specified by:
    `setStrictErrorChecking` in interface `Document`

### getDocumentURI

    public String getDocumentURI()

  DOM: Implements `Document.getDocumentURI()`.

  Specified by:
    `getDocumentURI` in interface `Document`

### setDocumentURI

    public void setDocumentURI(String uri)

  DOM: Implements `Document.setDocumentURI(String)`.

  Specified by:
    `setDocumentURI` in interface `Document`

### getDomConfig

    public DOMConfiguration getDomConfig()

  DOM: Implements `Document.getDomConfig()`.

  Specified by:
    `getDomConfig` in interface `Document`

### adoptNode

    public Node adoptNode(Node n)
                   throws DOMException

  DOM: Implements `Document.adoptNode(Node)`.

  Specified by:
    `adoptNode` in interface `Document`
  Throws:
    `DOMException`

### adoptNode1

    protected void adoptNode1(AbstractNode n)

  Helper function for `adoptNode(Node)`.

### renameNode

    public Node renameNode(Node n,
                           String ns,
                           String qn)

  DOM: Implements `Document.renameNode(Node,String,String)`.

  Specified by:
    `renameNode` in interface `Document`

### normalizeDocument

    public void normalizeDocument()

  DOM: Implements `Document.normalizeDocument()`. XXX Does not handle the 'entities' parameter yet.

  Specified by:
    `normalizeDocument` in interface `Document`

### normalizeDocument

    protected boolean normalizeDocument(Element e,
                                        boolean cdataSections,
                                        boolean comments,
                                        boolean elementContentWhitepace,
                                        boolean namespaceDeclarations,
                                        boolean namespaces,
                                        boolean splitCdataSections,
                                        DOMErrorHandler errorHandler)

  Helper function for `normalizeDocument()`.

### splitCdata

    protected boolean splitCdata(Element e,
                                 Node n,
                                 DOMErrorHandler errorHandler)

  Splits the given CDATA node if required.

### checkChars

    protected boolean checkChars(String s)

  Checks that the characters in the given string are all valid content characters.

### checkName

    protected boolean checkName(String s)

  Checks that the given string is a valid XML name.

### createDOMError

    protected DOMError createDOMError(String type,
                                      short severity,
                                      String key,
                                      Object[] args,
                                      Node related,
                                      Exception e)

  Creates a DOMError object with the given parameters.

### setTextContent

    public void setTextContent(String s)
                        throws DOMException

  DOM: Implements `Node.setTextContent(String)`.

  Specified by:
    `setTextContent` in interface `Node`
  Overrides:
    `setTextContent` in class `AbstractNode`
  Throws:
    `DOMException`

### setXBLManager

    public void setXBLManager(XBLManager m)

  Sets the XBLManager used for this document.

### getXBLManager

    public XBLManager getXBLManager()

  Returns the XBLManager used for this document.

### createExpression

    public org.w3c.dom.xpath.XPathExpression createExpression(String expression,
                                                              org.w3c.dom.xpath.XPathNSResolver resolver)
                                                       throws DOMException,
                                                              org.w3c.dom.xpath.XPathException

  DOM: Implements `XPathEvaluator.createExpression(String,XPathNSResolver)`.

  Specified by:
    `createExpression` in interface `org.w3c.dom.xpath.XPathEvaluator`
  Throws:
    `DOMException`
    `org.w3c.dom.xpath.XPathException`

### createNSResolver

    public org.w3c.dom.xpath.XPathNSResolver createNSResolver(Node n)

  DOM: Implements `XPathEvaluator.createNSResolver(Node)`.

  Specified by:
    `createNSResolver` in interface `org.w3c.dom.xpath.XPathEvaluator`

### evaluate

    public Object evaluate(String expression,
                           Node contextNode,
                           org.w3c.dom.xpath.XPathNSResolver resolver,
                           short type,
                           Object result)
                    throws org.w3c.dom.xpath.XPathException,
                           DOMException

  DOM: Implements `XPathEvaluator.evaluate(String,Node,XPathNSResolver,short,Object)`.

  Specified by:
    `evaluate` in interface `org.w3c.dom.xpath.XPathEvaluator`
  Throws:
    `org.w3c.dom.xpath.XPathException`
    `DOMException`

### createXPathException

    public org.w3c.dom.xpath.XPathException createXPathException(short type,
                                                                 String key,
                                                                 Object[] args)

  Creates an exception with the appropriate error message.

### getXblParentNode

    public Node getXblParentNode()

  Get the parent of this node in the fully flattened tree.

  Specified by:
    `getXblParentNode` in interface `NodeXBL`
  Overrides:
    `getXblParentNode` in class `AbstractNode`

### getXblChildNodes

    public NodeList getXblChildNodes()

  Get the list of child nodes of this node in the fully flattened tree.

  Specified by:
    `getXblChildNodes` in interface `NodeXBL`
  Overrides:
    `getXblChildNodes` in class `AbstractNode`

### getXblScopedChildNodes

    public NodeList getXblScopedChildNodes()

  Get the list of child nodes of this node in the fully flattened tree that are within the same shadow scope.

  Specified by:
    `getXblScopedChildNodes` in interface `NodeXBL`
  Overrides:
    `getXblScopedChildNodes` in class `AbstractNode`

### getXblFirstChild

    public Node getXblFirstChild()

  Get the first child node of this node in the fully flattened tree.

  Specified by:
    `getXblFirstChild` in interface `NodeXBL`
  Overrides:
    `getXblFirstChild` in class `AbstractNode`

### getXblLastChild

    public Node getXblLastChild()

  Get the last child node of this node in the fully flattened tree.

  Specified by:
    `getXblLastChild` in interface `NodeXBL`
  Overrides:
    `getXblLastChild` in class `AbstractNode`

### getXblPreviousSibling

    public Node getXblPreviousSibling()

  Get the node which directly precedes the current node in the xblParentNode's xblChildNodes list.

  Specified by:
    `getXblPreviousSibling` in interface `NodeXBL`
  Overrides:
    `getXblPreviousSibling` in class `AbstractNode`

### getXblNextSibling

    public Node getXblNextSibling()

  Get the node which directly follows the current node in the xblParentNode's xblChildNodes list.

  Specified by:
    `getXblNextSibling` in interface `NodeXBL`
  Overrides:
    `getXblNextSibling` in class `AbstractNode`

### getXblFirstElementChild

    public Element getXblFirstElementChild()

  Get the first element child of this node in the fully flattened tree.

  Specified by:
    `getXblFirstElementChild` in interface `NodeXBL`
  Overrides:
    `getXblFirstElementChild` in class `AbstractNode`

### getXblLastElementChild

    public Element getXblLastElementChild()

  Get the last element child of this node in the fully flattened tree.

  Specified by:
    `getXblLastElementChild` in interface `NodeXBL`
  Overrides:
    `getXblLastElementChild` in class `AbstractNode`

### getXblPreviousElementSibling

    public Element getXblPreviousElementSibling()

  Get the first element that precedes the current node in the xblParentNode's xblChildNodes list.

  Specified by:
    `getXblPreviousElementSibling` in interface `NodeXBL`
  Overrides:
    `getXblPreviousElementSibling` in class `AbstractNode`

### getXblNextElementSibling

    public Element getXblNextElementSibling()

  Get the first element that follows the current node in the xblParentNode's xblChildNodes list.

  Specified by:
    `getXblNextElementSibling` in interface `NodeXBL`
  Overrides:
    `getXblNextElementSibling` in class `AbstractNode`

### getXblBoundElement

    public Element getXblBoundElement()

  Get the bound element whose shadow tree this current node resides in.

  Specified by:
    `getXblBoundElement` in interface `NodeXBL`
  Overrides:
    `getXblBoundElement` in class `AbstractNode`

### getXblShadowTree

    public Element getXblShadowTree()

  Get the shadow tree of this node.

  Specified by:
    `getXblShadowTree` in interface `NodeXBL`
  Overrides:
    `getXblShadowTree` in class `AbstractNode`

### getXblDefinitions

    public NodeList getXblDefinitions()

  Get the xbl:definition elements currently binding this element.

  Specified by:
    `getXblDefinitions` in interface `NodeXBL`
  Overrides:
    `getXblDefinitions` in class `AbstractNode`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008 Apache Software Foundation. All Rights Reserved.