Method
GLibStringprepend_len
Declaration [src]
GString*
g_string_prepend_len (
GString* string,
const gchar* val,
gssize len
)
Description [src]
Prepends len
bytes of val
to string
.
If len
is positive, val
may contain embedded nuls and need
not be nul-terminated. It is the caller’s responsibility to
ensure that val
has at least len
addressable bytes.
If len
is negative, val
must be nul-terminated and len
is considered to request the entire string length. This
makes g_string_prepend_len()
equivalent to g_string_prepend().
Parameters
val
-
Type:
const gchar*
Bytes to prepend.
The data is owned by the caller of the method. The value is a NUL terminated UTF-8 string. len
-
Type:
gssize
Number of bytes in
val
to prepend, or -1 for all ofval
.
Return value
Type: GString
string
.
The returned data is owned by the instance. |