2017-05-14 09:48:41 +02:00
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/core/qgsexpressioncontextgenerator.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
2016-08-10 19:44:30 +02:00
|
|
|
|
|
|
|
class QgsExpressionContextGenerator
|
|
|
|
{
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
|
|
|
Abstract interface for generating an expression context.
|
|
|
|
|
|
|
|
You need to implement this interface in a class and register this class with
|
|
|
|
QgsFieldExpressionWidget.registerExpressionGenerator().
|
|
|
|
|
|
|
|
This is used for example in QgsPropertyOverrideButton or QgsFieldExpressionWidget
|
|
|
|
classes which will ask for a new QgsExpressionContext every time the expression
|
|
|
|
editor is opened. This way they are able to provide an up-to-date expression
|
|
|
|
editor even when the environment changes.
|
|
|
|
|
|
|
|
.. versionadded:: 3.0
|
|
|
|
%End
|
|
|
|
|
2016-08-10 19:44:30 +02:00
|
|
|
%TypeHeaderCode
|
|
|
|
#include "qgsexpressioncontextgenerator.h"
|
|
|
|
%End
|
|
|
|
public:
|
2017-05-14 09:48:41 +02:00
|
|
|
|
2016-08-10 19:44:30 +02:00
|
|
|
virtual QgsExpressionContext createExpressionContext() const = 0;
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
|
|
|
This method needs to be reimplemented in all classes which implement this interface
|
|
|
|
and return an expression context.
|
|
|
|
|
|
|
|
.. versionadded:: 3.0
|
|
|
|
:rtype: QgsExpressionContext
|
|
|
|
%End
|
2016-08-15 09:02:30 +10:00
|
|
|
|
|
|
|
virtual ~QgsExpressionContextGenerator();
|
2016-08-10 19:44:30 +02:00
|
|
|
};
|
2017-05-14 09:48:41 +02:00
|
|
|
|
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/core/qgsexpressioncontextgenerator.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|