public final class FTWeight extends FTExpr
| Constructor and Description |
|---|
FTWeight(InputInfo ii,
FTExpr e,
Expr w)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
FTExpr |
comp(QueryContext ctx)
Compiles and optimizes the expression, assigns data types and
cardinalities.
|
int |
count(Var v)
Counts how often the specified variable is used by an expression.
|
boolean |
indexAccessible(IndexContext ic)
Checks if an expression can be rewritten to an index access.
|
FTNode |
item(QueryContext ctx,
InputInfo ii)
This method is called by the sequential full-text evaluation.
|
FTIter |
iter(QueryContext ctx)
This method is called by the index-based full-text evaluation.
|
void |
plan(Serializer ser)
Serializes the expression tree.
|
boolean |
removable(Var v)
Checks if the specified variable is replaceable by a context item.
|
FTExpr |
remove(Var v)
|
java.lang.String |
toString() |
boolean |
uses(Expr.Use u)
Indicates if an expression uses the specified type or operation.
|
indexEquivalentcheckBln, checkColl, checkCreate, checkCtx, checkDbl, checkDBNode, checkEStr, checkEStr, checkIO, checkItem, checkItr, checkItr, checkMap, checkNode, checkNoEmpty, checkStr, checkType, checkUp, checkUp, checkWrite, compBln, ebv, optPre, preEval, size, test, type, valueaddText, compEbv, hasFreeVars, isEmpty, isFunction, isItem, isVacuous, isValue, iterable, markTailCalls, sameAsdescription, infopublic FTExpr comp(QueryContext ctx) throws QueryException
Exprcomp in class FTExprctx - query contextQueryException - query exceptionpublic FTNode item(QueryContext ctx, InputInfo ii) throws QueryException
FTExpritem in class FTExprctx - query contextii - input infoQueryException - query exceptionpublic FTIter iter(QueryContext ctx)
FTExprpublic boolean indexAccessible(IndexContext ic)
ExprExpr.indexEquivalent(org.basex.query.util.IndexContext) must be
implemented as well.indexAccessible in class Expric - index contextpublic boolean uses(Expr.Use u)
ExprExpr.comp(org.basex.query.QueryContext) methods to test the properties of sub-expressions.
It will return true as soon as at least one test is successful.public int count(Var v)
ExprGFLWOR.comp(org.basex.query.QueryContext) to rewrite where clauses as predicates and
remove statically bound or unused clausesGFLWOR.compHoist(org.basex.query.QueryContext) to hoist independent variablespublic boolean removable(Var v)
ExprPreds.removable(org.basex.query.util.Var), if one of the variables is used within
a predicate.MixedPath.removable(org.basex.query.util.Var), if the variable occurs within
the path.Group.removable(org.basex.query.util.Var), as the group by expression depends on
variable references.GFLWOR.comp(org.basex.query.QueryContext) to rewrite where clauses
into predicates.public FTExpr remove(Var v)
ExprVarRef expressions for the given variable
by a Context reference. This method is called by
GFLWOR.comp(org.basex.query.QueryContext) to rewrite where clauses as predicates.public void plan(Serializer ser) throws java.io.IOException
ExprInfo