org.exist.storage
Class Signatures

java.lang.Object
  extended byorg.exist.storage.Signatures

public final class Signatures
extends java.lang.Object

Static methods to deal with the signature of a node stored in the first byte of the node data in the persistent dom.


Field Summary
static int Attr
           
static int ByteContent
           
static int Char
           
static int Comm
           
static int Elem
           
static int IntContent
           
static int NoContent
           
static int Proc
           
static int ShortContent
           
 
Constructor Summary
Signatures()
           
 
Method Summary
static int getLength(int type)
          Returns the storage size of the given type as number of bytes required.
static byte getSizeType(int length)
          Returns one of IntContent, ShortContent, ByteContent or NoContent based on the number of bytes required to store the integer value given in length.
static short getType(byte signature)
          From the signature in byte 0 of the node data, extract the node type and return a constant as defined in Node.
static int read(int type, byte[] data, int pos)
           
static void write(int type, int size, byte[] data, int pos)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

Attr

public static final int Attr
See Also:
Constant Field Values

Proc

public static final int Proc
See Also:
Constant Field Values

Char

public static final int Char
See Also:
Constant Field Values

Comm

public static final int Comm
See Also:
Constant Field Values

Elem

public static final int Elem
See Also:
Constant Field Values

IntContent

public static final int IntContent
See Also:
Constant Field Values

ByteContent

public static final int ByteContent
See Also:
Constant Field Values

NoContent

public static final int NoContent
See Also:
Constant Field Values

ShortContent

public static final int ShortContent
See Also:
Constant Field Values
Constructor Detail

Signatures

public Signatures()
Method Detail

getLength

public static final int getLength(int type)
Returns the storage size of the given type as number of bytes required.


getSizeType

public static final byte getSizeType(int length)
Returns one of IntContent, ShortContent, ByteContent or NoContent based on the number of bytes required to store the integer value given in length.


getType

public static final short getType(byte signature)
From the signature in byte 0 of the node data, extract the node type and return a constant as defined in Node.


read

public static final int read(int type,
                             byte[] data,
                             int pos)

write

public static final void write(int type,
                               int size,
                               byte[] data,
                               int pos)


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