GeoLocation

#include <bb/platform/geo/GeoLocation>

To link against this class, add the following line to your .pro file: LIBS += -lbbcascadesmaps

A location in geographic space that represents a latitude and longitude coordinate, and is visually represented on the map using its Marker attribute.

Note:

See Geographic for information on object ownership and reference types.

Since:

BlackBerry 10.0.0

Inheritance

bb::platform::geo::Geographic
bb::platform::geo::GeoLocation

Public Functions Index

GeoLocation (const QString &id, QObject *parent=0)
GeoLocation (double lat=0, double lon=0, QObject *parent=0)
GeoLocation (const QString &id, const QString &name, const bb::platform::geo::Point &location, QObject *parent=0)
virtual ~GeoLocation ()
bb::platform::geo::Pointpoint () const
boolsetPoint (const bb::platform::geo::Point &point)
doublealtitude () const
boolsetAltitude (double alt)
bb::platform::geo::AltitudeMode::TypealtitudeMode () const
boolsetAltitudeMode (bb::platform::geo::AltitudeMode::Type mode)
doublelatitude () const
boolsetLatitude (double lat)
doublelongitude () const
boolsetLongitude (double lon)
bb::platform::geo::Markermarker () const
Q_SLOT voidsetMarker (const bb::platform::geo::Marker &marker)
Q_SLOT voidresetMarker ()
Q_REVISION (1) double radius() const
Q_REVISION (1) bool setRadius(double new Radius)
Q_SLOTQ_REVISION (1) void resetRadius()
virtual bb::platform::geo::BoundingBoxboundingBox () const
QStringdescription () const Inherited
Geographic (QObject *parent=0)Inherited
Geographic (const QString &id, QObject *parent=0)Inherited
QStringid () const Inherited
QStringname () const Inherited
Q_SLOT voidsetDescription (const QString &desc)Inherited
Q_SLOT voidsetId (const QString &id)Inherited
Q_SLOT voidsetName (const QString &name)Inherited
Q_SLOT voidsetStyleFamily (const QString &styleFamily)Inherited
QStringstyleFamily () const Inherited

Protected Functions Index

Only has inherited protected functions

voidsetBoundingBox (const bb::platform::geo::BoundingBox &newBox)Inherited

Signals Index

voidpointChanged (const bb::platform::geo::Point &point)
voidmarkerChanged (const bb::platform::geo::Marker &newMarker)
Q_REVISION (1) void radiusChanged(double new Radius)
voidboundaryChanged (const bb::platform::geo::BoundingBox &box)Inherited
voiddescriptionChanged (const QString &desc)Inherited
voididChanged (const QString &id)Inherited
voidnameChanged (const QString &name)Inherited
voidstyleFamilyChanged (const QString &newFamily)Inherited
voidtopographyChanged (const QString &id)Inherited

Properties

bb::platform::geo::Point point

The coordinates of this location.

Since:

BlackBerry 10.0.0

bb::platform::geo::Marker marker

The marker used to indicate this location.

Since:

BlackBerry 10.0.0

double radius

The radius of interest of the circle that represents this location.

Since:

BlackBerry 10.2.0

bb::platform::geo::BoundingBox boundingBoxInherited[read-only]

The axis-aligned bounding box in which this object is contained.

Since:

BlackBerry 10.0.0

QString descriptionInherited

The description of this object.

Since:

BlackBerry 10.0.0

QString idInherited

The ID of this Geographic object.

Since:

BlackBerry 10.0.0

QString nameInherited

The name of this object.

Since:

BlackBerry 10.0.0

QString styleFamilyInherited

The style family to be used in conjunction with this element.

Since:

BlackBerry 10.2.0

Public Functions

