I'm trying to determine the best approach for coding the following solution:
I have an XML document coming in (which conforms to a particular DTD). I would like to validate the node values and return a report (XML transformed to HTML) to the users enumerating the errors found in the document.
The validation falls into three categories - required fields, data type validation, and validation against a set of allowable values.
Does anyone have a suggestion as to the best approach to the problem? Is a schema the way to go (and would validation against a schema produce a list of all nodes that failed?) or should I loop through the document using
Java classes to perform the validation checks?
Thanks in advance for any help!