public class EntryFilteringCursorImpl extends org.apache.directory.api.ldap.model.cursor.AbstractCursor<org.apache.directory.api.ldap.model.entry.Entry> implements EntryFilteringCursor
| Modifier and Type | Field and Description |
|---|---|
private java.util.List<EntryFilter> |
filters
the list of filters to be applied
|
private static boolean |
IS_DEBUG
Speedup for logs
|
private static org.slf4j.Logger |
LOG
the logger used by this class
|
private static org.slf4j.Logger |
LOG_CURSOR
A dedicated log for cursors
|
private SearchOperationContext |
operationContext
the parameters associated with the search operation
|
private org.apache.directory.api.ldap.model.entry.Entry |
prefetched
the first accepted search result that is pre fetched
|
private org.apache.directory.api.ldap.model.schema.SchemaManager |
schemaManager
The SchemaManager
|
private org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> |
wrapped
the underlying wrapped search results Cursor
|
| Constructor and Description |
|---|
EntryFilteringCursorImpl(org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> wrapped,
SearchOperationContext operationContext,
org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager)
Creates a new entry filtering Cursor over an existing Cursor using a
no filter initially: more can be added later after creation.
|
EntryFilteringCursorImpl(org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> wrapped,
SearchOperationContext operationContext,
org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager,
EntryFilter filter)
Creates a new entry filtering Cursor over an existing Cursor using a
single filter initially: more can be added later after creation.
|
EntryFilteringCursorImpl(org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> wrapped,
SearchOperationContext operationContext,
org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager,
java.util.List<EntryFilter> filters)
Creates a new entry filtering Cursor over an existing Cursor using a
list of filters initially: more can be added later after creation.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
addEntryFilter(EntryFilter filter)
Adds an entry filter to this BaseEntryFilteringCursor at the very end of
the filter list.
|
void |
after(org.apache.directory.api.ldap.model.entry.Entry element) |
void |
afterLast() |
boolean |
available() |
void |
before(org.apache.directory.api.ldap.model.entry.Entry element) |
void |
beforeFirst() |
void |
close() |
void |
close(java.lang.Exception reason) |
boolean |
first() |
org.apache.directory.api.ldap.model.entry.Entry |
get() |
java.util.List<EntryFilter> |
getEntryFilters()
Gets an unmodifiable list of EntryFilters applied.
|
SearchOperationContext |
getOperationContext() |
boolean |
isAbandoned() |
boolean |
isClosed() |
boolean |
last() |
boolean |
next() |
boolean |
previous() |
boolean |
removeEntryFilter(EntryFilter filter) |
void |
setAbandoned(boolean abandoned) |
void |
setClosureMonitor(org.apache.directory.api.ldap.model.cursor.ClosureMonitor monitor) |
java.lang.String |
toString() |
java.lang.String |
toString(java.lang.String tabs) |
checkNotClosed, isAfterLast, isBeforeFirst, isFirst, isLast, iteratorclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitprivate static final org.slf4j.Logger LOG
private static final org.slf4j.Logger LOG_CURSOR
private static final boolean IS_DEBUG
private final org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> wrapped
private final SearchOperationContext operationContext
private final org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager
private final java.util.List<EntryFilter> filters
private org.apache.directory.api.ldap.model.entry.Entry prefetched
public EntryFilteringCursorImpl(org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> wrapped,
SearchOperationContext operationContext,
org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager,
EntryFilter filter)
wrapped - the underlying wrapped Cursor whose entries are filteredsearchControls - the controls of search that created this Cursorinvocation - the search operation invocation creating this Cursorfilter - a single filter to be usedpublic EntryFilteringCursorImpl(org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> wrapped,
SearchOperationContext operationContext,
org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager)
wrapped - the underlying wrapped Cursor whose entries are filteredsearchControls - the controls of search that created this Cursorinvocation - the search operation invocation creating this Cursorfilter - a single filter to be usedpublic EntryFilteringCursorImpl(org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> wrapped,
SearchOperationContext operationContext,
org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager,
java.util.List<EntryFilter> filters)
wrapped - the underlying wrapped Cursor whose entries are filteredoperationContext - the operation context that created this Cursorinvocation - the search operation invocation creating this Cursorfilters - a list of filters to be usedpublic boolean isAbandoned()
public void setAbandoned(boolean abandoned)
public boolean addEntryFilter(EntryFilter filter)
EntryFilteringCursoraddEntryFilter in interface EntryFilteringCursorfilter - a filter to apply to the entriesList.add(Object)public boolean removeEntryFilter(EntryFilter filter)
public java.util.List<EntryFilter> getEntryFilters()
getEntryFilters in interface EntryFilteringCursorpublic SearchOperationContext getOperationContext()
getOperationContext in interface EntryFilteringCursorpublic void after(org.apache.directory.api.ldap.model.entry.Entry element)
throws org.apache.directory.api.ldap.model.exception.LdapException,
org.apache.directory.api.ldap.model.cursor.CursorException
after in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>org.apache.directory.api.ldap.model.exception.LdapExceptionorg.apache.directory.api.ldap.model.cursor.CursorExceptionpublic void afterLast()
throws org.apache.directory.api.ldap.model.exception.LdapException,
org.apache.directory.api.ldap.model.cursor.CursorException
afterLast in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>org.apache.directory.api.ldap.model.exception.LdapExceptionorg.apache.directory.api.ldap.model.cursor.CursorExceptionpublic boolean available()
available in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>public void before(org.apache.directory.api.ldap.model.entry.Entry element)
throws org.apache.directory.api.ldap.model.exception.LdapException,
org.apache.directory.api.ldap.model.cursor.CursorException
before in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>org.apache.directory.api.ldap.model.exception.LdapExceptionorg.apache.directory.api.ldap.model.cursor.CursorExceptionpublic void beforeFirst()
throws org.apache.directory.api.ldap.model.exception.LdapException,
org.apache.directory.api.ldap.model.cursor.CursorException
beforeFirst in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>org.apache.directory.api.ldap.model.exception.LdapExceptionorg.apache.directory.api.ldap.model.cursor.CursorExceptionpublic void close()
close in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>close in class org.apache.directory.api.ldap.model.cursor.AbstractCursor<org.apache.directory.api.ldap.model.entry.Entry>public void close(java.lang.Exception reason)
close in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>close in class org.apache.directory.api.ldap.model.cursor.AbstractCursor<org.apache.directory.api.ldap.model.entry.Entry>public final void setClosureMonitor(org.apache.directory.api.ldap.model.cursor.ClosureMonitor monitor)
setClosureMonitor in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>setClosureMonitor in class org.apache.directory.api.ldap.model.cursor.AbstractCursor<org.apache.directory.api.ldap.model.entry.Entry>public boolean first()
throws org.apache.directory.api.ldap.model.exception.LdapException,
org.apache.directory.api.ldap.model.cursor.CursorException
first in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>org.apache.directory.api.ldap.model.exception.LdapExceptionorg.apache.directory.api.ldap.model.cursor.CursorExceptionpublic org.apache.directory.api.ldap.model.entry.Entry get()
throws org.apache.directory.api.ldap.model.cursor.InvalidCursorPositionException
get in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>org.apache.directory.api.ldap.model.cursor.InvalidCursorPositionExceptionpublic boolean isClosed()
isClosed in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>isClosed in class org.apache.directory.api.ldap.model.cursor.AbstractCursor<org.apache.directory.api.ldap.model.entry.Entry>public boolean last()
throws org.apache.directory.api.ldap.model.exception.LdapException,
org.apache.directory.api.ldap.model.cursor.CursorException
last in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>org.apache.directory.api.ldap.model.exception.LdapExceptionorg.apache.directory.api.ldap.model.cursor.CursorExceptionpublic boolean next()
throws org.apache.directory.api.ldap.model.exception.LdapException,
org.apache.directory.api.ldap.model.cursor.CursorException
next in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>org.apache.directory.api.ldap.model.exception.LdapExceptionorg.apache.directory.api.ldap.model.cursor.CursorExceptionpublic boolean previous()
throws org.apache.directory.api.ldap.model.exception.LdapException,
org.apache.directory.api.ldap.model.cursor.CursorException
previous in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>org.apache.directory.api.ldap.model.exception.LdapExceptionorg.apache.directory.api.ldap.model.cursor.CursorExceptionpublic java.lang.String toString(java.lang.String tabs)
toString in interface org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry>toString in class org.apache.directory.api.ldap.model.cursor.AbstractCursor<org.apache.directory.api.ldap.model.entry.Entry>Object.toString()public java.lang.String toString()
toString in class java.lang.ObjectObject.toString()