Class: QgsProcessingParameterMultipleLayers¶
A parameter for processing algorithms which accepts multiple map layers.
Class Hierarchy¶
Base classes¶
Base class for the definition of processing parameters. |
|
Abstract interface for classes which generate a file filter string. |
Methods
Returns the layer type for layers acceptable by the parameter. |
|
Returns the minimum number of layers required for the parameter. |
|
Sets the layer type for layers acceptable by the parameter. |
|
Sets the minimum number of layers required for the parameter. |
Static Methods
Creates a new parameter using the definition from a script code. |
|
Returns the type name for the parameter class. |
- class qgis.core.QgsProcessingParameterMultipleLayers[source]¶
Bases:
QgsProcessingParameterDefinition
,QgsFileFilterGenerator
- __init__(name: str | None, description: str | None = '', layerType: Qgis.ProcessingSourceType = Qgis.ProcessingSourceType.VectorAnyGeometry, defaultValue: Any = None, optional: bool = False)
Constructor for QgsProcessingParameterMultipleLayers.
- Parameters:
name (Optional[str])
description (Optional[str] = '')
layerType (Qgis.ProcessingSourceType = Qgis.ProcessingSourceType.VectorAnyGeometry)
defaultValue (Any = None)
optional (bool = False)
- __init__(a0: QgsProcessingParameterMultipleLayers)
- Parameters:
- static fromScriptCode(name: str | None, description: str | None, isOptional: bool, definition: str | None) QgsProcessingParameterMultipleLayers | None [source]¶
Creates a new parameter using the definition from a script code.
- Parameters:
name (Optional[str])
description (Optional[str])
isOptional (bool)
definition (Optional[str])
- Return type:
Optional[QgsProcessingParameterMultipleLayers]
- layerType(self) Qgis.ProcessingSourceType [source]¶
Returns the layer type for layers acceptable by the parameter.
See also
- Return type:
- minimumNumberInputs(self) int [source]¶
Returns the minimum number of layers required for the parameter. If the return value is < 1 then the parameter accepts any number of layers.
See also
- Return type:
int
- setLayerType(self, type: Qgis.ProcessingSourceType)[source]¶
Sets the layer
type
for layers acceptable by the parameter.See also
- Parameters:
type (Qgis.ProcessingSourceType)