You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xalan.apache.org by John Ollier <jo...@capula.co.uk> on 2003/02/13 15:40:32 UTC
xpath on the fly
Can anyone help me with this. Here is a fragment of my XML:
<node careZone="primary" id="chest_1_1" variance="false">
<nodeText>Retrosternal chest pain</nodeText>
<left>350</left>
<top>50</top>
<height>45</height>
<width>120</width>
<junctionYDifference>10</junctionYDifference>
<childID>chest_1_2</childID>
<childID>chest_1_3</childID>
</node>
<node careZone="primary" id="chest_1_2" variance="true">
<nodeText>Consider atypical presentation of cardiac ischaemia</nodeText>
<left>150</left>
<top>85</top>
<height>55</height>
<width>160</width>
<junctionYDifference>10</junctionYDifference>
</node>
What I want to do is produce:
<line from="350" to="150" />
i.e. take some data from the first <node> and some from the <node> with
@id=chest_1_2 that being the id stored in the <childID> element of the
first Node. I have tried all kinds of things, but none work.
I guess what I'm trying to do is generate some Xpath on the fly. Is this
possible?
Thanks in advance
John
--
Capula Elan
Palmerston Court Palmerston Way London SW8 4AJ
www.capula.co.uk
doing IT for you in healthcare
phone: [+44 ] 020 7840 6200
fax: [+44] 020 7840 6222