<xmlvalidate>
With Ant’s reliance on XML for its build files, it probably doesn’t come as a big surprise to learn of a task that will take an XML file and check it for errors. The <xmlvalidate> task will use the SAX parser that ships with Ant to validate a given file or list of XML files. You can of course use another implementation of a SAX processor if you want, by simply specifying the class name of the alternative.
Table 5.26 shows the list of attributes that are associated with this task.
Attributes | Description |
---|---|
file | The file in which the task will run. You can optionally specify the list of files using a nested fileset element. |
lenient | If set to true, the file is only checked to see it is ... |
Get Ant Developer’s Handbook now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.