Interface IExpression
-
- All Known Subinterfaces:
IContextExpression<T>
,IFilterExpression
,IMatchExpression<T>
public interface IExpression
A node in the expression tree- Since:
- 2.0
- Restriction:
- This interface is not intended to be implemented directly by clients.
- Restriction:
- This interface is not intended to be extended directly by clients.
-
-
Field Summary
Fields Modifier and Type Field Description static int
TYPE_ALL
static int
TYPE_AND
static int
TYPE_ARRAY
static int
TYPE_ASSIGNMENT
static int
TYPE_AT
static int
TYPE_COLLECT
static int
TYPE_CONDITION
static int
TYPE_EQUALS
static int
TYPE_EXISTS
static int
TYPE_FIRST
static int
TYPE_FLATTEN
static int
TYPE_FUNCTION
static int
TYPE_GREATER
static int
TYPE_GREATER_EQUAL
static int
TYPE_INTERSECT
static int
TYPE_LAMBDA
static int
TYPE_LATEST
static int
TYPE_LESS
static int
TYPE_LESS_EQUAL
static int
TYPE_LIMIT
static int
TYPE_LITERAL
static int
TYPE_MATCHES
static int
TYPE_MEMBER
static int
TYPE_NOT
static int
TYPE_NOT_EQUALS
static int
TYPE_OR
static int
TYPE_PARAMETER
static int
TYPE_PIPE
static int
TYPE_SELECT
static int
TYPE_TRAVERSE
static int
TYPE_UNION
static int
TYPE_UNIQUE
static int
TYPE_VARIABLE
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
accept(IExpressionVisitor visitor)
Let the visitor visit this instance and all expressions that this instance contains.Object
evaluate(IEvaluationContext context)
Evaluate this expression with given context and variables.int
getExpressionType()
Returns the expression type (see TYPE_xxx constants).void
toLDAPString(StringBuffer collector)
Appends the an LDAP filter representation of this expression to thecollector
.void
toString(StringBuffer collector)
Appends the string representation of this expression to the collectorcollector
.
-
-
-
Field Detail
-
TYPE_ALL
static final int TYPE_ALL
- See Also:
- Constant Field Values
-
TYPE_AND
static final int TYPE_AND
- See Also:
- Constant Field Values
-
TYPE_AT
static final int TYPE_AT
- See Also:
- Constant Field Values
-
TYPE_EQUALS
static final int TYPE_EQUALS
- See Also:
- Constant Field Values
-
TYPE_EXISTS
static final int TYPE_EXISTS
- See Also:
- Constant Field Values
-
TYPE_GREATER
static final int TYPE_GREATER
- See Also:
- Constant Field Values
-
TYPE_GREATER_EQUAL
static final int TYPE_GREATER_EQUAL
- See Also:
- Constant Field Values
-
TYPE_LAMBDA
static final int TYPE_LAMBDA
- See Also:
- Constant Field Values
-
TYPE_LESS
static final int TYPE_LESS
- See Also:
- Constant Field Values
-
TYPE_LESS_EQUAL
static final int TYPE_LESS_EQUAL
- See Also:
- Constant Field Values
-
TYPE_LITERAL
static final int TYPE_LITERAL
- See Also:
- Constant Field Values
-
TYPE_MATCHES
static final int TYPE_MATCHES
- See Also:
- Constant Field Values
-
TYPE_MEMBER
static final int TYPE_MEMBER
- See Also:
- Constant Field Values
-
TYPE_NOT
static final int TYPE_NOT
- See Also:
- Constant Field Values
-
TYPE_NOT_EQUALS
static final int TYPE_NOT_EQUALS
- See Also:
- Constant Field Values
-
TYPE_OR
static final int TYPE_OR
- See Also:
- Constant Field Values
-
TYPE_PARAMETER
static final int TYPE_PARAMETER
- See Also:
- Constant Field Values
-
TYPE_VARIABLE
static final int TYPE_VARIABLE
- See Also:
- Constant Field Values
-
TYPE_ARRAY
static final int TYPE_ARRAY
- See Also:
- Constant Field Values
-
TYPE_ASSIGNMENT
static final int TYPE_ASSIGNMENT
- See Also:
- Constant Field Values
-
TYPE_COLLECT
static final int TYPE_COLLECT
- See Also:
- Constant Field Values
-
TYPE_CONDITION
static final int TYPE_CONDITION
- See Also:
- Constant Field Values
-
TYPE_FIRST
static final int TYPE_FIRST
- See Also:
- Constant Field Values
-
TYPE_FLATTEN
static final int TYPE_FLATTEN
- See Also:
- Constant Field Values
-
TYPE_FUNCTION
static final int TYPE_FUNCTION
- See Also:
- Constant Field Values
-
TYPE_INTERSECT
static final int TYPE_INTERSECT
- See Also:
- Constant Field Values
-
TYPE_LATEST
static final int TYPE_LATEST
- See Also:
- Constant Field Values
-
TYPE_LIMIT
static final int TYPE_LIMIT
- See Also:
- Constant Field Values
-
TYPE_PIPE
static final int TYPE_PIPE
- See Also:
- Constant Field Values
-
TYPE_SELECT
static final int TYPE_SELECT
- See Also:
- Constant Field Values
-
TYPE_TRAVERSE
static final int TYPE_TRAVERSE
- See Also:
- Constant Field Values
-
TYPE_UNION
static final int TYPE_UNION
- See Also:
- Constant Field Values
-
TYPE_UNIQUE
static final int TYPE_UNIQUE
- See Also:
- Constant Field Values
-
-
Method Detail
-
accept
boolean accept(IExpressionVisitor visitor)
Let the visitor visit this instance and all expressions that this instance contains.- Parameters:
visitor
- The visiting visitor.- Returns:
true
if the visitor should continue visiting,false
otherwise.
-
evaluate
Object evaluate(IEvaluationContext context)
Evaluate this expression with given context and variables.- Parameters:
context
- The evaluation context- Returns:
- The result of the evaluation.
-
getExpressionType
int getExpressionType()
Returns the expression type (see TYPE_xxx constants).
-
toString
void toString(StringBuffer collector)
Appends the string representation of this expression to the collectorcollector
.
-
toLDAPString
void toLDAPString(StringBuffer collector)
Appends the an LDAP filter representation of this expression to thecollector
.- Throws:
UnsupportedOperationException
- if the expression contains nodes that cannot be represented in an LDAP filter
-
-