public class TransactionLogCursor
extends java.lang.Object
TransactionLogRecord objects from a log file.| Constructor and Description |
|---|
TransactionLogCursor(java.io.File file)
Create a TransactionLogCursor that will read from the specified file.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the cursor and the underlying file
|
TransactionLogRecord |
readLog()
Fetch the next TransactionLogRecord from log, recalculating the CRC and checking it against the stored one.
|
TransactionLogRecord |
readLog(boolean skipCrcCheck)
Fetch the next TransactionLogRecord from log.
|
public TransactionLogCursor(java.io.File file)
throws java.io.IOException
file - the file to read logs fromjava.io.IOException - if an I/O error occurs.public TransactionLogRecord readLog() throws java.io.IOException
java.io.IOException - if an I/O error occurs.public TransactionLogRecord readLog(boolean skipCrcCheck) throws java.io.IOException
skipCrcCheck - if set to false, the method will thow an InvalidChecksumException if the CRC on disk does
not match the recalculated one. Otherwise, the CRC is not recalculated nor checked agains the stored one.java.io.IOException - if an I/O error occurs.public void close()
throws java.io.IOException
java.io.IOException - if an I/O error occurs.Copyright © 2006-2021 Bitronix Software. All Rights Reserved.