Berkeley DB Java Edition
version 2.0.90

com.sleepycat.je
Class CursorConfig

java.lang.Object
  extended by com.sleepycat.je.CursorConfig
All Implemented Interfaces:
Cloneable

public class CursorConfig
extends Object
implements Cloneable

Specify the attributes of database cursor. An instance created with the default constructor is initialized with the system's default settings.


Field Summary
static CursorConfig DEFAULT
          Default configuration used if null is passed to methods that create a cursor.
static CursorConfig DIRTY_READ
          Deprecated. This has been replaced by READ_UNCOMMITTED to conform to ANSI database isolation terminology.
static CursorConfig READ_COMMITTED
          A convenience instance to configure a cursor for read committed isolation.
static CursorConfig READ_UNCOMMITTED
          A convenience instance to configure read operations performed by the cursor to return modified but not yet committed data.
 
Constructor Summary
CursorConfig()
          An instance created using the default constructor is initialized with the system's default settings.
 
Method Summary
 boolean getDirtyRead()
          Deprecated. This has been replaced by getReadUncommitted() to conform to ANSI database isolation terminology.
 boolean getReadCommitted()
          Return if the cursor is configured for read committed isolation.
 boolean getReadUncommitted()
          Return if read operations performed by the cursor are configured to return modified but not yet committed data.
 void setDirtyRead(boolean dirtyRead)
          Deprecated. This has been replaced by setReadUncommitted(boolean) to conform to ANSI database isolation terminology.
 void setReadCommitted(boolean readCommitted)
          Configure the cursor for read committed isolation.
 void setReadUncommitted(boolean readUncommitted)
          Configure read operations performed by the cursor to return modified but not yet committed data.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT

public static final CursorConfig DEFAULT
Default configuration used if null is passed to methods that create a cursor.


READ_UNCOMMITTED

public static final CursorConfig READ_UNCOMMITTED
A convenience instance to configure read operations performed by the cursor to return modified but not yet committed data.


DIRTY_READ

public static final CursorConfig DIRTY_READ
Deprecated. This has been replaced by READ_UNCOMMITTED to conform to ANSI database isolation terminology.
A convenience instance to configure read operations performed by the cursor to return modified but not yet committed data.


READ_COMMITTED

public static final CursorConfig READ_COMMITTED
A convenience instance to configure a cursor for read committed isolation.

This ensures the stability of the current data item read by the cursor but permits data read by this cursor to be modified or deleted prior to the commit of the transaction.

Constructor Detail

CursorConfig

public CursorConfig()
An instance created using the default constructor is initialized with the system's default settings.

Method Detail

setReadUncommitted

public void setReadUncommitted(boolean readUncommitted)
Configure read operations performed by the cursor to return modified but not yet committed data.

Parameters:
readUncommitted - If true, configure read operations performed by the cursor to return modified but not yet committed data.

getReadUncommitted

public boolean getReadUncommitted()
Return if read operations performed by the cursor are configured to return modified but not yet committed data.

Returns:
If read operations performed by the cursor are configured to return modified but not yet committed data.

setDirtyRead

public void setDirtyRead(boolean dirtyRead)
Deprecated. This has been replaced by setReadUncommitted(boolean) to conform to ANSI database isolation terminology.

Configure read operations performed by the cursor to return modified but not yet committed data.

Parameters:
dirtyRead - If true, configure read operations performed by the cursor to return modified but not yet committed data.


getDirtyRead

public boolean getDirtyRead()
Deprecated. This has been replaced by getReadUncommitted() to conform to ANSI database isolation terminology.

Return if read operations performed by the cursor are configured to return modified but not yet committed data.

Returns:
If read operations performed by the cursor are configured to return modified but not yet committed data.


setReadCommitted

public void setReadCommitted(boolean readCommitted)
Configure the cursor for read committed isolation.

This ensures the stability of the current data item read by the cursor but permits data read by this cursor to be modified or deleted prior to the commit of the transaction.

Parameters:
readCommitted - If true, configure the cursor for read committed isolation.

getReadCommitted

public boolean getReadCommitted()
Return if the cursor is configured for read committed isolation.

Returns:
If the cursor is configured for read committed isolation.

Berkeley DB Java Edition
version 2.0.90

Copyright (c) 1996-2005 Sleepycat Software, Inc. - All rights reserved.