Class CurrentWeather
- Namespace
- SimpleWeather
- Assembly
- SimpleWeather.dll
An object that provides current weather data
public class CurrentWeather
- Inheritance
-
CurrentWeather
- Inherited Members
Constructors
CurrentWeather(string)
Initializes a new instance of the CurrentWeather class from a JSON response.
public CurrentWeather(string jsonResponse)
Parameters
jsonResponsestringThe raw JSON returned by the weather API.
Properties
Base
Gets the OpenWeather base station identifier.
public string? Base { get; }
Property Value
City
Gets the city name associated with the reading.
public string? City { get; }
Property Value
CityID
Gets the city identifier assigned by OpenWeather.
public int? CityID { get; }
Property Value
- int?
Clouds
Gets the cloud coverage information.
public Clouds? Clouds { get; }
Property Value
Coordinates
Gets the coordinates associated with the weather reading.
public LatLong Coordinates { get; }
Property Value
Main
Gets the temperature and pressure readings.
public Main? Main { get; }
Property Value
Rain
Gets the rainfall totals.
public Rain? Rain { get; }
Property Value
Snow
Gets the snowfall totals.
public Snow? Snow { get; }
Property Value
StatusCode
Gets the HTTP-like status code when an error occurs.
public int? StatusCode { get; }
Property Value
- int?
Sys
Gets the system metadata values.
public Sys? Sys { get; }
Property Value
Timezone
Gets the timezone name returned by the API.
public string? Timezone { get; }
Property Value
TimezoneOffset
UTC (+/-) hour/s
public int? TimezoneOffset { get; }
Property Value
- int?
Visibility
Gets the visibility distance in meters when available.
public double? Visibility { get; }
Property Value
Weather
Gets the collection of high-level weather descriptors.
public Weather? Weather { get; }
Property Value
Wind
Gets the wind data for the reading.
public Wind? Wind { get; }