com.sleepycat.je.log.entry
Class BINDeltaLogEntry

java.lang.Object
  extended by com.sleepycat.je.log.entry.BaseEntry
      extended by com.sleepycat.je.log.entry.SingleItemEntry
          extended by com.sleepycat.je.log.entry.BINDeltaLogEntry
All Implemented Interfaces:
INContainingEntry, LogEntry, Cloneable

public class BINDeltaLogEntry
extends SingleItemEntry
implements INContainingEntry

A BINDeltaLogEntry knows how to create a whole BIN from a delta entry.


Field Summary
 
Fields inherited from class com.sleepycat.je.log.entry.BaseEntry
entryType
 
Constructor Summary
BINDeltaLogEntry(BINDelta delta)
          Construct a log entry for writing to the log.
BINDeltaLogEntry(Class<BINDelta> logClass)
           
 
Method Summary
 DatabaseId getDbId()
           
 IN getIN(DatabaseImpl dbImpl)
           
 long getPrevDeltaLsn()
           
 long getPrevFullLsn()
           
 Object getResolvedItem(DatabaseImpl dbImpl)
          Resolve a BINDelta item by fetching the full BIN and merging the delta.
 
Methods inherited from class com.sleepycat.je.log.entry.SingleItemEntry
dumpEntry, dumpRep, getMainItem, getSize, getTransactionId, logicalEquals, readEntry, writeEntry
 
Methods inherited from class com.sleepycat.je.log.entry.BaseEntry
clone, getLastLoggedSize, getLogType, getNoArgsConstructor, isDeleted, newInstanceOfType, newInstanceOfType, postFetchInit, postLogWork, setLogType, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.sleepycat.je.log.entry.LogEntry
clone, getLastLoggedSize, getLogType, isDeleted, postLogWork, setLogType
 

Constructor Detail

BINDeltaLogEntry

public BINDeltaLogEntry(Class<BINDelta> logClass)
Parameters:
logClass -

BINDeltaLogEntry

public BINDeltaLogEntry(BINDelta delta)
Construct a log entry for writing to the log.

Method Detail

getResolvedItem

public Object getResolvedItem(DatabaseImpl dbImpl)
Resolve a BINDelta item by fetching the full BIN and merging the delta.

Specified by:
getResolvedItem in interface LogEntry
Overrides:
getResolvedItem in class BaseEntry

getIN

public IN getIN(DatabaseImpl dbImpl)
         throws DatabaseException
Specified by:
getIN in interface INContainingEntry
Returns:
the IN held within this log entry.
Throws:
DatabaseException

getDbId

public DatabaseId getDbId()
Specified by:
getDbId in interface INContainingEntry
Specified by:
getDbId in interface LogEntry
Overrides:
getDbId in class SingleItemEntry
Returns:
the ID of the database containing this entry, or null if this entry type is not part of a database.

getPrevFullLsn

public long getPrevFullLsn()
Specified by:
getPrevFullLsn in interface INContainingEntry
Returns:
the LSN of the prior full version of this node, or NULL_LSN if there is no prior full version. Used for counting the prior version as obsolete. If the offset of the LSN is zero, only the file number is known because we read a version 1 log entry.

getPrevDeltaLsn

public long getPrevDeltaLsn()
Specified by:
getPrevDeltaLsn in interface INContainingEntry
Returns:
the LSN of the prior delta version of this node, or NULL_LSN if the prior version is a full version. Used for counting the prior version as obsolete. If the offset of the LSN is zero, only the file number is known because we read a version 1 log entry.


Copyright (c) 2004-2012 Oracle. All rights reserved.