remove exclude skipped-base-class for numeric format classes

This commit is contained in:
Julien Cabieces 2022-05-09 10:48:21 +02:00 committed by Nyall Dawson
parent aa35c1cbdc
commit 29f4b0ed6f
8 changed files with 11 additions and 9 deletions

View File

@ -157,7 +157,6 @@ Sets the ``interpretation`` of the numbers being converted.
.. versionadded:: 3.26 .. versionadded:: 3.26
%End %End
}; };
%ModuleHeaderCode %ModuleHeaderCode
@ -273,6 +272,8 @@ Writes the format to an XML ``element``.
bool operator==( const QgsNumericFormat &other ) const; bool operator==( const QgsNumericFormat &other ) const;
bool operator!=( const QgsNumericFormat &other ) const; bool operator!=( const QgsNumericFormat &other ) const;
protected:
}; };
/************************************************************************ /************************************************************************

View File

@ -34,7 +34,7 @@ QString QgsBearingNumericFormat::visibleName() const
int QgsBearingNumericFormat::sortKey() int QgsBearingNumericFormat::sortKey()
{ {
return QgsNumericFormat::sortKey(); // clazy:exclude=skipped-base-method return DEFAULT_SORT_KEY;
} }
double QgsBearingNumericFormat::suggestSampleValue() const double QgsBearingNumericFormat::suggestSampleValue() const

View File

@ -55,7 +55,7 @@ QString QgsGeographicCoordinateNumericFormat::visibleName() const
int QgsGeographicCoordinateNumericFormat::sortKey() int QgsGeographicCoordinateNumericFormat::sortKey()
{ {
return QgsNumericFormat::sortKey(); // clazy:exclude=skipped-base-method return DEFAULT_SORT_KEY;
} }
double QgsGeographicCoordinateNumericFormat::suggestSampleValue() const double QgsGeographicCoordinateNumericFormat::suggestSampleValue() const

View File

@ -37,7 +37,7 @@ QString QgsCurrencyNumericFormat::visibleName() const
int QgsCurrencyNumericFormat::sortKey() int QgsCurrencyNumericFormat::sortKey()
{ {
return QgsNumericFormat::sortKey(); // clazy:exclude=skipped-base-method return DEFAULT_SORT_KEY;
} }
double QgsCurrencyNumericFormat::suggestSampleValue() const double QgsCurrencyNumericFormat::suggestSampleValue() const

View File

@ -47,7 +47,7 @@ QgsNumericFormatContext::QgsNumericFormatContext()
int QgsNumericFormat::sortKey() int QgsNumericFormat::sortKey()
{ {
return 100; return DEFAULT_SORT_KEY;
} }
double QgsNumericFormat::suggestSampleValue() const double QgsNumericFormat::suggestSampleValue() const
@ -72,4 +72,3 @@ bool QgsNumericFormat::operator!=( const QgsNumericFormat &other ) const
{ {
return !operator==( other ); return !operator==( other );
} }

View File

@ -222,7 +222,6 @@ class CORE_EXPORT QgsNumericFormatContext
mInterpretation = interpretation; mInterpretation = interpretation;
} }
private: private:
QChar mThousandsSep; QChar mThousandsSep;
QChar mDecimalSep; QChar mDecimalSep;
@ -350,6 +349,9 @@ class CORE_EXPORT QgsNumericFormat
bool operator==( const QgsNumericFormat &other ) const; bool operator==( const QgsNumericFormat &other ) const;
bool operator!=( const QgsNumericFormat &other ) const; bool operator!=( const QgsNumericFormat &other ) const;
protected:
static constexpr int DEFAULT_SORT_KEY = 100;
}; };
#endif // QGSNUMERICFORMAT_H #endif // QGSNUMERICFORMAT_H

View File

@ -34,7 +34,7 @@ QString QgsPercentageNumericFormat::visibleName() const
int QgsPercentageNumericFormat::sortKey() int QgsPercentageNumericFormat::sortKey()
{ {
return QgsNumericFormat::sortKey(); // clazy:exclude=skipped-base-method return DEFAULT_SORT_KEY;
} }
double QgsPercentageNumericFormat::suggestSampleValue() const double QgsPercentageNumericFormat::suggestSampleValue() const

View File

@ -35,7 +35,7 @@ QString QgsScientificNumericFormat::visibleName() const
int QgsScientificNumericFormat::sortKey() int QgsScientificNumericFormat::sortKey()
{ {
return QgsNumericFormat::sortKey(); // clazy:exclude=skipped-base-method return DEFAULT_SORT_KEY;
} }
QString QgsScientificNumericFormat::formatDouble( double value, const QgsNumericFormatContext &context ) const QString QgsScientificNumericFormat::formatDouble( double value, const QgsNumericFormatContext &context ) const