com.neeve.ods
Interface IStoreTransactionLog


public interface IStoreTransactionLog

Represents an ODS store's transaction log.

Each ODS store binding can have at most a single active transaction at any point in time (shared and serialized across all threads operating on the store). The binding maintains a transaction log holding the uncommitted transaction operations. This interface exposes transaction log services accessible to the user. The primary service is the ability to record field level operations performed on store objects.

Threading:
A transaction log is safe for concurrent access by multiple threads.

Method Summary
 void clear()
          Clear a transaction log.
 boolean hasUncommitted()
          Get if there are uncommitted entries in the log
 void recordFieldUpdate(IStoreObject object, int fieldId, Object fieldVal)
          Record a field update in a transaction log.
 

Method Detail

recordFieldUpdate

void recordFieldUpdate(IStoreObject object,
                       int fieldId,
                       Object fieldVal)
Record a field update in a transaction log.

Parameters:
object - The object whose field update is to be recorded.
fieldId - The field's unique identifier. ODS requires all store objects to uniquely identify their fields using integer identifiers.
fieldVal - The field's old value.
Threading:
This method is safe for concurrent access by multiple threads with itself and other trasnaction log methods.

hasUncommitted

boolean hasUncommitted()
Get if there are uncommitted entries in the log

Threading:
This method is safe for concurrent access by multiple threads with itself and other transaction log methods.

This method returns if there are any uncommitted entries in the transaction log. A transaction log has uncommitted entries if and only if one or more store operations covered by the transaction log (object put, object remove and and object field update) were performed since the last commit.


clear

void clear()
Clear a transaction log.

Threading:
This method is safe for concurrent access by multiple threads with itself and other transaction log methods.

This method clears a transaction log of all its entries.



Copyright © 2015 Neeve Research, LLC. All Rights Reserved.