public final class Root extends Simple
Modifier and Type | Method and Description |
---|---|
boolean |
accept(ASTVisitor visitor)
Traverses this expression, notifying the visitor of declared and used variables,
and checking the tree for other recursive properties.
|
Expr |
compile(QueryContext qc,
VarScope scp)
Compiles and optimizes the expression, assigns types and cardinalities.
|
Expr |
copy(QueryContext qc,
VarScope scp,
IntObjMap<Var> vs)
Copies an expression.
|
boolean |
has(Expr.Flag flag)
Indicates if an expression has the specified compiler property.
|
Iter |
iter(QueryContext qc)
Evaluates the expression and returns an iterator on the resulting items.
|
boolean |
iterable()
Indicates if the items returned by this expression are iterable, i.e., if returned nodes are
in document order and contain no duplicates.
|
static ANode |
root(Value v)
Returns the root node of the specified item.
|
boolean |
sameAs(Expr cmp)
Compares the current and specified expression for equality.
|
String |
toString() |
checkUp, count, exprSize, inline, plan, removable
atomItem, atomValue, checkAtomic, checkNoEmpty, checkNoEmpty, checkNoneUp, checkNoUp, checkType, compBln, copyType, ctxValue, ebv, item, optPre, optPre, preEval, seqType, seqType, size, test, toArray, toArray, toAtomItem, toB64, toB64, toBin, toBin, toBoolean, toBoolean, toBytes, toBytes, toDouble, toDouble, toElem, toEmptyNode, toEmptyToken, toFloat, toFunc, toItem, toLong, toLong, toMap, toMap, toNode, toNode, toNumber, toQNm, toQNm, toToken, toToken, value
atomIter, data, hasFreeVars, indexAccessible, inlineAll, isEmpty, isFunction, isVacuous, isValue, markTailCalls, optimize, optimizeEbv, typeCheck, uses, visitAll
addPlan, addPlan, description, planAttr, planElem, toErrorString
public Root(InputInfo info)
info
- input infopublic Expr compile(QueryContext qc, VarScope scp)
Expr
QueryContext.compile()
.public Iter iter(QueryContext qc) throws QueryException
Expr
Expr.item(QueryContext, InputInfo)
must be implemented
by an expression, as it may be called by this method.iter
in class ParseExpr
qc
- query contextQueryException
- query exceptionpublic Expr copy(QueryContext qc, VarScope scp, IntObjMap<Var> vs)
Expr
public static ANode root(Value v)
v
- input nodepublic boolean has(Expr.Flag flag)
Expr
true
if at least one test is successful.public boolean accept(ASTVisitor visitor)
Expr
public boolean iterable()
Expr
AxisPath
.public boolean sameAs(Expr cmp)
Expr
Copyright © 2005–2015 BaseX Team. All rights reserved.