Marble

ParseRunnerPlugin.h
1// SPDX-License-Identifier: LGPL-2.1-or-later
2//
3// SPDX-FileCopyrightText: 2010 Dennis Nienhüser <nienhueser@kde.org>
4// SPDX-FileCopyrightText: 2011 Thibaut Gridel <tgridel@free.fr>
5// SPDX-FileCopyrightText: 2012 Bernhard Beschow <bbeschow@cs.tu-berlin.de>
6//
7
8#ifndef MARBLE_PARSERUNNERPLUGIN_H
9#define MARBLE_PARSERUNNERPLUGIN_H
10
11#include <QObject>
12#include "PluginInterface.h"
13
14namespace Marble
15{
16
17class ParsingRunner;
18
19/**
20 * A plugin for Marble to execute a parsing task.
21 */
22class MARBLE_EXPORT ParseRunnerPlugin : public QObject, public PluginInterface
23{
24 Q_OBJECT
25
26public:
27 /** Constructor with optional parent object */
28 explicit ParseRunnerPlugin( QObject* parent = nullptr );
29
30 /** Destructor */
31 ~ParseRunnerPlugin() override;
32
33 /**
34 * Returns a short description of the supported file format.
35 *
36 * Example: "Google Earth KML"
37 */
38 virtual QString fileFormatDescription() const = 0;
39
40 /**
41 * Returns the file extensions associated with the file format.
42 *
43 * Example: "kml", "kmz"
44 */
45 virtual QStringList fileExtensions() const = 0;
46
47 /** Plugin factory method to create a new runner instance.
48 * Method caller gets ownership of the returned object
49 */
50 virtual ParsingRunner *newRunner() const = 0;
51
52 // Overridden methods with default implementations
53
54 QIcon icon() const override;
55
56private:
57 class Private;
58 Private *const d;
59};
60
61}
62
63Q_DECLARE_INTERFACE( Marble::ParseRunnerPlugin, "org.kde.Marble.ParseRunnerPlugin/1.01" )
64
65#endif // MARBLE_PARSERUNNERPLUGIN_H
A plugin for Marble to execute a parsing task.
virtual ParsingRunner * newRunner() const =0
Plugin factory method to create a new runner instance.
virtual QStringList fileExtensions() const =0
Returns the file extensions associated with the file format.
virtual QString fileFormatDescription() const =0
Returns a short description of the supported file format.
This class specifies interface of a Marble plugin.
Binds a QML item to a specific geodetic location in screen coordinates.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:18:17 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.