Package org.nuxeo.ecm.directory.multi
Class MultiDirectoryExpressionEvaluator
java.lang.Object
org.nuxeo.ecm.directory.multi.MultiDirectoryExpressionEvaluator
Evaluator for an
Expression
in the context of the various subdirectories of a MultiDirectory's source.
The result is a set of entry ids.
The strategy for evaluation is to delegate as much as possible of the evaluation of expressions to subdirectories themselves.
We do a depth-first evaluation of expressions, delaying actual evaluation while an expression's references all fall into the same subdirectory.
- Since:
- 10.3
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Result is a set of entry ids.static class
Result is an operand associated to at most one subdirectory.static class
Renames the references according to a map.static interface
The result of an evaluation of an expression. -
Field Summary
-
Constructor Summary
ConstructorDescriptionMultiDirectoryExpressionEvaluator
(MultiDirectorySession.SourceInfo sourceInfo, String idField, String dirName) -
Method Summary
Modifier and TypeMethodDescriptioneval
(Expression expr) Evaluates an expression and returns the set of matching ids.protected MultiDirectoryExpressionEvaluator.Result
evalAndOr
(Expression expr) protected MultiDirectoryExpressionEvaluator.Result
evalExpression
(Expression expr) protected MultiDirectoryExpressionEvaluator.Result
protected MultiDirectoryExpressionEvaluator.Result
evalOperand
(Operand op) protected MultiDirectoryExpressionEvaluator.Result
evalReference
(Reference ref) protected MultiDirectoryExpressionEvaluator.Result
Evaluates an operand associated to a single directory and returns the set of matching ids.Evaluates a result and returns the set of matching ids.intersection
(Set<String> a, Set<String> b) Set intersection.Set union.
-
Field Details
-
dirInfos
-
idField
-
dirName
-
-
Constructor Details
-
MultiDirectoryExpressionEvaluator
public MultiDirectoryExpressionEvaluator(MultiDirectorySession.SourceInfo sourceInfo, String idField, String dirName)
-
-
Method Details
-
eval
Evaluates an expression and returns the set of matching ids. -
evalExpression
-
evalSimpleExpression
-
evalOperand
-
evalReference
-
evalAndOr
-
evalMultiExpression
-
evaluate
Evaluates a result and returns the set of matching ids. -
evaluate
Evaluates an operand associated to a single directory and returns the set of matching ids. -
union
Set union. -
intersection
Set intersection.
-