[英]Reconnect Nodejs SocketIO in android
I'm creating a chat app with nodejs socketIO in android. 我正在使用Android中的nodejs socketIO创建一个聊天应用程序。 I have a problem when i press the back button on the Activity it will return to the login Activity and disconnect the nodejs socketIO and i want to login again but not connected to nodejs socketIO again .
我在按下Activity上的后退按钮时遇到问题,它将返回登录Activity并断开nodejs socketIO的连接,我想再次登录但又不想再次连接到nodejs socketIO。 How to reconnect .
如何重新连接。 Please help me
请帮我
Here is logic which you can apply. 这是您可以应用的逻辑。
I hope this answer helps you and solve your problem. 我希望这个答案可以帮助您并解决您的问题。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.