EDataServer.Source.ref_main_context

### Method

# EDataServer Sourceref_main_context

since: 3.6

#### Declaration [src]

    GMainContext*
    e_source_ref_main_context (
      ESource* source
    )

#### Description [src]

Returns the `GMainContext` on which event sources for `source` are to be attached.

The returned `GMainContext` is referenced for thread-safety and must be unreferenced with `g_main_context_unref()` when finished with it.

Available since: 3.6

#### Return value

Type: `GMainContext`

A `GMainContext`.

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