GVariant docs fixes

This commit is contained in:
Ryan Lortie 2010-03-21 13:46:09 -05:00
parent 5c419c300b
commit c5a1c95b1f
2 changed files with 18 additions and 4 deletions

View File

@ -2097,12 +2097,25 @@ g_variant_parse (const GVariantType *type,
* g_variant_new_parsed_va: * g_variant_new_parsed_va:
* @format: a text format #GVariant * @format: a text format #GVariant
* @app: a pointer to a #va_list * @app: a pointer to a #va_list
* @returns: a new floating #GVariant instance * @returns: a new, usually floating, #GVariant
* *
* Parses @format and returns the result. * Parses @format and returns the result.
* *
* This is the version of g_variant_new_parsed() intended to be used * This is the version of g_variant_new_parsed() intended to be used
* from libraries. * from libraries.
*
* The return value will be floating if it was a newly created GVariant
* instance. In the case that @format simply specified the collection
* of a #GVariant pointer (eg: @format was "%*") then the collected
* #GVariant pointer will be returned unmodified, without adding any
* additional references.
*
* In order to behave correctly in all cases it is necessary for the
* calling function to g_variant_ref_sink() the return result before
* returning control to the user that originally provided the pointer.
* At this point, the caller will have their own full reference to the
* result. This can also be done by adding the result to a container,
* or by passing it to another g_variant_new() call.
**/ **/
GVariant * GVariant *
g_variant_new_parsed_va (const gchar *format, g_variant_new_parsed_va (const gchar *format,
@ -2139,6 +2152,7 @@ g_variant_new_parsed_va (const gchar *format,
* g_variant_new_parsed: * g_variant_new_parsed:
* @format: a text format #GVariant * @format: a text format #GVariant
* @...: arguments as per @format * @...: arguments as per @format
* @returns: a new floating #GVariant instance
* *
* Parses @format and returns the result. * Parses @format and returns the result.
* *

View File

@ -139,9 +139,9 @@ guint g_variant_hash (gconstp
gboolean g_variant_equal (gconstpointer one, gboolean g_variant_equal (gconstpointer one,
gconstpointer two); gconstpointer two);
GVariant * g_variant_get_normal_form (GVariant *variant); GVariant * g_variant_get_normal_form (GVariant *value);
gboolean g_variant_is_normal_form (GVariant *variant); gboolean g_variant_is_normal_form (GVariant *value);
GVariant * g_variant_byteswap (GVariant *variant); GVariant * g_variant_byteswap (GVariant *value);
GVariant * g_variant_new_from_data (const GVariantType *type, GVariant * g_variant_new_from_data (const GVariantType *type,
gconstpointer data, gconstpointer data,
gsize size, gsize size,