Main Page | Class Hierarchy | Data Structures | Directories | File List | Data Fields | Related Pages

com::sleepycat::collections::StoredCollections Class Reference


Static Public Member Functions

static Collection configuredCollection (Collection storedCollection, CursorConfig config)
static List configuredList (List storedList, CursorConfig config)
static Map configuredMap (Map storedMap, CursorConfig config)
static Set configuredSet (Set storedSet, CursorConfig config)
static SortedMap configuredSortedMap (SortedMap storedSortedMap, CursorConfig config)
static SortedSet configuredSortedSet (SortedSet storedSortedSet, CursorConfig config)
static Collection dirtyReadCollection (Collection storedCollection)
static List dirtyReadList (List storedList)
static Map dirtyReadMap (Map storedMap)
static Set dirtyReadSet (Set storedSet)
static SortedMap dirtyReadSortedMap (SortedMap storedSortedMap)
static SortedSet dirtyReadSortedSet (SortedSet storedSortedSet)
static Iterator iterator (Iterator storedIterator)

Detailed Description

This class consists exclusively of static methods that operate on or return stored collections and maps, jointly called containers. It contains methods for changing certain properties of a container. Because container properties are immutable, these methods always return a new container instance. This allows stored container instances to be used safely by multiple threads. Creating the new container instance is not expensive and creates only two new objects.

When a container is created with a particular property, all containers and iterators derived from that container will inherit the property. For example, if a read-uncommitted Map is created then calls to its subMap(), values(), entrySet(), and keySet() methods will create read-uncommitted containers also.

Method names beginning with "configured" create a new container with a specified CursorConfig from a given stored container. This allows configuring a container for read-committed isolation, read-uncommitted isolation, or any other property supported by CursorConfig. All operations performed with the resulting container will be performed with the specified cursor configuration.

Definition at line 44 of file StoredCollections.java.


Member Function Documentation

static Collection com::sleepycat::collections::StoredCollections::configuredCollection Collection  storedCollection,
CursorConfig  config
[inline, static]
 

Creates a configured collection from a given stored collection.

Parameters:
storedCollection the base collection.
config is the cursor configuration to be used for all operations performed via the new collection instance; null may be specified to use the default configuration.
Returns:
the configured collection.
Exceptions:
ClassCastException if the given container is not a StoredContainer.

Definition at line 62 of file StoredCollections.java.

Referenced by dirtyReadCollection().

static List com::sleepycat::collections::StoredCollections::configuredList List  storedList,
CursorConfig  config
[inline, static]
 

Creates a configured list from a given stored list.

Note that this method may not be called in the JE product, since the StoredList class is not supported.

Parameters:
storedList the base list.
config is the cursor configuration to be used for all operations performed via the new list instance; null may be specified to use the default configuration.
Returns:
the configured list.
Exceptions:
ClassCastException if the given container is not a StoredContainer.

Definition at line 86 of file StoredCollections.java.

Referenced by dirtyReadList().

static Map com::sleepycat::collections::StoredCollections::configuredMap Map  storedMap,
CursorConfig  config
[inline, static]
 

Creates a configured map from a given stored map.

Parameters:
storedMap the base map.
config is the cursor configuration to be used for all operations performed via the new map instance; null may be specified to use the default configuration.
Returns:
the configured map.
Exceptions:
ClassCastException if the given container is not a StoredContainer.

Definition at line 105 of file StoredCollections.java.

Referenced by dirtyReadMap().

static Set com::sleepycat::collections::StoredCollections::configuredSet Set  storedSet,
CursorConfig  config
[inline, static]
 

Creates a configured set from a given stored set.

Parameters:
storedSet the base set.
config is the cursor configuration to be used for all operations performed via the new set instance; null may be specified to use the default configuration.
Returns:
the configured set.
Exceptions:
ClassCastException if the given container is not a StoredContainer.

Definition at line 124 of file StoredCollections.java.

Referenced by dirtyReadSet().

