2024-10-01 07:28:54 发布
网友
我正在使用autobahn websocket评估并构建一个简单的websocket服务器
是否有人使用过子类WrappingWebSocketServerProtocol,是否有使用此实现的示例?与WebSocketServerProtocol相比有什么好处?要重写/实现哪些子方法
谢谢你
如果有人感兴趣,可以在下面的示例列表中找到一些答案:
https://github.com/tavendo/AutobahnPython/tree/master/examples/twisted/websocket/wrapping
AutobahnPython允许您在基于流的传输协议(如Telnet、IMAP、VNC等)上运行任何构建在WebSocket上的应用程序协议。对于这种包装,您将使用WrappingWebSocketServerProtocol和相关类。在
WrappingWebSocketServerProtocol
AutobahnPython还允许在任何基于流的传输协议/设施(如Unix域套接字、管道、串行等)上运行WebSocket。为此,您将使用端点:https://github.com/tavendo/AutobahnPython/tree/master/examples/twisted/websocket/echo_endpoints
现在,上面两个都涵盖了特殊的用例,如果你想做一个“普通”的WebSocket应用,你只需要使用WebSocketServerProtocol和相关的类。在
WebSocketServerProtocol
如果有人感兴趣,可以在下面的示例列表中找到一些答案:
https://github.com/tavendo/AutobahnPython/tree/master/examples/twisted/websocket/wrapping
AutobahnPython允许您在基于流的传输协议(如Telnet、IMAP、VNC等)上运行任何构建在WebSocket上的应用程序协议。对于这种包装,您将使用
WrappingWebSocketServerProtocol
和相关类。在AutobahnPython还允许在任何基于流的传输协议/设施(如Unix域套接字、管道、串行等)上运行WebSocket。为此,您将使用端点:https://github.com/tavendo/AutobahnPython/tree/master/examples/twisted/websocket/echo_endpoints
现在,上面两个都涵盖了特殊的用例,如果你想做一个“普通”的WebSocket应用,你只需要使用
WebSocketServerProtocol
和相关的类。在相关问题 更多 >
编程相关推荐