A validating XML parser, by parsing the XML document according to the rules specified in the DTD, tries to determine whether the document conforms to the DTD (valid), meaning that the structural relationships and sequences are the same. Depending on the implementation of the parser, if an error is encountered during validation, processing may stop, as in “panic mode” exception processing, or continue with internal corrections. Warnings or errors may be reported either as processing occurs or at the very end of the processing. Finally, most processors have a mode whereby validation can be turned off; however, with DTDs, certain constructs defined in DTDs not discussed here, such as entity definitions, must still be processed.