| openPilotLog

processflights.h
1 #ifndef PROCESSFLIGHTS_H
2 #define PROCESSFLIGHTS_H
3 #include <QtCore>
4 #include <src/opl.h>
5
6 class ProcessFlights
7 {
8 public:
9 ProcessFlights(const QVector<QStringList> &raw_csv_data,
10 const QHash<QString, int> &processed_pilots_ids,
11 const QHash<QString, int> &processed_tails_ids)
12 : rawData(raw_csv_data),
13 processedPilotsIds(processed_pilots_ids),
14 processedTailsIds(processed_tails_ids){};
15
16 void init(){
17 parseRawData();
18 processParsedData();
19 };
20 QVector<QHash<QString, QVariant> > getProcessedFlights() const;
21
22 private:
23 void parseRawData();
24 void processParsedData();
25 QVector<QStringList> rawData;
26 QVector<QStringList> rawFlightData;
27
28 QVector<QHash<QString, QVariant>> processedFlights;
29
30 QHash<QString, int> processedPilotsIds;
31 QHash<QString, int> processedTailsIds;
32 };
33
34 #endif // PROCESSFLIGHTS_H
ProcessFlights
Definition: processflights.h:7