37 QgsDebugMsg(
"Unable to run Python command: runner not available!" );
50 QgsDebugMsg(
"Unable to run Python command: runner not available!" );
QgsPythonRunner()
protected constructor: can be instantiated only from children
static bool eval(QString command, QString &result)
Eval a python statement.
Utility class for running python commands from various parts of QGIS.
virtual ~QgsPythonRunner()
virtual bool evalCommand(QString command, QString &result)=0
static bool run(QString command, QString messageOnError=QString())
execute a python statement
static QgsPythonRunner * mInstance
virtual bool runCommand(QString command, QString messageOnError=QString())=0
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.