Package net.sf.saxon.expr.flwor

This package contains classes responsible for evaluation of FLWOR expressions, in particular, those clauses of FLWOR expressions that are supported in Saxon-HE.

See:
          Description

Interface Summary
ExpressionProcessor  
 

Class Summary
Clause A "Clause" refers specifically to one of the clauses of a FLWOR expression, for example the "for" clause, the "let" clause, the "where" or "order by" clause.
FLWORExpression This class represents a FLWOR expression, evaluated using tuple streams
ForClause A "for" clause in a FLWOR expression
ForClauseOuterPull This class represents the tuple stream returned by a "for" clause in a FLWOR expression
ForClauseOuterPush This class implements the changes to the tuple stream effected by a "for" clause in a FLWOR expression where "allowing empty" is specified
ForClausePull This class implements the changes to the tuple stream effected by a "for" clause in a FLWOR expression
ForClausePush This class implements the changes to the tuple stream effected by a "for" clause in a FLWOR expression
LetClause A "let" clause in a FLWOR expression
LetClausePull Implements the changes to a tuple stream effected by the Let clause in a FLWOR expression
LetClausePush Implements the changes to a tuple stream effected by the Let clause in a FLWOR expression
LocalVariableBinding Represents the defining occurrence of a variable declared within a FLWOR expression, for example the $p in "for $x at $p in ...".
OrderByClause This class represents an "order by" clause in a FLWOR expression
OrderByClausePull Represents the tuple stream delivered by an "order by" clause.
OrderByClausePush Represents the tuple stream delivered by an "order by" clause.
ReturnClauseIterator This iterator applies the return expression of a FLWOR expression to each of the tuples in a supplied tuple stream, returning the result as an iterator
ReturnClausePush The class represents the final stage in a push-mode tuple pipeline.
SingularityPull The "singularity" tuple stream delivers a single empty tuple.
Tuple A tuple, as it appears in an XQuery tuple stream handled by extended FLWOR expressions.
TupleExpression A tuple expression is an expression that returns a tuple.
TuplePull Abtract class representing a tuple stream (used to evaluate a FLWOR expression) in pull mode (where the consumer of tuples activates the provider of those tuples)
TuplePush Abtract class representing a tuple stream (used to evaluate a FLWOR expression) in push mode (where the provider of tuples activates the consumer of those tuples)
WhereClause A "where" clause in a FLWOR expression
WhereClausePull This class represents the tuple stream delivered as the output of a where clause in a FLWOR expression: that is, it returns all the tuples in its input stream that satisfy a specified predicate.
WhereClausePush This class represents the tuple stream delivered as the output of a where clause in a FLWOR expression: that is, it supplies all the tuples in its input stream that satisfy a specified predicate.
 

Package net.sf.saxon.expr.flwor Description

This package contains classes responsible for evaluation of FLWOR expressions, in particular, those clauses of FLWOR expressions that are supported in Saxon-HE.

FLWOR expressions are implemented as a pipeline of clauses, much as described in the specification. The pipeline can be evaluated in push or pull mode: in push mode, the supplier of tuples activates the consumer of tuples when a tuple is ready to be processed, while in pull mode, the consumer of tuples calls the supplier to request the next tuple. In both cases the "tuple" is not actually passed as an argument or result of this call, but is represented by the state of local variables in the XPathContext stack on completion of the call. The only time tuples are represented as real objects is when the processing is not pipelined, for example when tuples need to be sorted or grouped.

Simple "for" and "let" expressions do not use this mechanism: instead, they are compiled to a ForExpression or LetExpression.

Michael H. Kay
Saxonica Limited
28 November 2011



Copyright (c) 2004-2011 Saxonica Limited. All rights reserved.