mapping object paths to method calls
Chris Rebert
cvrebert at gmail.com
Sun Apr 9 11:28:08 PDT 2006
Dan -
That sounds absolutely *perfect*.
By happy coincidence I'm using Python for this project.
Thanks a million!
- Chris
Daniel P. Berrange wrote:
> On Sun, Apr 09, 2006 at 11:35:38AM +0200, Thiago Macieira wrote:
>
>>Chris Rebert wrote:
>>
>>>My application will have a large database of objects accessible via an
>>>object path that incorporates their ids (e.g. /org/foo/bar/41254), and
>>>even using the flyweight pattern, I believe there would not be enough
>>>memory to register an object path for each object, therefore I would
>>>like to generate each object on demand if possible, as only a few of the
>>>many will be in use at any one time.
>>>If you have any ideas on how to accomplish this, I would be most
>>>appreciative.
>>
>>See above.
>>
>>Registering the object depends on how your binding does it. Technically
>>speaking, with a message filter, you could catch the call to any object,
>>without the need to call any specific "register object" function.
>
>
> The Python bindings already have support for exactly this capability. The
> ObjectTree class takes a base path, eg /org/foo/bar, and then handles
> calls for any object below this point, eg /org/foo/bar/41254 without needing
> any of the sub-objects to be explicitly registered - only the base path
> is registered.
>
> Regards,
> Dan.
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> dbus mailing list
> dbus at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dbus
More information about the dbus
mailing list