问题描述
您好,
我需要设置soap消息的正文部分,以便我可以在一次调用中创建订单项,另外,我必须通过多次服务来创建它。
I need to set body part of soap message so that I can create line items in one call, other wise I would have to create it with multiple calls to service.
我有一个字符串"< cre:InputParameters> &NBSP; < / CRE:InputParameters>&NBSP; &NBSP; < CRE:InputParameters>&NBSP; &NBSP; < / CRE:InputParameters>&NBSP;< CRE:InputParameters>&NBSP; &NBSP; < / cre:InputParameters>"
I have a string "<cre:InputParameters> </cre:InputParameters> <cre:InputParameters> </cre:InputParameters> <cre:InputParameters> </cre:InputParameters>"
我需要在正文中发送,以便服务可以在一次调用中创建订单项。它是在我通过soap UI调用但是使用生成的模式时创建的,我必须调用服务三次来创建3个项目,我不希望这样。
Which I need to send in body so service can create line items in one call. It is creating when I call via soap UI but using generated schemas I would have to call service three times to create 3 line items and I don't want that.
- Hassam
--Hassam
推荐答案
SOAP Web服务的WSDL定义了调用。所以当你是消费者时,你就没有选择。
The WSDL of a SOAP web service defines the calls. So when you're the consumer, then you don't have an option here.
当你是制片人时(当你是那个写过网络服务的人的时候)那么更改WSDL。
When you're the producer (when you're the guy who has written the web service) then change the WSDL.
这篇关于如何编写soap body,因为我们可以使用WCF.OutboundCustomHeaders编写头文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!