Viadeo Twitter Google Bookmarks ! Facebook Digg del.icio.us MySpace Yahoo MyWeb Blinklist Netvouz Reddit Simpy StumbleUpon Bookmarks Windows Live Favorites 
Logo Documentation Qt ·  Page d'accueil  ·  Toutes les classes  ·  Toutes les fonctions  ·  Vues d'ensemble  · 

QWhereaboutsUpdate Class Reference
[QtLocationModule]

The QWhereaboutsUpdate class contains the global position and other related information received at a particular point in time. More...

    #include <QWhereaboutsUpdate>

Public Types

  • enum DataType { GroundSpeed, VerticalSpeed, Course, HorizontalAccuracy, ..., UpdateTimeAccuracy }
  • flags DataTypes
  • enum PositionFixStatus { FixStatusUnknown, FixNotAcquired, FixAcquired }

Public Functions

Static Public Members

  • QWhereaboutsUpdate fromNmea ( const QByteArray & nmea, PositionFixStatus * fixStatus = 0 )

Detailed Description

The QWhereaboutsUpdate class contains the global position and other related information received at a particular point in time.

A QWhereaboutsUpdate object has, at a minimum, a coordinate value and a timestamp. It may also have course and speed measurements and estimates of the accuracy of the provided data.

Use dataValidityFlags() to determine whether values have been set for a particular data type.

See also QWhereabouts and QWhereaboutsCoordinate.


Member Type Documentation

enum QWhereaboutsUpdate::DataType
flags QWhereaboutsUpdate::DataTypes

Defines the types of data that may be included in an update.

ConstantValueDescription
QWhereaboutsUpdate::GroundSpeed0x2The speed over ground.
QWhereaboutsUpdate::VerticalSpeed0x4The vertical speed.
QWhereaboutsUpdate::Course0x8The course/track made good (i.e. bearing to true north).
QWhereaboutsUpdate::HorizontalAccuracy0x10The horizontal accuracy.
QWhereaboutsUpdate::VerticalAccuracy0x20The vertical accuracy
QWhereaboutsUpdate::GroundSpeedAccuracy0x40Accuracy of the speed over ground value.
QWhereaboutsUpdate::VerticalSpeedAccuracy0x80Accuracy over the vertical speed value.
QWhereaboutsUpdate::CourseAccuracy0x100Accuracy of the course/track made good value.
QWhereaboutsUpdate::UpdateTimeAccuracy0x200Accuracy of the update time value.

The DataTypes type is a typedef for QFlags<DataType>. It stores an OR combination of DataType values.

See also dataValidityFlags().

enum QWhereaboutsUpdate::PositionFixStatus

Defines the available position fix statuses for a position update. A global position cannot be accurately determined until a position fix is acquired.

ConstantValueDescription
QWhereaboutsUpdate::FixStatusUnknown0The position fix status cannot be determined from the position update.
QWhereaboutsUpdate::FixNotAcquired1No position fix has been acquired at the time of the update.
QWhereaboutsUpdate::FixAcquired2A position fix has been acquired at the time of the update.


Member Function Documentation

QWhereaboutsUpdate::QWhereaboutsUpdate ()

Constructs a null update.

QWhereaboutsUpdate::QWhereaboutsUpdate ( const QWhereaboutsCoordinate & coordinate, const QDateTime & dateTime )

Constructs an update with the given coordinate and dateTime.

QWhereaboutsUpdate::QWhereaboutsUpdate ( const QWhereaboutsUpdate & other )

Constructs an update from the contents of other.

QWhereaboutsUpdate::~QWhereaboutsUpdate ()

Destroys an update.

void QWhereaboutsUpdate::clear ()

Clears all attribute values for this update.

QWhereaboutsCoordinate QWhereaboutsUpdate::coordinate () const

Returns the coordinate for this update.

See also setCoordinate().

qreal QWhereaboutsUpdate::course () const

Returns the course (i.e. bearing to true north, in degrees).

Use dataValidityFlags() to check whether this value has been set.

See also setCourse().

qreal QWhereaboutsUpdate::courseAccuracy () const

Returns the estimated accuracy of the course() value (in degrees).

Use dataValidityFlags() to check whether this value has been set.

See also setCourseAccuracy().

DataTypes QWhereaboutsUpdate::dataValidityFlags () const

Returns a set of flags that indicate whether data has been set for a particular update attribute.

QWhereaboutsUpdate QWhereaboutsUpdate::fromNmea ( const QByteArray & nmea, PositionFixStatus * fixStatus = 0 )   [static]

Returns the parsed form of the NMEA data in nmea and sets fixStatus according to the parsed data. Returns a null update if nmea could not be parsed, or if it has an invalid checksum.

This function is able to parse GGA, GLL, RMC, VTG and ZDA sentences.

