Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » MOXy jaxb binding error for redefine element(MOXy jaxb binding error for redefine element)
icon8.gif  MOXy jaxb binding error for redefine element [message #884397] Sun, 10 June 2012 21:38 Go to next message
sanya hu is currently offline sanya hu
Messages: 2
Registered: June 2012
Junior Member
Hi All,
Can any one help me ?
In my project, I need to pares some schema files, and need to generate xml files base on these schemas. Now ,I want to user MOXy to generate empty xml files base on these schemas dynamicly.But exception happened.
Internal Exception: com.sun.istack.SAXParseException2: "file:/F:/workspace/test/src/custom2.xsd" is not a part of this compilation. Is this a mistake for "file:/F:/workspace/test/src/custom.xsd"?
	at org.eclipse.persistence.exceptions.JAXBException.errorCreatingDynamicJAXBContext(JAXBException.java:586)
	at org.eclipse.persistence.jaxb.dynamic.metadata.SchemaMetadata$XJCErrorListener.error(SchemaMetadata.java:235)
	at com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.error(SchemaCompilerImpl.java:316)
	at com.sun.tools.xjc.reader.internalizer.Internalizer.reportError(Internalizer.java:628)
	at com.sun.tools.xjc.reader.internalizer.Internalizer.reportError(Internalizer.java:619)
	at com.sun.tools.xjc.reader.internalizer.Internalizer.buildTargetNodeMap(Internalizer.java:262)
	at com.sun.tools.xjc.reader.internalizer.Internalizer.buildTargetNodeMap(Internalizer.java:391)
	at com.sun.tools.xjc.reader.internalizer.Internalizer.transform(Internalizer.java:146)
	at com.sun.tools.xjc.reader.internalizer.Internalizer.transform(Internalizer.java:108)
	at com.sun.tools.xjc.reader.internalizer.DOMForest.transform(DOMForest.java:442)
	at com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImpl.java:230)
	at com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImpl.java:94)
	at org.eclipse.persistence.jaxb.dynamic.metadata.SchemaMetadata.getJavaModelInput(SchemaMetadata.java:138)
	at org.eclipse.persistence.jaxb.dynamic.DynamicJAXBContext.initializeFromMetadata(DynamicJAXBContext.java:209)
	at org.eclipse.persistence.jaxb.dynamic.DynamicJAXBContextFactory.createContextFromXSD(DynamicJAXBContextFactory.java:345)
	... 2 more


I think the reason is the redefine element, because when I use import or include,it's ok. Please help.
  • Attachment: test.zip
    (Size: 2.87KB, Downloaded 92 times)
Re: MOXy jaxb binding error for redefine element [message #885020 is a reply to message #884397] Tue, 12 June 2012 05:27 Go to previous message
sanya hu is currently offline sanya hu
Messages: 2
Registered: June 2012
Junior Member
I edit the code XMLSchemaInternalizationLogic, add redefine type to it , and this problem seems work now .
Previous Topic:Attributes missing in metamodel using IBM JDK
Next Topic:OneToMany with composite keys
Goto Forum:
  


Current Time: Wed Aug 20 12:37:03 EDT 2014

Powered by FUDForum. Page generated in 0.03194 seconds