QGIS/python/analysis/vector/qgszonalstatistics.sip

74 lines
2.2 KiB
Plaintext
Raw Normal View History

2017-05-21 22:18:04 +07:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/analysis/vector/qgszonalstatistics.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/
class QgsZonalStatistics
{
2017-05-21 22:18:04 +07:00
%Docstring
A class that calculates raster statistics (count, sum, mean) for a polygon or multipolygon layer and appends the results as attributes*
%End
2017-05-21 22:18:04 +07:00
%TypeHeaderCode
#include "qgszonalstatistics.h"
%End
public:
enum Statistic
{
2017-05-21 22:18:04 +07:00
Count,
Sum,
Mean,
Median,
StDev,
Min,
Max,
Range,
Minority,
Majority,
Variety,
Variance,
All
};
typedef QFlags<QgsZonalStatistics::Statistic> Statistics;
QgsZonalStatistics( QgsVectorLayer *polygonLayer,
QgsRasterLayer *rasterLayer,
const QString &attributePrefix = "",
int rasterBand = 1,
QgsZonalStatistics::Statistics stats = QgsZonalStatistics::Statistics( QgsZonalStatistics::Count | QgsZonalStatistics::Sum | QgsZonalStatistics::Mean ) );
2017-05-21 22:18:04 +07:00
%Docstring
Constructor for QgsZonalStatistics.
%End
int calculateStatistics( QgsFeedback *feedback );
2017-05-21 22:18:04 +07:00
%Docstring
Starts the calculation
:return: 0 in case of success*
:rtype: int
%End
public:
};
QFlags<QgsZonalStatistics::Statistic> operator|(QgsZonalStatistics::Statistic f1, QFlags<QgsZonalStatistics::Statistic> f2);
2017-05-21 22:18:04 +07:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/analysis/vector/qgszonalstatistics.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/