com.sleepycat.je.txn
Class TxnPrepare
java.lang.Object
com.sleepycat.je.txn.TxnEnd
com.sleepycat.je.txn.TxnPrepare
- All Implemented Interfaces:
- Loggable
public class TxnPrepare
- extends TxnEnd
- implements Loggable
This class writes out a transaction prepare record.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TxnPrepare
public TxnPrepare(long id,
Xid xid)
TxnPrepare
public TxnPrepare()
- For constructing from the log.
getXid
public Xid getXid()
getTagName
protected String getTagName()
- Specified by:
getTagName in class TxnEnd
getLogSize
public int getLogSize()
- Specified by:
getLogSize in interface Loggable- Overrides:
getLogSize in class TxnEnd
- Returns:
- number of bytes used to store this object.
- See Also:
Loggable.getLogSize()
writeToLog
public void writeToLog(ByteBuffer logBuffer)
- Description copied from interface:
Loggable
- Serialize this object into the buffer.
- Specified by:
writeToLog in interface Loggable- Overrides:
writeToLog in class TxnEnd
- Parameters:
logBuffer - is the destination buffer- See Also:
Loggable.writeToLog(java.nio.ByteBuffer)
readFromLog
public void readFromLog(ByteBuffer logBuffer,
int entryVersion)
- Description copied from interface:
Loggable
- Initialize this object from the data in itemBuf.
- Specified by:
readFromLog in interface Loggable- Overrides:
readFromLog in class TxnEnd
- See Also:
Loggable.readFromLog(java.nio.ByteBuffer, int)
dumpLog
public void dumpLog(StringBuilder sb,
boolean verbose)
- Description copied from interface:
Loggable
- Write the object into the string buffer for log dumping. Each object
should be dumped without indentation or new lines and should be valid
XML.
- Specified by:
dumpLog in interface Loggable- Overrides:
dumpLog in class TxnEnd
- Parameters:
sb - destination string bufferverbose - if true, dump the full, verbose version- See Also:
Loggable.dumpLog(java.lang.StringBuilder, boolean)
logicalEquals
public boolean logicalEquals(Loggable other)
- Specified by:
logicalEquals in interface Loggable
- Returns:
- true if these two loggable items are logically the same.
Used for replication testing.
- See Also:
Always return false, this item should never be compared.
Copyright (c) 2004-2010 Oracle. All rights reserved.