DBUS C++ bindings?
robtaylor at floopily.org
Sun Mar 5 14:44:36 PST 2006
Murray Cumming wrote:
> On Sat, 2006-02-25 at 20:36 +0100, Thiago Macieira wrote:
>>Murray Cumming wrote:
>>>Glib::Value might be a good equivalent. However, one Glib::Value only
>>>contains one value. It can't contain x ints, y strings, and z booleans.
>>Can't it contain a value which happens to be a list?
> I don't think so.
I'm afraid I only just got around to reading this thread.. I have to
admit ignorance on exactly how glibmm interacts with glib itself, but in
the glib bindings we declare new gtypes for structs. In fact using the
dbus_gtype_specialized stuff, you can recursively define gtypes for any
combination of arrays, maps and structs. The 'specialized' types then
have vtables for things like appending, iteration, freeing of elements
(for the array and map types) and looking up elements (for structs).
These then get given concrete implementations.
Its all slightly weird, so I'm not sure how well it'd fit in with
glibmm. In the future I have a slight dream of refactoring this into a
scheme similar to P. Van Hoof's interfaces design pattern . we got a
while to smoke crack a bit about this at FOSDEM, so maybe one day.. ;)
More information about the dbus