ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: ScriptDef
Date Fri, 15 Feb 2002 06:51:47 GMT
On Fri, 15 Feb 2002, Conor MacNeill <conor@cortexebusiness.com.au>
wrote:

> My motivation was to make scripted tasks somewhat similar to a real
> task, as would be written in Java, particularly when using Rhino.

But this approach comes at some cost, as you are potentially locking
out languages supported by BSF - which Peter's approach would not.

You could still use a reflection like mechanism inside scriptdef to
actually set the parameters for languages where you can do it that
way, all that would have to change was that you'd have to declare your
parameters explicitly.

> In addition, the way I implemented <scriptdef> it can support nested
> elements, which are potentially repeated
> 
> It is hard to support that capability with simple named parameters.

It is possible, but cumbersome.

I see this part as something that is vaguely related to setting user
preferences.  Something like:

    I want to always have a child element 
    <compilerarg value="+Z" implementation="jikes" /> 
    in all my <javac> tasks.

Solve the syntax for this and you have an acceptable syntax to declare
the nested elements of scripted tasks.

Stefan

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message