7#include "GeoDataLink.h"
8#include "GeoDataTypes.h"
13class GeoDataLinkPrivate
17 GeoDataLink::RefreshMode m_refreshMode;
18 qreal m_refreshInterval;
19 GeoDataLink::ViewRefreshMode m_viewRefreshMode;
20 qreal m_viewRefreshTime;
21 qreal m_viewBoundScale;
28GeoDataLinkPrivate::GeoDataLinkPrivate()
30 , m_refreshMode(GeoDataLink::OnChange)
31 , m_refreshInterval(4.0)
32 , m_viewRefreshMode(GeoDataLink::Never)
33 , m_viewRefreshTime(4.0)
34 , m_viewBoundScale(1.0)
35 , m_viewFormat(QStringLiteral(
"BBOX=[bboxWest],[bboxSouth],[bboxEast],[bboxNorth]"))
41GeoDataLink::GeoDataLink()
42 : d(new GeoDataLinkPrivate)
47GeoDataLink::GeoDataLink(
const Marble::GeoDataLink &other)
48 : GeoDataObject(other)
49 , d(new GeoDataLinkPrivate(*other.d))
54GeoDataLink &GeoDataLink::operator=(
const GeoDataLink &other)
56 GeoDataObject::operator=(other);
61bool GeoDataLink::operator==(
const GeoDataLink &other)
const
63 return equals(other) && d->m_href == other.d->m_href && d->m_refreshMode == other.d->m_refreshMode && d->m_refreshInterval == other.d->m_refreshInterval
64 && d->m_viewRefreshMode == other.d->m_viewRefreshMode && d->m_viewRefreshTime == other.d->m_viewRefreshTime
65 && d->m_viewBoundScale == other.d->m_viewBoundScale && d->m_viewFormat == other.d->m_viewFormat && d->m_httpQuery == other.d->m_httpQuery;
68bool GeoDataLink::operator!=(
const GeoDataLink &other)
const
73GeoDataLink::~GeoDataLink()
78const char *GeoDataLink::nodeType()
const
80 return GeoDataTypes::GeoDataLinkType;
83QString GeoDataLink::href()
const
88void GeoDataLink::setHref(
const QString &href)
93GeoDataLink::RefreshMode GeoDataLink::refreshMode()
const
95 return d->m_refreshMode;
98void GeoDataLink::setRefreshMode(RefreshMode refreshMode)
100 d->m_refreshMode = refreshMode;
103qreal GeoDataLink::refreshInterval()
const
105 return d->m_refreshInterval;
108void GeoDataLink::setRefreshInterval(qreal refreshInterval)
110 d->m_refreshInterval = refreshInterval;
113GeoDataLink::ViewRefreshMode GeoDataLink::viewRefreshMode()
const
115 return d->m_viewRefreshMode;
118void GeoDataLink::setViewRefreshMode(ViewRefreshMode viewRefreshMode)
120 d->m_viewRefreshMode = viewRefreshMode;
123qreal GeoDataLink::viewRefreshTime()
const
125 return d->m_viewRefreshTime;
128void GeoDataLink::setViewRefreshTime(qreal viewRefreshTime)
130 d->m_viewRefreshTime = viewRefreshTime;
133qreal GeoDataLink::viewBoundScale()
const
135 return d->m_viewBoundScale;
138void GeoDataLink::setViewBoundScale(qreal viewBoundScale)
140 d->m_viewBoundScale = viewBoundScale;
143QString GeoDataLink::viewFormat()
const
145 return d->m_viewFormat;
148void GeoDataLink::setViewFormat(
const QString &viewFormat)
150 d->m_viewFormat = viewFormat;
153QString GeoDataLink::httpQuery()
const
155 return d->m_httpQuery;
157void GeoDataLink::setHttpQuery(
const QString &httpQuery)
159 d->m_httpQuery = httpQuery;
bool equals(const QVariant &lhs, const QVariant &rhs)
bool operator==(const StyleDelim &l, const StyleDelim &r)
Binds a QML item to a specific geodetic location in screen coordinates.