其中SOAP XML对象序列化库,用于Java的建议? [英] Which SOAP XML object serialization library for Java would you recommend?

查看:537
本文介绍了其中SOAP XML对象序列化库,用于Java的建议?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

其中的Java SOAP XML对象序列化库将你与其他平台/语言(.NET,德尔福)?

Which Java SOAP XML object serialization library would you recommend for Java object exchange with other platforms / languages (.NET, Delphi)?

通信方案可能是这样的:

Communication scenarios could look like this:

  • 在Java对象的作家 - > SOAP XML文本 - > .NET或德尔福对象读取器
  • 在.NET或Delphi对象的作家 - > SOAP XML文本 - > Java对象读取器

我知道有是XStream的XML序列化库和JSON作为替代解决方案,但是因为德尔福和.Net都内置了支持SOAP XML序列化的对象,这将提供一个'标准化'的方式与先进的功能,支持像嵌套对象,数组等等。

I know there is the XStream XML serialization library and JSON as alternative solutions, however since Delphi and .Net have built-in support for SOAP XML serialized objects, this would offer a 'standardized' way with support for advanced features like nested objects, arrays and so on.

编辑: 同时,我发现的 JAXB - (https://jaxb.dev.java.net/), JAXMe 和的JiBX - 绑定的XML Java的code( http://jibx.sourceforge.net/ )。但他们并没有在默认情况下产生的SOAP序列化的XML。

Meanwhile, I found JAXB - (https://jaxb.dev.java.net/), JAXMe, and JiBX - Binding XML to Java Code(http://jibx.sourceforge.net/). But they do not generate SOAP serialized XML by default.

一个可能的解决办法是,其能够没有HTTP服务器上运行,并提供了一​​个简单的文件接口为SOAP XML内容(不是一个完整的请求,只序列化对象)的web服务库。 轴2 CXF 看起来很有趣。

A possible solution would be a web service library which is able to run without a HTTP server, and offers a simple file interface for the SOAP XML content (not a complete request, just a serialized object). Axis 2 and CXF look very interesting.

推荐答案

我preFER JAX-WS(与JAXB 2.1数据绑定)比其他liberaries我用(JAX-RPC,轴1和2,但不XFire的)。该JAXB 2数据绑定使用泛型,这使得性能与maxOccurs的> 1. JAX-WS本身是相当有据可查的愉快的映射,并提供了一​​个相当不错的API。该方法和参数标注能有点失控在某些情况下 - 在注释形式的XML地狱。它通常是没有那么糟糕。

I prefer JAX-WS (with JAXB 2.1 databinding) over the other liberaries I've used (JAX-RPC, Axis 1 and 2, but not XFire). The JAXB 2 databinding uses generics, which makes for a pleasant mapping of properties with a maxoccurs > 1. JAX-WS itself is reasonably well documented and provides a reasonably good API. The method and parameter annotations can get a bit out of hand in some cases - XML hell in annotation form. It usually isn't so bad.

其中的JAX-WS堆栈的好的方面是地铁项目,其中Sun联合开发与微软和与Web服务支持.NET 3.0互操作好了,去,至于在一个可行的方式实施MTOM。

One of the nice aspects of the JAX-WS stack is project Metro, which Sun co-developed with Microsoft and interoperates well with the web service support .NET 3.0, going so far as to implement MTOM in a workable fashion.

这篇关于其中SOAP XML对象序列化库,用于Java的建议?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