如何在线或离线了解Clint [英] How to Know Clint online or Offline

查看:76
本文介绍了如何在线或离线了解Clint的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

亲爱的所有高级程序员,

我创建了客户端程序和服务器程序,当客户端程序运行时我可以显示这个客户端是否在线,问题是什么以及在哪里写代码知道他离线关闭他的电脑或休眠时,

谢谢和最好的问候,

Dear All Senior Programmer,
I created Client program and server program, when the client program is run I can show this client is online, the question What and where write code to know he is offline when shutdown his computer or hibernate it,
thanks and best regards,

推荐答案

没办法。从服务器部分的角度来看,甚至不存在离线用户。在具有身份验证的系统中,当所有用户都注销时,您可以安全地重新启动系统(安全将意味着没有任何丢失或弄乱用户相关数据)。例如,您可以阻止所有用户登录,然后等到最后一个用户注销。



-SA
No way. From the standpoint of the server part, an off-line user does not even exist. In the systems with authentication, you can safely restart the system ("safely" would mean "without any loss or messing up of user-related data") when all users are logged off. For example, you can block logging on for all users and then wait until the last user logs off.

—SA


这篇关于如何在线或离线了解Clint的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