如何扩展svc文件? [英] How to extend a svc file ?

查看:89
本文介绍了如何扩展svc文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好。



我是WCF中的新人。在我的一个项目中,我必须在WCF服务中添加一个方法。

此服务在DLL中,我无法访问代码。



如果可能的话,我想知道如何扩展svc文件以暴露我的新方法。



感谢您帮助我/>


祝你好运。

Hello every one.

I'm newbe in WCF. In one of my projects I had to add a methode in a WCF Service.
This service is in a DLL and I don't have access to the code.

I would like to know how I can extend the svc file to expose my new methode if it's possible.

Thanks for helping me

Best regards.

推荐答案

你可以创建一个WCF服务装饰器(它本身也是一个WCF服务) )。然后,这个服务可以简单地公开原始的所有方法(传递)并用你的附加方法装饰它。



祝你好运!
You could create a WCF service decorator (which by itself is also a WCF service). This service can then simply expose all methods of the original (pass-through) and decorate it with your additional method(s).

Good luck!


这篇关于如何扩展svc文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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