|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sleepycat.je.log.LogUtils
This class holds convenience methods for marshalling internal JE data to and from the log.
Field Summary | |
static int |
INT_BYTES
|
static int |
LONG_BYTES
|
static int |
UNSIGNED_INT_BYTES
|
Constructor Summary | |
LogUtils()
|
Method Summary | |
static boolean |
dumpBoolean(ByteBuffer itemBuffer,
StringBuffer sb,
String tag)
|
static int |
getBooleanLogSize()
|
static int |
getByteArrayLogSize(byte[] b)
|
static int |
getIntLogSize()
|
static int |
getLongLogSize()
|
static int |
getStringLogSize(String s)
|
static int |
getTimestampLogSize()
|
static long |
getUnsignedInt(ByteBuffer buf)
Unmarshall the next four bytes which hold an unsigned int into a long. |
static void |
putUnsignedInt(ByteBuffer buf,
long value)
Marshall a long into the next 4 bytes in this buffer. |
static boolean |
readBoolean(ByteBuffer logBuf)
Read a boolean from the log. |
static byte[] |
readByteArray(ByteBuffer logBuf)
Read a byte array from the log. |
static int |
readInt(ByteBuffer logBuf)
Read a int from the log. |
static long |
readLong(ByteBuffer logBuf)
Read a long from the log. |
static String |
readString(ByteBuffer logBuf)
Read a string from the log. |
static Timestamp |
readTimestamp(ByteBuffer logBuf)
Read a timestamp from the log. |
static void |
writeBoolean(ByteBuffer logBuf,
boolean bool)
Write a boolean into the log. |
static void |
writeByteArray(ByteBuffer logBuf,
byte[] b)
Write a byte array into the log. |
static void |
writeInt(ByteBuffer logBuf,
int i)
Write an int into the log. |
static void |
writeLong(ByteBuffer logBuf,
long l)
Write a long into the log. |
static void |
writeString(ByteBuffer logBuf,
String stringVal)
Write a string into the log. |
static void |
writeTimestamp(ByteBuffer logBuf,
Timestamp time)
Write a timestamp into the log. |
static void |
writeUnsignedInt(ByteBuffer logBuf,
long value)
Write a long as an unsigned int. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int INT_BYTES
public static final int LONG_BYTES
public static final int UNSIGNED_INT_BYTES
Constructor Detail |
public LogUtils()
Method Detail |
public static void putUnsignedInt(ByteBuffer buf, long value)
public static void writeUnsignedInt(ByteBuffer logBuf, long value)
public static long getUnsignedInt(ByteBuffer buf)
public static void writeInt(ByteBuffer logBuf, int i)
public static int readInt(ByteBuffer logBuf)
public static int getIntLogSize()
public static void writeLong(ByteBuffer logBuf, long l)
public static long readLong(ByteBuffer logBuf)
public static int getLongLogSize()
public static void writeByteArray(ByteBuffer logBuf, byte[] b)
public static byte[] readByteArray(ByteBuffer logBuf)
public static int getByteArrayLogSize(byte[] b)
public static void writeString(ByteBuffer logBuf, String stringVal)
public static String readString(ByteBuffer logBuf)
public static int getStringLogSize(String s)
public static void writeTimestamp(ByteBuffer logBuf, Timestamp time)
public static Timestamp readTimestamp(ByteBuffer logBuf)
public static int getTimestampLogSize()
public static void writeBoolean(ByteBuffer logBuf, boolean bool)
public static boolean readBoolean(ByteBuffer logBuf)
public static int getBooleanLogSize()
public static boolean dumpBoolean(ByteBuffer itemBuffer, StringBuffer sb, String tag)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |