Define validating parser
For in-depth treatment of For our purposes, a DTD, or Document Type Definition, is simply a file that defines the syntax of a SGML-based language.
The DTDs for HTML 2.0 and HTML 3.2 were written by the HTML Working Group of the declaration is the most, if not the only way to know which markup language it should validate documents against.
In other words, it can tell you whether the document is valid.
If validation is not activated, however, it can only tell whether or not the document is well-formed, as was shown in the previous section when you deleted the closing tag from an XML element.
Validates the XML string/file against the specified XSD string/file.
XSD files are "XML Schemas" that describe the structure of a XML document.
The Java XML implementation does so whenever the DTD makes it possible.
Be sure that the syntax is as described above, and that you use the correct public identifier; otherwise, The Validator will use the wrong DTD, or will be unable to find a DTD at all, and will produce a huge list of absolutely meaningless errors.(Even a DTD qualifies as a "schema," although it is the only one that does not use XML syntax to describe schema constraints.) However, "XML Schema" presents us with a terminology challenge.