1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2024-10-06 23:03:22 +02:00
GPXSee/src/map/pcs.h

42 lines
890 B
C
Raw Normal View History

2018-01-08 23:47:45 +01:00
#ifndef PCS_H
#define PCS_H
#include <QDebug>
#include <QList>
#include "gcs.h"
2018-01-08 23:47:45 +01:00
#include "projection.h"
class PCS
{
public:
PCS() : _gcs(0) {}
PCS(const GCS *gcs, const Projection::Method &m, const Projection::Setup &s)
: _gcs(gcs), _method(m), _setup(s) {}
PCS(const GCS *gcs, int proj);
const GCS *gcs() const {return _gcs;}
2018-01-08 23:47:45 +01:00
const Projection::Method &method() const {return _method;}
const Projection::Setup &setup() const {return _setup;}
bool isNull() const
{return (_gcs->isNull() && _method.isNull() && _setup.isNull());}
2018-01-08 23:47:45 +01:00
static void loadList(const QString &path);
static const PCS *pcs(int id);
static const PCS *pcs(const GCS *gcs, int proj);
2018-01-08 23:47:45 +01:00
private:
class Entry;
const GCS *_gcs;
2018-01-08 23:47:45 +01:00
Projection::Method _method;
Projection::Setup _setup;
static QList<Entry> _pcss;
static GCS _nullGCS;
2018-01-08 23:47:45 +01:00
};
QDebug operator<<(QDebug dbg, const PCS &pcs);
#endif // PCS_H