append_printf


Description:

[ PrintfFormat ]
public void append_printf (string format, ...)

Appends a formatted string onto the end of a StringBuilder.

This function is similar to printf except that the text is appended to the StringBuilder.

Example: Append a formatted string:

public static int main (string[] args) {
// Output: ``hello, world!``
StringBuilder builder = new StringBuilder ();
builder.append_printf ("%s, %s!\n", "hello", "world");
print (builder.str);
return 0;
}

valac --pkg glib-2.0 GLib.StringBuilder.append_printf.vala

Parameters:

this

a StringBuilder

format

the string format. See the printf documentation

...

the parameters to insert into the format string