Hi
Seems this is a common question, but none of the methods I've tried seem to
work.
I have a schema containing some anyURI elements, I'd like JAXB to
automatically read them into java.net.URI objects rather than Strings.
I found
https://metro.dev.java.net/guide/Customizing_XML_Schema_binding.html, and
modified my Ant script to suit. Simple mode is being enabled;
Unmarshaller.unmarshal(..) now returns a custom object rather than a
JAXBElement - but anyURIs are still Strings.
I tried using
<jaxb:javaType name="java.net.URI" xmlType="xs:anyURI"/>
also, but that gives me problems with uncaught URISyntaxExceptions - who is
supposed to catch those? Is there a way of having them flag as validation
errors?
Thanks in advance,
Chris
--
View this message in context: http://www.nabble.com/anyURI-to-java.net.URI-tp14949162p14949162.html
Sent from the java.net - jaxb users mailing list archive at Nabble.com.