Marble::RoutingManager

Search for usage in LXR

Marble::RoutingManager Class Reference

#include <RoutingManager.h>

Inheritance diagram for Marble::RoutingManager:

Public Types

enum  State { Downloading , Retrieved }
 

Properties

bool guidanceModeEnabled
 
State state
 
- Properties inherited from QObject
 objectName
 

Signals

void guidanceModeEnabledChanged (bool enabled)
 
void routeRetrieved (GeoDataDocument *route)
 
void stateChanged (RoutingManager::State newState)
 

Public Slots

void clearRoute ()
 
void retrieveRoute ()
 
void reverseRoute ()
 
void setGuidanceModeEnabled (bool enabled)
 

Public Member Functions

 RoutingManager (MarbleModel *marbleModel, QObject *parent=nullptr)
 
 ~RoutingManager () override
 
AlternativeRoutesModel * alternativeRoutesModel ()
 
RoutingProfile defaultProfile (RoutingProfile::TransportType transportType) const
 
bool guidanceModeEnabled () const
 
QString lastOpenPath () const
 
QString lastSavePath () const
 
void loadRoute (const QString &filename)
 
RoutingProfilesModel * profilesModel ()
 
void readSettings ()
 
QColor routeColorAlternative () const
 
QColor routeColorHighlighted () const
 
QColor routeColorStandard () const
 
RouteRequestrouteRequest ()
 
RoutingModel * routingModel ()
 
const RoutingModel * routingModel () const
 
void saveRoute (const QString &filename) const
 
void setLastOpenPath (const QString &path)
 
void setLastSavePath (const QString &path)
 
void setRouteColorAlternative (const QColor &color)
 
void setRouteColorHighlighted (const QColor &color)
 
void setRouteColorStandard (const QColor &color)
 
void setShowGuidanceModeStartupWarning (bool show)
 
bool showGuidanceModeStartupWarning () const
 
State state () const
 
void writeSettings () const
 
- Public Member Functions inherited from QObject
 QObject (QObject *parent)
 
QBindable< QStringbindableObjectName ()
 
bool blockSignals (bool block)
 
const QObjectListchildren () const const
 
QMetaObject::Connection connect (const QObject *sender, const char *signal, const char *method, Qt::ConnectionType type) const const
 
void deleteLater ()
 
void destroyed (QObject *obj)
 
bool disconnect (const char *signal, const QObject *receiver, const char *method) const const
 
bool disconnect (const QObject *receiver, const char *method) const const
 
void dumpObjectInfo () const const
 
void dumpObjectTree () const const
 
QList< QByteArraydynamicPropertyNames () const const
 
virtual bool event (QEvent *e)
 
virtual bool eventFilter (QObject *watched, QEvent *event)
 
findChild (const QString &name, Qt::FindChildOptions options) const const
 
QList< T > findChildren (const QRegularExpression &re, Qt::FindChildOptions options) const const
 
QList< T > findChildren (const QString &name, Qt::FindChildOptions options) const const
 
QList< T > findChildren (Qt::FindChildOptions options) const const
 
bool inherits (const char *className) const const
 
void installEventFilter (QObject *filterObj)
 
bool isQuickItemType () const const
 
bool isWidgetType () const const
 
bool isWindowType () const const
 
void killTimer (int id)
 
virtual const QMetaObjectmetaObject () const const
 
void moveToThread (QThread *targetThread)
 
QString objectName () const const
 
void objectNameChanged (const QString &objectName)
 
QObjectparent () const const
 
QVariant property (const char *name) const const
 
 Q_CLASSINFO (Name, Value)
 
 Q_EMIT Q_EMIT
 
 Q_ENUM (...)
 
 Q_ENUM_NS (...)
 
 Q_ENUMS (...)
 
 Q_FLAG (...)
 
 Q_FLAG_NS (...)
 
 Q_FLAGS (...)
 
 Q_GADGET Q_GADGET
 
 Q_GADGET_EXPORT (EXPORT_MACRO)
 
 Q_INTERFACES (...)
 
 Q_INVOKABLE Q_INVOKABLE
 
 Q_MOC_INCLUDE Q_MOC_INCLUDE
 
 Q_NAMESPACE Q_NAMESPACE
 
 Q_NAMESPACE_EXPORT (EXPORT_MACRO)
 
 Q_OBJECT Q_OBJECT
 
 Q_PROPERTY (...)
 
 Q_REVISION Q_REVISION
 
 Q_SET_OBJECT_NAME (Object)
 
 Q_SIGNAL Q_SIGNAL
 
 Q_SIGNALS Q_SIGNALS
 
 Q_SLOT Q_SLOT
 
 Q_SLOTS Q_SLOTS
 
