Property immutability: need workaround
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Christian_Ey
Posted On:   Wednesday, May 8, 2002 05:06 AM

Hi there, it is stated in the ANT doc very clearly that properties are immutable (once set never changed). I know that and in most cases this is a very useful feature. But there are cases in which it really might be good to have the possibility to change a property explicitly. For example if you want to perform the same target multiple times but with different properties: [...] In fact, I have a solution for that problem: I built a custom task called working the same way as the task except that it allows overriding properties (anyone interested - I can make it downloadable somewhere). But i   More>>

Hi there,



it is stated in the ANT doc very clearly that properties are immutable (once set never changed). I know that and in most cases this is a very useful feature.



But there are cases in which it really might be good to have the possibility to change a property explicitly. For example if you want to perform the same target multiple times but with different properties:



			




[...]











In fact, I have a solution for that problem: I built a custom task called working the same way as the task except that it allows overriding properties (anyone interested - I can make it downloadable somewhere).



But isn't there a better workaround for that problem? Or wouldn't it desirable to have such an override task in a future ant version?



Best regards,
Chris    <<Less

Re: Property immutability: need workaround

Posted By:   Erik_Hatcher  
Posted On:   Wednesday, May 8, 2002 05:41 PM

Have a look at the docs for /. Both support the overriding of properties on a per-invocation basis.
About | Sitemap | Contact