diff options
author | Rico Tzschichholz <ricotz@t-online.de> | 2012-06-23 20:59:19 +0200 |
---|---|---|
committer | Rico Tzschichholz <ricotz@t-online.de> | 2012-06-23 20:59:19 +0200 |
commit | 5819c75b8c2d4b8c72d3d6fa5e779556f1114f84 (patch) | |
tree | 8839b6cae0b4b2ff40d4f6de7b8f43de8acce3ae /gir/glib-2.0.c | |
parent | 64f3832893080f8faf476fdf730c51a52beb5dfa (diff) | |
download | gobject-introspection-5819c75b8c2d4b8c72d3d6fa5e779556f1114f84.tar.gz |
Update glib annotations from git
Diffstat (limited to 'gir/glib-2.0.c')
-rw-r--r-- | gir/glib-2.0.c | 72 |
1 files changed, 67 insertions, 5 deletions
diff --git a/gir/glib-2.0.c b/gir/glib-2.0.c index 7fa148c5..98dc7c70 100644 --- a/gir/glib-2.0.c +++ b/gir/glib-2.0.c @@ -14109,7 +14109,7 @@ * variable. If the program is found, the return value contains the * full name including the type suffix. * - * Returns: absolute path, or %NULL + * Returns: a newly-allocated string with the absolute path, or %NULL */ @@ -17334,7 +17334,8 @@ * <note><para> * Note that this is a "shallow" copy. If the list elements * consist of pointers to data, the pointers are copied but - * the actual data is not. + * the actual data is not. See g_list_copy_deep() if you need + * to copy the data as well. * </para></note> * * Returns: a copy of @list @@ -17342,6 +17343,36 @@ /** + * g_list_copy_deep: + * @list: a #GList + * @func: a copy function used to copy every element in the list + * @user_data: user data passed to the copy function @func, or #NULL + * + * Makes a full (deep) copy of a #GList. + * + * In contrast with g_list_copy(), this function uses @func to make a copy of + * each list element, in addition to copying the list container itself. + * + * @func, as a #GCopyFunc, takes two arguments, the data to be copied and a user + * pointer. It's safe to pass #NULL as user_data, if the copy function takes only + * one argument. + * + * For instance, if @list holds a list of GObjects, you can do: + * |[ + * another_list = g_list_copy_deep (list, (GCopyFunc) g_object_ref, NULL); + * ]| + * + * And, to entirely free the new list, you could do: + * |[ + * g_list_free_full (another_list, g_object_unref); + * ]| + * + * Returns: a full copy of @list, use #g_list_free_full to free it + * Since: 2.34 + */ + + +/** * g_list_delete_link: * @list: a #GList * @link_: node to delete from @list @@ -24303,7 +24334,8 @@ * <note><para> * Note that this is a "shallow" copy. If the list elements * consist of pointers to data, the pointers are copied but - * the actual data isn't. + * the actual data isn't. See g_slist_copy_deep() if you need + * to copy the data as well. * </para></note> * * Returns: a copy of @list @@ -24311,6 +24343,36 @@ /** + * g_slist_copy_deep: + * @list: a #GSList + * @func: a copy function used to copy every element in the list + * @user_data: user data passed to the copy function @func, or #NULL + * + * Makes a full (deep) copy of a #GSList. + * + * In contrast with g_slist_copy(), this function uses @func to make a copy of + * each list element, in addition to copying the list container itself. + * + * @func, as a #GCopyFunc, takes two arguments, the data to be copied and a user + * pointer. It's safe to pass #NULL as user_data, if the copy function takes only + * one argument. + * + * For instance, if @list holds a list of GObjects, you can do: + * |[ + * another_list = g_slist_copy_deep (list, (GCopyFunc) g_object_ref, NULL); + * ]| + * + * And, to entirely free the new list, you could do: + * |[ + * g_slist_free_full (another_list, g_object_unref); + * ]| + * + * Returns: a full copy of @list, use #g_slist_free_full to free it + * Since: 2.34 + */ + + +/** * g_slist_delete_link: * @list: a #GSList * @link_: node to delete @@ -27882,7 +27944,7 @@ * * This function may, however, modify @time_ in order to deal with * non-existent times. If the non-existent local @time_ of 02:30 were - * requested on March 13th 2010 in Toronto then this function would + * requested on March 14th 2010 in Toronto then this function would * adjust @time_ to be 03:00 and return the interval containing the * adjusted time. * @@ -29940,7 +30002,7 @@ * g_utf8_validate: * @str: (array length=max_len) (element-type guint8): a pointer to character data * @max_len: max bytes to validate, or -1 to go until NUL - * @end: (allow-none) (out): return location for end of valid data + * @end: (allow-none) (out) (transfer none): return location for end of valid data * * Validates UTF-8 encoded text. @str is the text to validate; * if @str is nul-terminated, then @max_len can be -1, otherwise |