ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Peter Reilly" <peter.kitt.rei...@gmail.com>
Subject Re: PropertyHelper thoughts
Date Fri, 22 Jun 2007 14:58:08 GMT
On 6/22/07, Dominique Devienne <ddevienne@gmail.com> wrote:
> On 6/22/07, Stefan Bodewig <bodewig@apache.org> wrote:
> > > Funnily enough I did restrict Properties to Strings
> > > and all the tests passed.  :)
> >
> > You mean I didn't write a unit test when I fixed Bugzilla Issue 904?
> > OK, what can I say? hmm, trying to come up with a cheap excuse, March
> > 2001, ah yes, Ant 2 and all that.  I must have been too busy with
> > politics.
> >
> > Actually your change would be totally unrelated to the bug in question
> > which involved Ant assuming that System properties were all strings
> > when copying them over to the Ant properties.
>
> Did I say that I want Ant properties to be Strings only?
>
> For System properties which are not Strings, they could be either (1)
> ignored, with a warning or not, and (2) pushed in the reference map
> instead (which a warning or not).
They should be ignored.
The Property javadoc page explicitly says that is it incorrect
to use the underlying data structure directly .
"""
 Because Properties inherits from Hashtable, the put and putAll
methods can be applied to a Properties object. Their use is strongly
discouraged
"""
>
> But for Ant properties, they should *always* be Strings!!! ;-) --DD
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> For additional commands, e-mail: dev-help@ant.apache.org
>
>

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


Mime
View raw message