在集成路线中集成Jaxb2Marshaller时需要帮助。
代码流:-
@Bean
public IntegrationFlow flow() throws JAXBException {
return from(...).
.enrichHeaders(...)
.handle(...)
.transform(processor()::generateXml)
.channel(...)
.get();
}
如何在Jaxb2Marshaller ()步骤中添加转换?
发布于 2018-08-10 06:50:32
有一个开箱即用的转换器可以使用:
.transform(new MarshallingTransformer(jaxbMarshaller()))
如何创建一个Jaxb2Marshaller
你可以参考Spring Framework文档:
https://docs.spring.io/spring/docs/current/spring-framework-reference/data-access.html#oxm-jaxb2
https://stackoverflow.com/questions/51776429
复制相似问题