mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-25 15:06:14 +01:00
Annotate API introduced for 2.30 with GLIB_AVAILABLE_IN_2_30
I didn't do this comprehensively, since there's a lot of it, mainly due to the GDBus object manager stuff, but anyone trying to use that would fail fast due to lack of the gdbus code generator. My main goal was to get API additions to existing classes like g_data_input_stream_read_line_utf8(), as well as the lower level new API like glib-unix.h. https://bugzilla.gnome.org/show_bug.cgi?id=676816
This commit is contained in:
parent
9c86e1168c
commit
a963712646
@ -58,6 +58,7 @@ struct _GActionInterface
|
|||||||
GVariant *parameter);
|
GVariant *parameter);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GType g_action_get_type (void) G_GNUC_CONST;
|
GType g_action_get_type (void) G_GNUC_CONST;
|
||||||
|
|
||||||
const gchar * g_action_get_name (GAction *action);
|
const gchar * g_action_get_name (GAction *action);
|
||||||
|
@ -102,6 +102,7 @@ char * g_data_input_stream_read_line (GDataInputStrea
|
|||||||
gsize *length,
|
gsize *length,
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
char * g_data_input_stream_read_line_utf8 (GDataInputStream *stream,
|
char * g_data_input_stream_read_line_utf8 (GDataInputStream *stream,
|
||||||
gsize *length,
|
gsize *length,
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
@ -115,6 +116,7 @@ char * g_data_input_stream_read_line_finish (GDataInputStrea
|
|||||||
GAsyncResult *result,
|
GAsyncResult *result,
|
||||||
gsize *length,
|
gsize *length,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
char * g_data_input_stream_read_line_finish_utf8(GDataInputStream *stream,
|
char * g_data_input_stream_read_line_finish_utf8(GDataInputStream *stream,
|
||||||
GAsyncResult *result,
|
GAsyncResult *result,
|
||||||
gsize *length,
|
gsize *length,
|
||||||
|
@ -181,6 +181,7 @@ GVariant *g_dbus_connection_call_sync (GDBusConnection
|
|||||||
gint timeout_msec,
|
gint timeout_msec,
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
void g_dbus_connection_call_with_unix_fd_list (GDBusConnection *connection,
|
void g_dbus_connection_call_with_unix_fd_list (GDBusConnection *connection,
|
||||||
const gchar *bus_name,
|
const gchar *bus_name,
|
||||||
const gchar *object_path,
|
const gchar *object_path,
|
||||||
@ -194,10 +195,12 @@ void g_dbus_connection_call_with_unix_fd_list (GDBusConnection
|
|||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GAsyncReadyCallback callback,
|
GAsyncReadyCallback callback,
|
||||||
gpointer user_data);
|
gpointer user_data);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GVariant *g_dbus_connection_call_with_unix_fd_list_finish (GDBusConnection *connection,
|
GVariant *g_dbus_connection_call_with_unix_fd_list_finish (GDBusConnection *connection,
|
||||||
GUnixFDList **out_fd_list,
|
GUnixFDList **out_fd_list,
|
||||||
GAsyncResult *res,
|
GAsyncResult *res,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GVariant *g_dbus_connection_call_with_unix_fd_list_sync (GDBusConnection *connection,
|
GVariant *g_dbus_connection_call_with_unix_fd_list_sync (GDBusConnection *connection,
|
||||||
const gchar *bus_name,
|
const gchar *bus_name,
|
||||||
const gchar *object_path,
|
const gchar *object_path,
|
||||||
|
@ -40,8 +40,10 @@ gboolean g_atomic_int_compare_and_exchange (volatile gint *a
|
|||||||
gint newval);
|
gint newval);
|
||||||
gint g_atomic_int_add (volatile gint *atomic,
|
gint g_atomic_int_add (volatile gint *atomic,
|
||||||
gint val);
|
gint val);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
guint g_atomic_int_and (volatile guint *atomic,
|
guint g_atomic_int_and (volatile guint *atomic,
|
||||||
guint val);
|
guint val);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
guint g_atomic_int_or (volatile guint *atomic,
|
guint g_atomic_int_or (volatile guint *atomic,
|
||||||
guint val);
|
guint val);
|
||||||
guint g_atomic_int_xor (volatile guint *atomic,
|
guint g_atomic_int_xor (volatile guint *atomic,
|
||||||
@ -55,8 +57,10 @@ gboolean g_atomic_pointer_compare_and_exchange (volatile void *a
|
|||||||
gpointer newval);
|
gpointer newval);
|
||||||
gssize g_atomic_pointer_add (volatile void *atomic,
|
gssize g_atomic_pointer_add (volatile void *atomic,
|
||||||
gssize val);
|
gssize val);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gsize g_atomic_pointer_and (volatile void *atomic,
|
gsize g_atomic_pointer_and (volatile void *atomic,
|
||||||
gsize val);
|
gsize val);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gsize g_atomic_pointer_or (volatile void *atomic,
|
gsize g_atomic_pointer_or (volatile void *atomic,
|
||||||
gsize val);
|
gsize val);
|
||||||
gsize g_atomic_pointer_xor (volatile void *atomic,
|
gsize g_atomic_pointer_xor (volatile void *atomic,
|
||||||
|
@ -100,7 +100,9 @@ gchar *g_file_read_link (const gchar *filename,
|
|||||||
GError **error);
|
GError **error);
|
||||||
|
|
||||||
/* Wrapper / workalike for mkdtemp() */
|
/* Wrapper / workalike for mkdtemp() */
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gchar *g_mkdtemp (gchar *tmpl);
|
gchar *g_mkdtemp (gchar *tmpl);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gchar *g_mkdtemp_full (gchar *tmpl,
|
gchar *g_mkdtemp_full (gchar *tmpl,
|
||||||
gint mode);
|
gint mode);
|
||||||
|
|
||||||
@ -114,6 +116,7 @@ gint g_mkstemp_full (gchar *tmpl,
|
|||||||
gint g_file_open_tmp (const gchar *tmpl,
|
gint g_file_open_tmp (const gchar *tmpl,
|
||||||
gchar **name_used,
|
gchar **name_used,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gchar *g_dir_make_tmp (const gchar *tmpl,
|
gchar *g_dir_make_tmp (const gchar *tmpl,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
|
||||||
|
@ -107,6 +107,7 @@ gboolean g_hash_table_iter_next (GHashTableIter *iter,
|
|||||||
gpointer *value);
|
gpointer *value);
|
||||||
GHashTable* g_hash_table_iter_get_hash_table (GHashTableIter *iter);
|
GHashTable* g_hash_table_iter_get_hash_table (GHashTableIter *iter);
|
||||||
void g_hash_table_iter_remove (GHashTableIter *iter);
|
void g_hash_table_iter_remove (GHashTableIter *iter);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
void g_hash_table_iter_replace (GHashTableIter *iter,
|
void g_hash_table_iter_replace (GHashTableIter *iter,
|
||||||
gpointer value);
|
gpointer value);
|
||||||
void g_hash_table_iter_steal (GHashTableIter *iter);
|
void g_hash_table_iter_steal (GHashTableIter *iter);
|
||||||
|
@ -41,25 +41,34 @@ G_BEGIN_DECLS
|
|||||||
*/
|
*/
|
||||||
typedef struct _GHmac GHmac;
|
typedef struct _GHmac GHmac;
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GHmac * g_hmac_new (GChecksumType digest_type,
|
GHmac * g_hmac_new (GChecksumType digest_type,
|
||||||
const guchar *key,
|
const guchar *key,
|
||||||
gsize key_len);
|
gsize key_len);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GHmac * g_hmac_copy (const GHmac *hmac);
|
GHmac * g_hmac_copy (const GHmac *hmac);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GHmac * g_hmac_ref (GHmac *hmac);
|
GHmac * g_hmac_ref (GHmac *hmac);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
void g_hmac_unref (GHmac *hmac);
|
void g_hmac_unref (GHmac *hmac);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
void g_hmac_update (GHmac *hmac,
|
void g_hmac_update (GHmac *hmac,
|
||||||
const guchar *data,
|
const guchar *data,
|
||||||
gssize length);
|
gssize length);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
const gchar * g_hmac_get_string (GHmac *hmac);
|
const gchar * g_hmac_get_string (GHmac *hmac);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
void g_hmac_get_digest (GHmac *hmac,
|
void g_hmac_get_digest (GHmac *hmac,
|
||||||
guint8 *buffer,
|
guint8 *buffer,
|
||||||
gsize *digest_len);
|
gsize *digest_len);
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gchar *g_compute_hmac_for_data (GChecksumType digest_type,
|
gchar *g_compute_hmac_for_data (GChecksumType digest_type,
|
||||||
const guchar *key,
|
const guchar *key,
|
||||||
gsize key_len,
|
gsize key_len,
|
||||||
const guchar *data,
|
const guchar *data,
|
||||||
gsize length);
|
gsize length);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gchar *g_compute_hmac_for_string (GChecksumType digest_type,
|
gchar *g_compute_hmac_for_string (GChecksumType digest_type,
|
||||||
const guchar *key,
|
const guchar *key,
|
||||||
gsize key_len,
|
gsize key_len,
|
||||||
|
@ -57,24 +57,30 @@ G_BEGIN_DECLS
|
|||||||
*/
|
*/
|
||||||
#define G_UNIX_ERROR (g_unix_error_quark())
|
#define G_UNIX_ERROR (g_unix_error_quark())
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GQuark g_unix_error_quark (void);
|
GQuark g_unix_error_quark (void);
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gboolean g_unix_open_pipe (gint *fds,
|
gboolean g_unix_open_pipe (gint *fds,
|
||||||
gint flags,
|
gint flags,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gboolean g_unix_set_fd_nonblocking (gint fd,
|
gboolean g_unix_set_fd_nonblocking (gint fd,
|
||||||
gboolean nonblock,
|
gboolean nonblock,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GSource *g_unix_signal_source_new (gint signum);
|
GSource *g_unix_signal_source_new (gint signum);
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
guint g_unix_signal_add_full (gint priority,
|
guint g_unix_signal_add_full (gint priority,
|
||||||
gint signum,
|
gint signum,
|
||||||
GSourceFunc handler,
|
GSourceFunc handler,
|
||||||
gpointer user_data,
|
gpointer user_data,
|
||||||
GDestroyNotify notify);
|
GDestroyNotify notify);
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
guint g_unix_signal_add (gint signum,
|
guint g_unix_signal_add (gint signum,
|
||||||
GSourceFunc handler,
|
GSourceFunc handler,
|
||||||
gpointer user_data);
|
gpointer user_data);
|
||||||
|
@ -628,6 +628,7 @@ gchar* g_utf8_find_prev_char (const gchar *str,
|
|||||||
glong g_utf8_strlen (const gchar *p,
|
glong g_utf8_strlen (const gchar *p,
|
||||||
gssize max) G_GNUC_PURE;
|
gssize max) G_GNUC_PURE;
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gchar *g_utf8_substring (const gchar *str,
|
gchar *g_utf8_substring (const gchar *str,
|
||||||
glong start_pos,
|
glong start_pos,
|
||||||
glong end_pos) G_GNUC_MALLOC;
|
glong end_pos) G_GNUC_MALLOC;
|
||||||
|
@ -207,8 +207,10 @@ typedef enum
|
|||||||
G_FORMAT_SIZE_IEC_UNITS = 1 << 1
|
G_FORMAT_SIZE_IEC_UNITS = 1 << 1
|
||||||
} GFormatSizeFlags;
|
} GFormatSizeFlags;
|
||||||
|
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gchar *g_format_size_full (guint64 size,
|
gchar *g_format_size_full (guint64 size,
|
||||||
GFormatSizeFlags flags);
|
GFormatSizeFlags flags);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
gchar *g_format_size (guint64 size);
|
gchar *g_format_size (guint64 size);
|
||||||
|
|
||||||
GLIB_DEPRECATED_FOR(g_format_size)
|
GLIB_DEPRECATED_FOR(g_format_size)
|
||||||
|
@ -86,6 +86,7 @@ gboolean g_variant_is_signature (const g
|
|||||||
GVariant * g_variant_new_variant (GVariant *value);
|
GVariant * g_variant_new_variant (GVariant *value);
|
||||||
GVariant * g_variant_new_strv (const gchar * const *strv,
|
GVariant * g_variant_new_strv (const gchar * const *strv,
|
||||||
gssize length);
|
gssize length);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GVariant * g_variant_new_objv (const gchar * const *strv,
|
GVariant * g_variant_new_objv (const gchar * const *strv,
|
||||||
gssize length);
|
gssize length);
|
||||||
GVariant * g_variant_new_bytestring (const gchar *string);
|
GVariant * g_variant_new_bytestring (const gchar *string);
|
||||||
@ -114,6 +115,7 @@ const gchar ** g_variant_get_strv (GVarian
|
|||||||
gsize *length);
|
gsize *length);
|
||||||
gchar ** g_variant_dup_strv (GVariant *value,
|
gchar ** g_variant_dup_strv (GVariant *value,
|
||||||
gsize *length);
|
gsize *length);
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
const gchar ** g_variant_get_objv (GVariant *value,
|
const gchar ** g_variant_get_objv (GVariant *value,
|
||||||
gsize *length);
|
gsize *length);
|
||||||
gchar ** g_variant_dup_objv (GVariant *value,
|
gchar ** g_variant_dup_objv (GVariant *value,
|
||||||
|
@ -237,6 +237,7 @@ GType g_ptr_array_get_type (void) G_GNUC_CONST;
|
|||||||
GType g_bytes_get_type (void) G_GNUC_CONST;
|
GType g_bytes_get_type (void) G_GNUC_CONST;
|
||||||
GType g_variant_type_get_gtype (void) G_GNUC_CONST;
|
GType g_variant_type_get_gtype (void) G_GNUC_CONST;
|
||||||
GType g_regex_get_type (void) G_GNUC_CONST;
|
GType g_regex_get_type (void) G_GNUC_CONST;
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GType g_match_info_get_type (void) G_GNUC_CONST;
|
GType g_match_info_get_type (void) G_GNUC_CONST;
|
||||||
GType g_error_get_type (void) G_GNUC_CONST;
|
GType g_error_get_type (void) G_GNUC_CONST;
|
||||||
GType g_date_time_get_type (void) G_GNUC_CONST;
|
GType g_date_time_get_type (void) G_GNUC_CONST;
|
||||||
@ -244,8 +245,11 @@ GType g_io_channel_get_type (void) G_GNUC_CONST;
|
|||||||
GType g_io_condition_get_type (void) G_GNUC_CONST;
|
GType g_io_condition_get_type (void) G_GNUC_CONST;
|
||||||
GType g_variant_builder_get_type (void) G_GNUC_CONST;
|
GType g_variant_builder_get_type (void) G_GNUC_CONST;
|
||||||
GType g_key_file_get_type (void) G_GNUC_CONST;
|
GType g_key_file_get_type (void) G_GNUC_CONST;
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GType g_main_loop_get_type (void) G_GNUC_CONST;
|
GType g_main_loop_get_type (void) G_GNUC_CONST;
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GType g_main_context_get_type (void) G_GNUC_CONST;
|
GType g_main_context_get_type (void) G_GNUC_CONST;
|
||||||
|
GLIB_AVAILABLE_IN_2_30
|
||||||
GType g_source_get_type (void) G_GNUC_CONST;
|
GType g_source_get_type (void) G_GNUC_CONST;
|
||||||
|
|
||||||
GLIB_DEPRECATED_FOR('G_TYPE_VARIANT')
|
GLIB_DEPRECATED_FOR('G_TYPE_VARIANT')
|
||||||
|
Loading…
Reference in New Issue
Block a user