Skip to main content
GuidesAPI ReferenceExamplesFAQ

Base Entities

|

Weather-related functionalities are organized into distinct classes, each designed to encapsulate specific weather data.

The main classes include LocationForecast, Conditions, and Parameter. This guide provides a detailed explanation of each class and its purpose.


LocationForecast

The LocationForecast class retains data such as the forecast update datetime, the geographic location, and forecast data.

PropertyTypeDescription
updatedDateTimeForecast update datetime (UTC)
coordCoordinatesGeographic location
forecastList<Conditions>Forecast data
Current Weather Forecast explained

Conditions

The Conditions class retains weather conditions for a given timestamp.

PropertyTypeDescription
typeStringFor possible values see add ref[PredefinedParameterTypeValues]
stampDateTimeDatetime for condition (UTC)
imageUint8ListImage representation as Uint8List
imgImgThe conditions image as Img
descriptionStringDescription translated according to the current SDK language
daylightDaylightDaylight condition
paramsList<Parameter>Parameter list

PredefinedParameterTypeValues

The PredefinedParameterTypeValues class contains the common values for Parameter.type and Conditions.type.

PropertyDescriptionUnit
airQuality'AirQuality'-
dewPoint'DewPoint'°C
feelsLike'FeelsLike'°C
humidity'Humidity'%
pressure'Pressure'mb
sunRise'Sunrise'-
sunSet'Sunset'-
temperature'Temperature'°C
uv'UV'-
visibility'Visibility'km
windDirection'WindDirection'°
windSpeed'WindSpeed'km/h
temperatureLow'TemperatureLow'°C
temperatureHigh'TemperatureHigh'°C
danger

The WeatherService may return data with varying property types, depending on data availability. A response might include only a subset of the values listed above.


Parameter

The Parameter class contains weather parameter data.

PropertyTypeDescription
typeStringFor possible values see add ref[PredefinedParameterTypeValues]
valuedoubleValue
nameStringName translated according to the current SDK language
unitStringUnit