get_main_context


Description:

[ Version ( since = "6.0" ) ]
public unowned MainContext get_main_context (Thread? thread)

Get the MainContext used while a potentially blocking operation is performed using nc, see set_main_context.

If this is null, then the setting applies to all the connections for which no other similar setting has been set.

If no main context has been defined, then some function calls (for example connection opening) may block until the operation has finished.

Parameters:

this

a Connection, or null

thread

the Thread in which context will be used, or null (for the current thread)

Returns:

a MainContext, or null