QGIS API Documentation 3.99.0-Master (8e76e220402)
Loading...
Searching...
No Matches
qgsprocessing.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsprocessing.h
3 ---------------
4 begin : July 2017
5 copyright : (C) 2017 by Nyall Dawson
6 email : nyall dot dawson at gmail dot com
7 ***************************************************************************/
8
9/***************************************************************************
10 * *
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
15 * *
16 ***************************************************************************/
17
18#ifndef QGSPROCESSING_H
19#define QGSPROCESSING_H
20
21#include "qgis.h"
22#include "qgis_core.h"
24#include "qgssettingstree.h"
25
26#include <QString>
27
28using namespace Qt::StringLiterals;
29
30//
31// Output definitions
32//
33
42
43class CORE_EXPORT QgsProcessing
44{
45 Q_GADGET
46
47 public:
48
51 {
52 PythonQgsProcessingAlgorithmSubclass,
53 };
54 Q_ENUM( PythonOutputType )
55
56
61 enum class LayerOptionsFlag : int SIP_ENUM_BASETYPE( IntFlag )
62 {
63 SkipIndexGeneration = 1 << 0,
64 };
65 Q_ENUM( LayerOptionsFlag )
67 Q_FLAG( LayerOptionsFlags )
68
74 static QString sourceTypeToString( Qgis::ProcessingSourceType type )
75 {
76 switch ( type )
77 {
79 return u"TypeMapLayer"_s;
81 return u"TypeVectorAnyGeometry"_s;
83 return u"TypeVectorPoint"_s;
85 return u"TypeVectorLine"_s;
87 return u"TypeVectorPolygon"_s;
89 return u"TypeRaster"_s;
91 return u"TypeFile"_s;
93 return u"TypeVector"_s;
95 return u"TypeMesh"_s;
97 return u"TypePlugin"_s;
99 return u"TypePointCloud"_s;
101 return u"TypeAnnotation"_s;
103 return u"TypeVectorTile"_s;
105 return u"TiledScene"_s;
106 }
107 return QString();
108 }
109
115 static QString documentationFlagToString( Qgis::ProcessingAlgorithmDocumentationFlag flag );
116
122 static const QString TEMPORARY_OUTPUT;
123
124#ifndef SIP_RUN
125 static inline QgsSettingsTreeNode *sTreeConfiguration = QgsSettingsTree::sTreeQgis->createChildNode( u"configuration"_s );
126
135#endif
136};
137
138#endif // QGSPROCESSING_H
Provides global constants and enumerations for use throughout the application.
Definition qgis.h:59
@ File
Files (i.e. non map layer sources, such as text files).
Definition qgis.h:3609
@ Plugin
Plugin layers.
Definition qgis.h:3612
@ TiledScene
Tiled scene layers.
Definition qgis.h:3616
@ Annotation
Annotation layers.
Definition qgis.h:3614
@ Vector
Tables (i.e. vector layers with or without geometry). When used for a sink this indicates the sink ha...
Definition qgis.h:3610
@ VectorTile
Vector tile layers.
Definition qgis.h:3615
@ MapLayer
Any map layer type (raster, vector, mesh, point cloud, annotation or plugin layer).
Definition qgis.h:3603
@ Mesh
Mesh layers.
Definition qgis.h:3611
@ Raster
Raster layers.
Definition qgis.h:3608
@ VectorAnyGeometry
Any vector layer with geometry.
Definition qgis.h:3604
@ VectorPoint
Vector point layers.
Definition qgis.h:3605
@ VectorPolygon
Vector polygon layers.
Definition qgis.h:3607
@ VectorLine
Vector line layers.
Definition qgis.h:3606
@ PointCloud
Point cloud layers.
Definition qgis.h:3613
ProcessingAlgorithmDocumentationFlag
Flags describing algorithm behavior for documentation purposes.
Definition qgis.h:3689
Contains enumerations and other constants for use in processing algorithms and parameters.
static const QgsSettingsEntryString * settingsDefaultOutputRasterLayerFormat
Settings entry default output raster layer format.
QFlags< LayerOptionsFlag > LayerOptionsFlags
static const QgsSettingsEntryString * settingsTempPath
Settings entry temp path.
static const QString TEMPORARY_OUTPUT
Constant used to indicate that a Processing algorithm output should be a temporary layer/file.
static const QgsSettingsEntryBool * settingsPreferFilenameAsLayerName
Settings entry prefer filename as layer name.
static QgsSettingsTreeNode * sTreeConfiguration
PythonOutputType
Available Python output types.
static const QgsSettingsEntryString * settingsDefaultOutputVectorLayerExt
Settings entry default output vector layer ext.
static QString sourceTypeToString(Qgis::ProcessingSourceType type)
Converts a source type to a string representation.
LayerOptionsFlag
Layer options flags.
A boolean settings entry.
A string settings entry.
A tree node for the settings tree to help organizing and introspecting the tree.
static QgsSettingsTreeNode * sTreeQgis
#define SIP_ENUM_BASETYPE(type)
Definition qgis_sip.h:275
#define SIP_MONKEYPATCH_SCOPEENUM
Definition qgis_sip.h:267