Class AccessControlPolicyIteratorAdapter
- java.lang.Object
-
- org.apache.jackrabbit.commons.iterator.RangeIteratorDecorator
-
- org.apache.jackrabbit.commons.iterator.AccessControlPolicyIteratorAdapter
-
- All Implemented Interfaces:
Iterator
,RangeIterator
,AccessControlPolicyIterator
public class AccessControlPolicyIteratorAdapter extends RangeIteratorDecorator implements AccessControlPolicyIterator
-
-
Field Summary
Fields Modifier and Type Field Description static AccessControlPolicyIterator
EMPTY
Static instance of an emptyAccessControlPolicyIteratorAdapter
.
-
Constructor Summary
Constructors Constructor Description AccessControlPolicyIteratorAdapter(Collection collection)
Creates an iterator for the given collection.AccessControlPolicyIteratorAdapter(Iterator iterator)
Creates an adapter for the givenIterator
.AccessControlPolicyIteratorAdapter(RangeIterator iterator)
Creates an adapter for the givenRangeIterator
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AccessControlPolicy
nextAccessControlPolicy()
Returns the next policy.-
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 AccessControlPolicyIterator EMPTY
Static instance of an emptyAccessControlPolicyIteratorAdapter
.
-
-
Constructor Detail
-
AccessControlPolicyIteratorAdapter
public AccessControlPolicyIteratorAdapter(RangeIterator iterator)
Creates an adapter for the givenRangeIterator
.- Parameters:
iterator
- iterator ofaccess control policies
.
-
AccessControlPolicyIteratorAdapter
public AccessControlPolicyIteratorAdapter(Iterator iterator)
Creates an adapter for the givenIterator
.- Parameters:
iterator
- iterator ofaccess control policies
.
-
AccessControlPolicyIteratorAdapter
public AccessControlPolicyIteratorAdapter(Collection collection)
Creates an iterator for the given collection.- Parameters:
collection
- collection ofAccessControlPolicy
objects.
-
-
Method Detail
-
nextAccessControlPolicy
public AccessControlPolicy nextAccessControlPolicy() throws NoSuchElementException
Returns the next policy.- Specified by:
nextAccessControlPolicy
in interfaceAccessControlPolicyIterator
- Returns:
- next policy.
- Throws:
NoSuchElementException
- if there is no next policy.
-
-