开发者

Binding for message type in WCF

开发者 https://www.devze.com 2023-03-22 17:53 出处:网络
I have a method in WCF which has a return type of Message as well as the input as message whcih type of binding will be used for this...what will be the service model 开发者_开发问答in my config fileT

I have a method in WCF which has a return type of Message as well as the input as message whcih type of binding will be used for this...what will be the service model 开发者_开发问答in my config file


The binding specified for the service (i.e., WsHttpBinding, NetTcpBinding, etc) is applied to the whole service, not just specific parts. Nor can you have a service that has different bindings for different parts.

I.e., you can't have Service A with a ServiceContract using WsHttpBinding, the DataContract using NetTcpBinding, etc.

You can have Service A expose different endpoints with different bindings, but the point is the binding applies to a given service as a whole. It's the B part of the ABCs of WCF - Address, Binding and Contract.


You can use any type of binding you want, it doesn't matter.

0

精彩评论

暂无评论...
验证码 换一张
取 消