@Override public Batch nextBatch() { Batch right = delegate.nextBatch(); return right == null ? null : new RightOnlyBatch(right); } }
@Override public Batch nextBatch() { Batch next = sequence.nextBatch(); return batchFilteredWith(next, filter); }
@Override public Batch nextBatch() { Batch next = sequence.nextBatch(); return batchFilteredWith(next, filter); }
@Override public Batch nextBatch() { Batch right = delegate.nextBatch(); return right == null ? null : new RightOnlyBatch(right); } }
protected Batch findNextBatch() { if (currentBatch == null || !currentBatch.hasNext()) { currentBatch = sequence.nextBatch(); } return currentBatch; }
@Override public Batch nextBatch() { initialize(); return dependentQuery.nextBatch(); }
protected Batch findNextBatch() { if (currentBatch == null || !currentBatch.hasNext()) { currentBatch = sequence.nextBatch(); } return currentBatch; }
@Override public Batch nextBatch() { initialize(); return dependentQuery.nextBatch(); }
@Override public Batch nextBatch() { return slicingBatch(original.nextBatch(), selectorIndexes); }
@Override public Batch nextBatch() { return slicingBatch(original.nextBatch(), selectorIndexes); }
protected Batch findNextNonEmptyLeftBatch() { while (currentLeft == null) { currentLeft = left.nextBatch(); if (currentLeft == null) return null; // no more left if (currentLeft.isEmpty() || !currentLeft.hasNext()) { // Skip any empty batches ... currentLeft = null; } } return currentLeft; }
protected Batch findNextNonEmptyLeftBatch() { while (currentLeft == null) { currentLeft = left.nextBatch(); if (currentLeft == null) return null; // no more left if (currentLeft.isEmpty() || !currentLeft.hasNext()) { // Skip any empty batches ... currentLeft = null; } } return currentLeft; }
@Override public Batch nextBatch() { return batchOf(null, second.nextBatch(), firstWidth, second.width()); }
@Override public Batch nextBatch() { return batchOf(first.nextBatch(), null, first.width(), secondWidth); }
@Override public Batch nextBatch() { return batchOf(null, second.nextBatch(), firstWidth, second.width()); }
@Test public void shouldCreateEmptySequenceOfVariousWidths() { for (int i = 0; i != 10; ++i) { NodeSequence seq = NodeSequence.emptySequence(i); assertThat("Incorrect width for empty sequence", seq.width(), is(i)); assertThat(seq.nextBatch(), is(nullValue())); seq.close(); } }