Marble

GeoDataPoint.h
1 //
2 // This file is part of the Marble Virtual Globe.
3 //
4 // This program is free software licensed under the GNU LGPL. You can
5 // find a copy of this license in LICENSE.txt in the top directory of
6 // the source code.
7 //
8 // Copyright 2006-2007 Torsten Rahn <[email protected]>
9 // Copyright 2007 Inge Wallin <[email protected]>
10 // Copyright 2008 Patrick Spendrin <[email protected]>
11 //
12 
13 
14 #ifndef MARBLE_GEODATAPOINT_H
15 #define MARBLE_GEODATAPOINT_H
16 
17 #include <QMetaType>
18 #include <QVector>
19 
20 #include <cmath>
21 
22 #include "geodata_export.h"
23 #include "GeoDataGeometry.h"
24 #include "GeoDataCoordinates.h"
25 
26 namespace Marble
27 {
28 
29 class GeoDataPointPrivate;
30 
47 class GEODATA_EXPORT GeoDataPoint : public GeoDataGeometry
48 {
49  public:
52 
53  GeoDataPoint( const GeoDataPoint& other );
54  explicit GeoDataPoint( const GeoDataCoordinates& other );
55  GeoDataPoint();
56 
65  GeoDataPoint( qreal lon, qreal lat, qreal alt = 0,
66  GeoDataPoint::Unit _unit = GeoDataCoordinates::Radian );
67 
68  ~GeoDataPoint() override;
69 
70  EnumGeometryId geometryId() const override;
71 
72  GeoDataGeometry *copy() const override;
73 
74  bool operator==( const GeoDataPoint &other ) const;
75  bool operator!=( const GeoDataPoint &other ) const;
76 
77  void setCoordinates( const GeoDataCoordinates &coordinates );
78 
79  const GeoDataCoordinates& coordinates() const;
80 
82  const char* nodeType() const override;
83 
84  // Type definitions
86 
87 
88  // Serialize the Placemark to @p stream
89  void pack( QDataStream& stream ) const override;
90  // Unserialize the Placemark from @p stream
91  void unpack( QDataStream& stream ) override;
92 
93  virtual void detach();
94 
95  private:
96  Q_DECLARE_PRIVATE(GeoDataPoint)
97 };
98 
99 }
100 
101 Q_DECLARE_METATYPE( Marble::GeoDataPoint )
102 
103 #endif
Unit
enum used constructor to specify the units used
A Geometry object representing a 3d point.
Definition: GeoDataPoint.h:47
A 3d point representation.
Binds a QML item to a specific geodetic location in screen coordinates.
A base class for all geodata features.
Notation
enum used to specify the notation / numerical system
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Sat Jul 4 2020 23:20:16 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.