GeoLocation (

Creates an instance of GeoLocation.

The resulting location defaults to that of a default Point.

Parameters
id

The identifier for this Geographic. It is up to the caller to ensure the uniqueness of Geographic IDs.

parent

The QObject parent of this object.

Since:

BlackBerry 10.0.0

GeoLocation (
  • doublelat,
  • doublelon,
  • QObject *parent )

Creates an instance of GeoLocation with the given latitude and longitude.

Parameters
lat

The latitude value (0 default).

lon

The longitude value (0 default).

parent

The QObject parent of this object.

Since:

BlackBerry 10.0.0

GeoLocation (

Creates an instance of GeoLocation with the information provided.

Parameters
id

The identifier for this Geographic. It is up to the caller to ensure the uniqueness of Geographic IDs.

name

The name of this location.

location

The location of this Point.

parent

The QObject parent of this object.

Since:

BlackBerry 10.0.0

virtual~GeoLocation ()

Destructor.

bb::platform::geo::Point point ()

Retrieves all point-based attributes of this location.

Return:

A Point version of this location.

Since:

BlackBerry 10.0.0

bool setPoint (

Sets all point-based attributes of this location.

Return:

true if operation resulted in a change.

Since:

BlackBerry 10.0.0

double altitude ()

Gets the altitude of this Point in meters.

Since:

BlackBerry 10.0.0

bool setAltitude (
  • doublealt)

Sets the altitude of this Point in meters.

Return:

true if the operation resulted in a change.

Since:

BlackBerry 10.0.0

bb::platform::geo::AltitudeMode::Type altitudeMode ()

Captures how the altitude attribute should be interpreted.

The default value is AltitudeMode::RelativeToGround.

Return:

How the altitude property should be interpreted.

Since:

BlackBerry 10.0.0

bool setAltitudeMode (

Sets the altitude mode.

The altitude measurement can be relative to the ground (default) or the sea level.

Since:

BlackBerry 10.0.0

Return:

true if the attribute changed.

Since:

BlackBerry 10.0.0

double latitude ()

Gets the point's latitude in degrees.

Since:

BlackBerry 10.0.0

bool setLatitude (
  • doublelat)

Sets the point's latitude in degrees.

Return:

true if operation resulted in a change.

Since:

BlackBerry 10.0.0

double longitude ()

Gets the point's longitude in degrees.

Since:

BlackBerry 10.0.0

bool setLongitude (
  • doublelon)

Sets the point's longitude in degrees.

Return:

true if operation resulted in a change.

Since:

BlackBerry 10.0.0

bb::platform::geo::Marker marker ()

Retrieves the marker, or icon, used to indicate this location.

Return:

The location's marker.

Since:

BlackBerry 10.0.0

Q_SLOT void setMarker (

Sets the marker, or icon, used to indicate this location.

Parameters
marker

The new marker.

Since:

BlackBerry 10.0.0

Q_SLOT void resetMarker ()

Resets the marker to the default icon, the blue pin.

Since:

BlackBerry 10.0.0

Q_REVISION (
  • 1)

The radius of interest of this location.

Return:

The radius of interest of this location.

Since:

BlackBerry 10.2.0

Q_REVISION (
  • 1)

Sets the radius of interest of this location.

Parameters
newRadius

The new radius value for this location.

Return:

true if this location's radius has changed.

Since:

BlackBerry 10.2.0

Q_SLOT Q_REVISION (
  • 1)

Resets the radius of interest of this location to 0 meters.

Since:

BlackBerry 10.2.0

virtualbb::platform::geo::BoundingBox boundingBox ()

Retrieves the axis-aligned bounding box for this Geographic.

Since:

BlackBerry 10.0.0

QString description ()Inherited

Gets the description of this Geographic.

Since:

BlackBerry 10.0.0

Geographic (Inherited

Constructor.

If no ID is supplied when constructing a Geographic entity, an ID that is guaranteed to be unique will be auto-generated.

Parameters
parent

The parent of this Geographic.

Since:

BlackBerry 10.0.0

Geographic (Inherited

Constructor.

Parameters
id

The identifier for this Geographic.

parent

The parent of this Geographic.

Since:

BlackBerry 10.0.0

QString id ()Inherited

Gets the unique identifier for this Geographic.

If two Geographics are attribute-wise equal, they still need to have different IDs. The ID needs to be unique within a process.

Since:

BlackBerry 10.0.0

QString name ()Inherited

Gets the name of this Geographic.

Since:

BlackBerry 10.0.0

Q_SLOT void setDescription (Inherited

Sets the description of this Geographic.

Since:

BlackBerry 10.0.0

Q_SLOT void setId (Inherited

Sets the ID of this Geographic.

Since:

BlackBerry 10.0.0

Q_SLOT void setName (Inherited

Sets the name of this Geographic.

Since:

BlackBerry 10.0.0

Q_SLOT void setStyleFamily (Inherited

Sets the style family for this Geographic.

Parameters
styleFamily

The new style family for this element.

Since:

BlackBerry 10.2.0

QString styleFamily ()Inherited

Gets the style family for this Geographic.

Since:

BlackBerry 10.2.0

Protected Functions

(Only has inherited protected functions)

void setBoundingBox (Inherited

Signals

void pointChanged (

Emitted when the point of this location changes.

Since:

BlackBerry 10.0.0

void markerChanged (

Emitted when the marker changes.

Since:

BlackBerry 10.0.0

Q_REVISION (
  • 1)

Emitted when the radius of interest has changed.

Parameters
newRadius

The new radius of this location.

Since:

BlackBerry 10.2.0

void boundaryChanged (Inherited

Emitted by derived classes when the bounding box has changed.

See the BoundingBox documentation.

Since:

BlackBerry 10.0.0

void descriptionChanged (Inherited

Emitted when the description of this Geographic changes.

Since:

BlackBerry 10.0.0

void idChanged (Inherited

Emitted when the ID of this Geographic' changes.

Since:

BlackBerry 10.0.0

void nameChanged (Inherited

Emitted when the name of this Geographic changes.

Since:

BlackBerry 10.0.0

void styleFamilyChanged (Inherited

Emitted when the style family attribute changes.

Since:

BlackBerry 10.2.0

void topographyChanged (Inherited

Emitted when the topography of this Geographic changes.

A Geographic's topography captures the location (or geographic) properties of the element.
Parameters
id

The ID of this Geographic.

Since:

BlackBerry 10.1.0