Marble

KmlRegionTagWriter.cpp
1 // SPDX-License-Identifier: LGPL-2.1-or-later
2 //
3 // SPDX-FileCopyrightText: 2012 Mayank Madan <[email protected]>
4 //
5 
6 #include "KmlRegionTagWriter.h"
7 
8 #include "GeoDataRegion.h"
9 #include "GeoDataLatLonAltBox.h"
10 #include "GeoDataTypes.h"
11 #include "GeoDataLod.h"
12 #include "GeoWriter.h"
13 #include "KmlElementDictionary.h"
14 #include "KmlLatLonAltBoxWriter.h"
15 #include "KmlLodTagWriter.h"
16 #include "KmlObjectTagWriter.h"
17 
18 namespace Marble
19 {
20 
21 static GeoTagWriterRegistrar s_writerRegion(
22  GeoTagWriter::QualifiedName( GeoDataTypes::GeoDataRegionType,
23  kml::kmlTag_nameSpaceOgc22 ),
24  new KmlRegionTagWriter);
25 
26 bool KmlRegionTagWriter::write( const GeoNode *node, GeoWriter& writer ) const
27 {
28  const GeoDataRegion *region = static_cast<const GeoDataRegion*>( node );
29  writer.writeStartElement( kml::kmlTag_Region );
30  KmlObjectTagWriter::writeIdentifiers( writer, region );
31  writeElement( &region->latLonAltBox(), writer );
32  writeElement( &region->lod(), writer );
33  writer.writeEndElement();
34  return true;
35 }
36 
37 }
38 
QPair< QString, QString > QualifiedName
Object Name and Namespace Pair This type is intended to be used in a similar way to.
Definition: GeoTagWriter.h:44
Binds a QML item to a specific geodetic location in screen coordinates.
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Tue Oct 3 2023 04:09:48 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.