AntContrib @ sourceforge:
<taskdef resource="net/sf/antcontrib/antcontrib.properties" />
<target name="castor" depends="init">
<foreach target="process" param="file">
<fileset dir="${schema}" includes="*.xsd"/>
</foreach>
</target>
<target name="process">
<java classname="org.exolab.castor.builder.SourceGenerator">
<arg line="-i ${file} -dest ${build} -package test"/>
</java>
</target>
Not tried, but it should (hopefully) work.
Jan Mat�rne
-----Urspr�ngliche Nachricht-----
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Gesendet am: Mittwoch, 8. Januar 2003 11:26
An: [EMAIL PROTECTED]
Betreff: Execute <java> task several times
Hello,
I would like to execute a Java class with the <java> task but with
several times passing different arguments to it. The arguments are
constructed using the members of a fileset.
<target name="castor" depends="init"
description="generate the source code from the XML schemas">
<fileset dir="${schema}" includes="*.xsd"/>
<!-- This task should be executed on the elements of the fileset:
each time ${schema}/schema.xsd below should be replaced
with the corresponding filename.
-->
<java classname="org.exolab.castor.builder.SourceGenerator">
<arg line="-i ${schema}/schema.xsd -dest ${build} -package
test"/>
</java>
</target>
Any idea how to do it?
Thanks in advance.
Peter
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>