18#ifndef QGSPROCESSINGWIDGETCONTEXT_H
19#define QGSPROCESSINGWIDGETCONTEXT_H
32class QgsProcessingModelAlgorithm;
35class QgsModelDesignerDialog;
117 QgsProcessingModelAlgorithm *
model()
const;
201 QgsProcessingModelAlgorithm *mModel =
nullptr;
203 QString mModelChildAlgorithmId;
205 QPointer< QgsMapCanvas > mMapCanvas;
207 QPointer< QgsMessageBar > mMessageBar;
209 QPointer< QgsProject > mProject;
211 QPointer< QgsBrowserGuiModel > mBrowserModel;
213 QPointer< QgsMapLayer > mActiveLayer;
217 QPointer< QgsModelDesignerDialog > mModelDialog;
A model for showing available data sources and other items in a structured tree.
Map canvas is a class for displaying all GIS data types on a canvas.
Base class for all map layer types.
A bar for displaying non-blocking messages to the user.
An interface for objects which can create Processing contexts.
Contains settings which reflect the context in which a Processing parameter widget is shown.
QgsMapCanvas * mapCanvas() const
Returns the map canvas associated with the widget.
QgsProject * project() const
Returns the project associated with the widget.
QgsBrowserGuiModel * browserModel() const
Returns the browser model associated with the widget.
QgsProcessingParameterWidgetContext()=default
void setActiveLayer(QgsMapLayer *layer)
Sets the current active layer.
QgsModelDesignerDialog * modelDesignerDialog() const
Returns the associated model designer dialog, if applicable.
void setModelChildAlgorithmId(const QString &id)
Sets the child algorithm id within the model which the parameter widget is associated with.
void setProject(QgsProject *project)
Sets the project associated with the widget.
QgsMessageBar * messageBar() const
Returns the message bar associated with the widget.
void setMapCanvas(QgsMapCanvas *canvas)
Sets the map canvas associated with the widget.
void setBrowserModel(QgsBrowserGuiModel *model)
Sets the browser model associated with the widget.
QgsProcessingModelAlgorithm * model() const
Returns the model which the parameter widget is associated with.
void setMessageBar(QgsMessageBar *bar)
Sets the message bar associated with the widget.
QgsMapLayer * activeLayer() const
Returns the current active layer.
void setModelDesignerDialog(QgsModelDesignerDialog *dialog)
Sets the associated model designer dialog, if applicable.
void setModel(QgsProcessingModelAlgorithm *model)
Sets the model which the parameter widget is associated with.
QgsProcessingContextGenerator * processingContextGenerator()
Returns the Processing context generator class that will be used to retrieve a Processing context for...
void registerProcessingContextGenerator(QgsProcessingContextGenerator *generator)
Registers a Processing context generator class that will be used to retrieve a Processing context for...
QString modelChildAlgorithmId() const
Returns the child algorithm ID within the model which the parameter widget is associated with.
An interface for objects which can create Processing widget contexts.
virtual QgsProcessingParameterWidgetContext createWidgetContext()=0
This method needs to be reimplemented in all classes which implement this interface and return a Proc...
virtual ~QgsProcessingWidgetContextGenerator()=default
Encapsulates a QGIS project, including sets of map layers and their styles, layouts,...