From c539242efa11538e5e3f91bf3ff2f0de1c526bed Mon Sep 17 00:00:00 2001 From: Steru Date: Mon, 5 Aug 2024 14:47:45 +0200 Subject: Added method to reverse order and statistic method. --- src/discipline/Sport.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/discipline/Sport.h') diff --git a/src/discipline/Sport.h b/src/discipline/Sport.h index 9175ad0..147f6e8 100644 --- a/src/discipline/Sport.h +++ b/src/discipline/Sport.h @@ -33,6 +33,10 @@ public: void sortByName(QJsonArray &competitors); void sortByCountry(QJsonArray &competitors); void sortByResult(QJsonArray &competitors); + void reverseOrder(QJsonArray &competitors); + + // statistic function(s) + void addRelativeToFirst(QJsonArray &competitors); void setDiscipline(QJsonObject discipline) { this->discipline = QJsonObject(discipline); @@ -80,6 +84,8 @@ private: bool validateDiscipline(); QJsonObject createCompetitorWithMedals(QJsonObject medalComp); + float calcRelativeStat(QString ref, QString val); + }; -- cgit v1.2.3