Implementing org.freedesktop.DBus.ObjectManager with Qt-DBus
I want to create a DBus object implementing org.freedesktop.DBus.ObjectManager to expose its child objects. I did not find any example/explanation in the documentation (or in the web). What is the simplest way to do that?
QDBusConnection::ExportChildObjectsdo that? I don't really understand how it is used.
Or should I create an adaptor for this interface? In this case, I need to introspect my objects in order to get theirs interfaces and properties. How is it achieved?
Edit: I found that I had to use
QDBusConnection::ExportChildObjects. Now, the child object is created but the parent stil does not implement the ObjectManager interface.
I guess I will need to go the second way but how can I know the interfaces implemented by an object. I can found no introspection mechanism either server side or client side.
On the server, do I need to explore the QMetaObject system myself and hope that get the information the same way as QtDBus?
On the client, do I need to call directly org.freedesktop.DBus.Introspectable.Instrospect and write my own Introspection XML parser?