Re: Free-form ANT Task Structure

2003-05-21 Thread peter reilly
Here is a simple example task: import java.util.*; import org.apache.tools.ant.DynamicConfigurator; import org.apache.tools.ant.Task; public class Dy extends Task implements DynamicConfigurator { private String subName; private Map attributes = new HashMap(); private List elem

RE: Free-form ANT Task Structure

2003-05-20 Thread Dominique Devienne
--Original Message- > From: Berin Loritsch [mailto:[EMAIL PROTECTED] > Sent: Tuesday, May 20, 2003 11:38 AM > To: [EMAIL PROTECTED] > Subject: Re: Free-form ANT Task Structure > > peter reilly wrote: > > To embed the config information, the easiest > > is to map the in

Re: Free-form ANT Task Structure

2003-05-20 Thread Berin Loritsch
peter reilly wrote: To embed the config information, the easiest is to map the info to objects. Ant introspection is very powerfull and easy to use for normal java data object. The problem is that it only works when you know in advance what the configuration elements are going to be. In this examp

RE: Free-form ANT Task Structure

2003-05-20 Thread Dominique Devienne
> -Original Message- > From: peter reilly [mailto:[EMAIL PROTECTED] > Sent: Tuesday, May 20, 2003 11:18 AM > To: Ant Developers List > Subject: Re: Free-form ANT Task Structure > > To embed the config information, the easiest > is to map the i

Re: Free-form ANT Task Structure

2003-05-20 Thread peter reilly
To embed the config information, the easiest is to map the info to objects. Ant introspection is very powerfull and easy to use for normal java data object. Alternatively one can use the DynamicConfigurator interface. This provides the name of the unknown element and the name/value of unknown at

Free-form ANT Task Structure

2003-05-20 Thread Berin Loritsch
I want to write a task that allows me to embed XML configuration information to set up some integration tests using JUnit as a base. I can live with a DOM or JDOM to interpret and transform into my configuration objects. The concept is based on some work I originally did to extend JUnit for testin