GLib.VariantType.new

function new(type_string: String): GLib.VariantType {
    // Gjs wrapper for g_variant_type_new()
}
  

Creates a new GLib.VariantType corresponding to the type string given by type_string. It is appropriate to call GLib.VariantType.prototype.free on the return value.

It is a programmer error to call this function with an invalid type string. Use GLib.variant_type_string_is_valid if you are unsure.

Since 2.24

type_string

a valid GVariant type string

Returns

a new GLib.VariantType