ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Vernum <>
Subject RE: if and unless attributes for all Tasks
Date Tue, 22 May 2001 00:35:55 GMT
From: Alan George []

> I first tried this in my case and found properties to be 
> immutable (i.e.
> the available task would not change the value of the 
> buildfile.available
> property once it was set the first time). 

Properties are mutable, just not through the <property> task.

> So, your CopyProperty class
> must do something to make properties mutable.  

Nah, it doesn't.
In fact, I didn't even use it.
Sorry, the taskdef was just at the top of my build file, and I didn't notice it.

The mutabilty comes from using AntCall.
Just like in unix, properties are passed to sub-processes (ant/antcall), but are not passed

> At a high level you are doing the same thing I am, which is task level
> conditional processing.  Yours uses the available task, mutable
> properties and a layer of targets to get conditional processing.   It
> seems to me that task level ifs are more explicit and natural in this
> case.  Do you agree?

I think I needed a few too many tasks to acheive what I wanted, but I actually think the overall
design is better than one with task level ifs.

View raw message