This week's book giveaway is in the OCPJP forum. We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line! See this thread for details.
can we write a build file with a for loop that runs n times ?
For eg., i want to run a for loop for n no of time depends on the value of n. But i dont want to write in java and call in build file...i am just trying with ANT tasks itself todo this... if anyone gives me a hint, or know abt how to write, kindly help me...
Ant doesn't directly support this. It very deliberately doesn't have scripting-like constructs becasue it is not a scripting language. However, you can get the ant-contrib extensions which include this sort of stuff.
Thanks Paul and Ulf !! you have given me a hint...
Using ANT Contrib tasks , i just wrote the simple loop
This code results in, printing the values one by one. But the size is fized and i need to give all the inputs in the list attribute...Is there any way that i can specify the list = No of values (n) and iterate it by the loop ( i= i+1). I tried several possibilities, but i cud not get it. Can anyone help me ?