操作合同的可选参数 [英] optional parameter for operationcontract

查看:75
本文介绍了操作合同的可选参数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有人知道我是否可以在WCF的操作合同中指定一个可选参数.例如,如果我有一个方法将第二个参数作为可选参数,那么该如何指定呢?

Does anybody know if I can specify an optional parameter in a operationcontract for WCF. For example, if I have a method that has an optional parameter as the second parameter, how do I specify it?

[操作合同]

doSomething(字符串方法,字符串参数=")

doSomething(String method, String parameters = "")

推荐答案

Ahhh ... c#中的默认参数?


这篇关于操作合同的可选参数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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