最简单的一种使用C#网络双向通信 [英] Easiest for two way communication over the internet using C#

查看:317
本文介绍了最简单的一种使用C#网络双向通信的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我用什么在互联网上双向通信而不需要在客户端打开端口?

What do I use for two way communication over the internet without the necessity to open ports on the client side?

用户不同意打开端口,做在客户端虽然一切端口转发,可以在服务器端。

Users won't agree to open ports and do port forwarding on the client side although everything is possible on the server side.

不过,我需要完成双向通信。

But,I need to accomplish two way communication..

我如何去实现呢?

这不要紧,无论其WCF或远程Web服务或...
我只是需要一个快速,快捷的方式,只是让概念制定和分发应用程序。

It doesn't matter whether its WCF or remoting or webservices... I just need a quick and fast way to just get the concept to work out and distribute the application.

ofcourse,这将是通过互联网。

ofcourse,it's going to be through the internet.

请帮助..
谢谢

Please help.. Thanks

编辑:请注意,我需要连接多个客户端,并维护每个会话客户端。

Edit : Please note that i need to connect multiple clients and maintain a session for each client.

推荐答案

WCF支持双面HTTP绑定。

WCF supports duplex HTTP bindings.

只要作为发起客户端可以访问该服务,回调合同可以被定义在客户端调用。它只是保持一旦客户端已经启动它的HTTP连接。

As long as the initiating client can access the service, a callback contract can be defined to call the client. It simply keeps the HTTP connection once the client has initiated it.

这篇关于最简单的一种使用C#网络双向通信的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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