public class SubtreeScopeEvaluator extends java.lang.Object implements Evaluator<org.apache.directory.api.ldap.model.filter.ScopeNode>
| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
baseId
The entry identifier of the scope base
|
private boolean |
baseIsContextEntry
Whether or not to accept all candidates.
|
private java.lang.String |
contextEntryId |
private Store |
db
The entry database/store
|
private boolean |
dereferencing
True if the scope requires alias dereferencing while searching
|
private org.apache.directory.api.ldap.model.filter.ScopeNode |
node
The ScopeNode containing initial search scope constraints
|
| Constructor and Description |
|---|
SubtreeScopeEvaluator(Store db,
org.apache.directory.api.ldap.model.filter.ScopeNode node)
Creates a subtree scope node evaluator for search expressions.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
evaluate(org.apache.directory.api.ldap.model.entry.Entry candidate)
Asserts whether or not a candidate has sub level scope while taking
alias dereferencing into account.
|
boolean |
evaluate(IndexEntry<?,java.lang.String> indexEntry)
Asserts whether or not a candidate has sub level scope while taking
alias dereferencing into account.
|
java.lang.String |
getBaseId() |
private java.lang.String |
getContextEntryId() |
org.apache.directory.api.ldap.model.filter.ScopeNode |
getExpression()
Gets the expression used by this expression Evaluator.
|
boolean |
isDereferencing() |
private boolean |
isDescendant(java.lang.String candidateId)
Tells if a candidate is a descendant of the base ID.
|
java.lang.String |
toString() |
java.lang.String |
toString(java.lang.String tabs)
Pretty-print an Evaluator
|
private final org.apache.directory.api.ldap.model.filter.ScopeNode node
private final java.lang.String baseId
private final boolean baseIsContextEntry
private final boolean dereferencing
private final Store db
private java.lang.String contextEntryId
public SubtreeScopeEvaluator(Store db, org.apache.directory.api.ldap.model.filter.ScopeNode node) throws java.lang.Exception
node - the scope nodedb - the database used to evaluate scope nodejava.lang.Exception - on db access failureprivate java.lang.String getContextEntryId()
throws java.lang.Exception
java.lang.Exceptionprivate boolean isDescendant(java.lang.String candidateId)
throws org.apache.directory.api.ldap.model.exception.LdapException
org.apache.directory.api.ldap.model.exception.LdapExceptionpublic boolean evaluate(IndexEntry<?,java.lang.String> indexEntry) throws org.apache.directory.api.ldap.model.exception.LdapException
evaluate in interface Evaluator<org.apache.directory.api.ldap.model.filter.ScopeNode>candidate - the entry tested to see if it is in subtree scopejava.lang.Exception - if the index lookups fail.org.apache.directory.api.ldap.model.exception.LdapExceptionEvaluator.evaluate(org.apache.directory.server.xdbm.IndexEntry)public boolean evaluate(org.apache.directory.api.ldap.model.entry.Entry candidate)
throws java.lang.Exception
evaluate in interface Evaluator<org.apache.directory.api.ldap.model.filter.ScopeNode>candidate - the entry tested to see if it is in subtree scopejava.lang.Exception - if the index lookups fail.Evaluator.evaluate(org.apache.directory.server.xdbm.IndexEntry)public org.apache.directory.api.ldap.model.filter.ScopeNode getExpression()
EvaluatorgetExpression in interface Evaluator<org.apache.directory.api.ldap.model.filter.ScopeNode>public java.lang.String getBaseId()
public boolean isDereferencing()
public java.lang.String toString(java.lang.String tabs)
Evaluatorpublic java.lang.String toString()
toString in class java.lang.ObjectObject.toString()