ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Reilly <peter.rei...@corvil.com>
Subject Re: cvs commit: ant/src/etc/testcases/taskdefs fail.xml
Date Thu, 29 Apr 2004 12:30:50 GMT
Jose Alberto Fernandez wrote:

>You could also have an add(Condition) method and
>that would allow your "no nesting required" notation without
>having to extend ConditionBase.
>
>  
>
This depends on getting the built-in conditions implemented as types, which
in turn depends on getting the "role" code in to deal with the "or" and 
"and"s
conditions/selectors.

Peter

>As a matter of fact, now that the introspector is able to deal with
>"add" methods. Shouldn't we deprecate ConditionBase and discourage
>people
>from using inheritance?
>
>It would produce a much clearer system.
>
>Jose Alberto
>
>
>  
>
>>-----Original Message-----
>>From: Peter Reilly [mailto:peter.reilly@corvil.com] 
>>Sent: 29 April 2004 11:38
>>To: Ant Developers List
>>Subject: Re: cvs commit: ant/src/etc/testcases/taskdefs fail.xml
>>
>>
>>I see a small problem here.
>>Exit was extending Task, and now is extending ConditionBase. 
>>ConditionBase does not extend Task so this breaks backward 
>>compatiblity.
>>
>>It may be better to do this:
>>
>><exit>
>>   <condition>
>>      <equals arg1="a" arg2="${dir.name}"/>
>>   </condition>
>></exit>
>>
>>rather that:
>><exit>
>>   <equals arg1="a" arg2="${dir.name}"/>
>></exit>
>>
>>(Dispite the fact that I normally argue against extra nesting).
>>
>>Peter
>>
>>mbenson@apache.org wrote:
>>
>>    
>>
>>>   * @since Ant 1.2
>>>   *
>>>   * @ant.task name="fail" category="control"
>>>   */
>>> -public class Exit extends Task {
>>> +public class Exit extends ConditionBase {
>>>      private String message;
>>>      private String ifCondition, unlessCondition;
>>>
>>>
>>> 
>>>
>>>      
>>>
>>---------------------------------------------------------------------
>>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
>
>
>
>  
>


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


Mime
View raw message