324.15. FlexVolume (un)marshalling
Camel의 플러그형 데이터 형식은ECDHEB, XStream, JibX, Castor 및 XMLBeans와 같은 라이브러리를 사용하여 pojo/xml marshalling을 지원합니다. 경로에서 이러한 데이터 형식을 사용하여 웹 서비스 간에 pojo를 전송하고 수신할 수 있습니다.
웹 서비스에 액세스하는 경우 요청을 마샬링하고 응답 메시지를 마샬링할 수 있습니다.
JaxbDataFormat jaxb = new JaxbDataFormat(false); jaxb.setContextPath("com.example.model"); from("direct:example").marshal(jaxb).to("spring-ws:http://foo.com/bar").unmarshal(jaxb);
JaxbDataFormat jaxb = new JaxbDataFormat(false);
jaxb.setContextPath("com.example.model");
from("direct:example").marshal(jaxb).to("spring-ws:http://foo.com/bar").unmarshal(jaxb);
마찬가지로 웹 서비스를 제공할 때ECDHE의 XML 요청을 수락 해제하고 응답 메시지를 XML로 마샬링할 수 있습니다.
from("spring-ws:rootqname:{http://example.com/}GetFoo?endpointMapping=#endpointMapping").unmarshal(jaxb) .to("mock:example").marshal(jaxb);
from("spring-ws:rootqname:{http://example.com/}GetFoo?endpointMapping=#endpointMapping").unmarshal(jaxb)
.to("mock:example").marshal(jaxb);