QtFit  0.1
Internal library development documentation
All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
WeatherConditionsMessage Class Reference

The WeatherConditionsMessage class represents a FIT WeatherConditionsMessage data message. More...

Inheritance diagram for WeatherConditionsMessage:
[legend]
Collaboration diagram for WeatherConditionsMessage:
[legend]

Public Member Functions

 WeatherConditionsMessage ()
 Constructs a WeatherConditionsMessage object. More...
 
DateTime timestamp () const
 Returns the WeatherConditionsMessage data message's timestamp field's current value. More...
 
WeatherReport weatherReport () const
 Returns the WeatherConditionsMessage data message's weatherReport field's current value. More...
 
qint8 temperature () const
 Returns the WeatherConditionsMessage data message's temperature field's current value. More...
 
WeatherStatus condition () const
 Returns the WeatherConditionsMessage data message's condition field's current value. More...
 
quint16 windDirection () const
 Returns the WeatherConditionsMessage data message's windDirection field's current value. More...
 
quint16 windSpeed () const
 Returns the WeatherConditionsMessage data message's windSpeed field's current value. More...
 
quint8 precipitationProbability () const
 Returns the WeatherConditionsMessage data message's precipitationProbability field's current value. More...
 
qint8 temperatureFeelsLike () const
 Returns the WeatherConditionsMessage data message's temperatureFeelsLike field's current value. More...
 
quint8 relativeHumidity () const
 Returns the WeatherConditionsMessage data message's relativeHumidity field's current value. More...
 
QString location () const
 Returns the WeatherConditionsMessage data message's location field's current value. More...
 
DateTime observedAtTime () const
 Returns the WeatherConditionsMessage data message's observedAtTime field's current value. More...
 
qint32 observedLocationLat () const
 Returns the WeatherConditionsMessage data message's observedLocationLat field's current value. More...
 
qint32 observedLocationLong () const
 Returns the WeatherConditionsMessage data message's observedLocationLong field's current value. More...
 
DayOfWeek dayOfWeek () const
 Returns the WeatherConditionsMessage data message's dayOfWeek field's current value. More...
 
qint8 highTemperature () const
 Returns the WeatherConditionsMessage data message's highTemperature field's current value. More...
 
qint8 lowTemperature () const
 Returns the WeatherConditionsMessage data message's lowTemperature field's current value. More...
 
void setTimestamp (const DateTime timestamp)
 Sets the timestamp field to timestamp. More...
 
void setWeatherReport (const WeatherReport weatherReport)
 Sets the weatherReport field to weatherReport. More...
 
void setTemperature (const qint8 temperature)
 Sets the temperature field to temperature. More...
 
void setCondition (const WeatherStatus condition)
 Sets the condition field to condition. More...
 
void setWindDirection (const quint16 windDirection)
 Sets the windDirection field to windDirection. More...
 
void setWindSpeed (const quint16 windSpeed)
 Sets the windSpeed field to windSpeed. More...
 
void setPrecipitationProbability (const quint8 precipitationProbability)
 Sets the precipitationProbability field to precipitationProbability. More...
 
void setTemperatureFeelsLike (const qint8 temperatureFeelsLike)
 Sets the temperatureFeelsLike field to temperatureFeelsLike. More...
 
void setRelativeHumidity (const quint8 relativeHumidity)
 Sets the relativeHumidity field to relativeHumidity. More...
 
void setLocation (const QString location)
 Sets the location field to location. More...
 
void setObservedAtTime (const DateTime observedAtTime)
 Sets the observedAtTime field to observedAtTime. More...
 
void setObservedLocationLat (const qint32 observedLocationLat)
 Sets the observedLocationLat field to observedLocationLat. More...
 
void setObservedLocationLong (const qint32 observedLocationLong)
 Sets the observedLocationLong field to observedLocationLong. More...
 
void setDayOfWeek (const DayOfWeek dayOfWeek)
 Sets the dayOfWeek field to dayOfWeek. More...
 
void setHighTemperature (const qint8 highTemperature)
 Sets the highTemperature field to highTemperature. More...
 
void setLowTemperature (const qint8 lowTemperature)
 Sets the lowTemperature field to lowTemperature. More...
 
- Public Member Functions inherited from AbstractDataMessage
 ~AbstractDataMessage ()
 Destroys the AbstractDataMessage object.
 
