QGeoSatelliteInfo 类

The QGeoSatelliteInfo class contains basic information about a satellite. 更多...

头: #include <QGeoSatelliteInfo>
qmake: QT += positioning
Since: Qt 5.2

公共类型

enum Attribute { Elevation, Azimuth }
enum SatelliteSystem { Undefined, GPS, GLONASS }

公共函数

QGeoSatelliteInfo ()
QGeoSatelliteInfo (const QGeoSatelliteInfo & other )
~QGeoSatelliteInfo ()
qreal attribute (QGeoSatelliteInfo::Attribute attribute ) const
bool hasAttribute (QGeoSatelliteInfo::Attribute attribute ) const
void removeAttribute (QGeoSatelliteInfo::Attribute attribute )
int satelliteIdentifier () const
QGeoSatelliteInfo::SatelliteSystem satelliteSystem () const
void setAttribute (QGeoSatelliteInfo::Attribute attribute , qreal value )
void setSatelliteIdentifier (int satId )
void setSatelliteSystem (QGeoSatelliteInfo::SatelliteSystem system )
void setSignalStrength (int signalStrength )
int signalStrength () const
bool operator!= (const QGeoSatelliteInfo & other ) const
QGeoSatelliteInfo & operator= (const QGeoSatelliteInfo & other )
bool operator== (const QGeoSatelliteInfo & other ) const
QDataStream & operator<< (QDataStream & stream , const QGeoSatelliteInfo & info )
QDataStream & operator>> (QDataStream & stream , QGeoSatelliteInfo & info )

详细描述

The QGeoSatelliteInfo class contains basic information about a satellite.

另请参阅 QGeoSatelliteInfoSource .

成员类型文档编制

enum QGeoSatelliteInfo:: Attribute

定义用于卫星信息的属性。

常量 描述
QGeoSatelliteInfo::Elevation 0 卫星仰角 (以度为单位)。
QGeoSatelliteInfo::Azimuth 1 正北方位角 (以度为单位)。

enum QGeoSatelliteInfo:: SatelliteSystem

定义卫星的 GNSS 系统。

常量 描述
QGeoSatelliteInfo::Undefined 0x00 未定义。
QGeoSatelliteInfo::GPS 0x01 全球定位系统 (USA 美国)。
QGeoSatelliteInfo::GLONASS 0x02 全球定位系统 (俄罗斯)。

成员函数文档编制

QGeoSatelliteInfo:: QGeoSatelliteInfo ()

创建卫星信息对象。

QGeoSatelliteInfo:: QGeoSatelliteInfo (const QGeoSatelliteInfo & other )

创建卫星信息对象采用值为 other .

QGeoSatelliteInfo:: ~QGeoSatelliteInfo ()

销毁卫星信息对象。

qreal QGeoSatelliteInfo:: attribute ( QGeoSatelliteInfo::Attribute attribute ) const

返回值为指定 attribute 如 qreal 值。

返回 -1 若值未设置。

另请参阅 hasAttribute () 和 setAttribute ().

bool QGeoSatelliteInfo:: hasAttribute ( QGeoSatelliteInfo::Attribute attribute ) const

返回 true 若指定 attribute 呈现在此更新中。

void QGeoSatelliteInfo:: removeAttribute ( QGeoSatelliteInfo::Attribute attribute )

移除指定 attribute 及其值。

int QGeoSatelliteInfo:: satelliteIdentifier () const

返回卫星标识符编号。

The satellite identifier number can be used to identify a satellite inside the satellite system. For satellite system GPS the satellite identifier number represents the PRN (Pseudo-random noise) number. For satellite system GLONASS the satellite identifier number represents the slot number.

另请参阅 setSatelliteIdentifier ().

QGeoSatelliteInfo::SatelliteSystem QGeoSatelliteInfo:: satelliteSystem () const

返回卫星系统 (GPS、GLONASS...)

另请参阅 setSatelliteSystem ().

void QGeoSatelliteInfo:: setAttribute ( QGeoSatelliteInfo::Attribute attribute , qreal value )

设置值为 attribute to value .

另请参阅 attribute ().

void QGeoSatelliteInfo:: setSatelliteIdentifier ( int satId )

将卫星标识编号设为 satId .

The satellite identifier number can be used to identify a satellite inside the satellite system. For satellite system GPS the satellite identifier number represents the PRN (Pseudo-random noise) number. For satellite system GLONASS the satellite identifier number represents the slot number.

另请参阅 satelliteIdentifier ().

void QGeoSatelliteInfo:: setSatelliteSystem ( QGeoSatelliteInfo::SatelliteSystem system )

设置卫星系统 (GPS、GLONASS...) 为 system .

另请参阅 satelliteSystem ().

void QGeoSatelliteInfo:: setSignalStrength ( int signalStrength )

将信号强度设为 signalStrength (以分贝为单位)。

另请参阅 signalStrength ().

int QGeoSatelliteInfo:: signalStrength () const

Returns the signal strength, or -1 if the value has not been set.

另请参阅 setSignalStrength ().

bool QGeoSatelliteInfo:: operator!= (const QGeoSatelliteInfo & other ) const

Returns true if any of the information for this satellite are not the same as those of other .

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

赋值值从 other 到此对象。

bool QGeoSatelliteInfo:: operator== (const QGeoSatelliteInfo & other ) const

Returns true if all the information for this satellite are the same as those of other .

相关非成员

QDataStream & operator<< ( QDataStream & stream , const QGeoSatelliteInfo & info )

写入给定 info 到指定 stream .

另请参阅 序列化 Qt 数据类型 .

QDataStream & operator>> ( QDataStream & stream , QGeoSatelliteInfo & info )

Reads satellite information from the specified stream 进给定 info .

另请参阅 序列化 Qt 数据类型 .