Send a message to all clients in a Group, except for the current client

天大地大妈咪最大 提交于 2019-12-23 07:27:35

问题


I want to execute a method on all connected clients from the server, except for the current client. Any way to do this without me maintaining my own list of clientids?

TIA!


回答1:


You can use Clients.OthersInGroup() method.




回答2:


This functionality has been proposed and discussed on the github issues list for the project, but is not yet implemented http://goo.gl/pyMwF.

For now, you will need to do your own filtering of your clients.



来源:https://stackoverflow.com/questions/10146961/send-a-message-to-all-clients-in-a-group-except-for-the-current-client

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!