MesgNum globalMessageNumber () const
 Returns the data message's global message number. More...
 

Protected Member Functions

 WeatherConditionsMessage (WeatherConditionsMessagePrivate *const d)
 
- Protected Member Functions inherited from AbstractDataMessage
 AbstractDataMessage (AbstractDataMessagePrivate *const d)
 

Additional Inherited Members

- Static Public Member Functions inherited from AbstractDataMessage
static AbstractDataMessagefromData (const DataDefinition *const defn, const QByteArray &record)
 Constructs the relevant AbstractDataMessage-derived class to parse record according to defn. More...
 
- Protected Attributes inherited from AbstractDataMessage
AbstractDataMessagePrivate *const d_ptr
 Internal d-pointer.
 

Detailed Description

The WeatherConditionsMessage class represents a FIT WeatherConditionsMessage data message.

See also
DataMessage

Definition at line 39 of file weatherconditionsmessage.h.

Constructor & Destructor Documentation

◆ WeatherConditionsMessage() [1/2]

WeatherConditionsMessage::WeatherConditionsMessage ( )

Constructs a WeatherConditionsMessage object.

Typically, instances of this class will be returned by FitStreamReader::readNext, but this constructor may be used, along with the relevant setter methods, to create a valid message.

Definition at line 52 of file weatherconditionsmessage.cpp.

53 {
54 
55 }
The AbstractDataMessage class is the polymorphic base class for all FIT Data Message classes.

◆ WeatherConditionsMessage() [2/2]

WeatherConditionsMessage::WeatherConditionsMessage ( WeatherConditionsMessagePrivate *const  d)
explicitprotected

Constructs a WeatherConditionsMessage object with private implementation d.

Parameters
dPointer to private implementation.

Definition at line 64 of file weatherconditionsmessage.cpp.

65 {
66 
67 }

Member Function Documentation

◆ condition()

WeatherStatus WeatherConditionsMessage::condition ( ) const

Returns the WeatherConditionsMessage data message's condition field's current value.

Corresponds to GSC Response weatherIcon field

Returns
the condition field value.

Definition at line 113 of file weatherconditionsmessage.cpp.

114 {
115  Q_D(const WeatherConditionsMessage);
116  return d->condition;
117 }
The WeatherConditionsMessage class represents a FIT WeatherConditionsMessage data message.

Referenced by setCondition().

Here is the caller graph for this function:

◆ dayOfWeek()

DayOfWeek WeatherConditionsMessage::dayOfWeek ( ) const

Returns the WeatherConditionsMessage data message's dayOfWeek field's current value.

Returns
the dayOfWeek field value.

Definition at line 230 of file weatherconditionsmessage.cpp.

231 {
232  Q_D(const WeatherConditionsMessage);
233  return d->dayOfWeek;
234 }

Referenced by setDayOfWeek().

Here is the caller graph for this function:

◆ highTemperature()

qint8 WeatherConditionsMessage::highTemperature ( ) const

Returns the WeatherConditionsMessage data message's highTemperature field's current value.

Returns
the highTemperature field value.

Definition at line 241 of file weatherconditionsmessage.cpp.

242 {
243  Q_D(const WeatherConditionsMessage);
244  return d->highTemperature;
245 }

Referenced by setHighTemperature().

Here is the caller graph for this function:

◆ location()

QString WeatherConditionsMessage::location ( ) const

Returns the WeatherConditionsMessage data message's location field's current value.

string corresponding to GCS response location string

Returns
the location field value.

Definition at line 186 of file weatherconditionsmessage.cpp.

187 {
188  Q_D(const WeatherConditionsMessage);
189  return d->location;
190 }

Referenced by setLocation().

Here is the caller graph for this function:

◆ lowTemperature()

qint8 WeatherConditionsMessage::lowTemperature ( ) const

Returns the WeatherConditionsMessage data message's lowTemperature field's current value.

Returns
the lowTemperature field value.

Definition at line 252 of file weatherconditionsmessage.cpp.

253 {
254  Q_D(const WeatherConditionsMessage);
255  return d->lowTemperature;
256 }

Referenced by setLowTemperature().

Here is the caller graph for this function:

◆ observedAtTime()

DateTime WeatherConditionsMessage::observedAtTime ( ) const

Returns the WeatherConditionsMessage data message's observedAtTime field's current value.

Returns
the observedAtTime field value.

