Gio.Initable.new_valist
Description: Reference for Gio.Initable.new_valist

### Function

# Gio Initablenew_valist

since: 2.22

#### Declaration [src]

    GObject*
    g_initable_new_valist (
      GType object_type,
      const gchar* first_property_name,
      va_list var_args,
      GCancellable* cancellable,
      GError** error
    )

#### Description [src]

Helper function for constructing `GInitable` object. This is similar to `g_object_new_valist()` but also initializes the object and returns `NULL`, setting an error on failure.

Available since: 2.22

This function is not directly available to language bindings.

#### Parameters

`object_type`

  Type: `GType`

  A `GType` supporting `GInitable`.

`first_property_name`

  Type: `const gchar*`

  The name of the first property, followed by the value, and other property value pairs, and ended by `NULL`.

  The data is owned by the caller of the function.
  The value is a NUL terminated UTF-8 string.

`var_args`

  Type: `va_list`

  The var args list generated from `first_property_name`.

`cancellable`

  Type: `GCancellable`

  Optional `GCancellable` object, `NULL` to ignore.

  The argument can be `NULL`.
  The data is owned by the caller of the function.

`error`

  Type: `GError **`

  The return location for a recoverable error.

  The argument can be `NULL`.
  If the return location is not `NULL`, then you must initialize it to a `NULL` `GError*`.
  The argument will be left initialized to `NULL` by the function if there are no errors.
  In case of error, the argument will be set to a newly allocated `GError`; the caller will take ownership of the data, and be responsible for freeing it.

#### Return value

Type: `GObject`

A newly allocated `GObject`, or `NULL` on error.

The caller of the function takes ownership of the data, and is responsible for freeing it.