• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

marble

  • sources
  • kde-4.12
  • kdeedu
  • marble
  • src
  • plugins
  • runner
  • yours
YoursPlugin.cpp
Go to the documentation of this file.
1 //
2 // This file is part of the Marble Virtual Globe.
3 //
4 // This program is free software licensed under the GNU LGPL. You can
5 // find a copy of this license in LICENSE.txt in the top directory of
6 // the source code.
7 //
8 // Copyright 2010 Dennis Nienhüser <earthwings@gentoo.org>
9 //
10 
11 #include "YoursPlugin.h"
12 #include "YoursRunner.h"
13 
14 namespace Marble
15 {
16 
17 YoursPlugin::YoursPlugin( QObject *parent ) :
18  RoutingRunnerPlugin( parent )
19 {
20  setSupportedCelestialBodies( QStringList() << "earth" );
21  setCanWorkOffline( false );
22  setStatusMessage( tr ( "This service requires an Internet connection." ) );
23 }
24 
25 QString YoursPlugin::name() const
26 {
27  return tr( "Yours Routing" );
28 }
29 
30 QString YoursPlugin::guiString() const
31 {
32  return tr( "Yours" );
33 }
34 
35 QString YoursPlugin::nameId() const
36 {
37  return "yours";
38 }
39 
40 QString YoursPlugin::version() const
41 {
42  return "1.0";
43 }
44 
45 QString YoursPlugin::description() const
46 {
47  return tr( "Worldwide routing using a YOURS server" );
48 }
49 
50 QString YoursPlugin::copyrightYears() const
51 {
52  return "2010";
53 }
54 
55 QList<PluginAuthor> YoursPlugin::pluginAuthors() const
56 {
57  return QList<PluginAuthor>()
58  << PluginAuthor( QString::fromUtf8( "Dennis Nienhüser" ), "earthwings@gentoo.org" );
59 }
60 
61 RoutingRunner *YoursPlugin::newRunner() const
62 {
63  return new YoursRunner;
64 }
65 
66 bool YoursPlugin::supportsTemplate( RoutingProfilesModel::ProfileTemplate profileTemplate ) const
67 {
68  return profileTemplate == RoutingProfilesModel::CarFastestTemplate;
69 }
70 
71 }
72 
73 Q_EXPORT_PLUGIN2( YoursPlugin, Marble::YoursPlugin )
74 
75 #include "YoursPlugin.moc"
Marble::YoursPlugin::YoursPlugin
YoursPlugin(QObject *parent=0)
Definition: YoursPlugin.cpp:17
Marble::YoursPlugin::description
QString description() const
Returns a user description of the plugin.
Definition: YoursPlugin.cpp:45
Marble::YoursRunner
Definition: YoursRunner.h:25
Marble::YoursPlugin::name
QString name() const
Returns the user-visible name of the plugin.
Definition: YoursPlugin.cpp:25
Marble::PluginAuthor
Definition: PluginInterface.h:28
QObject
Marble::YoursPlugin::pluginAuthors
QList< PluginAuthor > pluginAuthors() const
Definition: YoursPlugin.cpp:55
Marble::YoursPlugin::version
QString version() const
Definition: YoursPlugin.cpp:40
Marble::YoursPlugin::newRunner
virtual RoutingRunner * newRunner() const
Plugin factory method to create a new runner instance.
Definition: YoursPlugin.cpp:61
YoursPlugin.h
Q_EXPORT_PLUGIN2
#define Q_EXPORT_PLUGIN2(a, b)
Definition: marble_export.h:34
Marble::RoutingProfilesModel::CarFastestTemplate
Definition: RoutingProfilesModel.h:36
Marble::YoursPlugin::guiString
QString guiString() const
Returns the string that should appear in the user interface.
Definition: YoursPlugin.cpp:30
Marble::YoursPlugin::nameId
QString nameId() const
Returns the unique name of the plugin.
Definition: YoursPlugin.cpp:35
Marble::RoutingProfilesModel::ProfileTemplate
ProfileTemplate
Definition: RoutingProfilesModel.h:35
Marble::RoutingRunnerPlugin::setSupportedCelestialBodies
void setSupportedCelestialBodies(const QStringList &celestialBodies)
Definition: RoutingRunnerPlugin.cpp:61
Marble::RoutingRunnerPlugin::setCanWorkOffline
void setCanWorkOffline(bool canWorkOffline)
Definition: RoutingRunnerPlugin.cpp:66
Marble::RoutingRunner
Definition: RoutingRunner.h:27
Marble::RoutingRunnerPlugin
A plugin for Marble to execute a routing task.
Definition: RoutingRunnerPlugin.h:33
Marble::RoutingRunnerPlugin::setStatusMessage
void setStatusMessage(const QString &message)
Definition: RoutingRunnerPlugin.cpp:101
Marble::YoursPlugin::supportsTemplate
virtual bool supportsTemplate(RoutingProfilesModel::ProfileTemplate profileTemplate) const
True if the plugin supports the given routing profile template.
Definition: YoursPlugin.cpp:66
Marble::YoursPlugin::copyrightYears
QString copyrightYears() const
Definition: YoursPlugin.cpp:50
Marble::YoursPlugin
Definition: YoursPlugin.h:20
YoursRunner.h
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:38:53 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

marble

Skip menu "marble"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • kstars
  • libkdeedu
  •   keduvocdocument
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal