Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qgeomapversion.cpp
Go to the documentation of this file.
1
// Copyright (C) 2014 Appello Systems AB.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4
#
include
"qgeomapversion.h"
5
6
#
include
<
QJsonDocument
>
7
8
QT_BEGIN_NAMESPACE
9
10
QGeoMapVersion::QGeoMapVersion()
11
: m_version(-1) {}
12
13
bool
QGeoMapVersion::isNewVersion(
const
QJsonObject &newVersionData)
const
14
{
15
return
m_versionData != newVersionData;
16
}
17
18
int
QGeoMapVersion::version()
const
19
{
20
return
m_version;
21
}
22
23
void
QGeoMapVersion::setVersion(
int
version)
24
{
25
m_version = version;
26
}
27
28
void
QGeoMapVersion::setVersionData(
const
QJsonObject &versionData)
29
{
30
m_versionData = versionData;
31
}
32
33
34
QByteArray QGeoMapVersion::toJson()
const
35
{
36
37
QJsonObject object;
38
object[QLatin1String(
"version"
)] = m_version;
39
object[QLatin1String(
"data"
)] = m_versionData;
40
41
QJsonDocument document(object);
42
43
return
document.toJson();
44
}
45
46
QT_END_NAMESPACE
QPlatformGraphicsBufferHelper
\inmodule QtGui
qtlocation
src
plugins
geoservices
nokia
qgeomapversion.cpp
Generated on
for Qt by
1.14.0