|  |  |  | GIO Reference Manual |  | 
|---|---|---|---|---|
| Top | Description | Object Hierarchy | ||||
#include <gio/gio.h>
                    GDBusAnnotationInfo;
                    GDBusArgInfo;
                    GDBusMethodInfo;
                    GDBusSignalInfo;
enum                GDBusPropertyInfoFlags;
                    GDBusPropertyInfo;
                    GDBusInterfaceInfo;
                    GDBusNodeInfo;
const gchar *       g_dbus_annotation_info_lookup       (GDBusAnnotationInfo **annotations,
                                                         const gchar *name);
GDBusMethodInfo *   g_dbus_interface_info_lookup_method (GDBusInterfaceInfo *info,
                                                         const gchar *name);
GDBusSignalInfo *   g_dbus_interface_info_lookup_signal (GDBusInterfaceInfo *info,
                                                         const gchar *name);
GDBusPropertyInfo * g_dbus_interface_info_lookup_property
                                                        (GDBusInterfaceInfo *info,
                                                         const gchar *name);
void                g_dbus_interface_info_generate_xml  (GDBusInterfaceInfo *info,
                                                         guint indent,
                                                         GString *string_builder);
GDBusNodeInfo *     g_dbus_node_info_new_for_xml        (const gchar *xml_data,
                                                         GError **error);
GDBusInterfaceInfo * g_dbus_node_info_lookup_interface  (GDBusNodeInfo *info,
                                                         const gchar *name);
void                g_dbus_node_info_generate_xml       (GDBusNodeInfo *info,
                                                         guint indent,
                                                         GString *string_builder);
