Should GetManagedObjects include the current path?

David Henningsson diwic at ubuntu.com
Sat Oct 19 20:18:26 UTC 2019


Suppose we have two paths, /hello and /hello/world, where /hello 
implements org.freedesktop.DBus.ObjectManager. When GetManagedObjects is 
called on /hello, should it return data for both /hello and 
/hello/world, or just /hello/world?

There is a line in the spec saying "All returned object paths are 
children of the object path implementing this interface, i.e. their 
object paths start with the ObjectManager's object path plus '/'." This 
seems to indicate that just "/hello/world" should be returned and not 
"/hello", but

  - When calling AddMatch, the "path_namespace" in the example a few 
lines below is written so that it does include the path itself, and

  - The last part is not true for the root path "/", because if 
ObjectManager is implemented on "/", then "/" + "/" = "//" so this needs 
special handling

// David



More information about the dbus mailing list