ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: Immutability
Date Fri, 07 Dec 2001 15:13:14 GMT
On Fri, 7 Dec 2001, Erik Hatcher <jakarta-ant@ehatchersolutions.com>
wrote:

> I would argue that many of those need's that you mention are perhaps
> due to lack of understanding in how Ant works and how to do things
> without the need to overwrite properties.

Granted.

> No way am I bringing the "N" word into this discussion!  :))

Didn't mean to imply that (yes, I've seen the smiley 8-).  "This is
going to make Ant a procedural language" has been used to kill
discussions all over the place (by my self as well), that's all.
Effectively it can be used to end a thread, so it can be used for the
same purpose as Godwin's Law, that's all.

> Could you provide an example just so I have something more tangible
> to consider?

Appending to an existing path reference?  OK, this one just came to my
mind after I've seen Conor's mail.

> Struts has a <logic:iterate> tag that provides a scripting variable
> within the scope of the begin and end tags.

If you use a construct like a TaskContainer scoped variable, tasks
that are supposed to access them must be aware that they are nested in
this type of construct.

If you allow these containers to create a "normal" property, change it
during iteration and then remove it from the project when they are
done, you can use the ${} mechanism (if this one is fully dynamic) and
no extra coding is required.

For some other examples:

* chosing the compiler on a task by task basis.  There are projects
where you need to compile certain classes with a different compiler
than the rest of the project.

* reusing the same project instance in an "incremental" mode or under
GUI control without reconstructing it.  Or even just building the
project instance from a build file and let the user use some wizard to
set property values in the GUI.

* reacting to a change in environment - things become availbale or
unavailable.

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