static SortedMap com::sleepycat::collections::StoredCollections::configuredSortedMap SortedMap  storedSortedMap,
CursorConfig  config
[inline, static]
 

Creates a configured sorted map from a given stored sorted map.

Parameters:
storedSortedMap the base map.
config is the cursor configuration to be used for all operations performed via the new map instance; null may be specified to use the default configuration.
Returns:
the configured map.
Exceptions:
ClassCastException if the given container is not a StoredContainer.

Definition at line 143 of file StoredCollections.java.

Referenced by dirtyReadSortedMap().

static SortedSet com::sleepycat::collections::StoredCollections::configuredSortedSet SortedSet  storedSortedSet,
CursorConfig  config
[inline, static]
 

Creates a configured sorted set from a given stored sorted set.

Parameters:
storedSortedSet the base set.
config is the cursor configuration to be used for all operations performed via the new set instance; null may be specified to use the default configuration.
Returns:
the configured set.
Exceptions:
ClassCastException if the given container is not a StoredContainer.

Definition at line 164 of file StoredCollections.java.

Referenced by dirtyReadSortedSet().

static Collection com::sleepycat::collections::StoredCollections::dirtyReadCollection Collection  storedCollection  )  [inline, static]
 

Deprecated:
This method has been replaced by configuredCollection in order to conform to ANSI database isolation terminology. To obtain a dirty-read collection, pass CursorConfig.READ_UNCOMMITTED

Definition at line 177 of file StoredCollections.java.

References configuredCollection().

static List com::sleepycat::collections::StoredCollections::dirtyReadList List  storedList  )  [inline, static]
 

Deprecated:
This method has been replaced by configuredList in order to conform to ANSI database isolation terminology. To obtain a dirty-read list, pass CursorConfig.READ_UNCOMMITTED

Definition at line 189 of file StoredCollections.java.

References configuredList().

static Map com::sleepycat::collections::StoredCollections::dirtyReadMap Map  storedMap  )  [inline, static]
 

Deprecated:
This method has been replaced by configuredMap in order to conform to ANSI database isolation terminology. To obtain a dirty-read map, pass CursorConfig.READ_UNCOMMITTED

Definition at line 200 of file StoredCollections.java.

References configuredMap().

static Set com::sleepycat::collections::StoredCollections::dirtyReadSet Set  storedSet  )  [inline, static]
 

Deprecated:
This method has been replaced by configuredSet in order to conform to ANSI database isolation terminology. To obtain a dirty-read set, pass CursorConfig.READ_UNCOMMITTED

Definition at line 211 of file StoredCollections.java.

References configuredSet().

static SortedMap com::sleepycat::collections::StoredCollections::dirtyReadSortedMap SortedMap  storedSortedMap  )  [inline, static]
 

Deprecated:
This method has been replaced by configuredSortedMap in order to conform to ANSI database isolation terminology. To obtain a dirty-read map, pass CursorConfig.READ_UNCOMMITTED

Definition at line 223 of file StoredCollections.java.

References configuredSortedMap().

static SortedSet com::sleepycat::collections::StoredCollections::dirtyReadSortedSet SortedSet  storedSortedSet  )  [inline, static]
 

Deprecated:
This method has been replaced by configuredSortedSet in order to conform to ANSI database isolation terminology. To obtain a dirty-read set, pass CursorConfig.READ_UNCOMMITTED

Definition at line 236 of file StoredCollections.java.

References configuredSortedSet().

static Iterator com::sleepycat::collections::StoredCollections::iterator Iterator  storedIterator  )  [inline, static]
 

Clones a stored iterator preserving its current position.

Parameters:
storedIterator an iterator to clone.
Returns:
a new StoredIterator having the same position as the given iterator.
Exceptions:
ClassCastException if the given iterator is not a StoredIterator.

Definition at line 254 of file StoredCollections.java.


The documentation for this class was generated from the following file:
Generated on Sun Dec 25 12:15:00 2005 for Berkeley DB 4.4.16 by  doxygen 1.4.2