QGIS API Documentation 4.3.0-Master (729d6602d19)
Loading...
Searching...
No Matches
qgsprocessingparameterinterpolationpixelsize.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsprocessingparameterinterpolationpixelsize.h
3 ---------------------
4 Date : August 2026
5 Copyright : (C) 2026 by Nyall Dawson
6 Email : nyall dot dawson at gmail dot com
7 ***************************************************************************
8 * *
9 * This program is free software; you can redistribute it and/or modify *
10 * it under the terms of the GNU General Public License as published by *
11 * the Free Software Foundation; either version 2 of the License, or *
12 * (at your option) any later version. *
13 * *
14 ***************************************************************************/
15
16#ifndef QGSPROCESSINGPARAMETERINTERPOLATIONPIXELSIZE_H
17#define QGSPROCESSINGPARAMETERINTERPOLATIONPIXELSIZE_H
18
22
23#include <QString>
24
25using namespace Qt::StringLiterals;
26
27
35{
36 public:
39 const QString &name,
40 const QString &description = QString(),
41 const QString &interpolationSourceParameter = QString(),
42 const QString &extentParameter = QString(),
43 const QVariant &defaultValue = QVariant()
44 );
45
47 QString type() const override;
49 static QString typeName() { return u"interpolationpixelsize"_s; } // cppcheck-suppress duplInheritedMember
51
55 QString interpolationSourceParameter() const { return mInterpolationSourceParam; }
56
60 QString extentParameter() const { return mExtentParam; }
61
62 private:
63 QString mInterpolationSourceParam;
64 QString mExtentParam;
65};
66
67#ifndef SIP_RUN
69
77class CORE_EXPORT QgsProcessingParameterTypeInterpolationPixelSize : public QgsProcessingParameterType
78{
79 public:
80 QgsProcessingParameterDefinition *create( const QString &name ) const override SIP_FACTORY { return new QgsProcessingParameterInterpolationPixelSize( name ); }
81
82 QString description() const override { return QCoreApplication::translate( "Processing", "An input allowing setting the pixel size for interpolation algorithms." ); }
83
84 QString name() const override { return QCoreApplication::translate( "Processing", "Interpolation Pixel Size" ); }
85
86 QString id() const override { return QgsProcessingParameterInterpolationPixelSize::typeName(); }
87
88 QString pythonImportString() const override { return u"from qgis.core import QgsProcessingParameterInterpolationPixelSize"_s; }
89
90 QString className() const override { return u"QgsProcessingParameterInterpolationPixelSize"_s; }
91
92 QStringList acceptedPythonTypes() const override { return QStringList() << u"int"_s << u"float"_s; }
93
94 QStringList acceptedStringValues() const override { return QStringList() << QObject::tr( "A numeric value" ); }
95
96 QStringList acceptedParameterTypes() const override
97 {
98 return QStringList()
106 }
107
108 QStringList acceptedOutputTypes() const override
109 {
111 }
112
113 QColor modelColor() const override { return QColor( 34, 157, 214 ); /* blue */ };
114};
115
117#endif
118
119#endif // QGSPROCESSINGPARAMETERINTERPOLATIONPIXELSIZE_H
static QString typeName()
Returns the type name for the output class.
static QString typeName()
Returns the type name for the output class.
static QString typeName()
Returns the type name for the output class.
QVariant defaultValue() const
Returns the default value for the parameter.
QString description() const
Returns the description for the parameter.
QString name() const
Returns the name of the parameter.
virtual QColor modelColor() const
Returns the color to use for the parameter in model designer windows.
static QString typeName()
Returns the type name for the parameter class.
static QString typeName()
Returns the type name for the parameter class.
static QString typeName()
Returns the type name for the parameter class.
QgsProcessingParameterInterpolationPixelSize(const QString &name, const QString &description=QString(), const QString &interpolationSourceParameter=QString(), const QString &extentParameter=QString(), const QVariant &defaultValue=QVariant())
Constructor for QgsProcessingParameterInterpolationPixelSize.
QString extentParameter() const
Returns the linked extent parameter name.
QString interpolationSourceParameter() const
Returns the linked interpolation source parameter name.
QString asPythonString(QgsProcessing::PythonOutputType outputType=QgsProcessing::PythonOutputType::PythonQgsProcessingAlgorithmSubclass) const override
Returns the parameter definition as a Python command which can be used within a Python Processing scr...
QString type() const override
Unique parameter type name.
QgsProcessingParameterDefinition * clone() const override
Creates a clone of the parameter definition.
static QString typeName()
Returns the type name for the parameter class.
QgsProcessingParameterNumber(const QString &name, const QString &description=QString(), Qgis::ProcessingNumberParameterType type=Qgis::ProcessingNumberParameterType::Integer, const QVariant &defaultValue=QVariant(), bool optional=false, double minValue=std::numeric_limits< double >::lowest()+1, double maxValue=std::numeric_limits< double >::max())
Constructor for QgsProcessingParameterNumber.
static QString typeName()
Returns the type name for the parameter class.
static QString typeName()
Returns the type name for the parameter class.
Makes metadata of processing parameters available.
static QString typeName()
Returns the type name for the parameter class.
PythonOutputType
Available Python output types.
@ PythonQgsProcessingAlgorithmSubclass
Full Python QgsProcessingAlgorithm subclass.
#define SIP_FACTORY
Definition qgis_sip.h:83