I have a question, how can i trigger an ant job from swing. I will
like ant to pull it values from the swing and build based on selected
value from the swing GUI. Is there any jar file that will make the
process easier? Has anyone done anything like this? The other part is
can one trigger a Macro from swing
Daniel Pitts - 21 Dec 2007 18:45 GMT
> I have a question, how can i trigger an ant job from swing. I will
> like ant to pull it values from the swing and build based on selected
> value from the swing GUI. Is there any jar file that will make the
> process easier? Has anyone done anything like this? The other part is
> can one trigger a Macro from swing
Well, basically you have to design your gui first, and then get the
values out of the swing components, and execute ANT with the values you get.

Signature
Daniel Pitts' Tech Blog: <http://virtualinfinity.net/wordpress/>
Daniel Gee - 22 Dec 2007 08:36 GMT
> I have a question, how can i trigger an ant job from swing. I will
> like ant to pull it values from the swing and build based on selected
> value from the swing GUI. Is there any jar file that will make the
> process easier? Has anyone done anything like this? The other part is
> can one trigger a Macro from swing
well based on your swing components you just run the desired command
line eg:
String desiredCommandLine = "ant "+ myGUI.figureArgsString();
Runtime.getRuntime().exec(desiredCommandLine);
Thomas Kellerer - 22 Dec 2007 09:09 GMT
Daniel Gee wrote on 22.12.2007 09:36:
>> I have a question, how can i trigger an ant job from swing. I will
>> like ant to pull it values from the swing and build based on selected
[quoted text clipped - 7 lines]
> String desiredCommandLine = "ant "+ myGUI.figureArgsString();
> Runtime.getRuntime().exec(desiredCommandLine);
No need to run an external process. Ant is just a Java program/class and can be
called directly if the libraries are on the classpath of the calling app.
Roedy Green - 23 Dec 2007 04:59 GMT
On Fri, 21 Dec 2007 05:40:54 -0800 (PST), Emmanuel Ayanrinola
<tosenr@gmail.com> wrote, quoted or indirectly quoted someone who said
>I have a question, how can i trigger an ant job from swing. I will
>like ant to pull it values from the swing and build based on selected
>value from the swing GUI. Is there any jar file that will make the
>process easier? Has anyone done anything like this? The other part is
>can one trigger a Macro from swing
you can exec ant. See http://mindprod.com/jgloss/exec.html
Ant itself is written in Java, and its API is available to Java. It
will give you indigestion, but have a look at the ANT API Javadoc.
Surely somewhere in there is what you need.

Signature
Roedy Green Canadian Mind Products
The Java Glossary
http://mindprod.com