File indexing completed on 2025-01-18 09:59:55
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023 #ifndef __G_DBUS_ERROR_H__
0024 #define __G_DBUS_ERROR_H__
0025
0026 #if !defined (__GIO_GIO_H_INSIDE__) && !defined (GIO_COMPILATION)
0027 #error "Only <gio/gio.h> can be included directly."
0028 #endif
0029
0030 #include <gio/giotypes.h>
0031
0032 G_BEGIN_DECLS
0033
0034
0035
0036
0037
0038
0039
0040
0041
0042
0043
0044
0045
0046
0047
0048 #define G_DBUS_ERROR g_dbus_error_quark()
0049
0050 GIO_AVAILABLE_IN_ALL
0051 GQuark g_dbus_error_quark (void);
0052
0053
0054 GIO_AVAILABLE_IN_ALL
0055 gboolean g_dbus_error_is_remote_error (const GError *error);
0056 GIO_AVAILABLE_IN_ALL
0057 gchar *g_dbus_error_get_remote_error (const GError *error);
0058 GIO_AVAILABLE_IN_ALL
0059 gboolean g_dbus_error_strip_remote_error (GError *error);
0060
0061
0062
0063
0064
0065
0066
0067
0068
0069
0070 struct _GDBusErrorEntry
0071 {
0072 gint error_code;
0073 const gchar *dbus_error_name;
0074 };
0075
0076 GIO_AVAILABLE_IN_ALL
0077 gboolean g_dbus_error_register_error (GQuark error_domain,
0078 gint error_code,
0079 const gchar *dbus_error_name);
0080 GIO_AVAILABLE_IN_ALL
0081 gboolean g_dbus_error_unregister_error (GQuark error_domain,
0082 gint error_code,
0083 const gchar *dbus_error_name);
0084 GIO_AVAILABLE_IN_ALL
0085 void g_dbus_error_register_error_domain (const gchar *error_domain_quark_name,
0086 volatile gsize *quark_volatile,
0087 const GDBusErrorEntry *entries,
0088 guint num_entries);
0089
0090
0091 GIO_AVAILABLE_IN_ALL
0092 GError *g_dbus_error_new_for_dbus_error (const gchar *dbus_error_name,
0093 const gchar *dbus_error_message);
0094 GIO_AVAILABLE_IN_ALL
0095 void g_dbus_error_set_dbus_error (GError **error,
0096 const gchar *dbus_error_name,
0097 const gchar *dbus_error_message,
0098 const gchar *format,
0099 ...) G_GNUC_PRINTF(4, 5);
0100 GIO_AVAILABLE_IN_ALL
0101 void g_dbus_error_set_dbus_error_valist (GError **error,
0102 const gchar *dbus_error_name,
0103 const gchar *dbus_error_message,
0104 const gchar *format,
0105 va_list var_args) G_GNUC_PRINTF(4, 0);
0106 GIO_AVAILABLE_IN_ALL
0107 gchar *g_dbus_error_encode_gerror (const GError *error);
0108
0109 G_END_DECLS
0110
0111 #endif