37 QgsDebugMsg( QStringLiteral(
"Unable to run Python command: runner not available!" ) );
50 QgsDebugMsg( QStringLiteral(
"Unable to run Python command: runner not available!" ) );
static QgsPythonRunner * sInstance
Utility class for running Python commands from various parts of QGIS.
virtual bool evalCommand(QString command, QString &result)=0
static bool eval(const QString &command, QString &result)
Eval a Python statement.
virtual bool runCommand(QString command, QString messageOnError=QString())=0
static bool run(const QString &command, const QString &messageOnError=QString())
Execute a Python statement.
static bool isValid()
Returns true if the runner has an instance (and thus is able to run commands)
static void setInstance(QgsPythonRunner *runner)
Assign an instance of Python runner so that run() can be used.