On Monday 28 April 2003 18:40, Jose Alberto Fernandez wrote:
>
>       <condition property="x">
>         <and>
>           <if>
>               <istrue value="yes"/>
>               <then><echo>yes</echo></then>
>               <else><echo>no</echo></else>
>           </if>
>           <istrue value="yes"/>
>         </and>
>       </condition>

This particular example does not get through the  rules,
If extends ConditionBase, but does not extend Task, it
is declared by a <taskdef/> and thus gets the implicate
TaskAdapter wrapper. Thus the object presented to the
add(Condition condition) method does not extend Condition.

In general however, this is a problem. One example in
the current code is uptodate, this can be used in <condition/>
and as a task.

When used as a task, it can set a property, when used as
a condition, the property attribute is ignored.

Cheers,

Peter

Reply via email to