ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Keith Hatton" <khat...@axiomsystems.com>
Subject RE: Launching ant from inside java code
Date Thu, 18 Jul 2002 08:39:28 GMT
Subclass org.apache.tools.ant.Main and give your subclass a public constructor that calls 
super(String[] args).
It's a hack but it will work :)

Beware in case something, somewhere, calls System.exit() as the whole VM will shut down (unless
you intercept it, of course).

Keith


-----Original Message-----
From: Raphaele Giordan [mailto:rgiordan@sopragroup.com]
Sent: 18 July 2002 09:05
To: 'Ant Users List'
Subject: Launching ant from inside java code


hi,
is there a way to launch ant inside java code without launching a separate JVM ?
I tried to do so but I was unable to call the Main class constructeur as it is protected.
raphaele


--
To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


Mime
View raw message