type=“xsd:base64Binary”的 Axis Web 服务
所以我有一个 wsdl 定义了一个消息部分,如下所示
<wsdl:message name="processEnvelopeResponse">
<wsdl:part name="processEnvelopeReturn" type="xsd:base64Binary"/>
</wsdl:message>
这映射到一个 xsd,然后导入其他 xsd 等等。
我有以下问题:
- 如何从 xsd 生成消息部分对象
忽略这个,我已经找到了 回答,你可以这样做,只要你 将 xsd 导入到 wsdl 文件中。 稍后会详细解释
- 如何以允许我直接填充消息对象并通过网络传递的方式生成客户端对象
- 如何调用Web服务,将生成的对象转换为base64Binary(这个假设以上是不可能的)
So i have a wsdl that defines a message part like the following
<wsdl:message name="processEnvelopeResponse">
<wsdl:part name="processEnvelopeReturn" type="xsd:base64Binary"/>
</wsdl:message>
This maps to a xsd, wich then imports other xsds and so on.
I have the following questions:
- How can i generate the Message part objects from the xsd
Ignore this one, i have found the
answer, you can do this as long as you
import the xsd into the wsdl file.
Will explain better later on
- How can i generate the client side objects in a way that allows me to directly fill the message objects and pass it over the wire
- How do i call the webservice, transforming the generated objects in to base64Binary (this one assumes the above is not possible)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
因此,回答我自己的问题时,我能够生成工件以从 xsd 列表中调用 Web 服务,但在调用 Web 服务时我无法使用它们。
所以我最终不得不手动生成 XML,幸运的是这是一个小调用。
由于响应也来自 xsd:base64Binary,我必须将传入的字符串映射到 xml 对象中才能处理响应。
然后我通过 jdom 将 xmloutput 放入我得到的数据。
总而言之,这是一种愚蠢的方式来实现网络服务。
So answering my own question, i was able to generate the artifacts to call the webservice from the list of xsd's, but i was unable to use them when calling the webservice.
So i ended up having to generate the XML by hand, lucky was i that this was a small call.
And since the response came in xsd:base64Binary too i had to map the incoming string into xml objects in order to process the response.
I then put xmloutput through jdom i got my data.
all in all a stupid way to implement a webservice.