Method

GLibVariantBuilderadd_value

Declaration

void
g_variant_builder_add_value (
  GVariantBuilder* builder,
  GVariant* value
)

Description

Adds value to builder.

It is an error to call this function in any way that would create an inconsistent value to be constructed. Some examples of this are putting different types of items into an array, putting the wrong types or number of items in a tuple, putting more than one value into a variant, etc.

If value is a floating reference (see g_variant_ref_sink()), the builder instance takes ownership of value.

Available since:2.24

Parameters

value

Type: GVariant

A GVariant.

The data is owned by the caller of the function.