camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From james555 <luke...@gmx.net>
Subject Re: JAXB-Unmarshalling of soap xml including schema validation
Date Wed, 21 May 2014 07:49:14 GMT

Hi Willem,

a little bit confusing, but now I got it. In my code I used "import
org.apache.camel.model.dataformat.SoapJaxbDataFormat;" where setSchema is an
invalid method. Compared with your testcase "import
org.apache.camel.dataformat.soap.SoapJaxbDataFormat;" with setSchema method
is used, thanks !

Sideeffect of the two existing SoapJaxbDataFormat classes:
I define my SoapJaxbDataFormat in a servlet scenario with a
CamelContextLifecycle. Since
"org.apache.camel.dataformat.soap.SoapJaxbDataFormat" is not a
"DataFormatDefinition" I can't use

e.g.
camelContext.getDataFormats().put("soapJaxbDataFormat", soapJaxbDataFormat);

to access the SoapJaxbDataFormat in a RouteBuilder comfortably (Compiler
says: "The method put(String, DataFormatDefinition) in the type
Map<String,DataFormatDefinition> is not applicable for the arguments
(String, SoapJaxbDataFormat)". Is that meant to be ? As a workaround I now
have to use the Registry with bean binding: 

e.g.
registry.bind("soapJaxbDataFormat", soapJaxbDataFormat);

Is there a better way to access SoapJaxbDataFormat ?

	big thanks !
	
		james






    	



--
View this message in context: http://camel.465427.n5.nabble.com/JAXB-Unmarshalling-of-soap-xml-including-schema-validation-tp5751290p5751406.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Mime
View raw message