Class PropertyIteratorAdapter
- java.lang.Object
-
- org.apache.jackrabbit.commons.iterator.RangeIteratorDecorator
-
- org.apache.jackrabbit.commons.iterator.PropertyIteratorAdapter
-
- All Implemented Interfaces:
Iterator,PropertyIterator,RangeIterator
public class PropertyIteratorAdapter extends RangeIteratorDecorator implements PropertyIterator
-
-
Field Summary
Fields Modifier and Type Field Description static PropertyIteratorEMPTYStatic instance of an emptyPropertyIterator.
-
Constructor Summary
Constructors Constructor Description PropertyIteratorAdapter(Collection collection)Creates an iterator for the given collection.PropertyIteratorAdapter(Iterator iterator)Creates an adapter for the givenIterator.PropertyIteratorAdapter(Iterator iterator, long size)PropertyIteratorAdapter(RangeIterator iterator)Creates an adapter for the givenRangeIterator.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PropertynextProperty()Returns the next property.-
Methods inherited from class org.apache.jackrabbit.commons.iterator.RangeIteratorDecorator
getPosition, getSize, hasNext, next, remove, skip
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Iterator
forEachRemaining, hasNext, next, remove
-
Methods inherited from interface javax.jcr.RangeIterator
getPosition, getSize, skip
-
-
-
-
Field Detail
-
EMPTY
public static final PropertyIterator EMPTY
Static instance of an emptyPropertyIterator.
-
-
Constructor Detail
-
PropertyIteratorAdapter
public PropertyIteratorAdapter(RangeIterator iterator)
Creates an adapter for the givenRangeIterator.- Parameters:
iterator- iterator ofPropertyinstances
-
PropertyIteratorAdapter
public PropertyIteratorAdapter(Iterator iterator)
Creates an adapter for the givenIterator.- Parameters:
iterator- iterator ofPropertyinstances
-
PropertyIteratorAdapter
public PropertyIteratorAdapter(Iterator iterator, long size)
-
PropertyIteratorAdapter
public PropertyIteratorAdapter(Collection collection)
Creates an iterator for the given collection.- Parameters:
collection- collection ofPropertyinstances
-
-
Method Detail
-
nextProperty
public Property nextProperty()
Returns the next property.- Specified by:
nextPropertyin interfacePropertyIterator- Returns:
- next property
- Throws:
NoSuchElementException- if there is no next property
-
-