• 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
GeoDataResourceMap.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 "GeoDataResourceMap.h"
12 #include "GeoDataTypes.h"
13 
14 namespace Marble {
15 
16 class GeoDataResourceMapPrivate
17 {
18 public:
19  GeoDataAlias m_alias;
20  GeoDataResourceMapPrivate();
21 };
22 
23 GeoDataResourceMapPrivate::GeoDataResourceMapPrivate() :
24  m_alias()
25 {
26  // nothing to do
27 }
28 
29 GeoDataResourceMap::GeoDataResourceMap() : d( new GeoDataResourceMapPrivate )
30 {
31  // nothing to do
32 }
33 
34 GeoDataResourceMap::GeoDataResourceMap( const Marble::GeoDataResourceMap &other ) :
35  GeoNode( other ), d( new GeoDataResourceMapPrivate( *other.d ) )
36 {
37  // nothing to do
38 }
39 
40 GeoDataResourceMap &GeoDataResourceMap::operator=( const GeoDataResourceMap &other )
41 {
42  *d = *other.d;
43  return *this;
44 }
45 
46 bool GeoDataResourceMap::operator==( const GeoDataResourceMap &other ) const
47 {
48  return d->m_alias == other.d->m_alias;
49 }
50 
51 bool GeoDataResourceMap::operator!=( const GeoDataResourceMap &other ) const
52 {
53  return !this->operator==( other );
54 }
55 
56 GeoDataResourceMap::~GeoDataResourceMap()
57 {
58  delete d;
59 }
60 
61 const char *GeoDataResourceMap::nodeType() const
62 {
63  return GeoDataTypes::GeoDataResourceMapType;
64 }
65 
66 const GeoDataAlias &GeoDataResourceMap::alias() const
67 {
68  return d->m_alias;
69 }
70 
71 GeoDataAlias &GeoDataResourceMap::alias()
72 {
73  return d->m_alias;
74 }
75 
76 void GeoDataResourceMap::setAlias( const GeoDataAlias &alias )
77 {
78  d->m_alias = alias;
79 }
80 
81 QString GeoDataResourceMap::sourceHref() const
82 {
83  return d->m_alias.sourceHref();
84 }
85 
86 QString GeoDataResourceMap::targetHref() const
87 {
88  return d->m_alias.targetHref();
89 }
90 
91 void GeoDataResourceMap::setSourceHref( const QString& sourceHref )
92 {
93  d->m_alias.setSourceHref( sourceHref );
94 }
95 
96 void GeoDataResourceMap::setTargetHref( const QString& targetHref )
97 {
98  d->m_alias.setTargetHref( targetHref );
99 }
100 
101 
102 
103 }
GeoDataResourceMap.h
Marble::GeoNode
A shared base class for all classes that are mapped to a specific tag (ie.
Definition: GeoDocument.h:60
Marble::GeoDataResourceMap::sourceHref
QString sourceHref() const
Definition: GeoDataResourceMap.cpp:81
Marble::GeoDataResourceMap::setAlias
void setAlias(const GeoDataAlias &alias)
Definition: GeoDataResourceMap.cpp:76
Marble::GeoDataResourceMap::~GeoDataResourceMap
~GeoDataResourceMap()
Definition: GeoDataResourceMap.cpp:56
Marble::GeoDataResourceMap::alias
const GeoDataAlias & alias() const
Definition: GeoDataResourceMap.cpp:66
Marble::GeoDataResourceMap::operator==
bool operator==(const GeoDataResourceMap &other) const
Definition: GeoDataResourceMap.cpp:46
Marble::GeoDataResourceMap::targetHref
QString targetHref() const
Definition: GeoDataResourceMap.cpp:86
Marble::GeoDataResourceMap::setTargetHref
void setTargetHref(const QString &targetHref)
Definition: GeoDataResourceMap.cpp:96
QString
Marble::GeoDataResourceMap::setSourceHref
void setSourceHref(const QString &sourceHref)
Definition: GeoDataResourceMap.cpp:91
Marble::GeoDataResourceMap::nodeType
virtual const char * nodeType() const
Provides type information for downcasting a GeoNode.
Definition: GeoDataResourceMap.cpp:61
Marble::GeoDataResourceMap::GeoDataResourceMap
GeoDataResourceMap()
Definition: GeoDataResourceMap.cpp:29
Marble::GeoDataResourceMap::operator!=
bool operator!=(const GeoDataResourceMap &other) const
Definition: GeoDataResourceMap.cpp:51
Marble::GeoDataResourceMap
Definition: GeoDataResourceMap.h:22
Marble::GeoDataResourceMap::operator=
GeoDataResourceMap & operator=(const GeoDataResourceMap &other)
Definition: GeoDataResourceMap.cpp:40
Marble::GeoDataTypes::GeoDataResourceMapType
const char * GeoDataResourceMapType
Definition: GeoDataTypes.cpp:72
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