Java Mailing List Archive

http://www.ant-tasks.com/

Home » Ant Users List »

Setting custom classpath when invoking Ant programmatically

Gerrit .

2008-04-22


Author LoginPost Reply

Hi, I am trying to invoke Ant with an org.apache.tools.ant.Project instance. Can someone maybe give me a hint for the following problem:

* Is there a way to add custom folders and jars to the Ant classpath?
* (Maybe indirectly by configuring the ClassLoader?)


I ask this because I need the functionality for an Eclipse project. I was using AntRunner before, which has a function to set classpathes, emulating a command-line invocation. However, with AntRunner, I couldn't set a logger instance, only a class name, whereas Project provides this functionality.

Or is there maybe a way to combine these 2 classes?

Many thanks in advance!




_________________________________________________________________
Invite your mail contacts to join your friends list with Windows Live Spaces. It's easy!
http://spaces.live.com/spacesapi.aspx?wx_action=create&wx_url=/friends.aspx&mkt=en-us
©2008 ant-tasks.com - Jax Systems, LLC, U.S.A.