Ilwis-Objects  1.0
GIS and Remote Sensing framework for data access and processing
 All Classes Functions Enumerations Pages
projection.h
1 #ifndef PROJECTION_H
2 #define PROJECTION_H
3 
4 #include "Kernel_global.h"
5 
6 namespace Ilwis {
7 
8 class ProjectionImplementation;
9 class ConventionalCoordinateSystem;
10 
11 class KERNELSHARED_EXPORT Projection : public IlwisObject
12 {
13 public:
14  enum ProjectionParamValue { pvNONE, pvX0, pvY0, pvLON0,
15  pvLATTS, pvLAT0, pvK0, pvNORTH,
16  pvZONE, pvLAT1, pvLAT2, pvHEIGHT,
17  pvTILTED, pvTILT, pvAZIMYAXIS, pvAZIMCLINE,
18  pvPOLE, pvNORIENTED, pvELLCODE, pvLAST };
19 
20  enum FindMatch{fmNoItem, fmNoValue,fmMatch};
21 
22  Projection();
23  virtual ~Projection();
24 
25  virtual Coordinate latlon2coord(const LatLon&) const;
26  virtual LatLon coord2latlon(const Coordinate&) const;
27 
28  bool prepare(const QString& parms);
29  bool prepare();
30  void setImplementation(ProjectionImplementation *impl);
31 
32  QString authority() const;
33  void setAuthority(const QString &auth);
34  QString wkt() const;
35  void setWkt(const QString &wkt);
36  QString toProj4() const;
37 
38  IlwisTypes ilwisType() const;
39 
40  QVariant parameter(Projection::ProjectionParamValue type) const;
41  void setParameter(Projection::ProjectionParamValue type, const QVariant& value);
42  QString parameterName(Projection::ProjectionParamValue pv) const;
43 
44  bool isEqual(const IlwisObject* obj) const;
45  bool isValid() const;
46 
47  void setCoordinateSystem(ConventionalCoordinateSystem *csy);
48 protected:
49  static Projection::FindMatch find(const QString& v1, const QString& value) ;
50 
51 private:
52  QString _wkt;
53  QString _authority;
54  QScopedPointer<ProjectionImplementation> _implementation;
55 };
57 }
58 
59 
60 
61 #endif // PROJECTION_H