Xalan est un bibliotèque Java qui permet lancer des requettes XPath et appliquer les transformations XSLT à votre document.
javac ApplyXPath.java
Pour compiler le code Java on a deux options:
javac -cp "C:\xalan-j_2_7_1\xalan.jar" ApplyXPath.java
et après pour l’executer:
java -cp ".;C:\xalan-j_2_7_1\xalan.jar" ApplyXPath foo.xml /
java ApplyXPath foo.xml /
Loading classes, parsing foo.xml, and setting up serializer
Querying DOM using /
<output>
<doc>
<name first="David" last="Marston"/>
<name first="David" last="Bertoni"/>
<name first="Donald" last="Leslie"/>
<name first="Emily" last="Farmer"/>
<name first="Joseph" last="Kesselman"/>
<name first="Myriam" last="Midy"/>
<name first="Paul" last="Dick"/>
<name first="Stephen" last="Auriemma"/>
<name first="Scott" last="Boag"/>
<name first="Shane" last="Curcuru"/>
</doc>
</output>