#define             G_TYPE_DBUS_NODE_INFO
#define             G_TYPE_DBUS_INTERFACE_INFO
#define             G_TYPE_DBUS_METHOD_INFO
#define             G_TYPE_DBUS_SIGNAL_INFO
#define             G_TYPE_DBUS_PROPERTY_INFO
#define             G_TYPE_DBUS_ARG_INFO
#define             G_TYPE_DBUS_ANNOTATION_INFO
GDBusNodeInfo *     g_dbus_node_info_ref                (GDBusNodeInfo *info);
GDBusInterfaceInfo * g_dbus_interface_info_ref          (GDBusInterfaceInfo *info);
GDBusMethodInfo *   g_dbus_method_info_ref              (GDBusMethodInfo *info);
GDBusSignalInfo *   g_dbus_signal_info_ref              (GDBusSignalInfo *info);
GDBusPropertyInfo * g_dbus_property_info_ref            (GDBusPropertyInfo *info);
GDBusArgInfo *      g_dbus_arg_info_ref                 (GDBusArgInfo *info);
GDBusAnnotationInfo * g_dbus_annotation_info_ref        (GDBusAnnotationInfo *info);
void                g_dbus_node_info_unref              (GDBusNodeInfo *info);
void                g_dbus_interface_info_unref         (GDBusInterfaceInfo *info);
void                g_dbus_method_info_unref            (GDBusMethodInfo *info);
void                g_dbus_signal_info_unref            (GDBusSignalInfo *info);
void                g_dbus_property_info_unref          (GDBusPropertyInfo *info);
void                g_dbus_arg_info_unref               (GDBusArgInfo *info);
void                g_dbus_annotation_info_unref        (GDBusAnnotationInfo *info);
Various data structures and convenience routines to parse and
generate D-Bus introspection XML. Introspection information is
used when registering objects with g_dbus_connection_register_object().
The format of D-Bus introspection XML is specified in the D-Bus specification.
typedef struct {
  volatile gint         ref_count;
  gchar                *key;
  gchar                *value;
  GDBusAnnotationInfo **annotations;
} GDBusAnnotationInfo;
Information about an annotation.
| volatile gint  | The reference count or -1 if statically allocated. | 
| gchar * | The name of the annotation, e.g. "org.freedesktop.DBus.Deprecated". | 
| gchar * | The value of the annotation. | 
| GDBusAnnotationInfo ** | A pointer to a NULL-terminated array of pointers to GDBusAnnotationInfo structures orNULLif there are no annotations. | 
Since 2.26
typedef struct {
  volatile gint         ref_count;
  gchar                *name;
  gchar                *signature;
  GDBusAnnotationInfo **annotations;
} GDBusArgInfo;
Information about an argument for a method or a signal.
| volatile gint  | The reference count or -1 if statically allocated. | 
| gchar * | Name of the argument, e.g. unix_user_id. | 
| gchar * | D-Bus signature of the argument (a single complete type). | 
| GDBusAnnotationInfo ** | A pointer to a NULL-terminated array of pointers to GDBusAnnotationInfo structures orNULLif there are no annotations. | 
Since 2.26
typedef struct {
  volatile gint         ref_count;
  gchar                *name;
  GDBusArgInfo        **in_args;
  GDBusArgInfo        **out_args;
  GDBusAnnotationInfo **annotations;
} GDBusMethodInfo;
Information about a method on an D-Bus interface.
| volatile gint  | The reference count or -1 if statically allocated. | 
| gchar * | The name of the D-Bus method, e.g. RequestName. | 
| GDBusArgInfo ** | A pointer to a NULL-terminated array of pointers to GDBusArgInfo structures orNULLif there are no in arguments. | 
| GDBusArgInfo ** | A pointer to a NULL-terminated array of pointers to GDBusArgInfo structures orNULLif there are no out arguments. | 
| GDBusAnnotationInfo ** | A pointer to a NULL-terminated array of pointers to GDBusAnnotationInfo structures orNULLif there are no annotations. | 
Since 2.26
typedef struct {
  volatile gint         ref_count;
  gchar                *name;
  GDBusArgInfo        **args;
  GDBusAnnotationInfo **annotations;
} GDBusSignalInfo;
Information about a signal on a D-Bus interface.
| volatile gint  | The reference count or -1 if statically allocated. | 
| gchar * | The name of the D-Bus signal, e.g. "NameOwnerChanged". | 
| GDBusArgInfo ** | A pointer to a NULL-terminated array of pointers to GDBusArgInfo structures orNULLif there are no arguments. | 
| GDBusAnnotationInfo ** | A pointer to a NULL-terminated array of pointers to GDBusAnnotationInfo structures orNULLif there are no annotations. | 
Since 2.26
typedef enum
{
  G_DBUS_PROPERTY_INFO_FLAGS_NONE = 0,
  G_DBUS_PROPERTY_INFO_FLAGS_READABLE = (1<<0),
  G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE = (1<<1)
} GDBusPropertyInfoFlags;
Flags describing the access control of a D-Bus property.
| No flags set. | |
| Property is readable. | |
| Property is writable. | 
Since 2.26
typedef struct {
  volatile gint             ref_count;
  gchar                    *name;
  gchar                    *signature;
  GDBusPropertyInfoFlags    flags;
  GDBusAnnotationInfo     **annotations;
} GDBusPropertyInfo;
Information about a D-Bus property on a D-Bus interface.
| volatile gint  | The reference count or -1 if statically allocated. | 
| gchar * | The name of the D-Bus property, e.g. "SupportedFilesystems". | 
| gchar * | The D-Bus signature of the property (a single complete type). | 
| GDBusPropertyInfoFlags  | Access control flags for the property. | 
| GDBusAnnotationInfo ** | A pointer to a NULL-terminated array of pointers to GDBusAnnotationInfo structures orNULLif there are no annotations. | 
Since 2.26
typedef struct _GDBusInterfaceInfo GDBusInterfaceInfo;
Information about a D-Bus interface.
Since 2.26
typedef struct {
  volatile gint         ref_count;
  gchar                *path;
  GDBusInterfaceInfo  **interfaces;
  GDBusNodeInfo       **nodes;
  GDBusAnnotationInfo **annotations;
} GDBusNodeInfo;
Information about nodes in a remote object hierarchy.
| volatile gint  | The reference count or -1 if statically allocated. | 
| gchar * | The path of the node or NULLif omitted. Note that this may be a relative path. See the D-Bus specification for more details. | 
| GDBusInterfaceInfo ** | A pointer to a NULL-terminated array of pointers to GDBusInterfaceInfo structures orNULLif there are no interfaces. | 
| GDBusNodeInfo ** | A pointer to a NULL-terminated array of pointers to GDBusNodeInfo structures orNULLif there are no nodes. | 
| GDBusAnnotationInfo ** | A pointer to a NULL-terminated array of pointers to GDBusAnnotationInfo structures orNULLif there are no annotations. | 
Since 2.26
const gchar * g_dbus_annotation_info_lookup (GDBusAnnotationInfo **annotations,const gchar *name);
Looks up the value of an annotation.
This cost of this function is O(n) in number of annotations.
| 
 | A NULL-terminated array of annotations orNULL. | 
