org.pasoa.storage.je
Class BerkeleyDBJEStorage
java.lang.Object
org.pasoa.storage.je.BerkeleyDBJEStorage
- All Implemented Interfaces:
- BackendStore, Cache, Management, Record, Retrieval
- public class BerkeleyDBJEStorage
- extends Object
- implements BackendStore
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TOTAL_NUM_RECORDS_KEY
public static final String TOTAL_NUM_RECORDS_KEY
- See Also:
- Constant Field Values
BerkeleyDBJEStorage
public BerkeleyDBJEStorage(String home)
record
public void record(GlobalPAssertionKey gpid,
Element asserter,
Element assertion,
String kindOfAssertion)
throws Exception
- Specified by:
record
in interface Record
- Throws:
Exception
getInteractionRecord
public InteractionRecord getInteractionRecord(InteractionKey irid)
throws Exception
- Throws:
Exception
getInteractionRecord
public InteractionRecord getInteractionRecord(long index)
throws Exception
- Description copied from interface:
Retrieval
- Retrieve the message exchange at the given index
- Specified by:
getInteractionRecord
in interface Retrieval
- Throws:
Exception
getNumberOfInteractionRecords
public long getNumberOfInteractionRecords()
throws Exception
- Description copied from interface:
Retrieval
- Get the number of message exchanges available.
- Specified by:
getNumberOfInteractionRecords
in interface Retrieval
- Throws:
Exception
cacheEnabled
public boolean cacheEnabled()
- Specified by:
cacheEnabled
in interface Cache
cache
public void cache(CacheableItem ci)
throws Exception
- Specified by:
cache
in interface Cache
- Throws:
Exception
getCachedItem
public CacheableItem getCachedItem()
throws Exception
- Description copied from interface:
Cache
- Returns some item that has been cached.
No order is guranteed. Returns null if there are no CachableItems
left in the cache.
!!! When a cached item is gotten from the cache, it is removed
from the cache and not longer exists there.
- Specified by:
getCachedItem
in interface Cache
- Returns:
-
- Throws:
Exception
shutdown
public void shutdown()
throws Exception
- Specified by:
shutdown
in interface Management
- Throws:
Exception
delete
public void delete()
throws Exception
- Specified by:
delete
in interface Management
- Throws:
Exception