### Method

# EBackend SubprocessFactory ref_initable_backend

since: 3.16

#### Declaration [src]

    EBackend*
    e_subprocess_factory_ref_initable_backend (
      ESubprocessFactory* subprocess_factory,
      const gchar* uid,
      const gchar* backend_factory_type_name,
      const gchar* module_filename,
      GCancellable* cancellable,
      GError** error
    )

#### Description [src]

Returns either a newly-created or existing `EBackend` for `ESource`. The returned `EBackend` is referenced for thread-safety and must be unreferenced with `g_object_unref()` when finished with it.

If the newly-created backend implements the `GInitable` interface, then `g_initable_init()` is also called on it using `cancellable` and `error`.

The `subprocess_factory` retains a strong reference to `backend`.

If no suitable `EBackendFactory` exists, or if the `EBackend` fails to initialize, the function sets `error` and returns `NULL`.

Available since: 3.16

#### Parameters

`uid`

  Type: `const gchar*`

  UID of an `ESource` to open.

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

`backend_factory_type_name`

  Type: `const gchar*`

  The name of the backend factory type.

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

`module_filename`

  Type: `const gchar*`

  The name (full-path) of the backend module to be loaded.

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

`cancellable`

  Type: `GCancellable`

  Optional `GCancellable` object, or `NULL`.

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

`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 method 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: `EBackend`

An `EBackend` for `source`, or `NULL`.

The caller of the method takes ownership of the returned data, and is responsible for freeing it.
The return value can be `NULL`.