通过C#与socket.io服务器进行通信

通过C#与socket.io服务器进行通信

问题描述:

是否有下面的socket.io协议的C#客户端?我有一个与socket.io JavaScript客户端通过网站进行通信的socket.io服务器,但我也需要连接一个C#一块它可以发送和接收消息。有没有干净的方式目前做到这一点,否则我将不得不写我自己的客户端。

Is there a c# client that follows the socket.io protocol? I have a socket.io server that is communicating with a socket.io javascript client via a website, but i also need to connect a c# piece to it that can send and receive messages. Is there a clean way to do this currently or will I have to write my own client.

有上 codePLEX 项目(的NuGet 以及)这是socket.io一个C#客户端。
(我是这个项目的作者 - 所以我有偏见)我找不到我需要在客户端到底是什么,所以我建立它,它释放回开。

There is a project on codeplex ( NuGet as well ) that is a C# client for socket.io. (I am the author of this project - so I'm biased) I couldn't find exactly what I needed in a client, so I built it and released it back into the open.

例如客户端方式:

socket.On("news", (data) =>    {
Console.WriteLine(data);
});