如何使用QtDbus注册接口和注册方法?

时间:2012-01-30 05:02:52

标签: c++ qt dbus qtdbus

我想在QtDbus上注册一个接口和方法。

在glib Dbus中,我们有一个方法g_dbus_register_interface(..,..,..,..)。

有没有办法可以使用QtDbus做同样的事情?

1 个答案:

答案 0 :(得分:1)

是的,您必须使用QDBusConnectionInterface :: registerService和QDBusConnectionInterface :: registerObject。请按照本手册获取完整指南:http://techbase.kde.org/Development/Tutorials/D-Bus/Creating_Interfaces