multi client/server chat program in c#?

前端 未结 4 809
天命终不由人
天命终不由人 2021-01-23 11:36

the clients will be able to chat one-to-one and in group (temperately rooms) similar to Skype.

I will use the server to authorize the clients

my question is whic

相关标签:
4条回答
  • 2021-01-23 11:49

    I did not use WCF yet, but I can testify that TCPClient is a popular good start to do it, it works perfectly well, and you will find many ready-to-use examples all around the net. Besides, if you are beginning into networking, it is a good way to acknowledge the technology because you will know exactly what you are exactly doing and it will help you understand the basics of client/server technology.

    On the other Side, WCF seems to be a lot more simplified and straightforward, but makes it difficult to see what goes on behind the scenes.

    I suggest you try both with simple pieces of code and see for yourself, that's what I did every time I had technology alternatives to choose from, and this is IMHO the best way to make your own relevant decision.

    0 讨论(0)
  • 2021-01-23 11:50

    Go with WCF, WCF is good in wrapping the hard stuff, it presents those on a silver plate for you, the developer letting you focus on your program's logic.

    I'm sure WCF can satisfy your program needs and more.

    0 讨论(0)
  • 2021-01-23 11:53

    I would vote for WCF also, as it will provide you with a common interface for doing a client/server architecture regardless of what protocol (binding) you choose behind the scenes. For example, you could very quickly make your chat program work across HTTP via SOAP with just a few configuration changes. WCF will also allow you to easily interoperate with clients written in different languages, but is optimised for .NET on both ends using the NetTcpBinding.

    WCF will also work seamlessly with Visual Studio and is included in the .NET framework 3.0 and above, so no third party libraries will be required.

    0 讨论(0)
  • 2021-01-23 12:02

    You will want to use WCF. No hassle with ports and listeners and you will probably need some of the features (Instance management, security) WCF provides.

    0 讨论(0)
提交回复
热议问题