GLib.dataset_foreach
Description: Reference for GLib.dataset_foreach

### Function

# GLibdataset_foreach

#### Declaration [src]

    void
    g_dataset_foreach (
      gconstpointer dataset_location,
      GDataForeachFunc func,
      gpointer user_data
    )

#### Description [src]

Calls the given function for each data element which is associated with the given location. Note that this function is NOT thread-safe. So unless `dataset_location` can be protected from any modifications during invocation of this function, it should not be called.

`func` can make changes to the dataset, but the iteration will not reflect changes made during the `g_dataset_foreach()` call, other than skipping over elements that are removed.

#### Parameters

`dataset_location`

  Type: `gconstpointer`

  The location identifying the dataset.

  The data is owned by the caller of the function.

`func`

  Type: `GDataForeachFunc`

  The function to call for each data element.

`user_data`

  Type: `gpointer`

  User data to pass to the function.

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