KOSMIndoorMap

io.h
1/*
2 SPDX-FileCopyrightText: 2022 Volker Krause <vkrause@kde.org>
3 SPDX-License-Identifier: LGPL-2.0-or-later
4*/
5
6#ifndef OSM_IO_H
7#define OSM_IO_H
8
9#include "kosm_export.h"
10#include "abstractreader.h"
11#include "abstractwriter.h"
12
13class QStringView;
14
15#include <memory>
16
17namespace OSM {
18
19class DataSet;
20
21/** Access to OSM file/data readers. */
22namespace IO
23{
24
25/** Returns a suitable reader for the given file name. */
26[[nodiscard]] KOSM_EXPORT std::unique_ptr<AbstractReader> readerForFileName(QStringView fileName, OSM::DataSet *dataSet);
27/** Returns a suitable reader for the given MIME type. */
28[[nodiscard]] KOSM_EXPORT std::unique_ptr<AbstractReader> readerForMimeType(QStringView mimeType, OSM::DataSet *dataSet);
29
30/** Returns a suitable writer for the given file name. */
31[[nodiscard]] KOSM_EXPORT std::unique_ptr<AbstractWriter> writerForFileName(QStringView fileName);
32/** Returns a suitable writer for the given MIME type. */
33[[nodiscard]] KOSM_EXPORT std::unique_ptr<AbstractWriter> writerForMimeType(QStringView mimeType);
34
35}
36
37}
38
39#endif // OSM_IO_H
A set of nodes, ways and relations.
Definition datatypes.h:346
KOSM_EXPORT std::unique_ptr< AbstractReader > readerForMimeType(QStringView mimeType, OSM::DataSet *dataSet)
Returns a suitable reader for the given MIME type.
Definition io.cpp:51
KOSM_EXPORT std::unique_ptr< AbstractWriter > writerForMimeType(QStringView mimeType)
Returns a suitable writer for the given MIME type.
Definition io.cpp:69
KOSM_EXPORT std::unique_ptr< AbstractReader > readerForFileName(QStringView fileName, OSM::DataSet *dataSet)
Returns a suitable reader for the given file name.
Definition io.cpp:42
KOSM_EXPORT std::unique_ptr< AbstractWriter > writerForFileName(QStringView fileName)
Returns a suitable writer for the given file name.
Definition io.cpp:60
Low-level types and functions to work with raw OSM data as efficiently as possible.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:17:55 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.