qobject_cast (const QObject *object)
 
qobject_cast (QObject *object)
 
 QT_NO_NARROWING_CONVERSIONS_IN_CONNECT QT_NO_NARROWING_CONVERSIONS_IN_CONNECT
 
void removeEventFilter (QObject *obj)
 
void setObjectName (const QString &name)
 
void setObjectName (QAnyStringView name)
 
void setParent (QObject *parent)
 
bool setProperty (const char *name, const QVariant &value)
 
bool setProperty (const char *name, QVariant &&value)
 
bool signalsBlocked () const const
 
int startTimer (int interval, Qt::TimerType timerType)
 
int startTimer (std::chrono::milliseconds interval, Qt::TimerType timerType)
 
QThreadthread () const const
 

Additional Inherited Members

- Static Public Member Functions inherited from QObject
QMetaObject::Connection connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
 
QMetaObject::Connection connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type)
 
QMetaObject::Connection connect (const QObject *sender, PointerToMemberFunction signal, const QObject *context, Functor functor, Qt::ConnectionType type)
 
QMetaObject::Connection connect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method, Qt::ConnectionType type)
 
QMetaObject::Connection connect (const QObject *sender, PointerToMemberFunction signal, Functor functor)
 
bool disconnect (const QMetaObject::Connection &connection)
 
bool disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method)
 
bool disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method)
 
bool disconnect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method)
 
QString tr (const char *sourceText, const char *disambiguation, int n)
 
- Public Attributes inherited from QObject
typedef QObjectList
 
- Protected Member Functions inherited from QObject
virtual void childEvent (QChildEvent *event)
 
virtual void connectNotify (const QMetaMethod &signal)
 
virtual void customEvent (QEvent *event)
 
virtual void disconnectNotify (const QMetaMethod &signal)
 
bool isSignalConnected (const QMetaMethod &signal) const const
 
int receivers (const char *signal) const const
 
QObjectsender () const const
 
int senderSignalIndex () const const
 
virtual void timerEvent (QTimerEvent *event)
 

Detailed Description

Delegates data retrieval and model updates to the appropriate routing provider.

Definition at line 27 of file RoutingManager.h.

Member Enumeration Documentation

◆ State

enum Marble::RoutingManager::State

Definition at line 34 of file RoutingManager.h.

Property Documentation

◆ guidanceModeEnabled

bool Marble::RoutingManager::guidanceModeEnabled
readwrite

Definition at line 31 of file RoutingManager.h.

◆ state

State Marble::RoutingManager::state
read

Definition at line 30 of file RoutingManager.h.

Constructor & Destructor Documentation

◆ RoutingManager()

Marble::RoutingManager::RoutingManager ( MarbleModel * marbleModel,
QObject * parent = nullptr )
explicit

Constructor.

Definition at line 258 of file RoutingManager.cpp.

◆ ~RoutingManager()

Marble::RoutingManager::~RoutingManager ( )
override

Destructor.

Definition at line 272 of file RoutingManager.cpp.

Member Function Documentation

◆ alternativeRoutesModel()

AlternativeRoutesModel * Marble::RoutingManager::alternativeRoutesModel ( )

Provides access to the model which contains a list of alternative routes.

Definition at line 445 of file RoutingManager.cpp.

◆ clearRoute

void Marble::RoutingManager::clearRoute ( )
slot

Clear all via points.

Definition at line 575 of file RoutingManager.cpp.

◆ defaultProfile()

RoutingProfile Marble::RoutingManager::defaultProfile ( RoutingProfile::TransportType transportType) const

Generates a routing profile with default settings for the given transport type.

Definition at line 465 of file RoutingManager.cpp.

◆ guidanceModeEnabled()

bool Marble::RoutingManager::guidanceModeEnabled ( ) const

Definition at line 641 of file RoutingManager.cpp.

◆ lastOpenPath()

QString Marble::RoutingManager::lastOpenPath ( ) const

Return last directory the user opened a route from.

Definition at line 596 of file RoutingManager.cpp.

◆ lastSavePath()

QString Marble::RoutingManager::lastSavePath ( ) const

Return last directory the user saved a route to.

Definition at line 606 of file RoutingManager.cpp.

◆ loadRoute()

void Marble::RoutingManager::loadRoute ( const QString & filename)

Opens the given filename (kml format) and loads the route contained in it.

Definition at line 460 of file RoutingManager.cpp.

