ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: condition task idea
Date Fri, 24 Aug 2001 05:42:22 GMT
On Fri, 24 Aug 2001, Conor MacNeill <conor@cortexebusiness.com.au>
wrote:

Must have overlooked the part that said current implementation, sorry.

>     <condition property="sitraka.gate">
>       <and>
>         <property name="jakarta.oro.present"/>
>         <property name="jdk1.2+"/>
>       </and>
>     </condition>

Using the fact that unknown properties don't get expanded, this could
be written as (untested)

    <condition property="sitraka.gate">
      <not>
        <or>
          <equals arg1="${jakarta.oro.present}" 
                  arg2="$${jakarta.oro.present}"/>
          <equals arg1="${jdk1.2+}" 
                  arg2="$${jdk1.2+}"/>
        </or>
      </not>
    </condition>

And if you want to add a new condition, please dont't use <property>,
this element already has two different interpretations as task or
child of <ant> - how about <isset property="...."> or similar.

Stefan

Mime
View raw message