|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.openstreetmap.osmosis.core.store.IndexedObjectStoreReader<T>
T
- The object type being stored.public class IndexedObjectStoreReader<T>
Provides read-only access to an indexed object store. Each thread accessing the object store must create its own reader. The reader maintains all references to heavyweight resources such as file handles used to access the store eliminating the need for objects such as object iterators to be cleaned up explicitly.
Constructor Summary | |
---|---|
IndexedObjectStoreReader(RandomAccessObjectStoreReader<T> objectStoreReader,
IndexStoreReader<java.lang.Long,LongLongIndexElement> indexStoreReader)
Creates a new instance. |
Method Summary | |
---|---|
T |
get(long id)
Returns the object identified by id. |
void |
release()
Performs resource cleanup tasks such as closing files, or database connections. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public IndexedObjectStoreReader(RandomAccessObjectStoreReader<T> objectStoreReader, IndexStoreReader<java.lang.Long,LongLongIndexElement> indexStoreReader)
objectStoreReader
- Provides access to the object data.indexStoreReader
- Provides access to the index data.Method Detail |
---|
public T get(long id)
id
- The identifier for the object to be retrieved.
public void release()
release
in interface Releasable
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |