Validates the document against the governing schema and returns whether the document conforms to the schema.
- macOS 10.4+
If validation fails, on return contains an
NSErrorobject describing the reason or reasons for failure.
true if the validation operation succeeded, otherwise
The constants indicating the kind of validation errors are emitted by the underlying parser; see
NSXMLParser for most of these constants. If the schema is defined with a DTD, this method uses the
XMLDTD object set for the receiver for validation. If the schema is based on XML Schema, the method uses the URL specified as the value of the
xsi: attribute of the root element.
You can validate an XML document when it is first processed by specifying the
NSXMLDocument option when you initialize an
NSXMLDocument object with the