|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sleepycat.je.log.FileHeader
public class FileHeader
A FileHeader embodies the header information at the beginning of each log file.
Constructor Summary | |
---|---|
FileHeader()
For logging only. |
|
FileHeader(long fileNum,
long lastEntryInPrevFileOffset)
|
Method Summary | |
---|---|
void |
dumpLog(java.lang.StringBuffer sb,
boolean verbose)
Write the object into the string buffer for log dumping. |
static int |
entrySize()
A header is always a known size. |
(package private) long |
getLastEntryInPrevFileOffset()
|
int |
getLogSize()
|
int |
getLogVersion()
|
long |
getTransactionId()
|
void |
readFromLog(java.nio.ByteBuffer logBuffer,
byte entryTypeVersion)
Initialize this object from the data in itemBuf. |
java.lang.String |
toString()
Print in xml format |
(package private) boolean |
validate(java.lang.String fileName,
long expectedFileNum)
|
void |
writeToLog(java.nio.ByteBuffer logBuffer)
Serialize this object into the buffer. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
FileHeader(long fileNum, long lastEntryInPrevFileOffset)
public FileHeader()
Method Detail |
---|
public int getLogVersion()
boolean validate(java.lang.String fileName, long expectedFileNum) throws DatabaseException
DatabaseException
- if the header isn't valid.long getLastEntryInPrevFileOffset()
public static int entrySize()
public int getLogSize()
getLogSize
in interface Loggable
Loggable.getLogSize()
public void writeToLog(java.nio.ByteBuffer logBuffer)
Loggable
writeToLog
in interface Loggable
logBuffer
- is the destination bufferSerialize this object into the buffer. Update cksum with all
the bytes used by this object
public void readFromLog(java.nio.ByteBuffer logBuffer, byte entryTypeVersion) throws LogException
Loggable
readFromLog
in interface Loggable
itemBuf
- the source buffer
LogException
Initialize this object from the data in itemBuf.
public void dumpLog(java.lang.StringBuffer sb, boolean verbose)
Loggable
dumpLog
in interface Loggable
sb
- destination string bufferverbose
- if true, dump the full, verbose versionLoggable.dumpLog(java.lang.StringBuffer, boolean)
public long getTransactionId()
getTransactionId
in interface Loggable
Loggable.getTransactionId()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |