为什么我的 xslt 在 for-each 循环中无所事事? [英] Why my xslt is looping for nothing in for-each loop?

查看:63
本文介绍了为什么我的 xslt 在 for-each 循环中无所事事?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是这个论坛的新手.我在 NLP 项目上工作,我需要提取综合依赖项.这是我的代码 xml 的一部分:

i'm new to this forum. I work on an NLP projet and i need to extract synthatic dependencies. Here is a part of my code xml :

<trame>
<codage>utf-8</codage>
<delimiteur><![CDATA[. ,:;!?/_-"'()[]{}§0*><=+#]]></delimiteur>
<items>
<item type="forme" pos="1"><f>euh</f><c>I</c><l>euh</l><a>B</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>ROOT</a><a>ROOT</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>B</a><a>O</a><a>O</a><a>B</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>U</a><a>O</a><a>0</a><a>0</a><a>-</a><a>92.90196761259227</a><a>91.26525310558021</a><a>U</a><a>U_mm</a><a>mm</a><a>79.99999999999996</a><a>259.01900000000006</a><a>$L1</a><a>-</a><a>B</a><a>B_hl</a><a>hl</a><a>U</a><a>U_Hm</a><a>filled-pause_Hm</a><a>filled-pause</a><a>Hm</a><a>U</a><a>U_Hm</a><a>U_filled-pause_Hm</a><a>filled-pause</a><a>Hm</a><a>U</a><a>U_filled-pause</a><a>U_filled-pause_Hm</a><a>filled-pause</a><a>Hm</a><a>0.460299</a><a>0.540299</a><a>(IU:B)_(PER:B)_(PAQ:U)_(GR:U)</a><a>(ASNUC:U)_(PER:B)</a><a>(PRN:O)_(PER:B)</a><a>(PON:O)_(PAQ:U)_(PER:B)_(GR:U)</a></item>
<item type="delim" pos="2"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="3"><f>bon</f><c>I</c><l>bon</l><a>B</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>ROOT</a><a>ROOT</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>U</a><a>O</a><a>0</a><a>0</a><a>-</a><a>93.61142792134571</a><a>91.82168183237229</a><a>U</a><a>U_mmm2</a><a>mmm2</a><a>280.0</a><a>139.99999999999997</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>B</a><a>B_mh</a><a>lone_mh</a><a>lone</a><a>mh</a><a>B</a><a>B_mh</a><a>B_strong_mh</a><a>strong</a><a>mh</a><a>B</a><a>B_weak</a><a>B_weak_mh</a><a>weak</a><a>mh</a><a>0.540299</a><a>0.820299</a><a>(IU:I)_(PER:I)_(PAQ:B)_(GR:B)</a><a>(ASNUC:U)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:B)_(PER:I)_(GR:B)</a></item>
<item type="delim" pos="4"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="5"><f>pour</f><c>Pre</c><l>pour</l><a>B</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>AD(33)</a><a>AD(33)</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>0</a><a>0</a><a>-</a><a>93.55803841320873</a><a>93.98225339281224</a><a>U</a><a>U_hh</a><a>hh</a><a>238.0380000000001</a><a>172.99049999999997</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>I</a><a>-</a><a>-</a><a>lone</a><a>mh</a><a>I</a><a>-</a><a>-</a><a>strong</a><a>mh</a><a>L</a><a>-</a><a>-</a><a>weak</a><a>mh</a><a>0.820299</a><a>1.099946</a><a>(IU:I)_(PER:I)_(PAQ:I)_(GR:I)</a><a>(ASNUC:O)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:I)_(PER:I)_(GR:I)</a></item>
<item type="delim" pos="6"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="7"><f>aller</f><c>V</c><l>aller</l><a>B</a><a>infinitive</a><a>-</a><a>-</a><a>-</a><a>-</a><a>DEP(5)</a><a>DEP(5)</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>S</a><a>W</a><a>-</a><a>93.81598710004415</a><a>95.55844144923779</a><a>U</a><a>U_hh</a><a>hh</a><a>229.99999999999997</a><a>185.00000000000003</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>L</a><a>-</a><a>-</a><a>lone</a><a>mh</a><a>L</a><a>-</a><a>-</a><a>strong</a><a>mh</a><a>U</a><a>U_strong</a><a>U_strong_hh</a><a>strong</a><a>hh</a><a>1.099946</a><a>1.390299</a><a>(IU:I)_(PER:I)_(PAQ:L)_(GR:L)</a><a>(ASNUC:O)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:L)_(PER:I)_(GR:L)</a></item>
<item type="delim" pos="8"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="9"><f>du</f><c>Pre+D</c><l>de+le</l><a>B</a><a>-</a><a>-</a><a>-</a><a>sg</a><a>masc</a><a>OBJ(7)</a><a>OBJ(7)</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>0</a><a>0</a><a>-</a><a>93.91472893724618</a><a>93.43828093467815</a><a>U</a><a>U_hm</a><a>hm</a><a>310.00000000000006</a><a>132.99049999999997</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>B</a><a>B_hm</a><a>motherless_hm</a><a>motherless</a><a>hm</a><a>B</a><a>B_hm</a><a>B_weak_hm</a><a>weak</a><a>hm</a><a>U</a><a>U_weak</a><a>U_weak_hm</a><a>weak</a><a>hm</a><a>1.390299</a><a>1.700299</a><a>(IU:I)_(PER:I)_(PAQ:B)_(GR:B)</a><a>(ASNUC:O)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:B)_(PER:I)_(GR:B)</a></item>
<item type="delim" pos="10"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="11"><f>CRDT</f><c>N</c><l>CRDT</l><a>B</a><a>-</a><a>-</a><a>-</a><a>sg</a><a>masc</a><a>DEP(9)</a><a>DEP(9)</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>W</a><a>0</a><a>-</a><a>89.88396668576091</a><a>92.21161134439662</a><a>U</a><a>U_hm</a><a>hm</a><a>482.86399999999975</a><a>230.9190000000001</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>L</a><a>-</a><a>-</a><a>motherless</a><a>hm</a><a>L</a><a>-</a><a>-</a><a>weak</a><a>hm</a><a>U</a><a>U_weak</a><a>U_weak_mm</a><a>weak</a><a>mm</a><a>1.700299</a><a>2.513163</a><a>(IU:I)_(PER:I)_(PAQ:L)_(GR:L)</a><a>(ASNUC:O)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:L)_(PER:I)_(GR:L)</a></item>
<item type="delim" pos="12"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="13"><f>à</f><c>Pre</c><l>à</l><a>B</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>OBL(7)</a><a>OBL(7)</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>0</a><a>0</a><a>H</a><a>90.26366309887754</a><a>88.57247375870008</a><a>U</a><a>U_ml</a><a>ml</a><a>340.0000000000003</a><a>343.1742499999999</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>B</a><a>B_mHl2</a><a>tail_mHl2</a><a>tail</a><a>mHl2</a><a>B</a><a>B_mHl2</a><a>B_tail_mHl2</a><a>tail</a><a>mHl2</a><a>B</a><a>B_strong</a><a>B_strong_mHl2</a><a>strong</a><a>mHl2</a><a>2.583163</a><a>2.923163</a><a>(IU:I)_(PER:I)_(PAQ:B)_(GR:B)</a><a>(ASNUC:O)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:B)_(PER:I)_(GR:B)</a></item>
<item type="delim" pos="14"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="15"><f>la</f><c>D</c><l>le</l><a>B</a><a>-</a><a>-</a><a>-</a><a>sg</a><a>fem</a><a>DEP(17)</a><a>DEP(17)</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>0</a><a>0</a><a>H</a><a>92.07666113239492</a><a>86.20573686283727</a><a>U</a><a>U_ll</a><a>ll</a><a>273.67600000000004</a><a>396.37325</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>I</a><a>-</a><a>-</a><a>tail</a><a>mHl2</a><a>I</a><a>-</a><a>-</a><a>tail</a><a>mHl2</a><a>L</a><a>-</a><a>-</a><a>strong</a><a>mHl2</a><a>2.923163</a><a>3.196839</a><a>(IU:I)_(PER:I)_(PAQ:I)_(GR:I)</a><a>(ASNUC:O)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:I)_(PER:I)_(GR:I)</a></item>
<item type="delim" pos="16"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="17"><f>gare</f><c>N</c><l>gare</l><a>B</a><a>-</a><a>-</a><a>-</a><a>sg</a><a>fem</a><a>DEP(13)</a><a>DEP(13)</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>0</a><a>S</a><a>-</a><a>88.17122257833398</a><a>97.38585113265228</a><a>U</a><a>U_HH</a><a>HH</a><a>346.4720000000003</a><a>344.91649999999987</a><a>$L1</a><a>0.237114</a><a>I</a><a>-</a><a>hl</a><a>L</a><a>-</a><a>-</a><a>tail</a><a>mHl2</a><a>L</a><a>-</a><a>-</a><a>tail</a><a>mHl2</a><a>U</a><a>U_tail</a><a>U_tail_HH</a><a>tail</a><a>HH</a><a>3.196839</a><a>3.959468</a><a>(IU:I)_(PER:I)_(PAQ:L)_(GR:L)</a><a>(ASNUC:O)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:L)_(PER:I)_(GR:L)</a></item>
<item type="delim" pos="18"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="19"><f>euh</f><c>I</c><l>euh</l><a>B</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>ROOT</a><a>ROOT</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>U</a><a>O</a><a>0</a><a>_</a><a>H</a><a>86.44444171734648</a><a>87.63023960575637</a><a>U</a><a>U_ml</a><a>ml</a><a>309.9999999999996</a><a>171.13449999999997</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>U</a><a>U_ml</a><a>filled-pause_ml</a><a>filled-pause</a><a>ml</a><a>U</a><a>U_ml</a><a>U_filled-pause_ml</a><a>filled-pause</a><a>ml</a><a>U</a><a>U_filled-pause</a><a>U_filled-pause_ml</a><a>filled-pause</a><a>ml</a><a>4.196582</a><a>4.506582</a><a>(IU:I)_(PER:I)_(PAQ:U)_(GR:U)</a><a>(ASNUC:U)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:U)_(PER:I)_(GR:U)</a></item>
<item type="delim" pos="20"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="21"><f>de</f><c>Pre</c><l>de</l><a>B</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>DEP(17)</a><a>DEP(17)</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>0</a><a>0</a><a>-</a><a>88.80414647402179</a><a>86.72856086599734</a><a>U</a><a>U_ll</a><a>ll</a><a>150.00000000000034</a><a>257.940333333333</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>B</a><a>B_lhH2</a><a>lone-dis-strong_lhH2</a><a>lone-dis-strong</a><a>lhH2</a><a>B</a><a>B_lhH2</a><a>B_dis-strong_lhH2</a><a>dis-strong</a><a>lhH2</a><a>U</a><a>U_strong</a><a>U_strong_lH</a><a>strong</a><a>lH</a><a>4.506582</a><a>4.656582</a><a>(IU:I)_(PER:I)_(PAQ:B)_(GR:B)</a><a>(ASNUC:O)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:B)_(PER:I)_(GR:B)</a></item>
<item type="delim" pos="22"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="23"><f>Grenoble</f><c>N</c><l>Grenoble</l><a>B</a><a>-</a><a>-</a><a>-</a><a>sg</a><a>masc-fem</a><a>DEP(21)</a><a>DEP(21)</a><a>-</a><a>-</a><a>-</a><a>-</a><a>O</a><a>I</a><a>O</a><a>O</a><a>L</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>0</a><a>0</a><a>-</a><a>90.53937299589111</a><a>97.37944865527233</a><a>U</a><a>U_Hh</a><a>Hh</a><a>307.07300000000083</a><a>515.0497499999998</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>I</a><a>-</a><a>-</a><a>lone-dis-strong</a><a>lhH2</a><a>I</a><a>-</a><a>-</a><a>dis-strong</a><a>lhH2</a><a>B</a><a>B_dis-strong</a><a>B_dis-strong_Hh</a><a>dis-strong</a><a>Hh</a><a>4.656582</a><a>5.427476</a><a>(IU:I)_(PER:I)_(PAQ:I)_(GR:I)</a><a>(ASNUC:O)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:I)_(PER:I)_(GR:I)</a></item>
<item type="delim" pos="24"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="25"><f>je</f><c>Cl</c><l>je</l><a>B</a><a>-</a><a>-</a><a>1</a><a>sg</a><a>-</a><a>PARA_DISFL(31)</a><a>-</a><a>-</a><a>PARA_DISFL(31)</a><a>SUB_INHERITED(33)</a><a>-</a><a>U</a><a>I</a><a>B</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>S</a><a>S</a><a>H</a><a>92.99257118776505</a><a>93.45817303640241</a><a>U</a><a>U_hh</a><a>hh</a><a>524.4369999999998</a><a>474.6527500000002</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>L</a><a>-</a><a>-</a><a>lone-dis-strong</a><a>lhH2</a><a>L</a><a>-</a><a>-</a><a>dis-strong</a><a>lhH2</a><a>L</a><a>-</a><a>-</a><a>dis-strong</a><a>Hh</a><a>5.427476</a><a>5.951913</a><a>(IU:I)_(PER:I)_(PAQ:L)_(GR:L)</a><a>(ASNUC:O)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:L)_(PER:I)_(GR:L)</a></item>
<item type="delim" pos="26"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>
<item type="forme" pos="27"><f>euh</f><c>I</c><l>euh</l><a>B</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>ROOT</a><a>ROOT</a><a>-</a><a>-</a><a>-</a><a>-</a><a>B</a><a>I</a><a>I</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>O</a><a>U</a><a>O</a><a>0</a><a>0</a><a>H</a><a>94.4949160993508</a><a>89.91711913085308</a><a>U</a><a>U_hl</a><a>hl</a><a>1071.9409999999998</a><a>312.52675000000016</a><a>$L1</a><a>-</a><a>I</a><a>-</a><a>hl</a><a>B</a><a>B_hml2</a><a>lone_hml2</a><a>lone</a><a>hml2</a><a>B</a><a>B_hml2</a><a>B_strong_hml2</a><a>strong</a><a>hml2</a><a>B</a><a>B_strong</a><a>B_strong_hml2</a><a>strong</a><a>hml2</a><a>5.951913</a><a>7.023854</a><a>(IU:I)_(PER:I)_(PAQ:B)_(GR:B)</a><a>(ASNUC:U)_(PER:I)</a><a>(PRN:O)_(PER:I)</a><a>(PON:O)_(PAQ:B)_(PER:I)_(GR:B)</a></item>
<item type="delim" pos="28"><f> </f><c>BLANK</c><l>BLANK</l><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a><a>-</a></item>

