|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.basex.query.ExprInfo
org.basex.query.xpath.expr.Expr
public abstract class Expr
Common interface for all expressions.
Constructor Summary | |
---|---|
Expr()
|
Method Summary | |
---|---|
abstract Expr |
comp(XPContext ctx)
Optimizes the expression. |
abstract Item |
eval(XPContext ctx)
Evaluates the expression with the specified context set. |
Expr |
indexEquivalent(XPContext ctx,
Step step,
boolean seq)
Returns an equivalent expression which accesses an index structure. |
int |
indexSizes(XPContext ctx,
Step step,
int min)
Returns the number of results if this query is evaluated by an index. |
java.lang.Class<?> |
returnedValue()
Gets the expected return type. |
boolean |
sameAs(Expr cmp)
Checks current and specified expression for equivalence. |
abstract boolean |
usesPos()
Checks whether this Expression (or its children) make use of the position parameter. |
abstract boolean |
usesSize()
Checks whether this Expression (or its children) make use of the setsize parameter. |
Methods inherited from class org.basex.query.ExprInfo |
---|
color, info, name, plan, toString |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Expr()
Method Detail |
---|
public abstract Expr comp(XPContext ctx) throws QueryException
ctx
- expression context
QueryException
- evaluation exceptionpublic abstract Item eval(XPContext ctx) throws QueryException
ctx
- query context
QueryException
- evaluation exceptionpublic final java.lang.Class<?> returnedValue()
eval(org.basex.query.xpath.XPContext)
methodpublic boolean sameAs(Expr cmp)
cmp
- expression to be compared
public abstract boolean usesSize()
public abstract boolean usesPos()
public Expr indexEquivalent(XPContext ctx, Step step, boolean seq) throws QueryException
ctx
- rootstep
- location stepseq
- flag for sequential evaluation
QueryException
- evaluation exceptionpublic int indexSizes(XPContext ctx, Step step, int min)
Integer.MAX_VALUE
is returned, no index access is possible.
ctx
- rootstep
- the current location stepmin
- current minimum index hits
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |