public static class Aggregator.TupleMapIterator extends java.lang.Object implements DbIterator
DbIterator
,
Serialized FormModifier and Type | Field and Description |
---|---|
(package private) java.util.HashMap<Field,Tuple> |
fieldTupleMap |
(package private) Field[] |
keyArray |
(package private) int |
position |
(package private) TupleDesc |
tupleDesc |
Constructor and Description |
---|
TupleMapIterator(java.util.HashMap<Field,Tuple> fieldTupleMap,
TupleDesc tupleDesc) |
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes the iterator.
|
TupleDesc |
getTupleDesc()
Returns the TupleDesc associated with this DbIterator.
|
boolean |
hasNext()
Returns true if the iterator has more tuples.
|
Tuple |
next()
Returns the next tuple from the operator (typically implementing by reading
from a child operator or an access method).
|
void |
open()
Opens the iterator.
|
void |
rewind()
Resets the iterator to the start.
|
public void open() throws DbException, TransactionAbortedException
DbIterator
open
in interface DbIterator
DbException
- when there are problems opening/accessing the database.TransactionAbortedException
public boolean hasNext() throws DbException, TransactionAbortedException
DbIterator
hasNext
in interface DbIterator
DbException
TransactionAbortedException
public Tuple next() throws DbException, TransactionAbortedException, java.util.NoSuchElementException
DbIterator
next
in interface DbIterator
java.util.NoSuchElementException
- if there are no more tuples.DbException
TransactionAbortedException
public void rewind() throws DbException, TransactionAbortedException
DbIterator
rewind
in interface DbIterator
DbException
- when rewind is unsupported.TransactionAbortedException
public TupleDesc getTupleDesc()
DbIterator
getTupleDesc
in interface DbIterator
public void close()
DbIterator
close
in interface DbIterator