Skip to main content

Jaxb - multiple schemas with the same namespace

Please note these java.net forums are being decommissioned and use the new and improved forums at https://community.oracle.com/community/java.
1 reply [Last post]
graza
Offline
Joined: 2011-02-14

Normal
0

false
false
false

EN-US
X-NONE
X-NONE

MicrosoftInternetExplorer4

/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
mso-para-margin:0cm;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.0pt;
font-family:"Times New Roman","serif";
mso-fareast-font-family:"Times New Roman";}

I have been using Jaxb for a while now to create java objects for a schema.
The schema is regularly updated and I have simply been able to create a new object set with a new xsd every time this has happened.
However the owners of the schema have elected to move to a model whereby unless there is a major change to the schema that excludes backward compatibility the version will be set at 1.
The question is can I get Jaxb to deal with this efficiently?
Any help would be gratefully received.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
kubatzki
Offline
Joined: 2011-03-25

one might consider this as insanity. If you have no other choice try partial unmarshalling. Read the document in a dom-tree check requirements and unmarshall the fragments to the corresponding JAXBElement..
ys.