Improve FIT locations support
[GPXSee.git] / src / data / igcparser.h
blob87f3d60b401c2fa8e181b1ed3a2d6a3a3577627e
1 #ifndef IGCPARSER_H
2 #define IGCPARSER_H
4 #include <QDate>
5 #include <QTime>
6 #include "parser.h"
9 class IGCParser : public Parser
11 public:
12 IGCParser() : _errorLine(0) {}
14 bool parse(QFile *file, QList<TrackData> &tracks, QList<RouteData> &routes,
15 QList<Area> &polygons, QVector<Waypoint> &waypoints);
16 QString errorString() const {return _errorString;}
17 int errorLine() const {return _errorLine;}
19 private:
20 struct CTX {
21 QDate date;
22 QTime time;
25 bool readHRecord(CTX &ctx, const char *line, int len);
26 bool readBRecord(CTX &ctx, const char *line, int len, SegmentData &segment);
27 bool readCRecord(const char *line, int len, RouteData &route);
29 int _errorLine;
30 QString _errorString;
33 #endif // IGCPARSER_H