Search code examples
glibdbusvalagdbuslibgee

How to send Vala ArrayList through D-Bus?


Trying to send data from server to client and getting this error:

error: GVariant serialization of type `Gee.ArrayList' is not supported
public abstract ArrayList<EventData?> get_event_list () throws IOError;

Solution

  • You need to use a plain array. A good resource for showing D-Bus types mapped to Vala types is the Type Table in Vala D-Bus Examples.

    For EventData you should consider a Variant, struct or ObjectPath.