public class AssertTask
extends org.apache.tools.ant.taskdefs.condition.ConditionBase
This one could as well be implemented as
<macrodef name="assertTrue">
<attribute name="message" default="Assertion failed"/>
<element name="assertion" implicit="true"/>
<sequential>
<fail message="@{message}">
<condition>
<assertion/>
</condition>
</fail>
</sequential>
</macrodef>
but wouldn't be able to throw a specialized exception that way - and the macrodef would nest the exception in yet another BuildException.
| Constructor and Description |
|---|
AssertTask() |
| Modifier and Type | Method and Description |
|---|---|
void |
execute() |
void |
setMessage(java.lang.String value)
Message to use when the assertion fails.
|
add, addAnd, addAvailable, addChecksum, addContains, addEquals, addFilesMatch, addHttp, addIsFalse, addIsFileSelected, addIsReference, addIsSet, addIsTrue, addNot, addOr, addOs, addSocket, addUptodate, countConditions, getConditions, getTaskName, setTaskName