Definition at line 197 of file weatherconditionsmessage.cpp.

198 {
199  Q_D(const WeatherConditionsMessage);
200  return d->observedAtTime;
201 }

Referenced by setObservedAtTime().

Here is the caller graph for this function:

◆ observedLocationLat()

qint32 WeatherConditionsMessage::observedLocationLat ( ) const

Returns the WeatherConditionsMessage data message's observedLocationLat field's current value.

Returns
the observedLocationLat field value.

Definition at line 208 of file weatherconditionsmessage.cpp.

209 {
210  Q_D(const WeatherConditionsMessage);
211  return d->observedLocationLat;
212 }

Referenced by setObservedLocationLat().

Here is the caller graph for this function:

◆ observedLocationLong()

qint32 WeatherConditionsMessage::observedLocationLong ( ) const

Returns the WeatherConditionsMessage data message's observedLocationLong field's current value.

Returns
the observedLocationLong field value.

Definition at line 219 of file weatherconditionsmessage.cpp.

220 {
221  Q_D(const WeatherConditionsMessage);
222  return d->observedLocationLong;
223 }

Referenced by setObservedLocationLong().

Here is the caller graph for this function:

◆ precipitationProbability()

quint8 WeatherConditionsMessage::precipitationProbability ( ) const

Returns the WeatherConditionsMessage data message's precipitationProbability field's current value.

range 0-100

Returns
the precipitationProbability field value.

Definition at line 148 of file weatherconditionsmessage.cpp.

149 {
150  Q_D(const WeatherConditionsMessage);
151  return d->precipitationProbability;
152 }

Referenced by setPrecipitationProbability().

Here is the caller graph for this function:

◆ relativeHumidity()

quint8 WeatherConditionsMessage::relativeHumidity ( ) const

Returns the WeatherConditionsMessage data message's relativeHumidity field's current value.

Returns
the relativeHumidity field value.

Definition at line 173 of file weatherconditionsmessage.cpp.

174 {
175  Q_D(const WeatherConditionsMessage);
176  return d->relativeHumidity;
177 }

Referenced by setRelativeHumidity().

Here is the caller graph for this function:

◆ setCondition()

void WeatherConditionsMessage::setCondition ( const WeatherStatus  condition)

Sets the condition field to condition.

Parameters
conditionThe field value to set.

Definition at line 293 of file weatherconditionsmessage.cpp.

294 {
296  d->condition = condition;
297 }
WeatherStatus condition() const
Returns the WeatherConditionsMessage data message's condition field's current value.

References condition().

Here is the call graph for this function:

◆ setDayOfWeek()

void WeatherConditionsMessage::setDayOfWeek ( const DayOfWeek  dayOfWeek)

Sets the dayOfWeek field to dayOfWeek.

Parameters
dayOfWeekThe field value to set.

Definition at line 393 of file weatherconditionsmessage.cpp.

394 {
396  d->dayOfWeek = dayOfWeek;
397 }
DayOfWeek dayOfWeek() const
Returns the WeatherConditionsMessage data message's dayOfWeek field's current value.

References dayOfWeek().

Here is the call graph for this function:

◆ setHighTemperature()

void WeatherConditionsMessage::setHighTemperature ( const qint8  highTemperature)

Sets the highTemperature field to highTemperature.

Parameters
highTemperatureThe field value to set.

Definition at line 403 of file weatherconditionsmessage.cpp.

404 {
406  d->highTemperature = highTemperature;
407 }
qint8 highTemperature() const
Returns the WeatherConditionsMessage data message's highTemperature field's current value.

References highTemperature().

Here is the call graph for this function:

◆ setLocation()

void WeatherConditionsMessage::setLocation ( const QString  location)

Sets the location field to location.

Parameters
locationThe field value to set.

Definition at line 353 of file weatherconditionsmessage.cpp.

354 {
356  d->location = location;
357 }
QString location() const
Returns the WeatherConditionsMessage data message's location field's current value.

References location().

Here is the call graph for this function:

◆ setLowTemperature()

void WeatherConditionsMessage::setLowTemperature ( const qint8  lowTemperature)

Sets the lowTemperature field to lowTemperature.

Parameters
lowTemperatureThe field value to set.

Definition at line 413 of file weatherconditionsmessage.cpp.

