DBusRemoteObjectManager constructor
DBusRemoteObjectManager(
- DBusClient client, {
- required String name,
- required DBusObjectPath path,
Creates an object that access accesses a remote D-Bus object manager using bus name
with path
.
Requires the remote object to implement the org.freedesktop.DBus.ObjectManager interface.
Implementation
DBusRemoteObjectManager(DBusClient client,
{required String name, required DBusObjectPath path})
: super(client, name: name, path: path) {
var rawSignals =
DBusSignalStream(client, sender: name, pathNamespace: path);
signals = rawSignals.map((signal) {
if (signal.interface == 'org.freedesktop.DBus.ObjectManager' &&
signal.name == 'InterfacesAdded' &&
signal.signature == DBusSignature('oa{sa{sv}}')) {
return DBusObjectManagerInterfacesAddedSignal(signal);
} else if (signal.interface == 'org.freedesktop.DBus.ObjectManager' &&
signal.name == 'InterfacesRemoved' &&
signal.signature == DBusSignature('oas')) {
return DBusObjectManagerInterfacesRemovedSignal(signal);
} else if (signal.interface == 'org.freedesktop.DBus.Properties' &&
signal.name == 'PropertiesChanged' &&
signal.signature == DBusSignature('sa{sv}as')) {
return DBusPropertiesChangedSignal(signal);
} else {
return signal;
}
});
}