Marble::GeoDataObject
#include <GeoDataObject.h>
Public Member Functions | |
GeoDataObject (const GeoDataObject &) | |
QString | id () const |
GeoDataObject & | operator= (const GeoDataObject &) |
void | pack (QDataStream &stream) const override |
GeoDataObject * | parent () |
const GeoDataObject * | parent () const |
QString | resolvePath (const QString &relativePath) const |
void | setId (const QString &value) |
void | setParent (GeoDataObject *parent) |
void | setTargetId (const QString &value) |
QString | targetId () const |
void | unpack (QDataStream &steam) override |
Public Member Functions inherited from Marble::GeoNode | |
virtual const char * | nodeType () const =0 |
Protected Member Functions | |
virtual bool | equals (const GeoDataObject &other) const |
Detailed Description
A base class for all geodata objects.
GeoDataObject is the base class for all geodata classes. It is never instantiated by itself, but is always used as part of a derived object.
The Geodata objects are all modeled after the Google KML files as defined in https://developers.google.com/kml/documentation/kmlreference.
A GeoDataObject contains 2 properties, both corresponding directly to tags in the KML files: the id, which is a unique identifier of the object, and a targetId which is used to reference other objects that have already been loaded.
The id property must only be set if the Update mechanism of KML is used, which is currently not supported by Marble.
Definition at line 42 of file GeoDataObject.h.
Constructor & Destructor Documentation
◆ GeoDataObject() [1/2]
Marble::GeoDataObject::GeoDataObject | ( | ) |
Definition at line 36 of file GeoDataObject.cpp.
◆ GeoDataObject() [2/2]
Marble::GeoDataObject::GeoDataObject | ( | const GeoDataObject & | other | ) |
Definition at line 43 of file GeoDataObject.cpp.
◆ ~GeoDataObject()
|
override |
Definition at line 56 of file GeoDataObject.cpp.
Member Function Documentation
◆ equals()
|
protectedvirtual |
Compares the value of id and targetId of the two objects.
- Returns
- true if they these values are equal or false otherwise
Reimplemented in Marble::GeoDataAbstractView, Marble::GeoDataFeature, and Marble::GeoDataGeometry.
Definition at line 127 of file GeoDataObject.cpp.
◆ id()
QString Marble::GeoDataObject::id | ( | ) | const |
Get the id of the object.
Definition at line 76 of file GeoDataObject.cpp.
◆ operator=()
GeoDataObject & Marble::GeoDataObject::operator= | ( | const GeoDataObject & | rhs | ) |
Definition at line 50 of file GeoDataObject.cpp.
◆ pack()
|
override |
Reimplemented from Serializable.
Definition at line 115 of file GeoDataObject.cpp.
◆ parent() [1/2]
GeoDataObject * Marble::GeoDataObject::parent | ( | ) |
Definition at line 66 of file GeoDataObject.cpp.
◆ parent() [2/2]
const GeoDataObject * Marble::GeoDataObject::parent | ( | ) | const |
Provides the parent of the object in GeoDataContainers.
Definition at line 61 of file GeoDataObject.cpp.
◆ resolvePath()
Definition at line 96 of file GeoDataObject.cpp.
◆ setId()
void Marble::GeoDataObject::setId | ( | const QString & | value | ) |
Set the id of the object.
- Parameters
-
value the new id value
Definition at line 81 of file GeoDataObject.cpp.
◆ setParent()
void Marble::GeoDataObject::setParent | ( | GeoDataObject * | parent | ) |
Sets the parent of the object.
Definition at line 71 of file GeoDataObject.cpp.
◆ setTargetId()
void Marble::GeoDataObject::setTargetId | ( | const QString & | value | ) |
set a new targetId of this object
- Parameters
-
value the new targetId value
Definition at line 91 of file GeoDataObject.cpp.
◆ targetId()
QString Marble::GeoDataObject::targetId | ( | ) | const |
Get the targetId of the object to be replaced.
Definition at line 86 of file GeoDataObject.cpp.
◆ unpack()
|
override |
Reimplemented from Serializable.
Definition at line 121 of file GeoDataObject.cpp.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 4 2024 16:37:04 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.