414 {
416  d->lowTemperature = lowTemperature;
417 }
qint8 lowTemperature() const
Returns the WeatherConditionsMessage data message's lowTemperature field's current value.

References lowTemperature().

Here is the call graph for this function:

◆ setObservedAtTime()

void WeatherConditionsMessage::setObservedAtTime ( const DateTime  observedAtTime)

Sets the observedAtTime field to observedAtTime.

Parameters
observedAtTimeThe field value to set.

Definition at line 363 of file weatherconditionsmessage.cpp.

364 {
366  d->observedAtTime = observedAtTime;
367 }
DateTime observedAtTime() const
Returns the WeatherConditionsMessage data message's observedAtTime field's current value.

References observedAtTime().

Here is the call graph for this function:

◆ setObservedLocationLat()

void WeatherConditionsMessage::setObservedLocationLat ( const qint32  observedLocationLat)

Sets the observedLocationLat field to observedLocationLat.

Parameters
observedLocationLatThe field value to set.

Definition at line 373 of file weatherconditionsmessage.cpp.

374 {
376  d->observedLocationLat = observedLocationLat;
377 }
qint32 observedLocationLat() const
Returns the WeatherConditionsMessage data message's observedLocationLat field's current value.

References observedLocationLat().

Here is the call graph for this function:

◆ setObservedLocationLong()

void WeatherConditionsMessage::setObservedLocationLong ( const qint32  observedLocationLong)

Sets the observedLocationLong field to observedLocationLong.

Parameters
observedLocationLongThe field value to set.

Definition at line 383 of file weatherconditionsmessage.cpp.

384 {
386  d->observedLocationLong = observedLocationLong;
387 }
qint32 observedLocationLong() const
Returns the WeatherConditionsMessage data message's observedLocationLong field's current value.

References observedLocationLong().

Here is the call graph for this function:

◆ setPrecipitationProbability()

void WeatherConditionsMessage::setPrecipitationProbability ( const quint8  precipitationProbability)

Sets the precipitationProbability field to precipitationProbability.

Parameters
precipitationProbabilityThe field value to set.

Definition at line 323 of file weatherconditionsmessage.cpp.

324 {
326  d->precipitationProbability = precipitationProbability;
327 }
quint8 precipitationProbability() const
Returns the WeatherConditionsMessage data message's precipitationProbability field's current value.

References precipitationProbability().

Here is the call graph for this function:

◆ setRelativeHumidity()

void WeatherConditionsMessage::setRelativeHumidity ( const quint8  relativeHumidity)

Sets the relativeHumidity field to relativeHumidity.

Parameters
relativeHumidityThe field value to set.

Definition at line 343 of file weatherconditionsmessage.cpp.

344 {
346  d->relativeHumidity = relativeHumidity;
347 }
quint8 relativeHumidity() const
Returns the WeatherConditionsMessage data message's relativeHumidity field's current value.

References relativeHumidity().

Here is the call graph for this function:

◆ setTemperature()

void WeatherConditionsMessage::setTemperature ( const qint8  temperature)

Sets the temperature field to temperature.

Parameters
temperatureThe field value to set.

Definition at line 283 of file weatherconditionsmessage.cpp.

284 {
286  d->temperature = temperature;
287 }
qint8 temperature() const
Returns the WeatherConditionsMessage data message's temperature field's current value.

References temperature().

Here is the call graph for this function:

◆ setTemperatureFeelsLike()

void WeatherConditionsMessage::setTemperatureFeelsLike ( const qint8  temperatureFeelsLike)

Sets the temperatureFeelsLike field to temperatureFeelsLike.

Parameters
temperatureFeelsLikeThe field value to set.

Definition at line 333 of file weatherconditionsmessage.cpp.

334 {
336  d->temperatureFeelsLike = temperatureFeelsLike;
337 }
qint8 temperatureFeelsLike() const
Returns the WeatherConditionsMessage data message's temperatureFeelsLike field's current value.

References temperatureFeelsLike().

Here is the call graph for this function:

◆ setTimestamp()

void WeatherConditionsMessage::setTimestamp ( const DateTime  timestamp)

Sets the timestamp field to timestamp.

Parameters
timestampThe field value to set.

Definition at line 263 of file weatherconditionsmessage.cpp.

264 {
266  d->timestamp = timestamp;
267 }
DateTime timestamp() const
Returns the WeatherConditionsMessage data message's timestamp field's current value.

