Method Summary |
|
public static void | main(String[] args) |
final public static int | readInt(DataInput in) Read an integer previously written by writeInt(). |
final public static int | readInt(InputStream in) Read an integer previously written by writeInt(). |
final public static int | readInt(byte[] data, int offset) |
final public static int | readIntAndReturnIntPlusOverhead(byte[] data, int offset) Return the compressed Int value + stored size of the length + 1
Given offset in array to beginning of compressed int, return the
value of the compressed int + the number of bytes used to store the
length.
So 1 byte lengths will return: length + 1 + 1
So 2 byte lengths will return: length + 2 + 1
So 4 byte lengths will return: length + 4 + 1
Note that this routine will not work for lengths MAX_INT - (MAX_INT - 5).
This routine is currently used by the StorePage code to skip fields
as efficiently as possible. |
final public static long | readLong(DataInput in) Read a long previously written by writeLong(). |
final public static long | readLong(InputStream in) Read a long previously written by writeLong(). |
final public static long | readLong(byte[] data, int offset) |
final public static int | sizeInt(int value) |
final public static int | sizeLong(long value) |
final public static int | skipInt(DataInput in) Skip an integer previously written by writeInt(). |
final public static int | skipInt(InputStream in) Skip an integer previously written by writeInt(). |
final public static int | skipLong(DataInput in) Skip a long previously written by writeLong(). |
final public static int | skipLong(InputStream in) Skip a long previously written by writeLong(). |
final public static int | writeInt(DataOutput out, int value) Write a compressed integer only supporting signed values. |
final public static int | writeInt(OutputStream out, int value) Write a compressed integer directly to an OutputStream. |
final public static int | writeLong(DataOutput out, long value) Write a compressed long only supporting signed values. |
final public static int | writeLong(OutputStream out, long value) Write a compressed integer only supporting signed values. |