QGIS API Documentation
4.3.0-Master (16eddb2670e)
Toggle main menu visibility
Loading...
Searching...
No Matches
src
core
raster
qgsrasterchecker.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsrasterchecker.h - compare two rasters
3
--------------------------------------
4
Date : 5 Sep 2012
5
Copyright : (C) 2012 by Radim Blazek
6
email : radim dot blazek 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 QGSRASTERCHECKER_H
17
#define QGSRASTERCHECKER_H
18
19
#include "
qgis.h
"
20
#include "qgis_core.h"
21
22
#include <QDir>
23
#include <QString>
24
25
class
QImage;
26
33
class
CORE_EXPORT
QgsRasterChecker
34
{
35
public
:
36
QgsRasterChecker
();
37
38
QString
report
()
const
{
return
mReport; }
39
47
bool
runTest(
const
QString &verifiedKey, QString verifiedUri,
const
QString &expectedKey, QString expectedUri );
48
49
private
:
50
QString mReport;
51
QString mExpectedUri;
52
QString mCheckedUri;
53
QString mTabStyle;
54
QString mCellStyle;
55
QString mOkStyle;
56
QString mErrStyle;
57
QString mErrMsgStyle;
58
59
// Log error in html
60
void
error(
const
QString &message, QString &report );
61
// compare values and add table row in html report, set ok to false if not equal
62
QString compareHead();
63
bool
compare(
double
verifiedVal,
double
expectedVal,
double
tolerance );
64
void
compare(
const
QString ¶mName,
int
verifiedVal,
int
expectedVal, QString &report,
bool
&ok );
65
66
#ifndef SIP_RUN
67
73
void
compare(
const
QString ¶mName,
Qgis::DataType
verifiedVal,
Qgis::DataType
expectedVal, QString &report,
bool
&ok );
74
#endif
75
76
void
compare(
const
QString ¶mName,
double
verifiedVal,
double
expectedVal, QString &report,
bool
&ok,
double
tolerance = 0 );
77
void
compareRow(
78
const
QString ¶mName,
const
QString &verifiedVal,
const
QString &expectedVal, QString &report,
bool
ok,
const
QString &difference = QString(),
const
QString &tolerance = QString()
79
);
80
double
tolerance(
double
val,
int
places = 6 );
81
};
// class QgsRasterChecker
82
83
// clazy:excludeall=qstring-allocations
84
85
#endif
Qgis::DataType
DataType
Raster data types.
Definition
qgis.h:413
QgsRasterChecker::QgsRasterChecker
QgsRasterChecker()
Definition
qgsrasterchecker.cpp:34
QgsRasterChecker::report
QString report() const
Definition
qgsrasterchecker.h:38
qgis.h
Generated on
for QGIS API Documentation by
1.17.0