We don’t allow questions seeking recommendations for software libraries, tutorials, tools, books, or other off-site resources. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(4)
我强烈建议您查看Windows Communication Foundation。它附带任何版本的 .NET 3.0 或更高版本,因此如果您使用 VS 2008,您就拥有了所需的一切。
它抽象了很多网络细节,为您提供了一个非常简单的编程 API。甚至协议细节也被抽象出来,并且有大量的内置协议可供选择。
提供跨网络通信的最佳方式。
I highly suggest you look into the Windows Communication Foundation. It comes with any version of .NET 3.0 or greater, so if you're using VS 2008, you've got all you need.
It abstracts a heck of a lot of the details for networking, providing you with a very simple programming API. Even protocol details are abstracted away, and there are a ton of protocols to chose from already built in.
Hands down the best way to communicate across a network.
查看 .NET 框架库中的
System.Net
和System.Net.Sockets
命名空间。吃掉你的心。虽然我可能误解了你的“网络 API”的含义。
Check out the
System.Net
andSystem.Net.Sockets
namespaces in the .NET framework libraries. Eat your heart out.Though I may have misunderstood your meaning of 'networking API'.
网络是一个非常非常广泛的术语。如果您在查询中设置一些限制,例如“我正在寻找 c# 下套接字编程的示例代码”,您可能会更幸运。仍然广泛,但更负责任。
C# 在 .NET 框架中内置了许多网络功能,大部分位于 System.Net 命名空间中。我发现很少有东西需要使用外部库或 Windows 网络 API。您可以检查 System.Net 命名空间,看看它是否有您需要的内容,否则也许可以澄清您正在寻找的内容。
Networking is a very, very, very broad term. You might have more luck if you put some limits in your query, such as "I am looking for sample code for socket programming under c#". Still broad, but much more answerable.
C# has a lot of networking functionality built into the .NET framework., mostly in the System.Net namespace. I have found very few things that require using an external library or the windows networking api. You might check out the System.Net namespace and see if it has what you needs, otherwise maybe clarify what you are looking for.
如果您正在寻找框架已经内置的内容之外的东西,我听说过关于 Lidgren。
If you're looking for something outside of what's already built-in to the framework, I've heard good things about Lidgren.