net.sf.saxon.expr

Class AtomicMappingExpression

public final class AtomicMappingExpression extends SlashExpression implements ContextMappingFunction

An atomic mapping expression is a slash expression A/B where B has a static type that is an atomic type. For example, * / name().
Constructor Summary
AtomicMappingExpression(Expression start, Expression step)
Constructor
Method Summary
Expressioncopy()
Copy an expression.
voidexplain(ExpressionPresenter destination)
Diagnostic print of expression structure.
booleanisHybrid()
Determine whether this expression is capable (as far as static analysis is concerned) of returning a mixture of nodes and atomic values.
SequenceIteratoriterate(XPathContext context)
Iterate the path-expression in a given context
ExpressiontypeCheck(ExpressionVisitor visitor, ItemType contextItemType)
Type-check the expression

Constructor Detail

AtomicMappingExpression

public AtomicMappingExpression(Expression start, Expression step)
Constructor

Parameters: start A node-set expression denoting the absolute or relative set of nodes from which the navigation path should start. step The step to be followed from each node in the start expression to yield a new node-set

Method Detail

copy

public Expression copy()
Copy an expression. This makes a deep copy.

Returns: the copy of the original expression

explain

public void explain(ExpressionPresenter destination)
Diagnostic print of expression structure. The abstract expression tree is written to the supplied output destination.

isHybrid

public boolean isHybrid()
Determine whether this expression is capable (as far as static analysis is concerned) of returning a mixture of nodes and atomic values. If so, this needs to be prevented at run time

Returns: true if the static type allows both nodes and atomic values

iterate

public SequenceIterator iterate(XPathContext context)
Iterate the path-expression in a given context

Parameters: context the evaluation context

typeCheck

public Expression typeCheck(ExpressionVisitor visitor, ItemType contextItemType)
Type-check the expression