PythonQt
Public Member Functions | Static Public Member Functions | List of all members
PythonQtGILScope Class Reference

#include <PythonQtThreadSupport.h>

Public Member Functions

 PythonQtGILScope ()
 
 ~PythonQtGILScope ()
 
void release ()
 

Static Public Member Functions

static void setGILScopeEnabled (bool flag)
 
static bool isGILScopeEnabled ()
 Check if GIL scopes are enabled. More...
 

Detailed Description

Ensures/releases the Python GIL An instance of this class can be used to allow access to the Python API from C++ code.

Definition at line 60 of file PythonQtThreadSupport.h.

Constructor & Destructor Documentation

◆ PythonQtGILScope()

PythonQtGILScope::PythonQtGILScope ( )

◆ ~PythonQtGILScope()

PythonQtGILScope::~PythonQtGILScope ( )

Member Function Documentation

◆ isGILScopeEnabled()

static bool PythonQtGILScope::isGILScopeEnabled ( )
static

Check if GIL scopes are enabled.

◆ release()

void PythonQtGILScope::release ( )

◆ setGILScopeEnabled()

static void PythonQtGILScope::setGILScopeEnabled ( bool  flag)
static

This allows to globally enable/disable the GIL scopes. Make sure to only call this early in the PythonQt setup, or when you are holding the GIL.


The documentation for this class was generated from the following file: