Object paths naming conventions?

Havoc Pennington hp at pobox.com
Fri Jul 18 09:31:18 PDT 2008


On Fri, Jul 18, 2008 at 12:14 PM, Marcel Holtmann <marcel at holtmann.org> wrote:
> I might be totally missing something here, but please show me where it
> the pure object path and not object path + interface that actually
> defines the language object.

I think what you're missing is that not all objects are singletons.
There can be multiple objects implementing an interface.

The "just use interface" shortcut, in say Java, would look something like:

class SingletonFactory {
  void registerSingleton(Class klass, Object o);
  Object getSingleton(Class klass);

Where when a message arrived, you'd do getSingleton() based on the
interface (class) to get the registered singleton instance.

In this case you don't care what the object path is, it's true. So it
would be fine to allow omitting the object path to mean "look up
singleton by interface"

However, the protocol doesn't support this (you can't omit the object
path) and libdbus doesn't support this (you can't register instances
by interface name). So, without adding support for this, it isn't
right to just use "/" as the object path and then ignore the object
path. The feature is not implemented.


More information about the dbus mailing list