I have a member set that needs to be tokenized and then navigated. I have tried analyze-string and tokenize methods but am unable to navigate from the point of tokenization due to "no context" error in both cases.
If I can't navigate and also can't save the variable format individual tokens to a persistent structure and then retrieve, how do I solve this problem?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have a member set that needs to be tokenized and then navigated. I have tried analyze-string and tokenize methods but am unable to navigate from the point of tokenization due to "no context" error in both cases.
If I can't navigate and also can't save the variable format individual tokens to a persistent structure and then retrieve, how do I solve this problem?
Try assigning a variable to the relevant node before tokenizing its value. You can then navigate from the contents of this variable:
<xsl:variable name="x" select="."/>
<xsl:for-each select="tokenize(.)">
<xsl:if test="$x/a/b/c/d = ..."
Michael Kay
Thanks Mike. That is the solution. I've used the SaxonB processor for a month or so and it works beautifully.
We are generating large Deployment and Configuration XML files from model descriptions exported to XML. The processor is used for transforms.