| 
 | The name of the annotation to look up. | 
| Returns : | The value or NULLif not found. Do not free, it is owned byannotations. | 
Since 2.26
GDBusMethodInfo * g_dbus_interface_info_lookup_method (GDBusInterfaceInfo *info,const gchar *name);
Looks up information about a method.
This cost of this function is O(n) in number of methods.
| 
 | A GDBusInterfaceInfo. | 
| 
 | A D-Bus method name (typically in CamelCase) | 
| Returns : | A GDBusMethodInfo or NULLif not found. Do not free, it is owned byinfo. | 
Since 2.26
GDBusSignalInfo * g_dbus_interface_info_lookup_signal (GDBusInterfaceInfo *info,const gchar *name);
Looks up information about a signal.
This cost of this function is O(n) in number of signals.
| 
 | A GDBusInterfaceInfo. | 
| 
 | A D-Bus signal name (typically in CamelCase) | 
| Returns : | A GDBusSignalInfo or NULLif not found. Do not free, it is owned byinfo. | 
Since 2.26
GDBusPropertyInfo * g_dbus_interface_info_lookup_property (GDBusInterfaceInfo *info,const gchar *name);
Looks up information about a property.
This cost of this function is O(n) in number of properties.
| 
 | A GDBusInterfaceInfo. | 
| 
 | A D-Bus property name (typically in CamelCase). | 
| Returns : | A GDBusPropertyInfo or NULLif not found. Do not free, it is owned byinfo. | 
Since 2.26
void g_dbus_interface_info_generate_xml (GDBusInterfaceInfo *info,guint indent,GString *string_builder);
Appends an XML representation of info (and its children) to string_builder.
This function is typically used for generating introspection XML
documents at run-time for handling the
org.freedesktop.DBus.Introspectable.Introspect
method.
| 
 | A GDBusNodeInfo | 
| 
 | Indentation level. | 
| 
 | A GString to to append XML data to. | 
Since 2.26
GDBusNodeInfo * g_dbus_node_info_new_for_xml (const gchar *xml_data,GError **error);
Parses xml_data and returns a GDBusNodeInfo representing the data.
| 
 | Valid D-Bus introspection XML. | 
| 
 | Return location for error. | 
| Returns : | A GDBusNodeInfo structure or NULLiferroris set. Free
withg_dbus_node_info_unref(). | 
Since 2.26
GDBusInterfaceInfo * g_dbus_node_info_lookup_interface (GDBusNodeInfo *info,const gchar *name);
Looks up information about an interface.
This cost of this function is O(n) in number of interfaces.
| 
 | A GDBusNodeInfo. | 
| 
 | A D-Bus interface name. | 
| Returns : | A GDBusInterfaceInfo or NULLif not found. Do not free, it is owned byinfo. | 
Since 2.26
void g_dbus_node_info_generate_xml (GDBusNodeInfo *info,guint indent,GString *string_builder);
Appends an XML representation of info (and its children) to string_builder.
This function is typically used for generating introspection XML documents at run-time for
handling the org.freedesktop.DBus.Introspectable.Introspect method.
| 
 | A GDBusNodeInfo. | 
| 
 | Indentation level. | 
| 
 | A GString to to append XML data to. | 
Since 2.26
#define G_TYPE_DBUS_NODE_INFO (g_dbus_node_info_get_type ())
The GType for a boxed type holding a GDBusNodeInfo.
Since 2.26
#define G_TYPE_DBUS_INTERFACE_INFO (g_dbus_interface_info_get_type ())
The GType for a boxed type holding a GDBusInterfaceInfo.
Since 2.26
#define G_TYPE_DBUS_METHOD_INFO (g_dbus_method_info_get_type ())
The GType for a boxed type holding a GDBusMethodInfo.
Since 2.26
#define G_TYPE_DBUS_SIGNAL_INFO (g_dbus_signal_info_get_type ())
The GType for a boxed type holding a GDBusSignalInfo.
Since 2.26
#define G_TYPE_DBUS_PROPERTY_INFO (g_dbus_property_info_get_type ())
The GType for a boxed type holding a GDBusPropertyInfo.
Since 2.26
#define G_TYPE_DBUS_ARG_INFO (g_dbus_arg_info_get_type ())
The GType for a boxed type holding a GDBusArgInfo.
Since 2.26
#define G_TYPE_DBUS_ANNOTATION_INFO (g_dbus_annotation_info_get_type ())
The GType for a boxed type holding a GDBusAnnotationInfo.
Since 2.26
GDBusNodeInfo *     g_dbus_node_info_ref                (GDBusNodeInfo *info);
If info is statically allocated does nothing. Otherwise increases
the reference count.
| 
 | A GDBusNodeInfo | 
