Currently, ant must be used to execute a class file containing the main method, and two parameters (start and end) must be passed to the main method through the command line.
<Target name = "GSP" depends = "compile" Description = "generator structure pictures"> <echo message = "----------- generator structure pictures ----------"/> <property name = "start" value = "1" type = "codeph" text = "codeph"/> <property name = "end" value = "892046" type = "codeph" text = "codeph"/> <Java fork = "true" classname = "com. founder. CST. system. structureimagegenerator "> <Arg value =" $ {start} "/> <Arg value =" $ {end} "/> <classpath Path =" $ {build. dir}/classes "/> <classpath refID =" classpath "/> </Java> <echo message =" ----------- end ------------ "/> </Target>
In this way, execute ant GSP-dstart = 10-dend = 20 to upload 10 and 20 to the main method. It is best to set the default value.