|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.derby.impl.store.raw.log.LogRecord
public class LogRecord
The log record written out to disk. This log record includes:
The is a holder object that may be setup using the setValue() and re-used rather than creating a new object for each actual log record.
The format of a log record is
Format ID | LOG_RECORD the formatId is written by FormatIdOutputStream when this object is written out by writeObject |
Purpose | The log record described every change to the persistent store |
Upgrade | |
Disk Layout | loggable group(CompressedInt) the loggable's group value xactId(TransactionId) The Transaction this log belongs to op(Loggable) the log operation |
Field Summary | |
---|---|
private static int |
formatLength
|
private int |
group
|
(package private) java.io.ObjectInput |
input
|
private Loggable |
op
|
private TransactionId |
xactId
|
Constructor Summary | |
---|---|
LogRecord()
|
Method Summary | |
---|---|
static int |
formatOverhead()
|
Loggable |
getLoggable()
|
RePreparable |
getRePreparable()
|
static int |
getStoredSize(int group,
TransactionId xactId)
|
TransactionId |
getTransactionId()
|
int |
getTypeFormatId()
Return my format identifier. |
Undoable |
getUndoable()
|
int |
group()
|
boolean |
isAbort()
|
boolean |
isChecksum()
|
boolean |
isCLR()
|
boolean |
isCommit()
|
boolean |
isComplete()
|
boolean |
isFirst()
|
boolean |
isPrepare()
|
static int |
maxGroupStoredSize()
|
static int |
maxTransactionIdStoredSize(TransactionId tranId)
|
void |
readExternal(java.io.ObjectInput in)
Read this in |
boolean |
requiresPrepareLocks()
|
void |
setValue(TransactionId xactId,
Loggable op)
|
void |
skipLoggable()
Skip over the loggable. |
void |
writeExternal(java.io.ObjectOutput out)
Write this out. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private TransactionId xactId
private Loggable op
private int group
transient java.io.ObjectInput input
private static final int formatLength
Constructor Detail |
---|
public LogRecord()
Method Detail |
---|
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
writeExternal
in interface java.io.Externalizable
java.io.IOException
- error writing to log streampublic void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
readExternal
in interface java.io.Externalizable
java.io.IOException
- error reading from log stream
java.lang.ClassNotFoundException
- corrupted log streampublic int getTypeFormatId()
getTypeFormatId
in interface TypedFormat
public void setValue(TransactionId xactId, Loggable op)
public static int formatOverhead()
public static int maxGroupStoredSize()
public static int maxTransactionIdStoredSize(TransactionId tranId)
public static int getStoredSize(int group, TransactionId xactId)
public TransactionId getTransactionId() throws java.io.IOException, java.lang.ClassNotFoundException
java.io.IOException
java.lang.ClassNotFoundException
public Loggable getLoggable() throws java.io.IOException, java.lang.ClassNotFoundException
java.io.IOException
java.lang.ClassNotFoundException
public RePreparable getRePreparable() throws java.io.IOException, java.lang.ClassNotFoundException
java.io.IOException
java.lang.ClassNotFoundException
public void skipLoggable() throws StandardException
StandardException
- if the loggable is not found, log is corruptpublic Undoable getUndoable() throws java.io.IOException, java.lang.ClassNotFoundException
java.io.IOException
java.lang.ClassNotFoundException
public boolean isCLR()
public boolean isFirst()
public boolean isComplete()
public boolean isPrepare()
public boolean requiresPrepareLocks()
public boolean isCommit()
public boolean isAbort()
public int group()
public boolean isChecksum()
|
Built on Thu 2012-03-29 21:53:33+0000, from revision ??? | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |