libsysprof: use a{sv} for future profiler specific options

We may need this in the future to send backend-specific options to the
profiler peer.
This commit is contained in:
Christian Hergert
2019-05-29 15:08:17 -07:00
parent 62c9057089
commit a74e6daa3b
2 changed files with 20 additions and 1 deletions

View File

@ -229,7 +229,7 @@ sysprof_proxy_source_monitor (SysprofProxySource *self,
self->object_path,
"org.gnome.Sysprof3.Profiler",
"Start",
g_variant_new ("(h)", handle),
g_variant_new ("(a{sv}h)", NULL, handle),
G_VARIANT_TYPE ("()"),
G_DBUS_CALL_FLAGS_NO_AUTO_START,
-1,

View File

@ -2,9 +2,28 @@
"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd">
<node>
<interface name="org.gnome.Sysprof3.Profiler">
<!--
Start:
@options: an a{sv} of implementation specific options
@fd: a file-descriptor for the profiler to write to
Start the profiler if it is not running.
If the profiler is already running, this method should return
an error so that the caller knows not to call Stop().
It is also suggested that implementations disable profiling if
they lose the peer connection.
-->
<method name="Start">
<arg type="a{sv}" name="options" direction="in"/>
<arg type="h" name="fd" direction="in"/>
</method>
<!--
Stop:
Stop the profiler if it is running.
-->
<method name="Stop"/>
</interface>
</node>