QGIS API Documentation 3.41.0-Master (fda2aa46e9a)
Loading...
Searching...
No Matches
Public Member Functions | List of all members
QgsProcessingAlgorithmConfigurationWidget Class Referenceabstract

A configuration widget for processing algorithms allows providing additional configuration options directly on algorithm level, in addition to parameters. More...

#include <qgsprocessingalgorithmconfigurationwidget.h>

Inheritance diagram for QgsProcessingAlgorithmConfigurationWidget:
Inheritance graph
[legend]

Public Member Functions

 QgsProcessingAlgorithmConfigurationWidget (QWidget *parent=nullptr)
 Creates a new QgsProcessingAlgorithmConfigurationWidget.
 
 ~QgsProcessingAlgorithmConfigurationWidget () override=default
 
const QgsProcessingAlgorithmalgorithm () const
 Returns the algorithm instance associated with this widget.
 
virtual QVariantMap configuration () const =0
 Read the current configuration from this widget.
 
QgsExpressionContext createExpressionContext () const override
 This method needs to be reimplemented in all classes which implement this interface and return an expression context.
 
void registerProcessingContextGenerator (QgsProcessingContextGenerator *generator)
 Registers a Processing context generator class that will be used to retrieve a Processing context for the widget when required.
 
void setAlgorithm (const QgsProcessingAlgorithm *algorithm)
 Sets the algorithm instance associated with the widget.
 
virtual void setConfiguration (const QVariantMap &configuration)=0
 Set the configuration which this widget should represent.
 
virtual void setWidgetContext (const QgsProcessingParameterWidgetContext &context)
 Sets the context in which the Processing algorithm widget is shown, e.g., the parent model algorithm, a linked map canvas, and other relevant information which allows the widget to fine-tune its behavior.
 
const QgsProcessingParameterWidgetContextwidgetContext () const
 Returns the context in which the Processing algorithm widget is shown, e.g., the parent model algorithm, a linked map canvas, and other relevant information which allows the widget to fine-tune its behavior.
 
- Public Member Functions inherited from QgsExpressionContextGenerator
virtual ~QgsExpressionContextGenerator ()=default
 

Detailed Description

A configuration widget for processing algorithms allows providing additional configuration options directly on algorithm level, in addition to parameters.

Since
QGIS 3.2

Definition at line 40 of file qgsprocessingalgorithmconfigurationwidget.h.

Constructor & Destructor Documentation

◆ QgsProcessingAlgorithmConfigurationWidget()

QgsProcessingAlgorithmConfigurationWidget::QgsProcessingAlgorithmConfigurationWidget ( QWidget *  parent = nullptr)

◆ ~QgsProcessingAlgorithmConfigurationWidget()

QgsProcessingAlgorithmConfigurationWidget::~QgsProcessingAlgorithmConfigurationWidget ( )
overridedefault

Member Function Documentation

◆ algorithm()

const QgsProcessingAlgorithm * QgsProcessingAlgorithmConfigurationWidget::algorithm ( ) const
inline

Returns the algorithm instance associated with this widget.

See also
setAlgorithm()
Since
QGIS 3.6

Definition at line 98 of file qgsprocessingalgorithmconfigurationwidget.h.

◆ configuration()

virtual QVariantMap QgsProcessingAlgorithmConfigurationWidget::configuration ( ) const
pure virtual

Read the current configuration from this widget.

◆ createExpressionContext()

QgsExpressionContext QgsProcessingAlgorithmConfigurationWidget::createExpressionContext ( ) const
overridevirtual

This method needs to be reimplemented in all classes which implement this interface and return an expression context.

Implements QgsExpressionContextGenerator.

Definition at line 46 of file qgsprocessingalgorithmconfigurationwidget.cpp.

◆ registerProcessingContextGenerator()

void QgsProcessingAlgorithmConfigurationWidget::registerProcessingContextGenerator ( QgsProcessingContextGenerator generator)

Registers a Processing context generator class that will be used to retrieve a Processing context for the widget when required.

Since
QGIS 3.6

Definition at line 41 of file qgsprocessingalgorithmconfigurationwidget.cpp.

◆ setAlgorithm()

void QgsProcessingAlgorithmConfigurationWidget::setAlgorithm ( const QgsProcessingAlgorithm algorithm)

Sets the algorithm instance associated with the widget.

See also
algorithm()
Since
QGIS 3.6

Definition at line 36 of file qgsprocessingalgorithmconfigurationwidget.cpp.

◆ setConfiguration()

virtual void QgsProcessingAlgorithmConfigurationWidget::setConfiguration ( const QVariantMap &  configuration)
pure virtual

Set the configuration which this widget should represent.

◆ setWidgetContext()

void QgsProcessingAlgorithmConfigurationWidget::setWidgetContext ( const QgsProcessingParameterWidgetContext context)
virtual

Sets the context in which the Processing algorithm widget is shown, e.g., the parent model algorithm, a linked map canvas, and other relevant information which allows the widget to fine-tune its behavior.

Subclasses should take care to call the base class method when reimplementing this method.

See also
widgetContext()
Since
QGIS 3.6

Definition at line 26 of file qgsprocessingalgorithmconfigurationwidget.cpp.

◆ widgetContext()

const QgsProcessingParameterWidgetContext & QgsProcessingAlgorithmConfigurationWidget::widgetContext ( ) const

Returns the context in which the Processing algorithm widget is shown, e.g., the parent model algorithm, a linked map canvas, and other relevant information which allows the widget to fine-tune its behavior.

See also
setWidgetContext()
Since
QGIS 3.6

Definition at line 31 of file qgsprocessingalgorithmconfigurationwidget.cpp.


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