开发者

Design Pattern for VOIP client/server

I 'd know what Design pattern I should use for my VOIP Client and Server, where clients could call other clients w开发者_开发百科ithout through the server.

Thank you


You should create a class for end to end communication that deals with the Sockets, the interface will be strictly for communication, it should have no application related functions. Both the client and server will extend from this component.

Then since the client and server will have different functionality, you can design them however you wish.

Hope that help from a high level perspective. Here is a pretty good resource for finding specific design patterns. http://sourcemaking.com/design_patterns


Any voip complication framework is a complicated artificat. There's no single pattern you can use. Choose stack, build implementation aroud it, then you will know to ask questions more effectively.


I think you are saying you want the messaging (or signaling as it is commonly called) to set up the call to go through the server but the voice to go directly from client to client?

If so then you have a choice of protocols that you can use as an inspiration or a 'design pattern', but the most obvious is probably SIP, which will work like this in most standard setups.

See figure 1.1 at: http://www.cisco.com/univercd/cc/td/doc/product/voice/sipsols/biggulp/bgsipov.htm

The signaling to set up the call follows the solid arrows labeled SIP. The voice follows the dotted arrow labeled as RTP (RTP is Real-Time Transfer Protocol and is commonly used to transport voice across IP networks).

This can perhaps act as a 'design pattern' to meet your needs.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