I try to extract SUB dependencies but the problem is not here . When i run my XLST debugger, xslt proc (saxon 9.8 ) goes back and forth in the foreach loop in template matching//item to foreach loop and it never executes the code in.And i don't know why. Here is my code :

I try to extract SUB dependencies but the problem is not here . When i run my XLST debugger, xslt proc (saxon 9.8 ) goes back and forth in the foreach loop in template matching //item to foreach loop and it never executes the code in. And i don't know why. Here is my code :

<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="2.0" 
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
    xmlns:saxon="http://saxon.sf.net/" extension-element-prefixes="saxon"
    xmlns:str="http://exslt.org/strings" exclude-result-prefixes="saxon str" >
    <xsl:output method="html" encoding="utf-8"/>
    <xsl:variable name="count" saxon:assignable="yes" select="0"/>
    
    <xsl:template match="/">    
           <xsl:apply-templates/>
        
    </xsl:template>
    
    <xsl:template match="//item">
        <xsl:for-each select="current()">
            <xsl:variable name="sub_index" select= "@pos"/>
            <xsl:variable name="suj_index" select="replace(a[7], '\w+\((\d+)\)', '$1')"/>
            <xsl:variable name="relations">
            <xsl:choose>
                <xsl:when test="number($sub_index &lt; number($suj_index))">
                    <xsl:variable name="sub" select="following-sibling::item[@pos = number($suj_index)]/f/text()"/>
                    <xsl:copy>
                        <element>
                            <gouverneur>
                                <xsl:value-of select="following-sibling::item[@pos = number($suj_index)]"/>
                            </gouverneur>
                            <dependant>
                                <xsl:value-of select="current()"/>
                            </dependant>
                            <mots>
                                <xsl:variable name="rel_obj" select="concat(f/text(), ' ', following-sibling::item[@pos =$suj_index]/f/text())"/>
                            </mots>
                        </element>
                    </xsl:copy>
                    <saxon:assign name="count" select="$count+1"/>
                </xsl:when>
                <xsl:otherwise>
                    <xsl:variable name="sub" select="preceding-sibling::item[@pos = number($suj_index)]/f/text()"/>
                    <xsl:copy>
                        <element>
                            <gouverneur>
                                <xsl:value-of select="following-sibling::item[@pos = number($suj_index)]"/>
                            </gouverneur>
                            <dependant>
                                <xsl:value-of select="current()"/>
                            </dependant>
                            <mots>
                                <xsl:variable name="rel_obj" select="concat(f/text(), ' ', following-sibling::item[@pos =$suj_index]/f/text())"/>
                            </mots>
                        </element>
                    </xsl:copy>
                    <saxon:assign name="count" select="$count+1"/>
                </xsl:otherwise>
             </xsl:choose>
            </xsl:variable>
        </xsl:for-each>
    </xsl:template>
    
</xsl:stylesheet>

The problem comes from current(), Saxon, me (probably)? It go beck and forth :

The problem comes from current(), Saxon, me (probably)? It go beck and forth :

    <xsl:template match="//item">
        <xsl:for-each select="current()">

The current node is empty ?

The current node is empty ?

推荐答案

  1. <xsl:template match="//item"> matches one item; for-each is not needed.
  2. You fill <xsl:variable name="relations"> but never use it
  3. You fill <xsl:variable name="rel_obj"/> but never use it

这篇关于为什么我的 xslt 在 for-each 循环中无所事事?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