org.apache.jackrabbit.commons.iterator
Class RowIteratorAdapter
java.lang.Object
org.apache.jackrabbit.commons.iterator.RangeIteratorDecorator
org.apache.jackrabbit.commons.iterator.RowIteratorAdapter
- All Implemented Interfaces:
- java.util.Iterator, javax.jcr.query.RowIterator, javax.jcr.RangeIterator
public class RowIteratorAdapter
- extends RangeIteratorDecorator
- implements javax.jcr.query.RowIterator
Adapter class for turning RangeIterators or Iterators
into RowIterators.
|
Field Summary |
static javax.jcr.query.RowIterator |
EMPTY
Static instance of an empty RowIterator. |
|
Constructor Summary |
RowIteratorAdapter(java.util.Collection collection)
Creates an iterator for the given collection. |
RowIteratorAdapter(java.util.Iterator iterator)
Creates an adapter for the given Iterator. |
RowIteratorAdapter(javax.jcr.RangeIterator iterator)
Creates an adapter for the given RangeIterator. |
|
Method Summary |
javax.jcr.query.Row |
nextRow()
Returns the next row. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface javax.jcr.RangeIterator |
getPosition, getSize, skip |
| Methods inherited from interface java.util.Iterator |
hasNext, next, remove |
EMPTY
public static final javax.jcr.query.RowIterator EMPTY
- Static instance of an empty
RowIterator.
RowIteratorAdapter
public RowIteratorAdapter(javax.jcr.RangeIterator iterator)
- Creates an adapter for the given
RangeIterator.
- Parameters:
iterator - iterator of Rows
RowIteratorAdapter
public RowIteratorAdapter(java.util.Iterator iterator)
- Creates an adapter for the given
Iterator.
- Parameters:
iterator - iterator of Rows
RowIteratorAdapter
public RowIteratorAdapter(java.util.Collection collection)
- Creates an iterator for the given collection.
- Parameters:
collection - collection of Rows
nextRow
public javax.jcr.query.Row nextRow()
- Returns the next row.
- Specified by:
nextRow in interface javax.jcr.query.RowIterator
- Returns:
- next row
- Throws:
java.util.NoSuchElementException - if there is no next row
Copyright © 2004-2011 Apache Software Foundation. All Rights Reserved.