C

Qul::GeoPositionInfo Struct

struct Qul::GeoPositionInfo

The GeoPositionInfo class provides an API to communicate position information to PositionSource QML type. More...

Header: #include <qul/geopositionsource.h>
Since: Qt Quick Ultralite 2.11

Public Functions

GeoPositionInfo(double latitude_ = NAN, double longitude_ = NAN, double direction_ = NAN, double speed_ = NAN, uint64_t timestamp_ = 0)
bool hasDirection() const
bool hasLatitude() const
bool hasLongitude() const
bool hasSpeed() const

Public Variables

double direction
double latitude
double longitude
double speed
uint64_t timestamp

Detailed Description

This type is only used in the context of Qul::GeoPositionSource::getCurrentPosition as a parameter which is used by the PositionSource item to retrieve position information.

Note: The Qt for MCUs support for Qul::GeoPositionInfo is experimental only.

See also Qul::GeoPositionSource.

Member Function Documentation

GeoPositionInfo::GeoPositionInfo(double latitude_ = NAN, double longitude_ = NAN, double direction_ = NAN, double speed_ = NAN, uint64_t timestamp_ = 0)

Creates a GeoPositionInfo object and initializes its members with the given values: latitude_, longitude_, direction_, speed_, and timestamp_.

bool GeoPositionInfo::hasDirection() const

This function returns true if direction has been received. Otherwise, it returns false.

The return value of this function is used by the PositionSource item to set the value of Position::directionValid property.

bool GeoPositionInfo::hasLatitude() const

This function returns true if coordinate's latitude has been received. Otherwise, it returns false.

The return value of this function is used by the PositionSource item to set the value of Position::latitudeValid property.

bool GeoPositionInfo::hasLongitude() const

This function returns true if coordinate's longitude has been received. Otherwise, it returns false.

The return value of this function is used by the PositionSource item to set the value of Position::longitudeValid property.

bool GeoPositionInfo::hasSpeed() const

This function returns true if speed has been received. Otherwise, it returns false.

The return value of this function is used by the PositionSource item to set the value of the Position::speedValid property.

Member Variable Documentation

double GeoPositionInfo::direction

This variable is set by the user of the application to the value of direction retrieved from a GPS or other similar positioning systems.

The value of this variable is used by the PositionSource item to set the value of direction of Position::direction property.

double GeoPositionInfo::latitude

This variable is set by the user of the application to the value of coordinate's latitude retrieved from GPS or other similar positioning systems.

The value of this variable is used by the PositionSource item to set the value of coordinate's latitude of Position::coordinate property.

double GeoPositionInfo::longitude

This variable is set by the user of the application to the value of coordinate's longitude retrieved from GPS or other similar positioning systems.

The value of this variable is used by the PositionSource item to set the value of coordinate's longitude of Position::coordinate property.

double GeoPositionInfo::speed

This variable is set by the user of the application to the value of speed retrieved from a GPS or other similar positioning systems.

The value of this variable is used by the PositionSource item to set the speed value of the Position::speed property.

uint64_t GeoPositionInfo::timestamp

This variable is set by the user of the application to the value of timestamp retrieved from a GPS or other similar positioning systems.

The value of this variable is used by the PositionSource item to set the timestamp value of the Position::timestamp property.

Available under certain Qt licenses.
Find out more.