Validating xml with xsd java
You're right that you should have your file available to other services if you are passing a file back and forth.
The most common way to do that is to put the file in your Web site, and refer to that URL in the namespace location, as you've done.
I'm assuming that the /xsd directory on the domain is treated as any other and won't need any special directves in web.xml, would that be correct?
Permissions beyond the scope of this license may be available at [email protected]
The line "schema = Schema(new Stream Source(get Class().ged)));" manages to pick up the xsd from the classpath OK.
if I remove or rename the xsd it complains that it can't be found, which is what I'd expect :) Do you mean that the directive - xsi:no Namespace Schema Locatsd - isn't finding the xsd?
When sending data from a sender to a receiver, it is essential that both parts have the same "expectations" about the content.
With XML Schemas, the sender can describe the data in a way that the receiver will understand. However, an XML element with a data type like this: Even if documents are well-formed they can still contain errors, and those errors can have serious consequences.