GLib.Variant.prototype.dup_string
function dup_string(): [return_value: String, length: Number(gsize)] { // Gjs wrapper for g_variant_dup_string() }
Similar to GLib.Variant.prototype.get_string except that instead of returning a constant string, the string is duplicated.
The string will always be utf8 encoded.
The return value must be freed using GLib.free.
Since 2.24
- return_value
a newly allocated string, utf8 encoded
- length
a pointer to a #gsize, to store the length