QGIS API Documentation 3.41.0-Master (45a0abf3bec)
Loading...
Searching...
No Matches
qgsprocessingparametertypeimpl.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsprocessingparametertypeimpl.h
3 ------------------------
4 begin : March 2018
5 copyright : (C) 2018 by Matthias Kuhn
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 QGSPROCESSINGPARAMETERTYPEIMPL_H
19#define QGSPROCESSINGPARAMETERTYPEIMPL_H
20
21#include "qgis.h"
22#include "qgis_sip.h"
24#include <QCoreApplication>
25
26#define SIP_NO_FILE
27
36{
37 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
38 {
39 return new QgsProcessingParameterRasterLayer( name );
40 }
41
42 QString description() const override
43 {
44 return QCoreApplication::translate( "Processing", "A raster layer parameter." );
45 }
46
47 QString name() const override
48 {
49 return QCoreApplication::translate( "Processing", "Raster Layer" );
50 }
51
52 QString pythonImportString() const override
53 {
54 return QStringLiteral( "from qgis.core import QgsProcessingParameterRasterLayer" );
55 }
56
57 QString className() const override
58 {
59 return QStringLiteral( "QgsProcessingParameterRasterLayer" );
60 }
61
62 QString id() const override
63 {
64 return QStringLiteral( "raster" );
65 }
66
67 QStringList acceptedPythonTypes() const override
68 {
69 return QStringList() << QObject::tr( "str: layer ID" )
70 << QObject::tr( "str: layer name" )
71 << QObject::tr( "str: layer source" )
72 << QStringLiteral( "QgsProperty" )
73 << QStringLiteral( "QgsRasterLayer" );
74 }
75
76 QStringList acceptedStringValues() const override
77 {
78 return QStringList() << QObject::tr( "Path to a raster layer" );
79 }
80};
81
90{
91 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
92 {
93 return new QgsProcessingParameterMeshLayer( name );
94 }
95
96 QString description() const override
97 {
98 return QCoreApplication::translate( "Processing", "A mesh layer parameter." );
99 }
100
101 QString name() const override
102 {
103 return QCoreApplication::translate( "Processing", "Mesh Layer" );
104 }
105
106 QString pythonImportString() const override
107 {
108 return QStringLiteral( "from qgis.core import QgsProcessingParameterMeshLayer" );
109 }
110
111 QString className() const override
112 {
113 return QStringLiteral( "QgsProcessingParameterMeshLayer" );
114 }
115
116 QString id() const override
117 {
118 return QStringLiteral( "mesh" );
119 }
120
121 QStringList acceptedPythonTypes() const override
122 {
123 return QStringList() << QObject::tr( "str: layer ID" )
124 << QObject::tr( "str: layer name" )
125 << QObject::tr( "str: layer source" )
126 << QStringLiteral( "QgsMeshLayer" );
127 }
128
129 QStringList acceptedStringValues() const override
130 {
131 return QStringList() << QObject::tr( "Path to a mesh layer" );
132 }
133};
134
143{
144 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
145 {
146 return new QgsProcessingParameterVectorLayer( name );
147 }
148
149 QString description() const override
150 {
151 return QCoreApplication::translate( "Processing", "A vector layer parameter, e.g. for algorithms which change layer styles, edit layers in place, or other operations which affect an entire layer." );
152 }
153
154 QString name() const override
155 {
156 return QCoreApplication::translate( "Processing", "Vector Layer" );
157 }
158
159 QString pythonImportString() const override
160 {
161 return QStringLiteral( "from qgis.core import QgsProcessingParameterVectorLayer" );
162 }
163
164 QString className() const override
165 {
166 return QStringLiteral( "QgsProcessingParameterVectorLayer" );
167 }
168
169 QString id() const override
170 {
171 return QStringLiteral( "vector" );
172 }
173
174 QStringList acceptedPythonTypes() const override
175 {
176 return QStringList() << QObject::tr( "str: layer ID" )
177 << QObject::tr( "str: layer name" )
178 << QObject::tr( "str: layer source" )
179 << QStringLiteral( "QgsProperty" )
180 << QStringLiteral( "QgsVectorLayer" );
181 }
182
183 QStringList acceptedStringValues() const override
184 {
185 return QStringList() << QObject::tr( "Path to a vector layer" );
186 }
187};
188
197{
198 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
199 {
200 return new QgsProcessingParameterMapLayer( name );
201 }
202
203 QString description() const override
204 {
205 return QCoreApplication::translate( "Processing", "A generic map layer parameter, which accepts either vector or raster layers." );
206 }
207
208 QString name() const override
209 {
210 return QCoreApplication::translate( "Processing", "Map Layer" );
211 }
212
213 QString id() const override
214 {
215 return QStringLiteral( "layer" );
216 }
217
218 QString pythonImportString() const override
219 {
220 return QStringLiteral( "from qgis.core import QgsProcessingParameterMapLayer" );
221 }
222
223 QString className() const override
224 {
225 return QStringLiteral( "QgsProcessingParameterMapLayer" );
226 }
227
228 QStringList acceptedPythonTypes() const override
229 {
230 return QStringList() << QObject::tr( "str: layer ID" )
231 << QObject::tr( "str: layer name" )
232 << QObject::tr( "str: layer source" )
233 << QStringLiteral( "QgsMapLayer" )
234 << QStringLiteral( "QgsProperty" )
235 << QStringLiteral( "QgsRasterLayer" )
236 << QStringLiteral( "QgsVectorLayer" );
237 }
238
239 QStringList acceptedStringValues() const override
240 {
241 return QStringList() << QObject::tr( "Path to a vector, raster or mesh layer" );
242 }
243};
244
253{
254 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
255 {
256 return new QgsProcessingParameterBoolean( name );
257 }
258
259 QString description() const override
260 {
261 return QCoreApplication::translate( "Processing", "A boolean parameter, for true/false values." );
262 }
263
264 QString name() const override
265 {
266 return QCoreApplication::translate( "Processing", "Boolean" );
267 }
268
269 QString id() const override
270 {
271 return QStringLiteral( "boolean" );
272 }
273
274 QString pythonImportString() const override
275 {
276 return QStringLiteral( "from qgis.core import QgsProcessingParameterBoolean" );
277 }
278
279 QString className() const override
280 {
281 return QStringLiteral( "QgsProcessingParameterBoolean" );
282 }
283
284 QStringList acceptedPythonTypes() const override
285 {
286 return QStringList() << QStringLiteral( "bool" )
287 << QStringLiteral( "int" )
288 << QStringLiteral( "str" )
289 << QStringLiteral( "QgsProperty" );
290 }
291
292 QStringList acceptedStringValues() const override
293 {
294 return QStringList() << QObject::tr( "1 for true/yes" )
295 << QObject::tr( "0 for false/no" )
296 << QObject::tr( "field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field" )
297 << QObject::tr( "expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression" );
298 }
299};
300
309{
310 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
311 {
312 return new QgsProcessingParameterExpression( name );
313 }
314
315 QString description() const override
316 {
317 return QCoreApplication::translate( "Processing", "An expression parameter, to add custom expressions based on layer fields." );
318 }
319
320 QString name() const override
321 {
322 return QCoreApplication::translate( "Processing", "Expression" );
323 }
324
325 QString id() const override
326 {
327 return QStringLiteral( "expression" );
328 }
329
330 QString pythonImportString() const override
331 {
332 return QStringLiteral( "from qgis.core import QgsProcessingParameterExpression" );
333 }
334
335 QString className() const override
336 {
337 return QStringLiteral( "QgsProcessingParameterExpression" );
338 }
339
340 QStringList acceptedPythonTypes() const override
341 {
342 return QStringList() << QStringLiteral( "str" )
343 << QStringLiteral( "QgsProperty" );
344 }
345
346 QStringList acceptedStringValues() const override
347 {
348 return QStringList() << QObject::tr( "A valid QGIS expression string, e.g \"road_name\" = 'MAIN RD'" );
349 }
350};
351
360{
361 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
362 {
363 return new QgsProcessingParameterCrs( name );
364 }
365
366 QString description() const override
367 {
368 return QCoreApplication::translate( "Processing", "A coordinate reference system (CRS) input parameter." );
369 }
370
371 QString name() const override
372 {
373 return QCoreApplication::translate( "Processing", "CRS" );
374 }
375
376 QString id() const override
377 {
378 return QStringLiteral( "crs" );
379 }
380
381 QString pythonImportString() const override
382 {
383 return QStringLiteral( "from qgis.core import QgsProcessingParameterCrs" );
384 }
385
386 QString className() const override
387 {
388 return QStringLiteral( "QgsProcessingParameterCrs" );
389 }
390
391 QStringList acceptedPythonTypes() const override
392 {
393 return QStringList()
394 << QStringLiteral( "str: 'ProjectCrs'" )
395 << QObject::tr( "str: CRS auth ID (e.g. 'EPSG:3111')" )
396 << QObject::tr( "str: CRS PROJ4 (e.g. 'PROJ4:…')" )
397 << QObject::tr( "str: CRS WKT (e.g. 'WKT:…')" )
398 << QObject::tr( "str: layer ID. CRS of layer is used." )
399 << QObject::tr( "str: layer name. CRS of layer is used." )
400 << QObject::tr( "str: layer source. CRS of layer is used." )
401 << QObject::tr( "QgsCoordinateReferenceSystem" )
402 << QObject::tr( "QgsMapLayer: CRS of layer is used" )
403 << QObject::tr( "QgsProcessingFeatureSourceDefinition: CRS of source is used" )
404 << QStringLiteral( "QgsProperty" );
405 }
406
407 QStringList acceptedStringValues() const override
408 {
409 return QStringList() << QObject::tr( "CRS as an auth ID (e.g. 'EPSG:3111')" )
410 << QObject::tr( "CRS as a PROJ4 string (e.g. 'PROJ4:…')" )
411 << QObject::tr( "CRS as a WKT string (e.g. 'WKT:…')" )
412 << QObject::tr( "Path to a layer. The CRS of the layer is used." ) ;
413 }
414};
415
424{
425 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
426 {
427 return new QgsProcessingParameterRange( name );
428 }
429
430 QString description() const override
431 {
432 return QCoreApplication::translate( "Processing", "A numeric range parameter for processing algorithms." );
433 }
434
435 QString name() const override
436 {
437 return QCoreApplication::translate( "Processing", "Range" );
438 }
439
440 QString id() const override
441 {
442 return QStringLiteral( "range" );
443 }
444
445 QString pythonImportString() const override
446 {
447 return QStringLiteral( "from qgis.core import QgsProcessingParameterRange" );
448 }
449
450 QString className() const override
451 {
452 return QStringLiteral( "QgsProcessingParameterRange" );
453 }
454
455 QStringList acceptedPythonTypes() const override
456 {
457 return QStringList() << QObject::tr( "list[float]: list of 2 float values" )
458 << QObject::tr( "list[str]: list of strings representing floats" )
459 << QObject::tr( "str: as two comma delimited floats, e.g. '1,10'" )
460 << QStringLiteral( "QgsProperty" );
461 }
462
463 QStringList acceptedStringValues() const override
464 {
465 return QStringList() << QObject::tr( "Two comma separated numeric values, e.g. '1,10'" );
466 }
467};
468
477{
478 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
479 {
480 return new QgsProcessingParameterPoint( name );
481 }
482
483 QString description() const override
484 {
485 return QCoreApplication::translate( "Processing", "A point geometry parameter." );
486 }
487
488 QString name() const override
489 {
490 return QCoreApplication::translate( "Processing", "Point" );
491 }
492
493 QString id() const override
494 {
495 return QStringLiteral( "point" );
496 }
497
498 QString pythonImportString() const override
499 {
500 return QStringLiteral( "from qgis.core import QgsProcessingParameterPoint" );
501 }
502
503 QString className() const override
504 {
505 return QStringLiteral( "QgsProcessingParameterPoint" );
506 }
507
508 QStringList acceptedPythonTypes() const override
509 {
510 return QStringList() << QObject::tr( "str: as an 'x,y' string, e.g. '1.5,10.1'" )
511 << QStringLiteral( "QgsPointXY" )
512 << QStringLiteral( "QgsProperty" )
513 << QStringLiteral( "QgsReferencedPointXY" )
514 << QStringLiteral( "QgsGeometry: centroid of geometry is used" );
515 }
516
517 QStringList acceptedStringValues() const override
518 {
519 return QStringList() << QObject::tr( "Point coordinate as an 'x,y' string, e.g. '1.5,10.1'" );
520 }
521};
522
531{
532 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
533 {
534 return new QgsProcessingParameterGeometry( name );
535 }
536
537 QString description() const override
538 {
539 return QCoreApplication::translate( "Processing", "A geometry parameter." );
540 }
541
542 QString name() const override
543 {
544 return QCoreApplication::translate( "Processing", "Geometry" );
545 }
546
547 QString id() const override
548 {
549 return QStringLiteral( "geometry" );
550 }
551
552 QString pythonImportString() const override
553 {
554 return QStringLiteral( "from qgis.core import QgsProcessingParameterGeometry" );
555 }
556
557 QString className() const override
558 {
559 return QStringLiteral( "QgsProcessingParameterGeometry" );
560 }
561
562 QStringList acceptedPythonTypes() const override
563 {
564 return QStringList() << QObject::tr( "str: as Well-Known Text string (WKT)" )
565 << QStringLiteral( "QgsGeometry" )
566 << QStringLiteral( "QgsProperty" );
567 }
568
569 QStringList acceptedStringValues() const override
570 {
571 return QStringList() << QObject::tr( "Well-Known Text string (WKT)" );
572 }
573};
574
583{
584 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
585 {
586 return new QgsProcessingParameterEnum( name );
587 }
588
589 QString description() const override
590 {
591 return QCoreApplication::translate( "Processing", "An enumerated type parameter." );
592 }
593
594 QString name() const override
595 {
596 return QCoreApplication::translate( "Processing", "Enum" );
597 }
598
599 QString id() const override
600 {
601 return QStringLiteral( "enum" );
602 }
603
604 QString pythonImportString() const override
605 {
606 return QStringLiteral( "from qgis.core import QgsProcessingParameterEnum" );
607 }
608
609 QString className() const override
610 {
611 return QStringLiteral( "QgsProcessingParameterEnum" );
612 }
613
614 QStringList acceptedPythonTypes() const override
615 {
616 return QStringList() << QStringLiteral( "int" )
617 << QObject::tr( "str: as string representation of int, e.g. '1'" )
618 << QStringLiteral( "QgsProperty" );
619 }
620
621 QStringList acceptedStringValues() const override
622 {
623 return QStringList() << QObject::tr( "Number of selected option, e.g. '1'" )
624 << QObject::tr( "Comma separated list of options, e.g. '1,3'" );
625 }
626};
627
636{
637 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
638 {
639 return new QgsProcessingParameterExtent( name );
640 }
641
642 QString description() const override
643 {
644 return QCoreApplication::translate( "Processing", "A map extent parameter." );
645 }
646
647 QString name() const override
648 {
649 return QCoreApplication::translate( "Processing", "Extent" );
650 }
651
652 QString id() const override
653 {
654 return QStringLiteral( "extent" );
655 }
656
657 QString pythonImportString() const override
658 {
659 return QStringLiteral( "from qgis.core import QgsProcessingParameterExtent" );
660 }
661
662 QString className() const override
663 {
664 return QStringLiteral( "QgsProcessingParameterExtent" );
665 }
666
667 QStringList acceptedPythonTypes() const override
668 {
669 return QStringList() << QObject::tr( "str: as comma delimited list of x min, x max, y min, y max. E.g. '4,10,101,105'" )
670 << QObject::tr( "str: layer ID. Extent of layer is used." )
671 << QObject::tr( "str: layer name. Extent of layer is used." )
672 << QObject::tr( "str: layer source. Extent of layer is used." )
673 << QObject::tr( "QgsMapLayer: Extent of layer is used" )
674 << QObject::tr( "QgsProcessingFeatureSourceDefinition: Extent of source is used" )
675 << QStringLiteral( "QgsProperty" )
676 << QStringLiteral( "QgsRectangle" )
677 << QStringLiteral( "QgsReferencedRectangle" )
678 << QStringLiteral( "QgsGeometry: bounding box of geometry is used" );
679 }
680
681 QStringList acceptedStringValues() const override
682 {
683 return QStringList() << QObject::tr( "A comma delimited string of x min, x max, y min, y max. E.g. '4,10,101,105'" )
684 << QObject::tr( "Path to a layer. The extent of the layer is used." ) ;
685 }
686};
687
696{
697 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
698 {
699 return new QgsProcessingParameterMatrix( name );
700 }
701
702 QString description() const override
703 {
704 return QCoreApplication::translate( "Processing", "A table (matrix) parameter for processing algorithms." );
705 }
706
707 QString name() const override
708 {
709 return QCoreApplication::translate( "Processing", "Matrix" );
710 }
711
712 QString id() const override
713 {
714 return QStringLiteral( "matrix" );
715 }
716
717 QString pythonImportString() const override
718 {
719 return QStringLiteral( "from qgis.core import QgsProcessingParameterMatrix" );
720 }
721
722 QString className() const override
723 {
724 return QStringLiteral( "QgsProcessingParameterMatrix" );
725 }
726
727 QStringList acceptedPythonTypes() const override
728 {
729 return QStringList() << QObject::tr( "str: as comma delimited list of values" )
730 << QStringLiteral( "list" )
731 << QStringLiteral( "QgsProperty" );
732 }
733
734 QStringList acceptedStringValues() const override
735 {
736 return QStringList() << QObject::tr( "A comma delimited list of values" );
737 }
738};
739
748{
749 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
750 {
751 return new QgsProcessingParameterFile( name );
752 }
753
754 QString description() const override
755 {
756 return QCoreApplication::translate( "Processing", "A file or folder parameter, for use with non-map layer file sources or folders." );
757 }
758
759 QString name() const override
760 {
761 return QCoreApplication::translate( "Processing", "File/Folder" );
762 }
763
764 QString id() const override
765 {
766 return QStringLiteral( "file" );
767 }
768
769 QString pythonImportString() const override
770 {
771 return QStringLiteral( "from qgis.core import QgsProcessingParameterFile" );
772 }
773
774 QString className() const override
775 {
776 return QStringLiteral( "QgsProcessingParameterFile" );
777 }
778
779 QStringList acceptedPythonTypes() const override
780 {
781 return QStringList() << QStringLiteral( "str" )
782 << QStringLiteral( "QgsProperty" );
783 }
784
785 QStringList acceptedStringValues() const override
786 {
787 return QStringList() << QObject::tr( "Path to a file" );
788 }
789};
790
799{
800 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
801 {
802 return new QgsProcessingParameterField( name );
803 }
804
805 QString description() const override
806 {
807 return QCoreApplication::translate( "Processing", "A vector field parameter, for selecting an existing field from a vector source." );
808 }
809
810 QString name() const override
811 {
812 return QCoreApplication::translate( "Processing", "Vector Field" );
813 }
814
815 QString id() const override
816 {
817 return QStringLiteral( "field" );
818 }
819
820 QString pythonImportString() const override
821 {
822 return QStringLiteral( "from qgis.core import QgsProcessingParameterField" );
823 }
824
825 QString className() const override
826 {
827 return QStringLiteral( "QgsProcessingParameterField" );
828 }
829
830 QStringList acceptedPythonTypes() const override
831 {
832 return QStringList() << QStringLiteral( "str" )
833 << QStringLiteral( "QgsProperty" );
834 }
835
836 QStringList acceptedStringValues() const override
837 {
838 return QStringList() << QObject::tr( "The name of an existing field" )
839 << QObject::tr( "; delimited list of existing field names" );
840 }
841};
842
852{
853 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
854 {
856 }
857
858 QString description() const override
859 {
860 return QCoreApplication::translate( "Processing", "A vector layer destination parameter." );
861 }
862
863 QString name() const override
864 {
865 return QCoreApplication::translate( "Processing", "Vector Destination" );
866 }
867
868 QString id() const override
869 {
870 return QStringLiteral( "vectorDestination" );
871 }
872
873 QString pythonImportString() const override
874 {
875 return QStringLiteral( "from qgis.core import QgsProcessingParameterVectorDestination" );
876 }
877
878 QString className() const override
879 {
880 return QStringLiteral( "QgsProcessingParameterVectorDestination" );
881 }
882
884 {
887 return flags;
888 }
889
890 QStringList acceptedPythonTypes() const override
891 {
892 return QStringList() << QStringLiteral( "str" )
893 << QStringLiteral( "QgsProperty" )
894 << QStringLiteral( "QgsProcessingOutputLayerDefinition" );
895 }
896
897 QStringList acceptedStringValues() const override
898 {
899 return QStringList() << QObject::tr( "Path for new vector layer" );
900 }
901};
902
912{
913 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
914 {
915 return new QgsProcessingParameterFileDestination( name );
916 }
917
918 QString description() const override
919 {
920 return QCoreApplication::translate( "Processing", "A generic file based destination parameter." );
921 }
922
923 QString name() const override
924 {
925 return QCoreApplication::translate( "Processing", "File Destination" );
926 }
927
928 QString id() const override
929 {
930 return QStringLiteral( "fileDestination" );
931 }
932
933 QString pythonImportString() const override
934 {
935 return QStringLiteral( "from qgis.core import QgsProcessingParameterFileDestination" );
936 }
937
938 QString className() const override
939 {
940 return QStringLiteral( "QgsProcessingParameterFileDestination" );
941 }
942
944 {
947 return flags;
948 }
949
950 QStringList acceptedPythonTypes() const override
951 {
952 return QStringList() << QStringLiteral( "str" )
953 << QStringLiteral( "QgsProperty" );
954 }
955
956 QStringList acceptedStringValues() const override
957 {
958 return QStringList() << QObject::tr( "Path for new file" );
959 }
960};
961
972{
973 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
974 {
976 }
977
978 QString description() const override
979 {
980 return QCoreApplication::translate( "Processing", "A folder destination parameter." );
981 }
982
983 QString name() const override
984 {
985 return QCoreApplication::translate( "Processing", "Folder Destination" );
986 }
987
988 QString id() const override
989 {
990 return QStringLiteral( "folderDestination" );
991 }
992
993 QString pythonImportString() const override
994 {
995 return QStringLiteral( "from qgis.core import QgsProcessingParameterFolderDestination" );
996 }
997
998 QString className() const override
999 {
1000 return QStringLiteral( "QgsProcessingParameterFolderDestination" );
1001 }
1002
1004 {
1007 return flags;
1008 }
1009
1010 QStringList acceptedPythonTypes() const override
1011 {
1012 return QStringList() << QStringLiteral( "str" )
1013 << QStringLiteral( "QgsProperty" );
1014 }
1015
1016 QStringList acceptedStringValues() const override
1017 {
1018 return QStringList() << QObject::tr( "Path for an existing or new folder" );
1019 }
1020};
1021
1031{
1032 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1033 {
1034 return new QgsProcessingParameterRasterDestination( name );
1035 }
1036
1037 QString description() const override
1038 {
1039 return QCoreApplication::translate( "Processing", "A raster layer destination parameter." );
1040 }
1041
1042 QString name() const override
1043 {
1044 return QCoreApplication::translate( "Processing", "Raster Destination" );
1045 }
1046
1047 QString id() const override
1048 {
1049 return QStringLiteral( "rasterDestination" );
1050 }
1051
1052 QString pythonImportString() const override
1053 {
1054 return QStringLiteral( "from qgis.core import QgsProcessingParameterRasterDestination" );
1055 }
1056
1057 QString className() const override
1058 {
1059 return QStringLiteral( "QgsProcessingParameterRasterDestination" );
1060 }
1061
1063 {
1066 return flags;
1067 }
1068
1069 QStringList acceptedPythonTypes() const override
1070 {
1071 return QStringList() << QStringLiteral( "str" )
1072 << QStringLiteral( "QgsProperty" )
1073 << QStringLiteral( "QgsProcessingOutputLayerDefinition" );
1074 }
1075
1076 QStringList acceptedStringValues() const override
1077 {
1078 return QStringList() << QObject::tr( "Path for new raster layer" );
1079 }
1080};
1081
1090{
1091 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1092 {
1093 return new QgsProcessingParameterString( name );
1094 }
1095
1096 QString description() const override
1097 {
1098 return QCoreApplication::translate( "Processing", "A freeform string parameter." );
1099 }
1100
1101 QString name() const override
1102 {
1103 return QCoreApplication::translate( "Processing", "String" );
1104 }
1105
1106 QString id() const override
1107 {
1108 return QStringLiteral( "string" );
1109 }
1110
1111 QString pythonImportString() const override
1112 {
1113 return QStringLiteral( "from qgis.core import QgsProcessingParameterString" );
1114 }
1115
1116 QString className() const override
1117 {
1118 return QStringLiteral( "QgsProcessingParameterString" );
1119 }
1120
1121 QStringList acceptedPythonTypes() const override
1122 {
1123 return QStringList() << QStringLiteral( "str" )
1124 << QStringLiteral( "QgsProperty" );
1125 }
1126
1127 QStringList acceptedStringValues() const override
1128 {
1129 return QStringList() << QObject::tr( "String value" )
1130 << QObject::tr( "field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field" )
1131 << QObject::tr( "expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression" );
1132 }
1133};
1134
1143{
1144 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1145 {
1146 return new QgsProcessingParameterAuthConfig( name );
1147 }
1148
1149 QString description() const override
1150 {
1151 return QCoreApplication::translate( "Processing", "A authentication configuration parameter." );
1152 }
1153
1154 QString name() const override
1155 {
1156 return QCoreApplication::translate( "Processing", "Authentication Configuration" );
1157 }
1158
1159 QString id() const override
1160 {
1161 return QStringLiteral( "authcfg" );
1162 }
1163
1164 QString pythonImportString() const override
1165 {
1166 return QStringLiteral( "from qgis.core import QgsProcessingParameterAuthConfig" );
1167 }
1168
1169 QString className() const override
1170 {
1171 return QStringLiteral( "QgsProcessingParameterAuthConfig" );
1172 }
1173
1174 QStringList acceptedPythonTypes() const override
1175 {
1176 return QStringList() << QStringLiteral( "str" );
1177 }
1178
1179 QStringList acceptedStringValues() const override
1180 {
1181 return QStringList() << QObject::tr( "An existing QGIS authentication ID string" );
1182 }
1183};
1184
1193{
1194 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1195 {
1196 return new QgsProcessingParameterMultipleLayers( name );
1197 }
1198
1199 QString description() const override
1200 {
1201 return QCoreApplication::translate( "Processing", "An input allowing selection of multiple sources, including multiple map layers or file sources." );
1202 }
1203
1204 QString name() const override
1205 {
1206 return QCoreApplication::translate( "Processing", "Multiple Input" );
1207 }
1208
1209 QString id() const override
1210 {
1211 return QStringLiteral( "multilayer" );
1212 }
1213
1214 QString pythonImportString() const override
1215 {
1216 return QStringLiteral( "from qgis.core import QgsProcessingParameterMultipleLayers" );
1217 }
1218
1219 QString className() const override
1220 {
1221 return QStringLiteral( "QgsProcessingParameterMultipleLayers" );
1222 }
1223
1224 QStringList acceptedPythonTypes() const override
1225 {
1226 return QStringList() << QObject::tr( "list[str]: list of layer IDs" )
1227 << QObject::tr( "list[str]: list of layer names" )
1228 << QObject::tr( "list[str]: list of layer sources" )
1229 << QStringLiteral( "list[QgsMapLayer]" )
1230 << QStringLiteral( "QgsProperty" );
1231 }
1232};
1233
1242{
1243 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1244 {
1245 return new QgsProcessingParameterFeatureSource( name );
1246 }
1247
1248 QString description() const override
1249 {
1250 return QCoreApplication::translate( "Processing", "A vector feature parameter, e.g. for algorithms which operate on the features within a layer." );
1251 }
1252
1253 QString name() const override
1254 {
1255 return QCoreApplication::translate( "Processing", "Vector Features" );
1256 }
1257
1258 QString id() const override
1259 {
1260 return QStringLiteral( "source" );
1261 }
1262
1263 QString pythonImportString() const override
1264 {
1265 return QStringLiteral( "from qgis.core import QgsProcessingParameterFeatureSource" );
1266 }
1267
1268 QString className() const override
1269 {
1270 return QStringLiteral( "QgsProcessingParameterFeatureSource" );
1271 }
1272
1273 QStringList acceptedPythonTypes() const override
1274 {
1275 return QStringList() << QObject::tr( "str: layer ID" )
1276 << QObject::tr( "str: layer name" )
1277 << QObject::tr( "str: layer source" )
1278 << QStringLiteral( "QgsProcessingFeatureSourceDefinition" )
1279 << QStringLiteral( "QgsProperty" )
1280 << QStringLiteral( "QgsVectorLayer" );
1281 }
1282
1283 QStringList acceptedStringValues() const override
1284 {
1285 return QStringList() << QObject::tr( "Path to a vector layer" );
1286 }
1287};
1288
1297{
1298 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1299 {
1300 return new QgsProcessingParameterNumber( name );
1301 }
1302
1303 QString description() const override
1304 {
1305 return QCoreApplication::translate( "Processing", "A numeric parameter, including float or integer values." );
1306 }
1307
1308 QString name() const override
1309 {
1310 return QCoreApplication::translate( "Processing", "Number" );
1311 }
1312
1313 QString id() const override
1314 {
1315 return QStringLiteral( "number" );
1316 }
1317
1318 QString pythonImportString() const override
1319 {
1320 return QStringLiteral( "from qgis.core import QgsProcessingParameterNumber" );
1321 }
1322
1323 QString className() const override
1324 {
1325 return QStringLiteral( "QgsProcessingParameterNumber" );
1326 }
1327
1328 QStringList acceptedPythonTypes() const override
1329 {
1330 return QStringList() << QStringLiteral( "int" )
1331 << QStringLiteral( "float" )
1332 << QStringLiteral( "QgsProperty" );
1333 }
1334
1335 QStringList acceptedStringValues() const override
1336 {
1337 return QStringList() << QObject::tr( "A numeric value" )
1338 << QObject::tr( "field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field" )
1339 << QObject::tr( "expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression" );
1340 }
1341};
1342
1351{
1352 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1353 {
1354 return new QgsProcessingParameterDistance( name );
1355 }
1356
1357 QString description() const override
1358 {
1359 return QCoreApplication::translate( "Processing", "A numeric parameter representing a distance measure." );
1360 }
1361
1362 QString name() const override
1363 {
1364 return QCoreApplication::translate( "Processing", "Distance" );
1365 }
1366
1367 QString id() const override
1368 {
1369 return QStringLiteral( "distance" );
1370 }
1371
1372 QString pythonImportString() const override
1373 {
1374 return QStringLiteral( "from qgis.core import QgsProcessingParameterDistance" );
1375 }
1376
1377 QString className() const override
1378 {
1379 return QStringLiteral( "QgsProcessingParameterDistance" );
1380 }
1381
1382 QStringList acceptedPythonTypes() const override
1383 {
1384 return QStringList() << QStringLiteral( "int" )
1385 << QStringLiteral( "float" )
1386 << QStringLiteral( "QgsProperty" );
1387 }
1388
1389 QStringList acceptedStringValues() const override
1390 {
1391 return QStringList() << QObject::tr( "A numeric value" )
1392 << QObject::tr( "field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field" )
1393 << QObject::tr( "expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression" );
1394 }
1395};
1396
1397
1406{
1407 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1408 {
1409 return new QgsProcessingParameterArea( name );
1410 }
1411
1412 QString description() const override
1413 {
1414 return QCoreApplication::translate( "Processing", "A numeric parameter representing an area measure." );
1415 }
1416
1417 QString name() const override
1418 {
1419 return QCoreApplication::translate( "Processing", "Area" );
1420 }
1421
1422 QString id() const override
1423 {
1424 return QStringLiteral( "area" );
1425 }
1426
1427 QString pythonImportString() const override
1428 {
1429 return QStringLiteral( "from qgis.core import QgsProcessingParameterArea" );
1430 }
1431
1432 QString className() const override
1433 {
1434 return QStringLiteral( "QgsProcessingParameterArea" );
1435 }
1436
1437 QStringList acceptedPythonTypes() const override
1438 {
1439 return QStringList() << QStringLiteral( "int" )
1440 << QStringLiteral( "float" )
1441 << QStringLiteral( "QgsProperty" );
1442 }
1443
1444 QStringList acceptedStringValues() const override
1445 {
1446 return QStringList() << QObject::tr( "A numeric value" )
1447 << QObject::tr( "field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field" )
1448 << QObject::tr( "expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression" );
1449 }
1450};
1451
1452
1461{
1462 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1463 {
1464 return new QgsProcessingParameterVolume( name );
1465 }
1466
1467 QString description() const override
1468 {
1469 return QCoreApplication::translate( "Processing", "A numeric parameter representing a volume measure." );
1470 }
1471
1472 QString name() const override
1473 {
1474 return QCoreApplication::translate( "Processing", "Volume" );
1475 }
1476
1477 QString id() const override
1478 {
1479 return QStringLiteral( "volume" );
1480 }
1481
1482 QString pythonImportString() const override
1483 {
1484 return QStringLiteral( "from qgis.core import QgsProcessingParameterVolume" );
1485 }
1486
1487 QString className() const override
1488 {
1489 return QStringLiteral( "QgsProcessingParameterVolume" );
1490 }
1491
1492 QStringList acceptedPythonTypes() const override
1493 {
1494 return QStringList() << QStringLiteral( "int" )
1495 << QStringLiteral( "float" )
1496 << QStringLiteral( "QgsProperty" );
1497 }
1498
1499 QStringList acceptedStringValues() const override
1500 {
1501 return QStringList() << QObject::tr( "A numeric value" )
1502 << QObject::tr( "field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field" )
1503 << QObject::tr( "expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression" );
1504 }
1505};
1506
1507
1508
1517{
1518 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1519 {
1520 return new QgsProcessingParameterDuration( name );
1521 }
1522
1523 QString description() const override
1524 {
1525 return QCoreApplication::translate( "Processing", "A numeric parameter representing a duration measure." );
1526 }
1527
1528 QString name() const override
1529 {
1530 return QCoreApplication::translate( "Processing", "Duration" );
1531 }
1532
1533 QString id() const override
1534 {
1535 return QStringLiteral( "duration" );
1536 }
1537
1538 QString pythonImportString() const override
1539 {
1540 return QStringLiteral( "from qgis.core import QgsProcessingParameterDuration" );
1541 }
1542
1543 QString className() const override
1544 {
1545 return QStringLiteral( "QgsProcessingParameterDuration" );
1546 }
1547
1548 QStringList acceptedPythonTypes() const override
1549 {
1550 return QStringList() << QStringLiteral( "int" )
1551 << QStringLiteral( "float" )
1552 << QStringLiteral( "QgsProperty" );
1553 }
1554
1555 QStringList acceptedStringValues() const override
1556 {
1557 return QStringList() << QObject::tr( "A numeric value (unit type set by algorithms)" )
1558 << QObject::tr( "field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field" )
1559 << QObject::tr( "expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression" );
1560 }
1561};
1562
1571{
1572 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1573 {
1574 return new QgsProcessingParameterScale( name );
1575 }
1576
1577 QString description() const override
1578 {
1579 return QCoreApplication::translate( "Processing", "A numeric parameter representing a map scale." );
1580 }
1581
1582 QString name() const override
1583 {
1584 return QCoreApplication::translate( "Processing", "Scale" );
1585 }
1586
1587 QString id() const override
1588 {
1589 return QStringLiteral( "scale" );
1590 }
1591
1592 QString pythonImportString() const override
1593 {
1594 return QStringLiteral( "from qgis.core import QgsProcessingParameterScale" );
1595 }
1596
1597 QString className() const override
1598 {
1599 return QStringLiteral( "QgsProcessingParameterScale" );
1600 }
1601
1602 QStringList acceptedPythonTypes() const override
1603 {
1604 return QStringList() << QStringLiteral( "int: scale denominator" )
1605 << QStringLiteral( "float: scale denominator" )
1606 << QStringLiteral( "QgsProperty" );
1607 }
1608
1609 QStringList acceptedStringValues() const override
1610 {
1611 return QStringList() << QObject::tr( "A numeric value representing the scale denominator" );
1612 }
1613};
1614
1623{
1624 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1625 {
1626 return new QgsProcessingParameterBand( name );
1627 }
1628
1629 QString description() const override
1630 {
1631 return QCoreApplication::translate( "Processing", "A raster band parameter, for selecting an existing band from a raster source." );
1632 }
1633
1634 QString name() const override
1635 {
1636 return QCoreApplication::translate( "Processing", "Raster Band" );
1637 }
1638
1639 QString id() const override
1640 {
1641 return QStringLiteral( "band" );
1642 }
1643
1644 QString pythonImportString() const override
1645 {
1646 return QStringLiteral( "from qgis.core import QgsProcessingParameterBand" );
1647 }
1648
1649 QString className() const override
1650 {
1651 return QStringLiteral( "QgsProcessingParameterBand" );
1652 }
1653
1654 QStringList acceptedPythonTypes() const override
1655 {
1656 return QStringList() << QStringLiteral( "int" )
1657 << QStringLiteral( "QgsProperty" );
1658 }
1659
1660 QStringList acceptedStringValues() const override
1661 {
1662 return QStringList() << QObject::tr( "Integer value representing an existing raster band number" );
1663 }
1664};
1665
1674{
1675 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1676 {
1677 return new QgsProcessingParameterFeatureSink( name );
1678 }
1679
1681 {
1684 return flags;
1685 }
1686
1687 QString description() const override
1688 {
1689 return QCoreApplication::translate( "Processing", "A feature sink destination parameter." );
1690 }
1691
1692 QString name() const override
1693 {
1694 return QCoreApplication::translate( "Processing", "Feature Sink" );
1695 }
1696
1697 QString id() const override
1698 {
1699 return QStringLiteral( "sink" );
1700 }
1701
1702 QString pythonImportString() const override
1703 {
1704 return QStringLiteral( "from qgis.core import QgsProcessingParameterFeatureSink" );
1705 }
1706
1707 QString className() const override
1708 {
1709 return QStringLiteral( "QgsProcessingParameterFeatureSink" );
1710 }
1711
1712 QStringList acceptedPythonTypes() const override
1713 {
1714 return QStringList() << QObject::tr( "str: destination vector file, e.g. 'd:/test.shp'" )
1715 << QObject::tr( "str: 'memory:' to store result in temporary memory layer" )
1716 << QObject::tr( "str: using vector provider ID prefix and destination URI, e.g. 'postgres:…' to store result in PostGIS table" )
1717 << QStringLiteral( "QgsProcessingOutputLayerDefinition" )
1718 << QStringLiteral( "QgsProperty" );
1719 }
1720
1721 QStringList acceptedStringValues() const override
1722 {
1723 return QStringList() << QObject::tr( "Path for new vector layer" );
1724 }
1725};
1726
1735{
1736 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1737 {
1738 return new QgsProcessingParameterLayout( name );
1739 }
1740
1741 QString description() const override
1742 {
1743 return QCoreApplication::translate( "Processing", "A print layout parameter." );
1744 }
1745
1746 QString name() const override
1747 {
1748 return QCoreApplication::translate( "Processing", "Print Layout" );
1749 }
1750
1751 QString id() const override
1752 {
1753 return QStringLiteral( "layout" );
1754 }
1755
1756 QString pythonImportString() const override
1757 {
1758 return QStringLiteral( "from qgis.core import QgsProcessingParameterLayout" );
1759 }
1760
1761 QString className() const override
1762 {
1763 return QStringLiteral( "QgsProcessingParameterLayout" );
1764 }
1765
1766 QStringList acceptedPythonTypes() const override
1767 {
1768 return QStringList() << QObject::tr( "str: name of print layout in current project" )
1769 << QStringLiteral( "QgsProperty" );
1770 }
1771
1772 QStringList acceptedStringValues() const override
1773 {
1774 return QStringList() << QObject::tr( "Name of print layout in current project" );
1775 }
1776};
1777
1786{
1787 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1788 {
1789 return new QgsProcessingParameterLayoutItem( name );
1790 }
1791
1792 QString description() const override
1793 {
1794 return QCoreApplication::translate( "Processing", "A print layout item parameter." );
1795 }
1796
1797 QString name() const override
1798 {
1799 return QCoreApplication::translate( "Processing", "Print Layout Item" );
1800 }
1801
1802 QString id() const override
1803 {
1804 return QStringLiteral( "layoutitem" );
1805 }
1806
1807 QString pythonImportString() const override
1808 {
1809 return QStringLiteral( "from qgis.core import QgsProcessingParameterLayoutItem" );
1810 }
1811
1812 QString className() const override
1813 {
1814 return QStringLiteral( "QgsProcessingParameterLayoutItem" );
1815 }
1816
1817 QStringList acceptedPythonTypes() const override
1818 {
1819 return QStringList() << QObject::tr( "str: UUID of print layout item" )
1820 << QObject::tr( "str: id of print layout item" )
1821 << QStringLiteral( "QgsProperty" );
1822 }
1823
1824 QStringList acceptedStringValues() const override
1825 {
1826 return QStringList() << QObject::tr( "UUID or item id of layout item" );
1827 }
1828};
1829
1838{
1839 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1840 {
1841 return new QgsProcessingParameterColor( name );
1842 }
1843
1844 QString description() const override
1845 {
1846 return QCoreApplication::translate( "Processing", "A color parameter." );
1847 }
1848
1849 QString name() const override
1850 {
1851 return QCoreApplication::translate( "Processing", "Color" );
1852 }
1853
1854 QString id() const override
1855 {
1856 return QStringLiteral( "color" );
1857 }
1858
1859 QString pythonImportString() const override
1860 {
1861 return QStringLiteral( "from qgis.core import QgsProcessingParameterColor" );
1862 }
1863
1864 QString className() const override
1865 {
1866 return QStringLiteral( "QgsProcessingParameterColor" );
1867 }
1868
1869 QStringList acceptedPythonTypes() const override
1870 {
1871 return QStringList() << QObject::tr( "str: string representation of color, e.g #ff0000 or rgba(200,100,50,0.8)" )
1872 << QStringLiteral( "QColor" )
1873 << QStringLiteral( "QgsProperty" );
1874 }
1875
1876 QStringList acceptedStringValues() const override
1877 {
1878 return QStringList() << QObject::tr( "String representation of color, e.g #ff0000 or rgba(200,100,50,0.8)" )
1879 << QObject::tr( "field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field" )
1880 << QObject::tr( "expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression" );
1881 }
1882};
1883
1892{
1893 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1894 {
1896 }
1897
1898 QString description() const override
1899 {
1900 return QCoreApplication::translate( "Processing", "A coordinate operation parameter." );
1901 }
1902
1903 QString name() const override
1904 {
1905 return QCoreApplication::translate( "Processing", "Coordinate Operation" );
1906 }
1907
1908 QString id() const override
1909 {
1910 return QStringLiteral( "coordinateoperation" );
1911 }
1912
1913 QString pythonImportString() const override
1914 {
1915 return QStringLiteral( "from qgis.core import QgsProcessingParameterCoordinateOperation" );
1916 }
1917
1918 QString className() const override
1919 {
1920 return QStringLiteral( "QgsProcessingParameterCoordinateOperation" );
1921 }
1922
1923 QStringList acceptedPythonTypes() const override
1924 {
1925 return QStringList() << QObject::tr( "str: string representation of a Proj coordinate operation" );
1926 }
1927
1928 QStringList acceptedStringValues() const override
1929 {
1930 return QStringList() << QObject::tr( "String representation of Proj coordinate operation" );
1931 }
1932};
1933
1942{
1943 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1944 {
1945 return new QgsProcessingParameterMapTheme( name );
1946 }
1947
1948 QString description() const override
1949 {
1950 return QCoreApplication::translate( "Processing", "A map theme parameter." );
1951 }
1952
1953 QString name() const override
1954 {
1955 return QCoreApplication::translate( "Processing", "Map Theme" );
1956 }
1957
1958 QString id() const override
1959 {
1960 return QStringLiteral( "maptheme" );
1961 }
1962
1963 QString pythonImportString() const override
1964 {
1965 return QStringLiteral( "from qgis.core import QgsProcessingParameterMapTheme" );
1966 }
1967
1968 QString className() const override
1969 {
1970 return QStringLiteral( "QgsProcessingParameterMapTheme" );
1971 }
1972
1973 QStringList acceptedPythonTypes() const override
1974 {
1975 return QStringList() << QObject::tr( "str: name of an existing map theme" )
1976 << QStringLiteral( "QgsProperty" );
1977 }
1978
1979 QStringList acceptedStringValues() const override
1980 {
1981 return QStringList() << QObject::tr( "Name of an existing map theme" );
1982 }
1983};
1984
1993{
1994 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
1995 {
1996 return new QgsProcessingParameterDateTime( name );
1997 }
1998
1999 QString description() const override
2000 {
2001 return QCoreApplication::translate( "Processing", "A datetime parameter, including datetime, date or time values." );
2002 }
2003
2004 QString name() const override
2005 {
2006 return QCoreApplication::translate( "Processing", "Datetime" );
2007 }
2008
2009 QString id() const override
2010 {
2011 return QStringLiteral( "datetime" );
2012 }
2013
2014 QString pythonImportString() const override
2015 {
2016 return QStringLiteral( "from qgis.core import QgsProcessingParameterDateTime" );
2017 }
2018
2019 QString className() const override
2020 {
2021 return QStringLiteral( "QgsProcessingParameterDateTime" );
2022 }
2023
2024 QStringList acceptedPythonTypes() const override
2025 {
2026 return QStringList() << QStringLiteral( "str" )
2027 << QStringLiteral( "QDateTime" )
2028 << QStringLiteral( "QDate" )
2029 << QStringLiteral( "QTime" )
2030 << QStringLiteral( "QgsProperty" );
2031 }
2032
2033 QStringList acceptedStringValues() const override
2034 {
2035 return QStringList() << QObject::tr( "A datetime value in ISO format" )
2036 << QObject::tr( "field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field" )
2037 << QObject::tr( "expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression" );
2038 }
2039};
2040
2049{
2050 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
2051 {
2052 return new QgsProcessingParameterProviderConnection( name, QString(), QString() );
2053 }
2054
2055 QString description() const override
2056 {
2057 return QCoreApplication::translate( "Processing", "A connection name parameter, for registered database connections." );
2058 }
2059
2060 QString name() const override
2061 {
2062 return QCoreApplication::translate( "Processing", "Connection Name" );
2063 }
2064
2065 QString id() const override
2066 {
2067 return QStringLiteral( "providerconnection" );
2068 }
2069
2070 QString pythonImportString() const override
2071 {
2072 return QStringLiteral( "from qgis.core import QgsProcessingParameterProviderConnection" );
2073 }
2074
2075 QString className() const override
2076 {
2077 return QStringLiteral( "QgsProcessingParameterProviderConnection" );
2078 }
2079
2080 QStringList acceptedPythonTypes() const override
2081 {
2082 return QStringList() << QStringLiteral( "str" )
2083 << QStringLiteral( "QgsProperty" );
2084 }
2085
2086 QStringList acceptedStringValues() const override
2087 {
2088 return QStringList() << QObject::tr( "Name of registered database connection" );
2089 }
2090};
2091
2100{
2101 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
2102 {
2103 return new QgsProcessingParameterDatabaseSchema( name, QString(), QString() );
2104 }
2105
2106 QString description() const override
2107 {
2108 return QCoreApplication::translate( "Processing", "A database schema parameter." );
2109 }
2110
2111 QString name() const override
2112 {
2113 return QCoreApplication::translate( "Processing", "Database Schema" );
2114 }
2115
2116 QString id() const override
2117 {
2118 return QStringLiteral( "databaseschema" );
2119 }
2120
2121 QString pythonImportString() const override
2122 {
2123 return QStringLiteral( "from qgis.core import QgsProcessingParameterDatabaseSchema" );
2124 }
2125
2126 QString className() const override
2127 {
2128 return QStringLiteral( "QgsProcessingParameterDatabaseSchema" );
2129 }
2130
2131 QStringList acceptedPythonTypes() const override
2132 {
2133 return QStringList() << QStringLiteral( "str" )
2134 << QStringLiteral( "QgsProperty" );
2135 }
2136
2137 QStringList acceptedStringValues() const override
2138 {
2139 return QStringList() << QObject::tr( "Name of existing database schema" );
2140 }
2141};
2142
2151{
2152 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
2153 {
2154 return new QgsProcessingParameterDatabaseTable( name, QString(), QString(), QString() );
2155 }
2156
2157 QString description() const override
2158 {
2159 return QCoreApplication::translate( "Processing", "A database table parameter." );
2160 }
2161
2162 QString name() const override
2163 {
2164 return QCoreApplication::translate( "Processing", "Database Table" );
2165 }
2166
2167 QString id() const override
2168 {
2169 return QStringLiteral( "databasetable" );
2170 }
2171
2172 QString pythonImportString() const override
2173 {
2174 return QStringLiteral( "from qgis.core import QgsProcessingParameterDatabaseTable" );
2175 }
2176
2177 QString className() const override
2178 {
2179 return QStringLiteral( "QgsProcessingParameterDatabaseTable" );
2180 }
2181
2182 QStringList acceptedPythonTypes() const override
2183 {
2184 return QStringList() << QStringLiteral( "str" )
2185 << QStringLiteral( "QgsProperty" );
2186 }
2187
2188 QStringList acceptedStringValues() const override
2189 {
2190 return QStringList() << QObject::tr( "Name of existing database table" );
2191 }
2192};
2193
2202{
2203 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
2204 {
2205 return new QgsProcessingParameterPointCloudLayer( name );
2206 }
2207
2208 QString description() const override
2209 {
2210 return QCoreApplication::translate( "Processing", "A point cloud layer parameter." );
2211 }
2212
2213 QString name() const override
2214 {
2215 return QCoreApplication::translate( "Processing", "Point Cloud Layer" );
2216 }
2217
2218 QString pythonImportString() const override
2219 {
2220 return QStringLiteral( "from qgis.core import QgsProcessingParameterPointCloudLayer" );
2221 }
2222
2223 QString className() const override
2224 {
2225 return QStringLiteral( "QgsProcessingParameterPointCloudLayer" );
2226 }
2227
2228 QString id() const override
2229 {
2230 return QStringLiteral( "pointcloud" );
2231 }
2232
2233 QStringList acceptedPythonTypes() const override
2234 {
2235 return QStringList() << QObject::tr( "str: layer ID" )
2236 << QObject::tr( "str: layer name" )
2237 << QObject::tr( "str: layer source" )
2238 << QStringLiteral( "QgsPointCloudLayer" );
2239 }
2240
2241 QStringList acceptedStringValues() const override
2242 {
2243 return QStringList() << QObject::tr( "Path to a point cloud layer" );
2244 }
2245};
2246
2255{
2256 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
2257 {
2258 return new QgsProcessingParameterAnnotationLayer( name );
2259 }
2260
2261 QString description() const override
2262 {
2263 return QCoreApplication::translate( "Processing", "An annotation layer parameter." );
2264 }
2265
2266 QString name() const override
2267 {
2268 return QCoreApplication::translate( "Processing", "Annotation Layer" );
2269 }
2270
2271 QString pythonImportString() const override
2272 {
2273 return QStringLiteral( "from qgis.core import QgsProcessingParameterAnnotationLayer" );
2274 }
2275
2276 QString className() const override
2277 {
2278 return QStringLiteral( "QgsProcessingParameterAnnotationLayer" );
2279 }
2280
2281 QString id() const override
2282 {
2283 return QStringLiteral( "annotation" );
2284 }
2285
2286 QStringList acceptedPythonTypes() const override
2287 {
2288 return QStringList() << QObject::tr( "str: layer ID" )
2289 << QObject::tr( "str: layer name" )
2290 << QObject::tr( "\"main\": main annotation layer for a project" )
2291 << QStringLiteral( "QgsAnnotationLayer" );
2292 }
2293
2294 QStringList acceptedStringValues() const override
2295 {
2296 return QStringList() << QObject::tr( "Layer ID for an annotation layer, or \"main\" for the main annotation layer in a project." );
2297 }
2298};
2299
2309{
2310 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
2311 {
2313 }
2314
2315 QString description() const override
2316 {
2317 return QCoreApplication::translate( "Processing", "A point cloud layer destination parameter." );
2318 }
2319
2320 QString name() const override
2321 {
2322 return QCoreApplication::translate( "Processing", "Point Cloud Destination" );
2323 }
2324
2325 QString id() const override
2326 {
2327 return QStringLiteral( "pointCloudDestination" );
2328 }
2329
2330 QString pythonImportString() const override
2331 {
2332 return QStringLiteral( "from qgis.core import QgsProcessingParameterPointCloudDestination" );
2333 }
2334
2335 QString className() const override
2336 {
2337 return QStringLiteral( "QgsProcessingParameterPointCloudDestination" );
2338 }
2339
2341 {
2344 return flags;
2345 }
2346
2347 QStringList acceptedPythonTypes() const override
2348 {
2349 return QStringList() << QStringLiteral( "str" )
2350 << QStringLiteral( "QgsProperty" )
2351 << QStringLiteral( "QgsProcessingOutputLayerDefinition" );
2352 }
2353
2354 QStringList acceptedStringValues() const override
2355 {
2356 return QStringList() << QObject::tr( "Path for new point cloud layer" );
2357 }
2358};
2359
2368{
2369 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
2370 {
2372 }
2373
2374 QString description() const override
2375 {
2376 return QCoreApplication::translate( "Processing", "A point cloud attribute parameter, for selecting an attribute from a point cloud source." );
2377 }
2378
2379 QString name() const override
2380 {
2381 return QCoreApplication::translate( "Processing", "Point Cloud Attribute" );
2382 }
2383
2384 QString id() const override
2385 {
2386 return QStringLiteral( "attribute" );
2387 }
2388
2389 QString pythonImportString() const override
2390 {
2391 return QStringLiteral( "from qgis.core import QgsProcessingParameterPointCloudAttribute" );
2392 }
2393
2394 QString className() const override
2395 {
2396 return QStringLiteral( "QgsProcessingParameterPointCloudAttribute" );
2397 }
2398
2399 QStringList acceptedPythonTypes() const override
2400 {
2401 return QStringList() << QStringLiteral( "str" )
2402 << QStringLiteral( "QgsProperty" );
2403 }
2404
2405 QStringList acceptedStringValues() const override
2406 {
2407 return QStringList() << QObject::tr( "The name of an attribute" )
2408 << QObject::tr( "; delimited list of attribute names" );
2409 }
2410};
2411
2421{
2422 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY
2423 {
2425 }
2426
2427 QString description() const override
2428 {
2429 return QCoreApplication::translate( "Processing", "A vector tiles layer destination parameter." );
2430 }
2431
2432 QString name() const override
2433 {
2434 return QCoreApplication::translate( "Processing", "Vector Tile Destination" );
2435 }
2436
2437 QString id() const override
2438 {
2439 return QStringLiteral( "vectorTileDestination" );
2440 }
2441
2442 QString pythonImportString() const override
2443 {
2444 return QStringLiteral( "from qgis.core import QgsProcessingParameterVectorTileDestination" );
2445 }
2446
2447 QString className() const override
2448 {
2449 return QStringLiteral( "QgsProcessingParameterVectorTileDestination" );
2450 }
2451
2453 {
2456 return flags;
2457 }
2458
2459 QStringList acceptedPythonTypes() const override
2460 {
2461 return QStringList() << QStringLiteral( "str" )
2462 << QStringLiteral( "QgsProperty" )
2463 << QStringLiteral( "QgsProcessingOutputLayerDefinition" );
2464 }
2465
2466 QStringList acceptedStringValues() const override
2467 {
2468 return QStringList() << QObject::tr( "Path for new vector tile layer" );
2469 }
2470};
2471
2472#endif // QGSPROCESSINGPARAMETERTYPEIMPL_H
@ ExposeToModeler
Is this parameter available in the modeler. Is set to on by default.
QFlags< ProcessingParameterTypeFlag > ProcessingParameterTypeFlags
Flags which dictate the behavior of Processing parameter types.
Definition qgis.h:3473
An annotation layer parameter for processing algorithms.
A double numeric parameter for area values.
A string parameter for authentication configuration ID values.
A raster band parameter for Processing algorithms.
A boolean parameter for processing algorithms.
A color parameter for processing algorithms.
A coordinate operation parameter for processing algorithms, for selection between available coordinat...
A coordinate reference system parameter for processing algorithms.
A database schema parameter for processing algorithms, allowing users to select from existing schemas...
A database table name parameter for processing algorithms, allowing users to select from existing dat...
A datetime (or pure date or time) parameter for processing algorithms.
Base class for the definition of processing parameters.
A double numeric parameter for distance values.
A double numeric parameter for duration values.
An enum based parameter for processing algorithms, allowing for selection from predefined values.
An expression parameter for processing algorithms.
A rectangular map extent parameter for processing algorithms.
A feature sink output for processing algorithms.
An input feature source (such as vector layers) parameter for processing algorithms.
A vector layer or feature source field parameter for processing algorithms.
A generic file based destination parameter, for specifying the destination path for a file (non-map l...
An input file or folder parameter for processing algorithms.
A folder destination parameter, for specifying the destination path for a folder created by the algor...
A geometry parameter for processing algorithms.
A print layout item parameter, allowing users to select a particular item from a print layout.
A print layout parameter, allowing users to select a print layout.
A map layer parameter for processing algorithms.
A map theme parameter for processing algorithms, allowing users to select an existing map theme from ...
A table (matrix) parameter for processing algorithms.
A mesh layer parameter for processing algorithms.
A parameter for processing algorithms which accepts multiple map layers.
A numeric parameter for processing algorithms.
A point cloud layer attribute parameter for Processing algorithms.
A point cloud layer destination parameter, for specifying the destination path for a point cloud laye...
A point cloud layer parameter for processing algorithms.
A point parameter for processing algorithms.
A data provider connection parameter for processing algorithms, allowing users to select from availab...
A numeric range parameter for processing algorithms.
A raster layer destination parameter, for specifying the destination path for a raster layer created ...
A raster layer parameter for processing algorithms.
A double numeric parameter for map scale values.
A string parameter for processing algorithms.
An annotation layer parameter for processing algorithms.
An area parameter for processing algorithms.
A authentication configuration parameter for processing algorithms.
A raster band parameter for Processing algorithms.
A boolean parameter for processing algorithms.
A color parameter for Processing algorithms.
A coordinate operation parameter for Processing algorithms.
A crs parameter for processing algorithms.
A database schema name parameter for processing algorithms.
A database table name parameter for processing algorithms.
A datetime parameter for processing algorithms.
A distance parameter for processing algorithms.
A duration parameter for processing algorithms.
An enum based parameter for processing algorithms, allowing for selection from predefined values.
An expression parameter for processing algorithms.
A rectangular map extent parameter for processing algorithms.
A feature sink parameter for Processing algorithms.
An input feature source (such as vector layers) parameter for processing algorithms.
A vector layer or feature source field parameter for processing algorithms.
A generic file based destination parameter, for specifying the destination path for a file (non-map l...
An input file or folder parameter for processing algorithms.
A folder destination parameter, for specifying the destination path for a folder created by the algor...
A geometry parameter for processing algorithms.
A print layout item parameter for Processing algorithms.
A print layout parameter for Processing algorithms.
A generic map layer parameter for processing algorithms.
A map theme parameter for Processing algorithms.
A table (matrix) parameter for processing algorithms.
A mesh layer parameter for processing algorithms.
A parameter for processing algorithms which accepts multiple map layers.
A numeric parameter for processing algorithms.
A point cloud layer attribute parameter for Processing algorithms.
A pointcloud layer destination parameter, for specifying the destination path for a point cloud layer...
A point cloud layer parameter for processing algorithms.
A point parameter for processing algorithms.
A provider connection name parameter for processing algorithms.
A numeric range parameter for processing algorithms.
A raster layer destination parameter, for specifying the destination path for a raster layer created ...
A raster layer parameter for processing algorithms.
A scale parameter for processing algorithms.
A string parameter for processing algorithms.
A vector layer destination parameter, for specifying the destination path for a vector layer created ...
A vector layer parameter for processing algorithms.
A vector tile layer destination parameter, for specifying the destination path for a vector tile laye...
A volume parameter for processing algorithms.
Makes metadata of processing parameters available.
virtual QString name() const =0
A human readable and translatable short name for this parameter type.
virtual QStringList acceptedPythonTypes() const
Returns a list of the Python data types accepted as values for the parameter.
virtual QgsProcessingParameterDefinition * create(const QString &name) const =0
Creates a new parameter of this type.
virtual QString description() const =0
A human readable and translatable description for this parameter type.
virtual QString id() const =0
A static id for this type which will be used for storing this parameter type.
virtual QString className() const
Returns the corresponding class name for the parameter type.
virtual Qgis::ProcessingParameterTypeFlags flags() const
Determines if this parameter is available in the modeler.
virtual QStringList acceptedStringValues() const
Returns a descriptive list of the possible string values acceptable for the parameter.
virtual QString pythonImportString() const
Returns a valid Python import string for importing the corresponding parameter type,...
A vector layer destination parameter, for specifying the destination path for a vector layer created ...
A vector layer (with or without geometry) parameter for processing algorithms.
A vector tile layer destination parameter, for specifying the destination path for a vector tile laye...
A double numeric parameter for volume values.
#define SIP_FACTORY
Definition qgis_sip.h:76