Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » Descriptor for class was not found in the project"
Descriptor for class was not found in the project" [message #1707393] Fri, 04 September 2015 12:58
Jared Fucci is currently offline Jared FucciFriend
Messages: 3
Registered: July 2015
Junior Member
All I can find are article and topics for " A descriptor with default root element <0> was not found in the project", i can't find anything on just "A descriptor for class <0> was not found in the project. " I had this original project that worked fine until we moved to 12c and now the marshalling of these is giving me this issue. I'm not great with JAXB and I don't even know what is exactly meant by "descriptor", they mean namespace? But I have working on this for days and I can't figure it out, any help would be greatly appreciated.

The command that causes the error(last line):
javax.xml.bind.Marshaller bindmarshaller = 	JAXBContext.newInstance(this.schema).createMarshaller();
StringWriter writer = new StringWriter();

bindmarshaller.marshal(header, new StreamResult(writer));

The plugin that binds the xmls:
					<!-- JAxb api -->
					<!-- JAxb impl - needed for deployment -->

The xjb file that is bound:
<?xml version="1.0" encoding="UTF-8"?>
<jxb:bindings version="1.0"
               xmlns:jxb="<removed to post>"
               xmlns:xs="<removed to post>">
   	<jxb:bindings schemaLocation="CSHeaderSchema.xsd" node="/xs:schema">
	      <jxb:package name="<removed package>" />

The schema:
<?xml version="1.0" encoding="utf-8"?>
<xs:schema id="Header" xmlns:xs="<removed to post>" version="1.0.0"> 
  <xs:element name="CSHeader"> 
        <xs:element name="MsgType" minOccurs="1">



The error I get:
 - with linked exception:
[Exception [EclipseLink-25007] (Eclipse Persistence Services - 2.4.2.v20130514-5956486): org.eclipse.persistence.exceptions.XMLMarshalException
Exception Description: 
A descriptor for class <removed package>.CSHeader was not found in the project.  
For JAXB, if the JAXBContext was bootstrapped using TypeMappingInfo[] you must call a marshal method that accepts TypeMappingInfo as an input parameter.
Previous Topic:Need to extend existing ComplexType defined in XSD to accept empty strings from XML
Next Topic:Entity is not updated
Goto Forum:

Current Time: Mon Feb 26 06:39:12 GMT 2024

Powered by FUDForum. Page generated in 0.01942 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top