Operator.fetchNext implementation. Iterates over tuples from the child operator, projecting out the fields from the tuple @return The next tuple, or null if there are no more tuples
()
| 70 | * @return The next tuple, or null if there are no more tuples |
| 71 | */ |
| 72 | protected Tuple fetchNext() throws NoSuchElementException, |
| 73 | TransactionAbortedException, DbException { |
| 74 | if (!child.hasNext()) return null; |
| 75 | Tuple t = child.next(); |
| 76 | Tuple newTuple = new Tuple(td); |
| 77 | newTuple.setRecordId(t.getRecordId()); |
| 78 | for (int i = 0; i < td.numFields(); i++) { |
| 79 | newTuple.setField(i, t.getField(outFieldIds.get(i))); |
| 80 | } |
| 81 | return newTuple; |
| 82 | } |
| 83 | |
| 84 | @Override |
| 85 | public OpIterator[] getChildren() { |
nothing calls this directly
no test coverage detected