i've modified the the org.apache.tools.ant.CallTarget class to support 
iterations.

it allows to execute the antcall task in a looping way. the iterate
attribute contains the list (space separated) to iterate through, the
iterator attribute defines the name of the property that will contain
the element of the current iteration (the looping variable). for example:

    <target name="buildModule" if="module">
        <echo message="building module ${module}"/>
        ...
    </target>

    <target name="build">
        <property name="modules" value="frontend backend reporting"/>

        <antcall target="buildModule"
              iterate="${modules}" iterator="module" />
    </target>

the antcall task will invoke the buildModule target 3 times, each time
the value of the iterator variable -module- will be set to "frontend",
"backend" and "reporting".


attached you'll find the modified CallTarget.java file.

regards.

a

Attachment: CallTarget.java
Description: application/unknown-content-type-java_auto_file

Reply via email to