org.openstreetmap.osmosis.core.customdb.v0_5.impl
Class WayStorageContainer

java.lang.Object
  extended by org.openstreetmap.osmosis.core.customdb.v0_5.impl.WayStorageContainer
All Implemented Interfaces:
Releasable

public class WayStorageContainer
extends java.lang.Object
implements Releasable

Holds references to all of the node storage related classes.

Author:
Brett Henderson

Constructor Summary
WayStorageContainer(RandomAccessObjectStoreReader<Way> wayObjectReader, IndexStoreReader<java.lang.Long,LongLongIndexElement> wayObjectOffsetIndexReader, WayTileAreaIndexReader wayTileIndexReader, IndexStoreReader<java.lang.Long,LongLongIndexElement> wayRelationIndexReader)
          Creates a new instance.
 
Method Summary
 IndexStoreReader<java.lang.Long,LongLongIndexElement> getWayObjectOffsetIndexReader()
          Gets the way object offset reader.
 RandomAccessObjectStoreReader<Way> getWayObjectReader()
          Gets the raw way reader.
 IndexStoreReader<java.lang.Long,LongLongIndexElement> getWayRelationIndexReader()
          Gets the way to relation index reader.
 WayTileAreaIndexReader getWayTileIndexReader()
          Gets the tile to way index reader.
 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

WayStorageContainer

public WayStorageContainer(RandomAccessObjectStoreReader<Way> wayObjectReader,
                           IndexStoreReader<java.lang.Long,LongLongIndexElement> wayObjectOffsetIndexReader,
                           WayTileAreaIndexReader wayTileIndexReader,
                           IndexStoreReader<java.lang.Long,LongLongIndexElement> wayRelationIndexReader)
Creates a new instance.

Parameters:
wayObjectReader - The raw way objects.
wayObjectOffsetIndexReader - The way object offsets.
wayTileIndexReader - The tile to way index.
wayRelationIndexReader - The way to relation index.
Method Detail

getWayObjectReader

public RandomAccessObjectStoreReader<Way> getWayObjectReader()
Gets the raw way reader.

Returns:
The raw way reader.

getWayObjectOffsetIndexReader

public IndexStoreReader<java.lang.Long,LongLongIndexElement> getWayObjectOffsetIndexReader()
Gets the way object offset reader.

Returns:
The way object offset reader.

getWayTileIndexReader

public WayTileAreaIndexReader getWayTileIndexReader()
Gets the tile to way index reader.

Returns:
The tile to way index reader.

getWayRelationIndexReader

public IndexStoreReader<java.lang.Long,LongLongIndexElement> getWayRelationIndexReader()
Gets the way to relation index reader.

Returns:
The way to relation index reader.

release

public void release()
Performs resource cleanup tasks such as closing files, or database connections. This must be called after all processing is complete and may be called multiple times. Implementations must call release on any nested Releasable objects. It should be called within a finally block to ensure it is called in exception scenarios.

Specified by:
release in interface Releasable