• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

marble

  • sources
  • kde-4.14
  • kdeedu
  • marble
  • src
  • lib
  • marble
  • geodata
  • data
GeoDataAlias.cpp
Go to the documentation of this file.
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 2013 Sanjiban Bairagya <sanjiban22393@gmail.com>
9 //
10 
11 #include "GeoDataAlias.h"
12 #include "GeoDataTypes.h"
13 
14 namespace Marble {
15 
16 class GeoDataAliasPrivate
17 {
18 public:
19  QString m_sourceHref;
20  QString m_targetHref;
21 
22  GeoDataAliasPrivate();
23 };
24 
25 GeoDataAliasPrivate::GeoDataAliasPrivate() :
26  m_sourceHref(), m_targetHref()
27 {
28  // nothing to do
29 }
30 
31 GeoDataAlias::GeoDataAlias() : d( new GeoDataAliasPrivate )
32 {
33  // nothing to do
34 }
35 
36 GeoDataAlias::GeoDataAlias( const Marble::GeoDataAlias &other ) :
37  GeoNode( other ), d( new GeoDataAliasPrivate( *other.d ) )
38 {
39  // nothing to do
40 }
41 
42 GeoDataAlias &GeoDataAlias::operator=( const GeoDataAlias &other )
43 {
44  *d = *other.d;
45  return *this;
46 }
47 
48 bool GeoDataAlias::operator==( const GeoDataAlias &other ) const
49 {
50  return ( d->m_sourceHref == other.d->m_sourceHref ) && ( d->m_targetHref == other.d->m_targetHref );
51 }
52 
53 bool GeoDataAlias::operator!=( const GeoDataAlias &other ) const
54 {
55  return !this->operator==(other);
56 }
57 
58 GeoDataAlias::~GeoDataAlias()
59 {
60  delete d;
61 }
62 
63 const char *GeoDataAlias::nodeType() const
64 {
65  return GeoDataTypes::GeoDataAliasType;
66 }
67 
68 QString GeoDataAlias::sourceHref() const
69 {
70  return d->m_sourceHref;
71 }
72 
73 QString GeoDataAlias::targetHref() const
74 {
75  return d->m_targetHref;
76 }
77 
78 void GeoDataAlias::setSourceHref( const QString& sourceHref )
79 {
80  d->m_sourceHref = sourceHref;
81 }
82 
83 void GeoDataAlias::setTargetHref( const QString& targetHref )
84 {
85  d->m_targetHref = targetHref;
86 }
87 
88 }
Marble::GeoDataAlias::GeoDataAlias
GeoDataAlias()
Definition: GeoDataAlias.cpp:31
Marble::GeoDataAlias::setSourceHref
void setSourceHref(const QString &sourceHref)
Definition: GeoDataAlias.cpp:78
Marble::GeoDataAlias::nodeType
virtual const char * nodeType() const
Provides type information for downcasting a GeoNode.
Definition: GeoDataAlias.cpp:63
Marble::GeoNode
A shared base class for all classes that are mapped to a specific tag (ie.
Definition: GeoDocument.h:60
Marble::GeoDataAlias::operator!=
bool operator!=(const GeoDataAlias &other) const
Definition: GeoDataAlias.cpp:53
Marble::GeoDataAlias::sourceHref
QString sourceHref() const
Definition: GeoDataAlias.cpp:68
Marble::GeoDataAlias::targetHref
QString targetHref() const
Definition: GeoDataAlias.cpp:73
Marble::GeoDataAlias::setTargetHref
void setTargetHref(const QString &targetHref)
Definition: GeoDataAlias.cpp:83
QString
Marble::GeoDataAlias::operator==
bool operator==(const GeoDataAlias &other) const
Definition: GeoDataAlias.cpp:48
Marble::GeoDataAlias::~GeoDataAlias
~GeoDataAlias()
Definition: GeoDataAlias.cpp:58
Marble::GeoDataTypes::GeoDataAliasType
const char * GeoDataAliasType
the following const char* XXType are used to provide RTTI to the GeoData for downcasting to the good ...
Definition: GeoDataTypes.cpp:30
GeoDataAlias.h
Marble::GeoDataAlias::operator=
GeoDataAlias & operator=(const GeoDataAlias &other)
Definition: GeoDataAlias.cpp:42
GeoDataTypes.h
Marble::GeoDataAlias
Definition: GeoDataAlias.h:22
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:13:39 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

marble

Skip menu "marble"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal