org.apache.accumulo.core.iterators.system
public abstract class HeapIterator extends Object implements SortedKeyValueIterator<Key,Value>
PriorityQueue
of multiple SortedKeyValueIterators. Provides a simple way to interact with multiple SortedKeyValueIterators in sorted
order.Modifier | Constructor and Description |
---|---|
protected |
HeapIterator() |
protected |
HeapIterator(int maxSize) |
Modifier and Type | Method and Description |
---|---|
protected void |
addSource(SortedKeyValueIterator<Key,Value> source) |
protected void |
clear() |
protected void |
createHeap(int maxSize) |
Key |
getTopKey()
Returns top key.
|
Value |
getTopValue()
Returns top value.
|
boolean |
hasTop()
Returns true if the iterator has more elements.
|
void |
next()
Advances to the next K,V pair.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
deepCopy, init, seek
protected HeapIterator()
protected HeapIterator(int maxSize)
protected void createHeap(int maxSize)
public final Key getTopKey()
SortedKeyValueIterator
getTopKey
in interface SortedKeyValueIterator<Key,Value>
public final Value getTopValue()
SortedKeyValueIterator
getTopValue
in interface SortedKeyValueIterator<Key,Value>
public final boolean hasTop()
SortedKeyValueIterator
hasTop
in interface SortedKeyValueIterator<Key,Value>
public final void next() throws IOException
SortedKeyValueIterator
next
in interface SortedKeyValueIterator<Key,Value>
IOException
- if an I/O error occurs.protected final void clear()
protected final void addSource(SortedKeyValueIterator<Key,Value> source)
Copyright © 2015 Apache Accumulo Project. All Rights Reserved.