xpath

T

Tony

Hello!

Thus is some text from the xpath 1.0 specification.
I don't really understand what they are trying to say in this piece of text
so i hope sombody can help me here.
The variable bindings, function library and namespace declarations used to
evaluate a subexpression are always the same as those used to evaluate the
containing expression. The context node, context position, and context size
used to evaluate a subexpression are sometimes different from those used to
evaluate the containing expression. Several kinds of expressions change the
context node; only predicates change the context position and context size
(see [2.4 Predicates]). When the evaluation of a kind of expression is
described, it will always be explicitly stated if the context node, context
position, and context size change for the evaluation of subexpressions; if
nothing is said about the context node, context position, and context size,
they remain unchanged for the evaluation of subexpressions of that kind of
expression.

//Tony
 
A

Arne Vajhøj

Thus is some text from the xpath 1.0 specification.
I don't really understand what they are trying to say in this piece of
text so i hope sombody can help me here.
The variable bindings, function library and namespace declarations used
to evaluate a subexpression are always the same as those used to
evaluate the containing expression. The context node, context position,
and context size used to evaluate a subexpression are sometimes
different from those used to evaluate the containing expression. Several
kinds of expressions change the context node; only predicates change the
context position and context size (see [2.4 Predicates]). When the
evaluation of a kind of expression is described, it will always be
explicitly stated if the context node, context position, and context
size change for the evaluation of subexpressions; if nothing is said
about the context node, context position, and context size, they remain
unchanged for the evaluation of subexpressions of that kind of expression.

I think they are trying to explain what is shared between and what
can be different between a subexpression and a containing expression.

My recommendation for a C# developer would be that if such
stuff becomes important, then the XPath is too complex
and you should look for another way of solving the problem -
a way that may be less elegant but more readable.

Arne
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top