Function

GLibVariantnew_dict_entry

since: 2.24

Declaration [src]

GVariant*
g_variant_new_dict_entry (
  GVariant* key,
  GVariant* value
)

Description [src]

Creates a new dictionary entry GVariant. key and value must be non-NULL. key must be a value of a basic type (ie: not a container).

If the key or value are floating references (see g_variant_ref_sink()), the new instance takes ownership of them as if via g_variant_ref_sink().

Available since: 2.24

Parameters

key

Type: GVariant

A basic GVariant, the key.

The data is owned by the caller of the function.
value

Type: GVariant

A GVariant, the value.

The data is owned by the caller of the function.

Return value

Type: GVariant

A floating reference to a new dictionary entry GVariant.

The data is owned by the called function.