If the condition holds true, the property value is set (true by default); otherwise, the property is not set. You can set the value to something other than the default by specifying the value attribute.
Example -- check to see if certain files are present?
<target name="check_endorsed">
<condition property="endorsed.exists">
<and>
<available file="${endorsed.dir}/xalan.jar"/>
<available file="${endorsed.dir}/dom3-xml-apis-2.5.0.jar"/>
<available file="${endorsed.dir}/dom3-xercesImpl-2.5.0.jar"/>
</and>
</condition>
<fail unless="endorsed.exists">
Your Java endorsed folder does not contain all the necessary jar files!
Run the dist target and then copy all the jar files from dist/endorsed to:
${endorsed.dir}
</fail>
</target>