![]() |
![]() |
![]() |
Alarmd Reference Manual | ![]() |
---|---|---|---|---|
void (*DBusNameNotifyCb) (gpointer user_data);void dbus_do_call (DBusConnection *bus,DBusMessage **reply,gboolean activation, constgchar *service, constgchar *path, constgchar *interface, constgchar *name,int first_arg_type, ...);void dbus_do_call_gvalue (DBusConnection *bus,DBusMessage **reply,gboolean activation, constgchar *service, constgchar *path, constgchar *interface, constgchar *name, constGValueArray *args);void dbus_watch_name (constgchar *name, DBusNameNotifyCb cb,gpointer user_data);void dbus_unwatch_name (constgchar *name, DBusNameNotifyCb cb,gpointer user_data);void dbus_set_osso (osso_context_t *osso);DBusConnection * get_dbus_connection (DBusBusType type);void dbus_message_iter_append_gvalue (DBusMessageIter *iter,GValue *gvalue,gboolean as_variator);
void (*DBusNameNotifyCb) (gpointer user_data);
Callback to be called when a watched name changes owner.
user_data : |
user data set when the signal handler was connected. |
void dbus_do_call (DBusConnection *bus,DBusMessage **reply,gboolean activation, constgchar *service, constgchar *path, constgchar *interface, constgchar *name,int first_arg_type, ...);
Does a method call over dbus. End the list of argument type / value pairs with a DBUS_TYPE_INVALID. The argument values must be passed by pointer.
bus : |
|
reply : |
Location to store reply or NULL for no replies. |
activation : |
Should the receiver be started if necessary. |
service : |
Service to be called. |
path : |
Path to be called. |
interface : |
Interface to be called. |
name : |
Name of the method call. |
first_arg_type : |
Type of the first argument. |
... : |
Value of first argument, type of second argument... |
void dbus_do_call_gvalue (DBusConnection *bus,DBusMessage **reply,gboolean activation, constgchar *service, constgchar *path, constgchar *interface, constgchar *name, constGValueArray *args);
Does a method call over dbus.
bus : |
|
reply : |
Location to store reply or NULL for no replies. |
activation : |
Should the receiver be started if necessary. |
service : |
Service to be called. |
path : |
Path to be called. |
interface : |
Interface to be called. |
name : |
Name of the method call. |
args : |
Arguments for the method call. |
void dbus_watch_name (constgchar *name, DBusNameNotifyCb cb,gpointer user_data);
Watches the name, when it changes owner, cb will be called.
name : |
Name to watch. |
cb : |
Callback to call when name changes owner. |
user_data : |
user data to pass to the cb .
|
void dbus_unwatch_name (constgchar *name, DBusNameNotifyCb cb,gpointer user_data);
Stops watching for owner changes of name
.
name : |
Name to stop watching. |
cb : |
Callback that should no longer be called. |
user_data : |
user data to pass to the cb .
|
void dbus_set_osso (osso_context_t *osso);
Sets a singleton osso context that is used to get dbus connections wherever they are needed, See get_dbus_connection.
osso : |
osso context to get connections from. |
DBusConnection * get_dbus_connection (DBusBusType type);
Gets system or session bus from the osso context registered with dbus_set_osso. dbus_set_osso _must_ be called before this can be called.
type : |
DBUS_BUS_SESSION for session bus or DBUS_TYPE_SYSTEM for system bus. |
Returns : | A dbus connection to the bus specified by type . Callers owns a
reference, unref with dbus_connection_unref.
|
void dbus_message_iter_append_gvalue (DBusMessageIter *iter,GValue *gvalue,gboolean as_variator);
Adds a gvalue to a dbus message.
iter : |
Iter into which the gvalue is written to. |
gvalue : |
The value which will be written. |
as_variator : |
If true, the value will be written inside a variator container. |