◆ profilesModel()

RoutingProfilesModel * Marble::RoutingManager::profilesModel ( )

Provides access to the model which contains all possible routing profiles.

Definition at line 277 of file RoutingManager.cpp.

◆ readSettings()

void Marble::RoutingManager::readSettings ( )

Restores a previously saved route request and route from disk, if any.

Definition at line 496 of file RoutingManager.cpp.

◆ retrieveRoute

void Marble::RoutingManager::retrieveRoute ( )
slot

Retrieve a route suiting the routeRequest.

Definition at line 302 of file RoutingManager.cpp.

◆ reverseRoute

void Marble::RoutingManager::reverseRoute ( )
slot

Reverse the previously requested route, i.e.

swap start and destination (and via points, if any)

Definition at line 569 of file RoutingManager.cpp.

◆ routeColorAlternative()

QColor Marble::RoutingManager::routeColorAlternative ( ) const

Get color for alternative route rendering.

Definition at line 636 of file RoutingManager.cpp.

◆ routeColorHighlighted()

QColor Marble::RoutingManager::routeColorHighlighted ( ) const

Get color for highlighted route rendering.

Definition at line 626 of file RoutingManager.cpp.

◆ routeColorStandard()

QColor Marble::RoutingManager::routeColorStandard ( ) const

Get color for standard route rendering.

Definition at line 616 of file RoutingManager.cpp.

◆ routeRequest()

RouteRequest * Marble::RoutingManager::routeRequest ( )

Returns the current route request.

Definition at line 292 of file RoutingManager.cpp.

◆ routingModel() [1/2]

RoutingModel * Marble::RoutingManager::routingModel ( )

Provides access to the routing model which contains a list of routing instructions describing steps to get from the source to the destination.

See also
retrieveDirections

Definition at line 282 of file RoutingManager.cpp.

◆ routingModel() [2/2]

const RoutingModel * Marble::RoutingManager::routingModel ( ) const

Definition at line 287 of file RoutingManager.cpp.

◆ saveRoute()

void Marble::RoutingManager::saveRoute ( const QString & filename) const

Saves the current route to the file with the given filename.

Existing files will be overwritten. The route is saved in kml format.

Definition at line 455 of file RoutingManager.cpp.

◆ setGuidanceModeEnabled

void Marble::RoutingManager::setGuidanceModeEnabled ( bool enabled)
slot

Toggle turn by turn navigation mode.

Definition at line 501 of file RoutingManager.cpp.

◆ setLastOpenPath()

void Marble::RoutingManager::setLastOpenPath ( const QString & path)

Set last directory the user opened a route from.

Definition at line 591 of file RoutingManager.cpp.

◆ setLastSavePath()

void Marble::RoutingManager::setLastSavePath ( const QString & path)

Set last directory the user saved a route to.

Definition at line 601 of file RoutingManager.cpp.

◆ setRouteColorAlternative()

void Marble::RoutingManager::setRouteColorAlternative ( const QColor & color)

Set color for alternative route rendering.

Definition at line 631 of file RoutingManager.cpp.

◆ setRouteColorHighlighted()

void Marble::RoutingManager::setRouteColorHighlighted ( const QColor & color)

Set color for highlighted route rendering.

Definition at line 621 of file RoutingManager.cpp.

◆ setRouteColorStandard()

void Marble::RoutingManager::setRouteColorStandard ( const QColor & color)

Set color for standard route rendering.

Definition at line 611 of file RoutingManager.cpp.

◆ setShowGuidanceModeStartupWarning()

void Marble::RoutingManager::setShowGuidanceModeStartupWarning ( bool show)

Set whether a warning message should be shown to the user before starting guidance mode.

Definition at line 581 of file RoutingManager.cpp.

◆ showGuidanceModeStartupWarning()

bool Marble::RoutingManager::showGuidanceModeStartupWarning ( ) const

Returns true (default) if a warning is shown to the user when starting guidance mode.

Definition at line 586 of file RoutingManager.cpp.

◆ state()

RoutingManager::State Marble::RoutingManager::state ( ) const

Returns whether a route is being downloaded.

Returns

Definition at line 297 of file RoutingManager.cpp.

◆ stateChanged

void Marble::RoutingManager::stateChanged ( RoutingManager::State newState)
signal

Directions and waypoints for the given route are being downloaded or have been retrieved – newState tells which of both.

◆ writeSettings()

void Marble::RoutingManager::writeSettings ( ) const

Saves the current route request and the current route to disk.

Definition at line 450 of file RoutingManager.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:18:18 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.