DbFileIterator is the iterator interface that all SimpleDB Dbfile should implement.
| 9 | * implement. |
| 10 | */ |
| 11 | public interface DbFileIterator{ |
| 12 | /** |
| 13 | * Opens the iterator |
| 14 | * @throws DbException when there are problems opening/accessing the database. |
| 15 | */ |
| 16 | void open() |
| 17 | throws DbException, TransactionAbortedException; |
| 18 | |
| 19 | /** @return true if there are more tuples available, false if no more tuples or iterator isn't open. */ |
| 20 | boolean hasNext() |
| 21 | throws DbException, TransactionAbortedException; |
| 22 | |
| 23 | /** |
| 24 | * Gets the next tuple from the operator (typically implementing by reading |
| 25 | * from a child operator or an access method). |
| 26 | * |
| 27 | * @return The next tuple in the iterator. |
| 28 | * @throws NoSuchElementException if there are no more tuples |
| 29 | */ |
| 30 | Tuple next() |
| 31 | throws DbException, TransactionAbortedException, NoSuchElementException; |
| 32 | |
| 33 | /** |
| 34 | * Resets the iterator to the start. |
| 35 | * @throws DbException When rewind is unsupported. |
| 36 | */ |
| 37 | void rewind() throws DbException, TransactionAbortedException; |
| 38 | |
| 39 | /** |
| 40 | * Closes the iterator. |
| 41 | */ |
| 42 | void close(); |
| 43 | } |
no outgoing calls
no test coverage detected