public void test_filter() { final IChunkedIterator<Long> actual = (IChunkedIterator<Long>) new ChunkedStriterator<IChunkedIterator<Long>, Long>( Arrays.asList(new Long[] { 1L, 3L, 5L }).iterator()) .addFilter(new MergeFilter<IChunkedIterator<Long>, Long>( new ChunkedWrappedIterator<Long>(Arrays.asList( new Long[] { 2L, 3L, 4L }).iterator()))); assertEquals(new Long[] { 1L, 2L, 3L, 4L, 5L }, actual.nextChunk()); }
public void test_filter() { final IChunkedIterator<Long> actual = (IChunkedIterator<Long>) new ChunkedStriterator<IChunkedIterator<Long>, Long>( Arrays.asList(new Long[] { 1L, 3L, 5L }).iterator()) .addFilter(new MergeFilter<IChunkedIterator<Long>, Long>( new ChunkedWrappedIterator<Long>(Arrays.asList( new Long[] { 2L, 3L, 4L }).iterator()))); assertEquals(new Long[] { 1L, 2L, 3L, 4L, 5L }, actual.nextChunk()); }