On Mon, 23 Jul 2001, <[EMAIL PROTECTED]> wrote:

> Probably that's something for ant2, but beeing able to use the tasks
> as standalone beans in normal java code would be extremely
> usefull.

I'd prefer to not use the tasks directly - rather have the tasks as a
thin Ant specific layer on top of service code.

For example, we already have the Execute class as a service class you
can use to execute an arbitrary system command and people should use
this sevice class instead of the implementation of the <exec> task.

There are many other tasks that should (and I hope will) be refactored
into a service class more or less independent of Ant and a Ant task
layer on top of it, this includes <javac> (where the service layer
could come from Sam's commons javac package idea) and <java>, but even
rather simple things like <touch> or <copy> as well.

This seems to boil down to: don't use the tasks directly.  If it is
easier to use the task than the underlying service framework (or there
is no separate service), refactor the task - which is something for
Ant2, of course.

Stefan

Reply via email to