The QDBusVirtualObject class is used to handle several DBus paths with one class. More

Inheritance diagram of PySide6.QtDBus.QDBusVirtualObject

Detailed Description#

class PySide6.QtDBus.QDBusVirtualObject([parent=None])#


Constructs a QDBusVirtualObject with parent.

abstract PySide6.QtDBus.QDBusVirtualObject.handleMessage(message, connection)#
Return type


This function needs to handle all messages to the path of the virtual object, when the SubPath option is specified. The service, path, interface and methods are all part of the message. Parameter connection is the connection handle. Must return true when the message is handled, otherwise false (will generate dbus error message).

abstract PySide6.QtDBus.QDBusVirtualObject.introspect(path)#

path – str

Return type


This function needs to handle the introspection of the virtual object on path. It must return xml of the form:

<interface name="org.qtproject.QtDBus.MyObject" >
    <property access="readwrite" type="i" name="prop1" />

If you pass the SubPath option, this introspection has to include all child nodes. Otherwise QDBus handles the introspection of the child nodes.