1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2024-11-25 04:05:53 +01:00
GPXSee/src/map/coordinatesystem.h

32 lines
715 B
C
Raw Normal View History

#ifndef COORDINATESYSTEM_H
#define COORDINATESYSTEM_H
2018-04-07 18:42:25 +02:00
#include <QDebug>
class CoordinateSystem
{
public:
2018-04-05 21:13:48 +02:00
enum AxisOrder {Unknown, XY, YX};
CoordinateSystem() : _axisOrder(Unknown) {}
2018-04-07 18:42:25 +02:00
CoordinateSystem(AxisOrder axisOrder) : _axisOrder(axisOrder) {}
CoordinateSystem(int code);
bool operator==(const CoordinateSystem &other) const
{return (_axisOrder == other._axisOrder);}
2018-05-16 18:52:48 +02:00
bool isNull() const {return (_axisOrder == Unknown);}
bool isValid() const {return (_axisOrder != Unknown);}
AxisOrder axisOrder() const {return _axisOrder;}
private:
AxisOrder _axisOrder;
};
2018-04-07 18:42:25 +02:00
#ifndef QT_NO_DEBUG
QDebug operator<<(QDebug dbg, const CoordinateSystem &cs);
#endif // QT_NO_DEBUG
#endif // COORDINATESYSTEM_H