ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Conor MacNeill" <co...@ebinteractive.com.au>
Subject RE: Dynamic binding of properties
Date Thu, 05 Oct 2000 06:01:27 GMT
Jeff,

Properties are still immutable but can be bound in a target rather than at
parse time. So we are vaguely dynamic.

Mutability is easy to introduce but then prevents a build's property values
from being set externally. One thought is to associate a priority value with
each property and only allow it to be changed at the same or higher
priority. That introduces mutability with precedence. Personally I think it
is the way to go.

Conor


--
Conor MacNeill
conor@cortexebusiness.com.au
Cortex eBusiness
http://www.cortexebusiness.com.au

> -----Original Message-----
> From: Jeff Turner [mailto:jeff@socialchange.net.au]
> Sent: Thursday, 5 October 2000 16:55
> To: ant-user@jakarta.apache.org
> Cc: Scott M Stark
> Subject: Re: Dynamic binding of properties
>
>
>
>
> On Thu, 5 Oct 2000, Peter James Donald wrote:
>
> > On Wed, 4 Oct 2000, Scott M Stark wrote:
> > > I tried to write an ant script that would go through an
> object serialization compatibility
> > > testing suite. It is using BSF/JavaScript to try to simplify
> the writing of a common set
> > > of steps shown below as the runV target. The script below
> does not work because
> > > properties are bound as the xml document is parsed. Now I
> have looked at how
> > > properties are handled by Ant and at first glance it does not
> seem that it would be
> > > all that difficult to introduce dynamic properties, but it
> would require a complete
> > > change in how properties and attributes are represented. Is
> this something that
> > > could show up on a future todo list or are there
> ramifications that would make this
> > > unlikely?
> >
> > It is in progress now and will eventually go to fully
> > dynamic evaluation I believe. It is doing partial dynamic
> > evaluation now so you may want to download latest CVS as
> > that *may* solve your problem (don't know haven't updated
> > from CVS since it was added)
>
> I don't think it's got very far. Using the latest CVS, the following:
>
> <property name="base" value="."/>
> <echo message="base is ${base}"/>
> <property name="base" value="foo"/>
> <echo message="base is ${base}"/>
>
> Just prints:
>
> main:
> base is .
> base is .
>
> --Jeff
>
> >
> > Cheers,
> >
> > Pete
> >
> > *--------------------------------------------------*
> > | Latrobe University,     | Does the name 'Pavlov' |
> > | Bundoora, Australia     |    ring a bell ?       |
> > *--------------------------------------------------*
> >
> >
>
>


Mime
View raw message