Obsolete Members for QDBusConnectionInterface
类QDBusConnectionInterface 的以下成员已被弃用。提供这些成员是为了保持旧源代码的正常运行。我们强烈建议不要在新代码中使用它们。
信号
(deprecated) void | serviceOwnerChanged(const QString &name, const QString &oldOwner, const QString &newOwner) |
成员函数文档
[signal, deprecated]
void QDBusConnectionInterface::serviceOwnerChanged(const QString &name, const QString &oldOwner, const QString &newOwner)
该函数已被弃用。我们强烈建议不要在新代码中使用它。
请使用QDBusServiceWatcher 。
每当总线上发生服务所有权变更(包括名称的出现和消失)时,D-Bus 服务器都会发出该信号。
该信号表示应用程序oldOwner 已将总线名称name 的所有权移交给应用程序newOwner 。如果oldOwner 为空字符串,则表示name 名称刚刚创建;如果newOwner 为空字符串,则表示name 名称当前没有所有者,不再可用。
注意: 连接到此信号将使应用程序监听并接收总线上的每一次服务所有权变更。根据正在运行的服务数量,这将使应用程序被激活以接收超过其需要的信号。为避免这一问题,请使用QDBusServiceWatcher 类,它可以监听特定的变更。
© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.