D-Bus Utilities

D-Bus Utilities — Various utilities related to D-Bus.

Synopsis

#include <gio/gio.h>

gchar *             g_dbus_generate_guid                (void);
gboolean            g_dbus_is_guid                      (const gchar *string);
gboolean            g_dbus_is_name                      (const gchar *string);
gboolean            g_dbus_is_unique_name               (const gchar *string);
gboolean            g_dbus_is_member_name               (const gchar *string);
gboolean            g_dbus_is_interface_name            (const gchar *string);

Description

Various utility routines related to D-Bus.

Details

g_dbus_generate_guid ()

gchar *             g_dbus_generate_guid                (void);

Generate a D-Bus GUID that can be used with e.g. g_dbus_connection_new().

See the D-Bus specification regarding what strings are valid D-Bus GUID (for example, D-Bus GUIDs are not RFC-4122 compliant).

Returns :

A valid D-Bus GUID. Free with g_free().

Since 2.26


g_dbus_is_guid ()

gboolean            g_dbus_is_guid                      (const gchar *string);

Checks if string is a D-Bus GUID.

See the D-Bus specification regarding what strings are valid D-Bus GUID (for example, D-Bus GUIDs are not RFC-4122 compliant).

string :

The string to check.

Returns :

TRUE if string is a guid, FALSE otherwise.

Since 2.26


g_dbus_is_name ()

gboolean            g_dbus_is_name                      (const gchar *string);

Checks if string is a valid D-Bus bus name (either unique or well-known).

string :

The string to check.

Returns :

TRUE if valid, FALSE otherwise.

Since 2.26


g_dbus_is_unique_name ()

gboolean            g_dbus_is_unique_name               (const gchar *string);

Checks if string is a valid D-Bus unique bus name.

string :

The string to check.

Returns :

TRUE if valid, FALSE otherwise.

Since 2.26


g_dbus_is_member_name ()

gboolean            g_dbus_is_member_name               (const gchar *string);

Checks if string is a valid D-Bus member (e.g. signal or method) name.

string :

The string to check.

Returns :

TRUE if valid, FALSE otherwise.

Since 2.26


g_dbus_is_interface_name ()

gboolean            g_dbus_is_interface_name            (const gchar *string);

Checks if string is a valid D-Bus interface name.

string :

The string to check.

Returns :

TRUE if valid, FALSE otherwise.

Since 2.26