Summary
The methods you've used in this chapter cover DOM Level 3.0 Validation, letting you test whether you can add or remove elements and attributes from an XML document according to a given schema. We constructed and dynamically validated an example XML document catalog.xml
with an XML schema catalog.xsd
. The DOM 3 Validation implementation in XDK 11g does have a limitation in that not all methods are supported.
In the next chapter we will discuss the Java API for XML Binding (JAXB) to bind an XML schema to Java classes.