|
Enroute Flight Navigation
A navigation app for VFR pilots
|
Traffic factor whose precise position is known. More...
#include <TrafficFactor_WithPosition.h>
Public Slots | |
| void | updateExtrapolatedData () |
| Update extrapolated data. | |
Signals | |
| void | positionInfoChanged () |
| Notifier signal. | |
Public Member Functions | |
| TrafficFactor_WithPosition (QObject *parent=nullptr) | |
| Default constructor. | |
| bool | updateFrom (const TrafficFactorData_WithPosition &data) |
| Offer a data record to this object, for the same traffic factor. | |
| void | replaceBy (const TrafficFactorData_WithPosition &data) |
| Replace this object by a different traffic factor. | |
| QGeoCoordinate | extrapolatedCoordinate () const |
| Getter method for property with the same name. | |
| QBindable< QGeoCoordinate > | bindableExtrapolatedCoordinate () const |
| Getter method for property with the same name. | |
| Units::Angle | extrapolatedTrueTrack () const |
| Getter method for property with the same name. | |
| QBindable< Units::Angle > | bindableExtrapolatedTrueTrack () const |
| Getter method for property with the same name. | |
| QString | icon () const |
| Getter method for property with the same name. | |
| QBindable< QString > | bindableIcon () const |
| Getter method for property with the same name. | |
| Positioning::PositionInfo | positionInfo () const |
| Getter method for property with the same name. | |
| QBindable< Positioning::PositionInfo > | bindablePositionInfo () const |
| Getter method for property with the same name. | |
| void | setPositionInfo (const Positioning::PositionInfo &newPositionInfo) |
| Setter function for property with the same name. | |
| Units::Distance | uncertaintyRadius () const |
| Getter method for property with the same name. | |
| QBindable< Units::Distance > | bindableUncertaintyRadius () const |
| Getter method for property with the same name. | |
| Public Member Functions inherited from Traffic::TrafficFactor_Abstract | |
| TrafficFactor_Abstract (QObject *parent=nullptr) | |
| Default constructor. | |
| bool | hasHigherPriorityThan (const TrafficFactor_Abstract &rhs) const |
| Estimates if this traffic object has higher priority than other traffic object. | |
| void | startLifetime () |
| Starts or extends the lifetime of this object. | |
| int | alarmLevel () const |
| Getter method for property with the same name. | |
| QBindable< int > | bindableAlarmLevel () |
| Getter method for property with the same name. | |
| bool | animate () const |
| Getter method for property with the same name. | |
| QBindable< bool > | bindableAnimate () |
| Getter method for property with the same name. | |
| QString | callSign () const |
| Getter method for property with the same name. | |
| QBindable< QString > | bindableCallSign () const |
| Getter method for property with the same name. | |
| QString | color () const |
| Getter method for property with the same name. | |
| QBindable< QString > | bindableColor () const |
| Getter method for property with the same name. | |
| QString | description () const |
| Getter method for property with the same name. | |
| QBindable< QString > | bindableDescription () const |
| Getter method for property with the same name. | |
| Units::Distance | hDist () const |
| Getter method for property with the same name. | |
| QBindable< Units::Distance > | bindableHDist () |
| Getter method for property with the same name. | |
| QString | ID () const |
| Getter method for property with the same name. | |
| QBindable< QString > | bindableID () const |
| Getter method for property with the same name. | |
| bool | relevant () const |
| Getter method for property with the same name. | |
| QBindable< bool > | bindableRelevant () |
| Getter method for property with the same name. | |
| QString | relevantString () const |
| Getter method for property with the same name. | |
| QBindable< QString > | bindableRelevantString () |
| Getter method for property with the same name. | |
| TrafficFactor_Abstract::Type | type () const |
| Getter method for property with the same name. | |
| QBindable< TrafficFactor_Abstract::Type > | bindableType () |
| Getter method for property with the same name. | |
| QString | typeString () const |
| Getter method for property with the same name. | |
| QBindable< QString > | bindableTypeString () |
| Getter method for property with the same name. | |
| bool | valid () const |
| Getter method for property with the same name. | |
| QBindable< bool > | bindableValid () |
| Getter method for property with the same name. | |
| Units::Distance | vDist () const |
| Getter method for property with the same name. | |
| QBindable< Units::Distance > | bindableVDist () |
| Getter method for property with the same name. | |
| void | setAlarmLevel (int newAlarmLevel) |
| Setter function for property with the same name. | |
| void | setCallSign (const QString &newCallSign) |
| Setter function for property with the same name. | |
| void | setHDist (Units::Distance newHDist) |
| Setter function for property with the same name. | |
| void | setID (const QString &newID) |
| Setter function for property with the same name. | |
| void | setType (TrafficFactor_Abstract::Type newType) |
| Setter function for property with the same name. | |
| void | setVDist (Units::Distance newVDist) |
| Setter function for property with the same name. | |
Properties | |
| QGeoCoordinate | extrapolatedCoordinate |
| Extrapolated Coordinate. | |
| Units::Angle | extrapolatedTrueTrack |
| Extrapolated True Track. | |
| QString | icon |
| Suggested icon. | |
| Positioning::PositionInfo | positionInfo |
| PositionInfo of the traffic. | |
| Units::Distance | uncertaintyRadius |
| Uncertainty radius. | |
| Properties inherited from Traffic::TrafficFactor_Abstract | |
| int | alarmLevel |
| Alarm Level. | |
| bool | animate |
| Indicates if changes in properties should be animated in the GUI. | |
| QString | callSign |
| Call sign. | |
| QString | color |
| Suggested color for GUI representation of the traffic. | |
| QString | description |
| Description of the traffic, for use in GUI. | |
| Units::Distance | hDist |
| Horizontal distance from own position to the traffic, at the time of report. | |
| QString | ID |
| Identifier string of the traffic. | |
| bool | relevant |
| Indicates relevant traffic. | |
| QString | relevantString |
| Translated string containing the 'relevant' property. | |
| Type | type |
| Type of aircraft, as reported by the traffic receiver. | |
| QString | typeString |
| Type of aircraft, as reported by the traffic receiver. | |
| bool | valid |
| Validity. | |
| Units::Distance | vDist |
| Vertical distance from own position to the traffic, at the time of report. | |
Additional Inherited Members | |
| Public Types inherited from Traffic::TrafficFactor_Abstract | |
| enum | Type : quint8 { unknown , Aircraft , Airship , Balloon , Copter , Drone , Glider , HangGlider , Jet , Paraglider , Skydiver , StaticObstacle , TowPlane } |
| Aircraft type. More... | |
| Static Public Member Functions inherited from Traffic::TrafficFactor_Abstract | |
| static bool | isRelevant (Units::Distance hDist, Units::Distance vDist) |
| Relevance criterion shared by the "relevant" property and priority logic. | |
| Static Public Attributes inherited from Traffic::TrafficFactor_Abstract | |
| static constexpr auto | lifetime = 45s |
| Length of lifetime for objects of this class. | |
| static constexpr Units::Distance | maxVerticalDistance = Units::Distance::fromM(1500.0) |
| Maximal vertical distance for relevant traffic. | |
| static constexpr Units::Distance | maxHorizontalDistance = Units::Distance::fromNM(20.0) |
| Maximal horizontal distance for relevant traffic. | |
| Protected Member Functions inherited from Traffic::TrafficFactor_Abstract | |
| void | updateFrom (const TrafficFactorData &data) |
| Update this object with newer data for the same traffic factor. | |
| void | replaceBy (const TrafficFactorData &data) |
| Replace this object by a different traffic factor. | |
| bool | isSameFactorAs (const TrafficFactorData &data) const |
| Check whether a data record refers to the same factor as *this. | |
| Static Protected Attributes inherited from Traffic::TrafficFactor_Abstract | |
| static constexpr qsizetype | idMatchLength = 6 |
| Number of characters in ICAO HEX IDs. | |
Traffic factor whose precise position is known.
Objects of this class represent traffic factors whose precise position is known. Other properties of the traffic, such as heading and ground speed, might also be known. Compared to TrafficFactor_Abstract, instances of this class hold an important additional property, namely the positionInfo for the traffic.
Definition at line 40 of file TrafficFactor_WithPosition.h.
|
explicit |
Default constructor.
| parent | The standard QObject parent pointer |
|
inlinenodiscard |
Getter method for property with the same name.
Definition at line 155 of file TrafficFactor_WithPosition.h.
|
inlinenodiscard |
Getter method for property with the same name.
Definition at line 179 of file TrafficFactor_WithPosition.h.
|
inlinenodiscard |
Getter method for property with the same name.
Definition at line 198 of file TrafficFactor_WithPosition.h.
|
inlinenodiscard |
Getter method for property with the same name.
Definition at line 213 of file TrafficFactor_WithPosition.h.
|
inlinenodiscard |
Getter method for property with the same name.
Definition at line 245 of file TrafficFactor_WithPosition.h.
|
inlinenodiscard |
Getter method for property with the same name.
Definition at line 149 of file TrafficFactor_WithPosition.h.
|
inlinenodiscard |
Getter method for property with the same name.
Definition at line 173 of file TrafficFactor_WithPosition.h.
|
inlinenodiscard |
Getter method for property with the same name.
Definition at line 192 of file TrafficFactor_WithPosition.h.
|
inlinenodiscard |
Getter method for property with the same name.
Definition at line 207 of file TrafficFactor_WithPosition.h.
|
inline |
Replace this object by a different traffic factor.
This method is for the case where this is repurposed to represent a *different traffic factor, namely the one described by data. It takes over the positionInfo of data and replaces the remaining properties through TrafficFactor_Abstract::replaceBy().
| data | Data record whose contents replace the data of *this |
Definition at line 113 of file TrafficFactor_WithPosition.h.
|
inline |
Setter function for property with the same name.
| newPositionInfo | Property positionInfo |
Definition at line 222 of file TrafficFactor_WithPosition.h.
|
inlinenodiscard |
Getter method for property with the same name.
Definition at line 239 of file TrafficFactor_WithPosition.h.
|
slot |
Update extrapolated data.
This method extrapolates the position of the aircraft and sets the property extrapolatedCoordinate appropriately.
|
inlinenodiscard |
Offer a data record to this object, for the same traffic factor.
This method checks whether data describes the same traffic factor as *this, by comparing identifiers. The intended use is that a caller offers a freshly received record to each of its traffic objects in turn until one accepts it.
When the record is adopted, the positionInfo is taken over and the remaining properties are updated through TrafficFactor_Abstract::updateFrom(); see there for how the "animate" property, callsign and type are handled.
| data | Data record offered to *this |
Definition at line 85 of file TrafficFactor_WithPosition.h.
|
read |
Extrapolated Coordinate.
Extrapolated coordinate of the traffic, for use in the GUI. For performance reasons, instances of this class do not have their own timer/animation logic to update the property. Instead, the property is set whenever the positionInfo changes and whenever the slot updatedExtrapolatedData() is called. The owner of this class (= TrafficDataProvider) is responsible to call updatedExtrapolatedData() at regular intervals.
Definition at line 143 of file TrafficFactor_WithPosition.h.
|
read |
Extrapolated True Track.
Extrapolated true track of the traffic, for use in the GUI. For performance reasons, instances of this class do not have their own timer/animation logic to update the property. Instead, the property is set whenever the positionInfo changes and whenever the slot updatedExtrapolatedData() is called. The owner of this class (= TrafficDataProvider) is responsible to call updatedExtrapolatedData() at regular intervals.
Definition at line 167 of file TrafficFactor_WithPosition.h.
|
read |
Suggested icon.
Depending on alarm level, type and movement of the traffic opponent, this property suggests an icon for GUI representation of the traffic.
Definition at line 186 of file TrafficFactor_WithPosition.h.
|
read |
Uncertainty radius.
If the last position update is less than 30s ago, this property holds the value zero. If the last position update is more than 30s ago, this property holds the radius of the "uncertainty circle" that should be drawn around the extrapolated position, to notify the user that the position data is stale. The radius is also zero when the object is invalid or has no finite groundSpeed/trueTrack.
Definition at line 233 of file TrafficFactor_WithPosition.h.