Weather constructor
Weather({
- String apiUrl = 'https://api.open-meteo.com/v1/',
- required double latitude,
- required double longitude,
- double? elevation,
- TemperatureUnit? temperature_unit,
- WindspeedUnit? windspeed_unit,
- PrecipitationUnit? precipitation_unit,
- int? past_days,
- int? forecast_days,
- int? forecast_hours,
- int? forecast_minutely_15,
- int? past_hours,
- int? past_minutely_15,
- DateTime? start_date,
- DateTime? end_date,
- DateTime? start_hour,
- DateTime? end_hour,
- DateTime? start_minutely_15,
- DateTime? end_minutely_15,
- CellSelection? cell_selection,
- String? apikey,
Implementation
Weather({
this.apiUrl = 'https://api.open-meteo.com/v1/',
required this.latitude,
required this.longitude,
this.elevation,
this.temperature_unit,
this.windspeed_unit,
this.precipitation_unit,
this.past_days,
this.forecast_days,
this.forecast_hours,
this.forecast_minutely_15,
this.past_hours,
this.past_minutely_15,
this.start_date,
this.end_date,
this.start_hour,
this.end_hour,
this.start_minutely_15,
this.end_minutely_15,
this.cell_selection,
this.apikey,
}) {
Uri.parse(apiUrl);
throwCheckLatLng(latitude, longitude);
}