org.exist.numbering
Class DLN

java.lang.Object
  extended byorg.exist.numbering.DLNBase
      extended byorg.exist.numbering.DLN
All Implemented Interfaces:
java.lang.Comparable

public class DLN
extends DLNBase

Represents a node id in the form of a dynamic level number (DLN). DLN's are hierarchical ids, which borrow from Dewey's decimal classification. Examples for node ids: 1, 1.1, 1.2, 1.2.1, 1.2.2, 1.3. In this case, 1 represents the root node, 1.1 is the first node on the second level, 1.2 the second, and so on.


Field Summary
 
Fields inherited from class org.exist.numbering.DLNBase
bitIndex, bits, BITS_PER_UNIT, PER_COMPONENT_SIZE, UNIT_SHIFT
 
Constructor Summary
  DLN()
           
protected DLN(byte[] data, int nbits)
           
  DLN(DLN other)
           
  DLN(int id)
           
  DLN(int[] id)
           
  DLN(int units, byte[] data, int startOffset)
           
  DLN(VariableByteInput is)
           
 
Method Summary
 DLN getParentId()
           
static void main(java.lang.String[] args)
           
 DLN newChild()
          Returns a new DLN representing the first child node of this node.
 DLN nextSibling()
          Returns a new DLN representing the next following sibling of this node.
 void write(VariableByteOutputStream os)
          Write the node id to a VariableByteOutputStream.
 
Methods inherited from class org.exist.numbering.DLNBase
addLevelId, bitWidth, compareTo, compareTo, debug, getLevelCount, getLevelId, getLevelIds, getUnitsRequired, incrementLevelId, lastLevelOffset, serialize, setCurrentLevelId, setLevelId, size, startsWith, toBitString, toString, units
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DLN

public DLN()

DLN

public DLN(int[] id)

DLN

public DLN(int id)

DLN

public DLN(DLN other)

DLN

public DLN(int units,
           byte[] data,
           int startOffset)

DLN

public DLN(VariableByteInput is)
    throws java.io.IOException

DLN

protected DLN(byte[] data,
              int nbits)
Method Detail

newChild

public DLN newChild()
Returns a new DLN representing the first child node of this node.

Returns:
new child node id

nextSibling

public DLN nextSibling()
Returns a new DLN representing the next following sibling of this node.

Returns:
new sibling node id.

getParentId

public DLN getParentId()

write

public void write(VariableByteOutputStream os)
           throws java.io.IOException
Write the node id to a VariableByteOutputStream.

Parameters:
os -
Throws:
java.io.IOException

main

public static void main(java.lang.String[] args)


<oXygen/> XML Editor provides support for editing and debugging XQuery expressions against the eXist XML Database.