org.openstreetmap.osmosis.core.mysql.v0_5.impl
Class WayHistoryReader
java.lang.Object
org.openstreetmap.osmosis.core.mysql.common.BaseTableReader<T>
org.openstreetmap.osmosis.core.mysql.v0_5.impl.BaseEntityReader<EntityHistory<Way>>
org.openstreetmap.osmosis.core.mysql.v0_5.impl.WayHistoryReader
- All Implemented Interfaces:
- java.util.Iterator<EntityHistory<Way>>, Releasable, ReleasableIterator<EntityHistory<Way>>
public class WayHistoryReader
- extends BaseEntityReader<EntityHistory<Way>>
Reads the set of way changes from a database that have occurred within a
time interval.
- Author:
- Brett Henderson
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
WayHistoryReader
public WayHistoryReader(DatabaseLoginCredentials loginCredentials,
boolean readAllUsers,
java.util.Date intervalBegin,
java.util.Date intervalEnd)
- Creates a new instance.
- Parameters:
loginCredentials
- Contains all information required to connect to the database.readAllUsers
- If this flag is true, all users will be read from the database
regardless of their public edits flag.intervalBegin
- Marks the beginning (inclusive) of the time interval to be
checked.intervalEnd
- Marks the end (exclusive) of the time interval to be checked.
createResultSet
protected java.sql.ResultSet createResultSet(DatabaseContext queryDbCtx)
- Builds the result set that the reader will iterate over.
- Specified by:
createResultSet
in class BaseTableReader<EntityHistory<Way>>
- Parameters:
queryDbCtx
- The database context to query against.
- Returns:
- A result set positioned before the first record.
createNextValue
protected BaseTableReader.ReadResult<EntityHistory<Way>> createNextValue(java.sql.ResultSet resultSet)
- Builds an entity object from the current recordset row.
- Specified by:
createNextValue
in class BaseTableReader<EntityHistory<Way>>
- Parameters:
resultSet
- The record set to retrieve the data from.
- Returns:
- The result of the read.