References timestamp().

Here is the call graph for this function:

◆ setWeatherReport()

void WeatherConditionsMessage::setWeatherReport ( const WeatherReport  weatherReport)

Sets the weatherReport field to weatherReport.

Parameters
weatherReportThe field value to set.

Definition at line 273 of file weatherconditionsmessage.cpp.

274 {
276  d->weatherReport = weatherReport;
277 }
WeatherReport weatherReport() const
Returns the WeatherConditionsMessage data message's weatherReport field's current value.

References weatherReport().

Here is the call graph for this function:

◆ setWindDirection()

void WeatherConditionsMessage::setWindDirection ( const quint16  windDirection)

Sets the windDirection field to windDirection.

Parameters
windDirectionThe field value to set.

Definition at line 303 of file weatherconditionsmessage.cpp.

304 {
306  d->windDirection = windDirection;
307 }
quint16 windDirection() const
Returns the WeatherConditionsMessage data message's windDirection field's current value.

References windDirection().

Here is the call graph for this function:

◆ setWindSpeed()

void WeatherConditionsMessage::setWindSpeed ( const quint16  windSpeed)

Sets the windSpeed field to windSpeed.

Parameters
windSpeedThe field value to set.

Definition at line 313 of file weatherconditionsmessage.cpp.

314 {
316  d->windSpeed = windSpeed;
317 }
quint16 windSpeed() const
Returns the WeatherConditionsMessage data message's windSpeed field's current value.

References windSpeed().

Here is the call graph for this function:

◆ temperature()

qint8 WeatherConditionsMessage::temperature ( ) const

Returns the WeatherConditionsMessage data message's temperature field's current value.

Returns
the temperature field value.

Definition at line 100 of file weatherconditionsmessage.cpp.

101 {
102  Q_D(const WeatherConditionsMessage);
103  return d->temperature;
104 }

Referenced by setTemperature().

Here is the caller graph for this function:

◆ temperatureFeelsLike()

qint8 WeatherConditionsMessage::temperatureFeelsLike ( ) const

Returns the WeatherConditionsMessage data message's temperatureFeelsLike field's current value.

Heat Index if GCS heatIdx above or equal to 90F or wind chill if GCS windChill below or equal to 32F

Returns
the temperatureFeelsLike field value.

Definition at line 162 of file weatherconditionsmessage.cpp.

163 {
164  Q_D(const WeatherConditionsMessage);
165  return d->temperatureFeelsLike;
166 }

Referenced by setTemperatureFeelsLike().

Here is the caller graph for this function:

◆ timestamp()

DateTime WeatherConditionsMessage::timestamp ( ) const

Returns the WeatherConditionsMessage data message's timestamp field's current value.

time of update for current conditions, else forecast time

Returns
the timestamp field value.

Definition at line 76 of file weatherconditionsmessage.cpp.

77 {
78  Q_D(const WeatherConditionsMessage);
79  return d->timestamp;
80 }

Referenced by setTimestamp().

Here is the caller graph for this function:

◆ weatherReport()

WeatherReport WeatherConditionsMessage::weatherReport ( ) const

Returns the WeatherConditionsMessage data message's weatherReport field's current value.

Current or forecast

Returns
the weatherReport field value.

Definition at line 89 of file weatherconditionsmessage.cpp.

90 {
91  Q_D(const WeatherConditionsMessage);
92  return d->weatherReport;
93 }

Referenced by setWeatherReport().

Here is the caller graph for this function:

◆ windDirection()

quint16 WeatherConditionsMessage::windDirection ( ) const

Returns the WeatherConditionsMessage data message's windDirection field's current value.

Returns
the windDirection field value.

Definition at line 124 of file weatherconditionsmessage.cpp.

125 {
126  Q_D(const WeatherConditionsMessage);
127  return d->windDirection;
128 }

Referenced by setWindDirection().

Here is the caller graph for this function:

◆ windSpeed()

quint16 WeatherConditionsMessage::windSpeed ( ) const

Returns the WeatherConditionsMessage data message's windSpeed field's current value.

Returns
the windSpeed field value.

Definition at line 135 of file weatherconditionsmessage.cpp.

136 {
137  Q_D(const WeatherConditionsMessage);
138  return d->windSpeed;
139 }

Referenced by setWindSpeed().

Here is the caller graph for this function:

The documentation for this class was generated from the following files: