org.enhydra.xml.lazydom
Class LazyEntityReference

java.lang.Object
  |
  +--org.enhydra.apache.xerces.dom.NodeImpl
        |
        +--org.enhydra.apache.xerces.dom.ChildNode
              |
              +--org.enhydra.apache.xerces.dom.ParentNode
                    |
                    +--org.enhydra.apache.xerces.dom.EntityReferenceImpl
                          |
                          +--org.enhydra.xml.lazydom.LazyEntityReference
All Implemented Interfaces:
Cloneable, EntityReference, EventTarget, LazyNode, LazyParent, Node, NodeList, Serializable

public class LazyEntityReference
extends org.enhydra.apache.xerces.dom.EntityReferenceImpl
implements LazyParent

Lazy text node.

See Also:
Serialized Form

Inner classes inherited from class org.enhydra.apache.xerces.dom.ParentNode
org.enhydra.apache.xerces.dom.ParentNode.UserDataRecord
 
Fields inherited from class org.enhydra.apache.xerces.dom.EntityReferenceImpl
baseURI, name, serialVersionUID
 
Fields inherited from class org.enhydra.apache.xerces.dom.ParentNode
firstChild, fNodeListCache, ownerDocument
 
Fields inherited from class org.enhydra.apache.xerces.dom.ChildNode
nextSibling, previousSibling
 
Fields inherited from class org.enhydra.apache.xerces.dom.NodeImpl
DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_IS_CONTAINED, DOCUMENT_POSITION_PRECEDING, ELEMENT_DEFINITION_NODE, FIRSTCHILD, flags, HASSTRING, ID, IGNORABLEWS, NORMALIZED, OWNED, ownerNode, READONLY, SPECIFIED, SYNCCHILDREN, SYNCDATA, TREE_POSITION_ANCESTOR, TREE_POSITION_DESCENDANT, TREE_POSITION_DISCONNECTED, TREE_POSITION_EQUIVALENT, TREE_POSITION_FOLLOWING, TREE_POSITION_PRECEDING, TREE_POSITION_SAME_NODE
 
Fields inherited from interface org.enhydra.xml.lazydom.LazyNode
DOCUMENT_NODE_ID, NULL_NODE_ID
 
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 LazyEntityReference(LazyDocument ownerDoc, LazyEntityReference template, String name)
          Constructor.
 
Method Summary
 Node appendChild(Node newChild)
           
 void appendChildWhileExpanding(Node child)
          Append a child during node expansion.
 boolean areChildrenExpanded()
          Are the children of this node expanded?
 Node cloneNode(boolean deep)
           
 NodeList getChildNodes()
           
 Node getFirstChild()
           
 Node getLastChild()
           
 Node getNextSibling()
           
 int getNodeId()
          Get the node numeric id number.
 Node getParentNode()
           
 Node getPreviousSibling()
           
 LazyEntityReference getTemplateEntityReference()
          Get the template for this node.
 LazyNode getTemplateNode()
          Get the template node as a LazyNode.
 boolean hasChildNodes()
           
 Node insertBefore(Node newChild, Node refChild)
           
 boolean isParentExpanded()
          Is the parent of this node expanded?
 boolean isTemplateNode()
          Check if this node is a template node.
 void makeTemplateNode(int nodeId)
           
 void normalize()
           
 Node removeChild(Node oldChild)
           
 Node replaceChild(Node newChild, Node oldChild)
           
 void setChildrenExpanded()
          Flag the children as being expanded.
 void setNodeValue(String value)
          Set the node value, invalidating the id.
 void setParentExpanded()
          Flag the parent as being expanded.
 void setParentWhileExpanding(Node parent)
          Set the parent of this node during expansion.
 LazyNode templateClone(Document ownerDocument)
          Create a new node, using this node as the template.
 
Methods inherited from class org.enhydra.apache.xerces.dom.EntityReferenceImpl
getBaseURI, getEntityRefValue, getNodeName, getNodeType, setBaseURI, setReadOnly, synchronizeChildren
 
