ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Cohen <sco...@javactivity.org>
Subject Re: cvs commit: ant/src/etc/testcases/taskdefs/optional/net ftp.xml
Date Thu, 26 May 2005 01:28:27 GMT
Antoine:  OK, I've taken a look.  Here is the problem, or maybe I don't 
understand EnumeratedAttribute fully.

In response to a suggestion of Steve Loughran the other day, I've 
implemented all of my new attributes with the convention that a value of 
"" means "Don't set the attribute - leave the default value in place". 
This was to accomodate Steve's suggestion of wanting property-file 
driven scripts.

Such a script would define
<property name="timestampGranularity" value=""/>
An optional property file could define

timestampGranularity=MINUTE

or

timestampGranularity=NONE.

If neither specified, the default to be used (whose value varies 
depending on the chosen action).

I'm having difficulty understanding how this convention would fit into 
the pattern of EnumeratedAttribute.  There may be such a way that I'm 
just not understanding.  I'm still open to whatever suggestions you 
might have on this score or alternative ideas to improve this code.

Steve Cohen wrote:
> Antoine Levy-Lambert wrote:
> 
>> Hello Steve,
>>
>> what about using a class derived from EnumeratedAttribute as type for 
>> timestampGranularity ?
>>
>> Cheers,
>>
>> Antoine
>>
...

> I'll take a look.
> 
> ---------------------------------------------------------------------
> 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