Qt Mobility Reference Documentation

QGeoMappingManagerEngine Class Reference

The QGeoMappingManagerEngine class provides an interface and convenience methods to implementors of QGeoServiceProvider plugins who want to provides support for displaying and interacting with maps. More...

 #include <QGeoMappingManagerEngine>

Inherits QObject.

Inherited by QGeoTiledMappingManagerEngine.


Public Functions

QGeoMappingManagerEngine ( const QMap<QString, QVariant> & parameters, QObject * parent = 0 )
virtual ~QGeoMappingManagerEngine ()
virtual QGeoMapData * createMapData () = 0
QLocale locale () const
QString managerName () const
int managerVersion () const
qreal maximumZoomLevel () const
qreal minimumZoomLevel () const
void setLocale ( const QLocale & locale )
QList<QGraphicsGeoMap::ConnectivityMode> supportedConnectivityModes () const
QList<QGraphicsGeoMap::MapType> supportedMapTypes () const
  • 29 public functions inherited from QObject

Protected Functions

void setMaximumZoomLevel ( qreal maximumZoom )
void setMinimumZoomLevel ( qreal minimumZoom )
void setSupportedConnectivityModes ( const QList<QGraphicsGeoMap::ConnectivityMode> & connectivityModes )
void setSupportedMapTypes ( const QList<QGraphicsGeoMap::MapType> & mapTypes )
  • 7 protected functions inherited from QObject

Additional Inherited Members

  • 1 property inherited from QObject
  • 1 public slot inherited from QObject
  • 1 signal inherited from QObject
  • 1 public variable inherited from QObject
  • 4 static public members inherited from QObject
  • 2 protected variables inherited from QObject

Detailed Description

The QGeoMappingManagerEngine class provides an interface and convenience methods to implementors of QGeoServiceProvider plugins who want to provides support for displaying and interacting with maps.

Subclasses of QGeoMappingManagerEngine need to provide an implementations of createMapData(). The QGeoMapData instances returned by createMapData() can be used to contain and manage information concerning what a particular QGraphicsGeoMap is viewing.

The functions setSupportedMapTypes(const QList<QGraphicsGeoMap::MapType> &mapTypes), setSupportedConnectivityModes(const QList<QGraphicsGeoMap::ConnectivityMode> &connectivityModes), setMinimumZoomLevel(qreal minimumZoom) and setMaximumZoomLevel(qreal maximumZoom) configure the reported capabilities of the engine.

It is important that this is done before createMapData() or any of the capability reporting functions are used to prevent incorrect or inconsistent behaviour.


Member Function Documentation

QGeoMappingManagerEngine::QGeoMappingManagerEngine ( const QMap<QString, QVariant> & parameters, QObject * parent = 0 )

Constructs a new engine with the specified parent, using parameters to pass any implementation specific data to the engine.

QGeoMappingManagerEngine::~QGeoMappingManagerEngine () [virtual]

Destroys this engine.

QGeoMapData * QGeoMappingManagerEngine::createMapData () [pure virtual]

Returns a new QGeoMapData instance which will be managed by this manager.

A QGeoMapData instance contains and manages the information about what a QGraphicsGeoMap is looking at. A single manager can be used by several QGraphicsGeoMap instances since each instance has an associated QGeoMapData instance.

The QGeoMapData instance can be treated as a kind of session object, or as a model in a model-view-controller architecture, with QGraphicsGeoMap as the view and QGeoMappingManagerEngine as the controller.

Subclasses of QGeoMappingManagerEngine are free to override this function to return subclasses of QGeoMapData in order to customize the map.

QLocale QGeoMappingManagerEngine::locale () const

Returns the locale used to hint to this mapping manager about what language to use for map labels.

See also setLocale().

QString QGeoMappingManagerEngine::managerName () const

Returns the name which this engine implementation uses to distinguish itself from the implementations provided by other plugins.

The combination of managerName() and managerVersion() should be unique amongst plugin implementations.

int QGeoMappingManagerEngine::managerVersion () const

Returns the version of this engine implementation.

The combination of managerName() and managerVersion() should be unique amongst plugin implementations.

qreal QGeoMappingManagerEngine::maximumZoomLevel () const

Returns the maximum zoom level supported by this engine.

Larger values of the zoom level correspond to more detailed views of the map.

See also setMaximumZoomLevel().

qreal QGeoMappingManagerEngine::minimumZoomLevel () const

Returns the minimum zoom level supported by this engine.

Larger values of the zoom level correspond to more detailed views of the map.

See also setMinimumZoomLevel().

void QGeoMappingManagerEngine::setLocale ( const QLocale & locale )

Sets the locale to be used by the this manager to locale.

If this mapping manager supports returning map labels in different languages, they will be returned in the language of locale.

The locale used defaults to the system locale if this is not set.

See also locale().

void QGeoMappingManagerEngine::setMaximumZoomLevel ( qreal maximumZoom ) [protected]

Sets the maximum zoom level supported by this engine to maximumZoom.

Larger values of the zoom level correspond to more detailed views of the map.

Subclasses of QGeoMappingManagerEngine should use this function to ensure maximumZoomLevel() provides accurate information.

See also maximumZoomLevel().

void QGeoMappingManagerEngine::setMinimumZoomLevel ( qreal minimumZoom ) [protected]

Sets the minimum zoom level supported by this engine to minimumZoom.

Larger values of the zoom level correspond to more detailed views of the map.

Subclasses of QGeoMappingManagerEngine should use this function to ensure minimumZoomLevel() provides accurate information.

See also minimumZoomLevel().

void QGeoMappingManagerEngine::setSupportedConnectivityModes ( const QList<QGraphicsGeoMap::ConnectivityMode> & connectivityModes ) [protected]

Sets the list of connectivity modes supported by this engine to connectivityModes.

Subclasses of QGeoMappingManagerEngine should use this function to ensure that supportedConnectivityModes() provides accurate information.

If createMapData does not specify a connectivity mode the first mode from connectivityModes will be used, or QGraphicsGeoMap::NoConnectivity will be used if connectivityModes is empty.

See also supportedConnectivityModes().

void QGeoMappingManagerEngine::setSupportedMapTypes ( const QList<QGraphicsGeoMap::MapType> & mapTypes ) [protected]

Sets the list of map types supported by this engine to mapTypes.

Subclasses of QGeoMappingManagerEngine should use this function to ensure that supportedMapTypes() provides accurate information.

See also supportedMapTypes().

QList<QGraphicsGeoMap::ConnectivityMode> QGeoMappingManagerEngine::supportedConnectivityModes () const

Returns a list of the connectivity modes supported by this engine.

See also setSupportedConnectivityModes().

QList<QGraphicsGeoMap::MapType> QGeoMappingManagerEngine::supportedMapTypes () const

Returns a list of the map types supported by this engine.

See also setSupportedMapTypes().

X

Thank you for giving your feedback.

Make sure it is related to this specific page. For more general bugs and requests, please use the Qt Bug Tracker.