Methods inherited from class org.enhydra.apache.xerces.dom.ParentNode
checkNormalizationAfterInsert, checkNormalizationAfterRemove, getChildNodesUnoptimized, getLength, getOwnerDocument, getTextContent, getTextContent, hasTextContent, internalInsertBefore, internalRemoveChild, isEqualNode, item, lastChild, lastChild, ownerDocument, setOwnerDocument, setTextContent
 
Methods inherited from class org.enhydra.apache.xerces.dom.ChildNode
parentNode, previousSibling
 
Methods inherited from class org.enhydra.apache.xerces.dom.NodeImpl
addEventListener, changed, changes, compareDocumentPosition, compareTreePosition, dispatchEvent, getAttributes, getContainer, getElementAncestor, getFeature, getLocalName, getNamespaceURI, getNodeNumber, getNodeValue, getPrefix, getReadOnly, getUserData, getUserData, getUserDataRecord, hasAttributes, hasStringValue, hasStringValue, internalIsIgnorableWhitespace, isDefaultNamespace, isFirstChild, isFirstChild, isIdAttribute, isIdAttribute, isIgnorableWhitespace, isNormalized, isNormalized, isOwned, isOwned, isReadOnly, isReadOnly, isSameNode, isSpecified, isSpecified, isSupported, lookupNamespacePrefix, lookupNamespaceURI, lookupPrefix, needsSyncChildren, needsSyncChildren, needsSyncData, needsSyncData, removeEventListener, setPrefix, setUserData, setUserData, synchronizeData, toString
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.w3c.dom.Node
compareDocumentPosition, getAttributes, getBaseURI, getFeature, getLocalName, getNamespaceURI, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getPrefix, getTextContent, getUserData, hasAttributes, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, setPrefix, setTextContent, setUserData
 

Constructor Detail

LazyEntityReference

protected LazyEntityReference(LazyDocument ownerDoc,
                              LazyEntityReference template,
                              String name)
Constructor.
Parameters:
ownerDoc - The document that owns this node.
template - If not-null, get the parameters from this template.
name - The entity name. Will be ignored if template is not-null.
Method Detail

getTemplateEntityReference

public LazyEntityReference getTemplateEntityReference()
Get the template for this node.
See Also:
LazyNode.getTemplateNode()

cloneNode

public Node cloneNode(boolean deep)
Specified by:
cloneNode in interface Node
Overrides:
cloneNode in class org.enhydra.apache.xerces.dom.EntityReferenceImpl
See Also:
Node.cloneNode(boolean)

makeTemplateNode

public void makeTemplateNode(int nodeId)
Specified by:
makeTemplateNode in interface LazyNode

getNodeId

public int getNodeId()
Description copied from interface: LazyNode
Get the node numeric id number.
Specified by:
getNodeId in interface LazyNode
See Also:
LazyNode.getNodeId()

isTemplateNode

public boolean isTemplateNode()
Description copied from interface: LazyNode
Check if this node is a template node.
Specified by:
isTemplateNode in interface LazyNode
See Also:
LazyNode.isTemplateNode()

getTemplateNode

public LazyNode getTemplateNode()
Description copied from interface: LazyNode
Get the template node as a LazyNode.
Specified by:
getTemplateNode in interface LazyNode
See Also:
LazyNode.getTemplateNode()

templateClone

public LazyNode templateClone(Document ownerDocument)
Description copied from interface: LazyNode
Create a new node, using this node as the template.
Specified by:
templateClone in interface LazyNode
See Also:
LazyNode.templateClone(org.w3c.dom.Document)

setNodeValue

public void setNodeValue(String value)
Set the node value, invalidating the id. All node data is modified by this routine.
Specified by:
setNodeValue in interface Node
Overrides:
setNodeValue in class org.enhydra.apache.xerces.dom.NodeImpl
See Also:
Node.setNodeValue(java.lang.String)

isParentExpanded

public boolean isParentExpanded()
Description copied from interface: LazyParent
Is the parent of this node expanded?
Specified by:
isParentExpanded in interface LazyParent
See Also:
LazyParent.isParentExpanded()

setParentExpanded

public void setParentExpanded()
Description copied from interface: LazyParent
Flag the parent as being expanded.
Specified by:
setParentExpanded in interface LazyParent
See Also:
LazyParent.setParentExpanded()

setParentWhileExpanding

