GLib.DuplicateFunc
Description: Reference for GLib.DuplicateFunc

### Function

# GLibDuplicateFunc

#### Declaration

    gpointer
    (* GDuplicateFunc) (
      gpointer data,
      gpointer user_data
    )

#### Description [src]

The type of functions that are used to ‘duplicate’ an object. What this means depends on the context, it could just be incrementing the reference count, if `data` is a ref-counted object.

#### Parameters

`data`

  Type: `gpointer`

  The data to duplicate.

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

`user_data`

  Type: `gpointer`

  User data that was specified in g_datalist_id_dup_data().

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

#### Return value

Type: `gpointer`

A duplicate of data.

The data is owned by the called function.
The return value can be `NULL`.