ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rainer Noack" <>
Subject AW: Taskdef and classpath
Date Tue, 30 Mar 2010 20:50:41 GMT

If possible, you should encapsulate the task in a java program i.e. a public
static void main(String[] args]) method.
Then call this via java task with fork="true"
There you can specify the correct classpath.



-----Ursprüngliche Nachricht-----
Von: Knuplesch, Juergen [] 
Gesendet: Dienstag, 30. März 2010 10:04
An: Ant Users List
Betreff: Taskdef and classpath


I have an ANT-task that I call inside my buildfiles.
I have access to the source of this task.

I have problems with elements on the classpath, because I use different

How can I define my task in a way, that there are only the elements on its
classpath (e.g. the xml parser), that I want, especially there should not be
all the elements of ANT on this classpath?

What is the correct / best way:

1.just define a classpath in the taskdef task (this does not seem to work)
2.create a separate classloader in this task. But how do I configure it in a
way, that I get rid of all the ANT classpath elements??

Greetings Juergen

Jürgen Knuplesch 

To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message