ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Allan Lewis" <allan.e.le...@gmail.com>
Subject Accessing classes in a path from a custom task
Date Sat, 19 Feb 2011 15:17:20 GMT
I'm working on a custom ant task, and want to create a class based on
classname provided to the task.  I've made a path available to the task, but
can't quite figure out how to make those classes available to the task, so I
wind up getting a java.lang.ClassNotFoundException when trying to create the
class.

 

In other words, given the following:

 

<path id="my.path">

<fileset dir="lib" includes="*.jar"/>

</path>

 

<path id="my.runtime.path">

<fileset dir="lib-runtime" includes="*.jar"/>

</path>

 

<typedef name="mytask" classname="com.mytask.MyTask"
classpathref="my.path"/>

 

< mytask classpathref="my.runtime.path" classname="com.foo.Bar"/>

 

What has to happen in order to get 'com.foo.Bar' available to my task at
runtime?


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message