cancel
Showing results for 
Search instead for 
Did you mean: 

Use jaxb api

Former Member
0 Kudos

Hello,

I would like to use the JAXB api to parse XML document.

The aim is to parse SOAP message sent by a server.

- I've download jaxb-api.jar, jaxb-impl.jar, jaxb-lib.jar and jaxb-xjc.jar.

- Here my <b>code</b> :

JAXBContext jc = JAXBContext.newInstance( "aaa.bbb.ccc");

Unmarshaller u = jc.createUnmarshaller();

Object o = u.unmarshal( httpConn.getInputStream() );

==> Here generated <b>error</b> :

JAXBException : Unable to locate jaxb.properties for package aaa.bbb.ccc

I use the IDE Eclipse, must I do a particular configuration ?

Could you help me please ?

Thanks.

Delphine.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Delphine,

As far as I understand other than adding the 4 java archives you mentioned to the class path, there's nothing else as far as set up/configuration is concerned.

As the exception clearly says, its a pure JAXB exception and not from the SAP server. Are you using jaxb-1.0-beta , if yes, it has this bug.

There are some solutions mentioned in

and

Hope this helps,

Kiran<u></u><u></u><u></u><u></u>

Former Member
0 Kudos

Delphine,

the jaxb.properties file is automatically generated by the schema compiler. Please make sure that the jaxb.properties file is in the built path of your java application.

Sebastian