JAXB: W3C spec XSD -> 2 different packages
Hi JAXB gurus - I have an interesting challenge I hope someone can help out with.
I want to have xjc generate Java classes from the W3C specification for XML Encryption. That .xsd is located here:
Note that this .xsd additionally imports the W3C XML Digital Signature .xsd.
When I run xjc without any customization, it creates two packages based on the namespaces alone:
Which is great - just not what I want. I want to customize this so that the objects go in org.w3.xmlenc and org.w3.xmldsig packages respectively.
Also, because this is a W3C spec, I don't want to/can't touch the source .xsd files at all. I need to treat them as static/read-only. I'm putting my JAXB directives in a separate .xjb file.
How do I make this happen based on external .xjb customization files without touching the source .xsd files?
Thanks for any pointers!