|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Objectorg.exist.dom.NodeImpl
org.exist.dom.StoredNode
public class StoredNode
The base class for all persistent DOM nodes in the database.
| Field Summary | |
|---|---|
static int |
LENGTH_SIGNATURE_LENGTH
|
static long |
UNKNOWN_NODE_IMPL_ADDRESS
|
| Constructor Summary | |
|---|---|
StoredNode(NodeProxy other)
Creates a new StoredNode instance. |
|
StoredNode(short nodeType)
Creates a new StoredNode instance. |
|
StoredNode(short nodeType,
NodeId nodeId)
Creates a new StoredNode instance. |
|
StoredNode(StoredNode other)
Copy constructor: creates a copy of the other node. |
|
| Method Summary | |
|---|---|
boolean |
accept(Iterator iterator,
NodeVisitor visitor)
Visit the current node. |
boolean |
accept(NodeVisitor visitor)
|
void |
clear()
Reset this object to its initial state. |
static StoredNode |
deserialize(byte[] data,
int start,
int len,
DocumentImpl doc)
Read a node from the specified byte array. |
static StoredNode |
deserialize(byte[] data,
int start,
int len,
DocumentImpl doc,
boolean pooled)
Read a node from the specified byte array. |
boolean |
equals(Object obj)
|
int |
getDocId()
|
DocumentImpl |
getDocument()
|
long |
getInternalAddress()
Get the internal storage address of this node |
Node |
getNextSibling()
|
NodeId |
getNodeId()
The method getNodeId |
short |
getNodeType()
|
Document |
getOwnerDocument()
|
Node |
getParentNode()
|
StoredNode |
getParentStoredNode()
|
NodePath |
getPath()
|
NodePath |
getPath(NodePath parentPath)
|
Node |
getPreviousSibling()
|
QName |
getQName()
|
boolean |
isDirty()
Returns true if the node was modified recently and nodes were inserted at the start or in the middle of its children. |
void |
release()
Release all memory resources hold by this node. |
byte[] |
serialize()
|
void |
setDirty(boolean dirty)
|
void |
setInternalAddress(long internalAddress)
Set the internal storage address of this node. |
void |
setNodeId(NodeId dln)
The method setNodeId |
void |
setOwnerDocument(DocumentImpl ownerDocument)
Set the owner document. |
String |
toString()
|
String |
toString(boolean top)
|
| Methods inherited from class java.lang.Object |
|---|
getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final int LENGTH_SIGNATURE_LENGTH
public static final long UNKNOWN_NODE_IMPL_ADDRESS
| Constructor Detail |
|---|
public StoredNode(short nodeType)
StoredNode instance.
nodeType - a short value
public StoredNode(short nodeType,
NodeId nodeId)
StoredNode instance.
nodeType - a short valuenodeId - a NodeId valuepublic StoredNode(StoredNode other)
other - a StoredNode valuepublic StoredNode(NodeProxy other)
StoredNode instance.
other - a NodeProxy value| Method Detail |
|---|
public void clear()
public byte[] serialize()
public static StoredNode deserialize(byte[] data,
int start,
int len,
DocumentImpl doc)
deserialize(byte[], int, int,DocumentImpl,boolean)
method of the corresponding node class.
data - start - len - doc -
public static StoredNode deserialize(byte[] data,
int start,
int len,
DocumentImpl doc,
boolean pooled)
deserialize(byte[], int, int, DocumentImpl, boolean)
method of the corresponding node class. The node will be allocated in the pool
and should be released once it is no longer needed.
data - start - len - doc - public QName getQName()
getQName in interface QNameablepublic boolean equals(Object obj)
equals in class ObjectObject.equals(java.lang.Object)public void setNodeId(NodeId dln)
setNodeId
dln - a NodeId valuepublic NodeId getNodeId()
getNodeId
NodeId valuepublic long getInternalAddress()
public void setInternalAddress(long internalAddress)
internalAddress - The new internalAddress valuepublic boolean isDirty()
public void setDirty(boolean dirty)
public short getNodeType()
getNodeType in interface NodeNode.getNodeType()public Document getOwnerDocument()
getOwnerDocument in interface NodeNode.getOwnerDocument()public DocumentImpl getDocument()
public void setOwnerDocument(DocumentImpl ownerDocument)
ownerDocument - The new ownerDocument valuepublic int getDocId()
public Node getParentNode()
getParentNode in interface NodeNode.getParentNode()public StoredNode getParentStoredNode()
public Node getPreviousSibling()
getPreviousSibling in interface NodeNode.getPreviousSibling()public Node getNextSibling()
getNextSibling in interface NodeNode.getNextSibling()public NodePath getPath()
public NodePath getPath(NodePath parentPath)
public String toString()
toString in class Objectpublic String toString(boolean top)
public void release()
public boolean accept(NodeVisitor visitor)
public boolean accept(Iterator iterator,
NodeVisitor visitor)
Visitable
accept in interface Visitableiterator - an iterator positioned at the current nodevisitor - the visitor to call.
|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||