public void setParentWhileExpanding(Node parent)
Description copied from interface: LazyParent
Set the parent of this node during expansion. This should also flag the parent as being expanded.
Specified by:
setParentWhileExpanding in interface LazyParent
See Also:
LazyParent.setParentWhileExpanding(org.w3c.dom.Node)

areChildrenExpanded

public boolean areChildrenExpanded()
Description copied from interface: LazyParent
Are the children of this node expanded?
Specified by:
areChildrenExpanded in interface LazyParent
See Also:
LazyParent.areChildrenExpanded()

setChildrenExpanded

public void setChildrenExpanded()
Description copied from interface: LazyParent
Flag the children as being expanded.
Specified by:
setChildrenExpanded in interface LazyParent
See Also:
LazyParent.setChildrenExpanded()

appendChildWhileExpanding

public void appendChildWhileExpanding(Node child)
Description copied from interface: LazyParent
Append a child during node expansion. This should only add the child, not trigger any other expansion.
Specified by:
appendChildWhileExpanding in interface LazyParent
See Also:
LazyParent.appendChildWhileExpanding(org.w3c.dom.Node)

getParentNode

public Node getParentNode()
Specified by:
getParentNode in interface Node
Overrides:
getParentNode in class org.enhydra.apache.xerces.dom.ChildNode
See Also:
Node.getParentNode()

getChildNodes

public NodeList getChildNodes()
Specified by:
getChildNodes in interface Node
Overrides:
getChildNodes in class org.enhydra.apache.xerces.dom.ParentNode
See Also:
Node.getChildNodes()

getFirstChild

public Node getFirstChild()
Specified by:
getFirstChild in interface Node
Overrides:
getFirstChild in class org.enhydra.apache.xerces.dom.ParentNode
See Also:
Node.getFirstChild()

getLastChild

public Node getLastChild()
Specified by:
getLastChild in interface Node
Overrides:
getLastChild in class org.enhydra.apache.xerces.dom.ParentNode
See Also:
Node.getLastChild()

getPreviousSibling

public Node getPreviousSibling()
Specified by:
getPreviousSibling in interface Node
Overrides:
getPreviousSibling in class org.enhydra.apache.xerces.dom.ChildNode
See Also:
Node.getPreviousSibling()

getNextSibling

public Node getNextSibling()
Specified by:
getNextSibling in interface Node
Overrides:
getNextSibling in class org.enhydra.apache.xerces.dom.ChildNode
See Also:
Node.getNextSibling()

insertBefore

public Node insertBefore(Node newChild,
                         Node refChild)
                  throws DOMException
Specified by:
insertBefore in interface Node
Overrides:
insertBefore in class org.enhydra.apache.xerces.dom.ParentNode
See Also:
Node.insertBefore(org.w3c.dom.Node, org.w3c.dom.Node)

replaceChild

public Node replaceChild(Node newChild,
                         Node oldChild)
                  throws DOMException
Specified by:
replaceChild in interface Node
Overrides:
replaceChild in class org.enhydra.apache.xerces.dom.ParentNode
See Also:
Node.replaceChild(org.w3c.dom.Node, org.w3c.dom.Node)

removeChild

public Node removeChild(Node oldChild)
                 throws DOMException
Specified by:
removeChild in interface Node
Overrides:
removeChild in class org.enhydra.apache.xerces.dom.ParentNode
See Also:
Node.removeChild(org.w3c.dom.Node)

appendChild

public Node appendChild(Node newChild)
                 throws DOMException
Specified by:
appendChild in interface Node
Overrides:
appendChild in class org.enhydra.apache.xerces.dom.NodeImpl
See Also:
Node.appendChild(org.w3c.dom.Node)

hasChildNodes

public boolean hasChildNodes()
Specified by:
hasChildNodes in interface Node
Overrides:
hasChildNodes in class org.enhydra.apache.xerces.dom.ParentNode
See Also:
Node.hasChildNodes()

normalize

public void normalize()
Specified by:
normalize in interface Node
Overrides:
normalize in class org.enhydra.apache.xerces.dom.ParentNode
See Also:
Node.normalize()


Copyright © 1999-2002 enhydra.org (Mark Diekhans, David Li, Richard Kunze). All Rights reserved.