users@jaxb.java.net

Re: Does turning on schema validation require packaging the xsd file?

From: Aleksei Valikov <valikov_at_gmx.net>
Date: Fri, 15 Jan 2010 21:52:18 +0100

Hi,

> In order to do schema validation with JAXB 2, do I really have to
> package the xsd file so the SchemaFactory can create a Schema I can put
> on the unmarshaller?

Generally, yes.

> It seems odd to need this, as my JAXB-annotated
> classes seem to already have all the information that might be required
> to do a validation.

No, generally annotations are not enough for validation.

Bye.
/lexi