| Modifier and Type | Field and Description |
|---|---|
private static boolean |
COMPARE_GREATER
Constants used for comparisons
|
private static boolean |
COMPARE_LESSER |
private static int |
EQUALITY_MATCH
equality matching type constant
|
private static int |
ORDERING_MATCH
ordering matching type constant
|
private ScopeEvaluator |
scopeEvaluator
ScopeNode evaluator we depend on
|
private static int |
SUBSTRING_MATCH
substring matching type constant
|
private SubstringEvaluator |
substringEvaluator
Substring node evaluator we depend on
|
| Constructor and Description |
|---|
LeafEvaluator(SubstringEvaluator substringEvaluator)
Creates a leaf expression node evaluator.
|
| Modifier and Type | Method and Description |
|---|---|
private boolean |
evalEquality(org.apache.directory.api.ldap.model.filter.EqualityNode<?> node,
org.apache.directory.api.ldap.model.entry.Entry entry)
Evaluates a simple equality attribute value assertion on a perspective
candidate.
|
private boolean |
evalGreaterOrLesser(org.apache.directory.api.ldap.model.filter.SimpleNode<?> node,
org.apache.directory.api.ldap.model.entry.Entry entry,
boolean isGreaterOrLesser)
Evaluates a simple greater than or less than attribute value assertion on
a perspective candidate.
|
private boolean |
evalPresence(org.apache.directory.api.ldap.model.schema.AttributeType attributeType,
org.apache.directory.api.ldap.model.entry.Entry entry)
Evaluates a simple presence attribute value assertion on a perspective
candidate.
|
boolean |
evaluate(org.apache.directory.api.ldap.model.filter.ExprNode node,
org.apache.directory.api.ldap.model.name.Dn dn,
org.apache.directory.api.ldap.model.entry.Entry entry)
Evaluates a candidate to determine if a filter expression selects it.
|
private org.apache.directory.api.ldap.model.schema.LdapComparator<? super java.lang.Object> |
getComparator(org.apache.directory.api.ldap.model.schema.AttributeType attributeType)
Gets the comparator for equality matching.
|
private org.apache.directory.api.ldap.model.schema.MatchingRule |
getMatchingRule(org.apache.directory.api.ldap.model.schema.AttributeType attributeType,
int matchType)
Gets the matching rule for an attributeType.
|
private org.apache.directory.api.ldap.model.schema.Normalizer |
getNormalizer(org.apache.directory.api.ldap.model.schema.AttributeType attributeType)
Gets the normalizer for equality matching.
|
ScopeEvaluator |
getScopeEvaluator() |
SubstringEvaluator |
getSubstringEvaluator() |
private static final int EQUALITY_MATCH
private static final int ORDERING_MATCH
private static final int SUBSTRING_MATCH
private SubstringEvaluator substringEvaluator
private ScopeEvaluator scopeEvaluator
private static final boolean COMPARE_GREATER
private static final boolean COMPARE_LESSER
public LeafEvaluator(SubstringEvaluator substringEvaluator)
schemaManager - The server schemaManagerpublic ScopeEvaluator getScopeEvaluator()
public SubstringEvaluator getSubstringEvaluator()
public boolean evaluate(org.apache.directory.api.ldap.model.filter.ExprNode node,
org.apache.directory.api.ldap.model.name.Dn dn,
org.apache.directory.api.ldap.model.entry.Entry entry)
throws org.apache.directory.api.ldap.model.exception.LdapException
evaluate in interface Evaluatordn - the normalized distinguished name of the entry being testedentry - the entry to evaluateorg.apache.directory.api.ldap.model.exception.LdapException - if there is a database fault during evaluationprivate boolean evalGreaterOrLesser(org.apache.directory.api.ldap.model.filter.SimpleNode<?> node,
org.apache.directory.api.ldap.model.entry.Entry entry,
boolean isGreaterOrLesser)
throws org.apache.directory.api.ldap.model.exception.LdapException
node - the greater than or less than node to evaluateentry - the perspective candidateisGreater - true if it is a greater than or equal to comparison,
false if it is a less than or equal to comparison.org.apache.directory.api.ldap.model.exception.LdapException - if there is a database access failureprivate boolean evalPresence(org.apache.directory.api.ldap.model.schema.AttributeType attributeType,
org.apache.directory.api.ldap.model.entry.Entry entry)
throws org.apache.directory.api.ldap.model.exception.LdapException
attrId - the name of the attribute tested for presenceentry - the perspective candidateorg.apache.directory.api.ldap.model.exception.LdapExceptionprivate boolean evalEquality(org.apache.directory.api.ldap.model.filter.EqualityNode<?> node,
org.apache.directory.api.ldap.model.entry.Entry entry)
throws org.apache.directory.api.ldap.model.exception.LdapException
node - the equality node to evaluateentry - the perspective candidateorg.apache.directory.api.ldap.model.exception.LdapException - if there is a database access failureprivate org.apache.directory.api.ldap.model.schema.LdapComparator<? super java.lang.Object> getComparator(org.apache.directory.api.ldap.model.schema.AttributeType attributeType)
throws org.apache.directory.api.ldap.model.exception.LdapException
attributeType - the attributeTypeorg.apache.directory.api.ldap.model.exception.LdapException - if there is a failureprivate org.apache.directory.api.ldap.model.schema.Normalizer getNormalizer(org.apache.directory.api.ldap.model.schema.AttributeType attributeType)
throws org.apache.directory.api.ldap.model.exception.LdapException
attributeType - the attributeTypeorg.apache.directory.api.ldap.model.exception.LdapException - if there is a failureprivate org.apache.directory.api.ldap.model.schema.MatchingRule getMatchingRule(org.apache.directory.api.ldap.model.schema.AttributeType attributeType,
int matchType)
throws org.apache.directory.api.ldap.model.exception.LdapException
attributeType - the attributeTypeorg.apache.directory.api.ldap.model.exception.LdapException - if there is a failure