| Returns : | The same info. | 
Since 2.26
GDBusInterfaceInfo * g_dbus_interface_info_ref          (GDBusInterfaceInfo *info);
If info is statically allocated does nothing. Otherwise increases
the reference count.
| 
 | A GDBusInterfaceInfo | 
| Returns : | The same info. | 
Since 2.26
GDBusMethodInfo *   g_dbus_method_info_ref              (GDBusMethodInfo *info);
If info is statically allocated does nothing. Otherwise increases
the reference count.
| 
 | A GDBusMethodInfo | 
| Returns : | The same info. | 
Since 2.26
GDBusSignalInfo *   g_dbus_signal_info_ref              (GDBusSignalInfo *info);
If info is statically allocated does nothing. Otherwise increases
the reference count.
| 
 | A GDBusSignalInfo | 
| Returns : | The same info. | 
Since 2.26
GDBusPropertyInfo * g_dbus_property_info_ref            (GDBusPropertyInfo *info);
If info is statically allocated does nothing. Otherwise increases
the reference count.
| 
 | A GDBusPropertyInfo | 
| Returns : | The same info. | 
Since 2.26
GDBusArgInfo *      g_dbus_arg_info_ref                 (GDBusArgInfo *info);
If info is statically allocated does nothing. Otherwise increases
the reference count.
| 
 | A GDBusArgInfo | 
| Returns : | The same info. | 
Since 2.26
GDBusAnnotationInfo * g_dbus_annotation_info_ref        (GDBusAnnotationInfo *info);
If info is statically allocated does nothing. Otherwise increases
the reference count.
| 
 | A GDBusNodeInfo | 
| Returns : | The same info. | 
Since 2.26
void                g_dbus_node_info_unref              (GDBusNodeInfo *info);
If info is statically allocated, does nothing. Otherwise decreases
the reference count of info. When its reference count drops to 0,
the memory used is freed.
| 
 | A GDBusNodeInfo. | 
Since 2.26
void                g_dbus_interface_info_unref         (GDBusInterfaceInfo *info);
If info is statically allocated, does nothing. Otherwise decreases
the reference count of info. When its reference count drops to 0,
the memory used is freed.
| 
 | A GDBusInterfaceInfo. | 
Since 2.26
void                g_dbus_method_info_unref            (GDBusMethodInfo *info);
If info is statically allocated, does nothing. Otherwise decreases
the reference count of info. When its reference count drops to 0,
the memory used is freed.
| 
 | A GDBusMethodInfo. | 
Since 2.26
void                g_dbus_signal_info_unref            (GDBusSignalInfo *info);
If info is statically allocated, does nothing. Otherwise decreases
the reference count of info. When its reference count drops to 0,
the memory used is freed.
| 
 | A GDBusSignalInfo. | 
Since 2.26
void                g_dbus_property_info_unref          (GDBusPropertyInfo *info);
If info is statically allocated, does nothing. Otherwise decreases
the reference count of info. When its reference count drops to 0,
the memory used is freed.
| 
 | A GDBusPropertyInfo. | 
Since 2.26
void                g_dbus_arg_info_unref               (GDBusArgInfo *info);
If info is statically allocated, does nothing. Otherwise decreases
the reference count of info. When its reference count drops to 0,
the memory used is freed.
| 
 | A GDBusArgInfo. | 
Since 2.26
void                g_dbus_annotation_info_unref        (GDBusAnnotationInfo *info);
If info is statically allocated, does nothing. Otherwise decreases
the reference count of info. When its reference count drops to 0,
the memory used is freed.
| 
 | A GDBusAnnotationInfo. | 
Since 2.26