Some points to note:

  • If nmea contains a date that has a year component in two-digit form, it is assumed that it refers to a year after the year 2000, and the updateDate() of the returned upate is set accordingly.
  • The returned update may not have valid date and/or time values as some sentences do not have this information. GGA and GLL sentences do not have date information, and VTG sentences have neither date nor time information.

qreal QWhereaboutsUpdate::groundSpeed () const

Returns the speed over ground, in meters/sec.

Use dataValidityFlags() to check whether this value has been set.

See also setGroundSpeed().

qreal QWhereaboutsUpdate::groundSpeedAccuracy () const

Returns the estimated accuracy of the groundSpeed() value (in meters/sec).

Use dataValidityFlags() to check whether this value has been set.

See also setGroundSpeedAccuracy().

qreal QWhereaboutsUpdate::horizontalAccuracy () const

Returns the estimated horizontal accuracy (in meters).

Use dataValidityFlags() to check whether this value has been set.

See also setHorizontalAccuracy().

bool QWhereaboutsUpdate::isNull () const

Returns true if no attributes are set for this update.

void QWhereaboutsUpdate::setCoordinate ( const QWhereaboutsCoordinate & coordinate )

Sets the coordinate for this update to coordinate.

See also coordinate().

void QWhereaboutsUpdate::setCourse ( qreal course )

Sets the course (i.e. bearing to true north, in degrees) to course.

See also course().

void QWhereaboutsUpdate::setCourseAccuracy ( qreal accuracy )

Sets the estimated accuracy of the course() value (in degrees) to accuracy.

See also courseAccuracy().

void QWhereaboutsUpdate::setGroundSpeed ( qreal speed )

Sets the speed over ground (in meters/sec) to speed.

See also groundSpeed().

void QWhereaboutsUpdate::setGroundSpeedAccuracy ( qreal accuracy )

Sets the estimated accuracy of the groundSpeed() value (in meters/sec) to accuracy.

See also groundSpeedAccuracy().

void QWhereaboutsUpdate::setHorizontalAccuracy ( qreal accuracy )

Sets the estimated horizontal accuracy (in meters) to accuracy.

See also horizontalAccuracy().

void QWhereaboutsUpdate::setUpdateDate ( const QDate & date )

Sets the date on which this update was received to date.

See also updateDate().

void QWhereaboutsUpdate::setUpdateDateTime ( const QDateTime & dateTime ) const

Sets the date and time at which this update was received to dateTime.

See also updateDateTime() and updateDate().

void QWhereaboutsUpdate::setUpdateTime ( const QTime & time )

Sets the time at which this update was received to time, which should be in UTC time.

See also updateTime().

void QWhereaboutsUpdate::setUpdateTimeAccuracy ( qreal accuracy )

Sets the estimated accuracy of the updateTime() value (in seconds) to accuracy.

See also updateTimeAccuracy().

void QWhereaboutsUpdate::setVerticalAccuracy ( qreal accuracy )

Sets the estimated vertical accuracy (in meters) to accuracy.

See also verticalAccuracy().

void QWhereaboutsUpdate::setVerticalSpeed ( qreal speed )

Sets the vertical speed (in meters/sec) to speed.

See also verticalSpeed().

void QWhereaboutsUpdate::setVerticalSpeedAccuracy ( qreal accuracy )

Sets the estimated accuracy of the verticalSpeed() value (in meters/sec) to accuracy.

See also verticalSpeedAccuracy().

QDate QWhereaboutsUpdate::updateDate () const

Returns the date on which this update was received.

See also setUpdateDate().

QDateTime QWhereaboutsUpdate::updateDateTime () const

Returns the date and time at which this update was received.

Returns an invalid value if the updateDate() or updateTime() is not valid.

See also setUpdateDateTime() and setUpdateDate().

QTime QWhereaboutsUpdate::updateTime () const

Returns the time at which this update was received.

See also setUpdateTime().

qreal QWhereaboutsUpdate::updateTimeAccuracy () const

Returns the estimated accuracy of the updateTime() value (in seconds).

Use dataValidityFlags() to check whether this value has been set.

See also setUpdateTimeAccuracy().

qreal QWhereaboutsUpdate::verticalAccuracy () const

Returns the estimated vertical accuracy (in meters).

Use dataValidityFlags() to check whether this value has been set.

See also setVerticalAccuracy().

qreal QWhereaboutsUpdate::verticalSpeed () const

Returns the vertical speed, in meters/sec.

Use dataValidityFlags() to check whether this value has been set.

See also setVerticalSpeed().

qreal QWhereaboutsUpdate::verticalSpeedAccuracy () const

Returns the estimated accuracy of the verticalSpeed() value (in meters/sec).

Use dataValidityFlags() to check whether this value has been set.

See also setVerticalSpeedAccuracy().

QWhereaboutsUpdate & QWhereaboutsUpdate::operator= ( const QWhereaboutsUpdate & other )

Assigns other to this update and returns a reference to this update.

Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. Qt qtextended4.4
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD.
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP !
 
 
 
 
Partenaires

Hébergement Web