public class SortedMergeIterator extends AbstractSortedMerge implements OsmIterator
AbstractSortedMerge.Input<T extends OsmEntity>
nodeItems, relationItems, wayItems
bounds, hasBounds, inputs
Constructor and Description |
---|
SortedMergeIterator(Collection<OsmIterator> inputs)
Merge the elements from a collection of OSM input sources to a single OSM
input source.
|
SortedMergeIterator(Collection<OsmIterator> inputs,
Comparator<? super OsmNode> comparatorNodes,
Comparator<? super OsmWay> comparatorWays,
Comparator<? super OsmRelation> comparatorRelations)
Merge the elements from a collection of OSM input sources to a single OSM
input source.
|
SortedMergeIterator(Collection<OsmIterator> inputs,
Comparator<OsmEntity> comparator)
Merge the elements from a collection of OSM input sources to a single OSM
input source.
|
Modifier and Type | Method and Description |
---|---|
OsmBounds |
getBounds() |
boolean |
hasBounds() |
boolean |
hasNext() |
Iterator<EntityContainer> |
iterator() |
EntityContainer |
next() |
void |
remove() |
advanceNodeItem, advanceRelationItem, advanceWayItem, createItem
initBounds
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEach, spliterator
forEachRemaining
public SortedMergeIterator(Collection<OsmIterator> inputs) throws IOException
inputs
- a collection of iterators to retrieve data from.IOException
public SortedMergeIterator(Collection<OsmIterator> inputs, Comparator<OsmEntity> comparator) throws IOException
inputs
- a collection of iterators to retrieve data from.comparator
- a Comparator used to compare elements of the same type.IOException
public SortedMergeIterator(Collection<OsmIterator> inputs, Comparator<? super OsmNode> comparatorNodes, Comparator<? super OsmWay> comparatorWays, Comparator<? super OsmRelation> comparatorRelations) throws IOException
inputs
- a collection of iterators to retrieve data from.comparatorNodes
- a Comparator used to compare nodes.comparatorWays
- a Comparator used to compare ways.comparatorRelations
- a Comparator used to compare relations.IOException
public Iterator<EntityContainer> iterator()
iterator
in interface Iterable<EntityContainer>
public void remove()
remove
in interface Iterator<EntityContainer>
public boolean hasBounds()
hasBounds
in interface OsmIterator
public OsmBounds getBounds()
getBounds
in interface OsmIterator
public boolean hasNext()
hasNext
in interface Iterator<EntityContainer>
public EntityContainer next()
next
in interface Iterator<EntityContainer>