Calling a method that returns an array of structs

Colin Walters walters at verbum.org
Wed May 28 11:25:26 PDT 2008


On Fri, May 16, 2008 at 5:44 PM, Boyd Timothy <btimothy at gmail.com> wrote:

> I've been reading through old mailing posts about this subject, but so
> far none of them seem to match up with what I'm trying to do.
>
> I've got a DBus method in one process that returns an array of
> structs.  Each struct contains three strings.
>
> I'd like to be able to call this from my C app using dbus-glib, but I
> can't figure out what the parameters to dbus_g_proxy_call () would be.
>  Could someone point me to something that would help out?
>

Hi, I think the type declaration would be:

dbus_g_type_get_collection ("GArray",  dbus_g_type_get_struct
("GValueArray", G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING,
G_TYPE_INVALID))

There is very little test coverage (and examples) of structs right now
unfortunately.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freedesktop.org/archives/dbus/attachments/20080528/f99d6fa3/attachment.html 


More information about the dbus mailing list