package com.dayu.pipirrapp.bean.net; /** * author: zuo * Date: 2024-01-26 * Time: 10:23 * 备注:天气接口返回的实例 */ public class WeatherResponse { private Result[] results; private String date; public String getDate() { return date; } public void setDate(String date) { this.date = date; } public Result[] getResults() { return results; } public void setResults(Result[] value) { this.results = value; } public class Result { public Daily[] daily; //返回指定days天数的结果 public String last_update; public Location location; public Daily[] getDaily() { return daily; } public void setDaily(Daily[] value) { this.daily = value; } public String getLast_update() { return last_update; } public void setLast_update(String last_update) { this.last_update = last_update; } public Location getLocation() { return location; } public void setLocation(Location value) { this.location = value; } } public class Daily { private String code_day; //白天天气现象代码 private String code_night;//晚间天气现象代码 private String date;//日期(该城市的本地时间) private String high;//当天最高温度 private String humidity; //相对湿度,0~100,单位为百分比 private String low;//当天最低温度 private String precip;//降水概率,范围0~1,单位百分比(目前仅支持国外城市) private String rainfall; //降水量,单位mm private String text_day; //白天天气现象文字 private String text_night;//晚间天气现象文字 private String wind_direction;//风向文字 private String wind_direction_degree;//风向角度,范围0~360 private String wind_scale;//风力等级 private String wind_speed;//风速,单位km/h(当unit=c时)、mph(当unit=f时) public String getCode_day() { return code_day; } public void setCode_day(String code_day) { this.code_day = code_day; } public String getCode_night() { return code_night; } public void setCode_night(String code_night) { this.code_night = code_night; } public String getDate() { return date; } public void setDate(String date) { this.date = date; } public String getHigh() { return high; } public void setHigh(String high) { this.high = high; } public String getHumidity() { return humidity; } public void setHumidity(String humidity) { this.humidity = humidity; } public String getLow() { return low; } public void setLow(String low) { this.low = low; } public String getPrecip() { return precip; } public void setPrecip(String precip) { this.precip = precip; } public String getRainfall() { return rainfall; } public void setRainfall(String rainfall) { this.rainfall = rainfall; } public String getText_day() { return text_day; } public void setText_day(String text_day) { this.text_day = text_day; } public String getText_night() { return text_night; } public void setText_night(String text_night) { this.text_night = text_night; } public String getWind_direction() { return wind_direction; } public void setWind_direction(String wind_direction) { this.wind_direction = wind_direction; } public String getWind_direction_degree() { return wind_direction_degree; } public void setWind_direction_degree(String wind_direction_degree) { this.wind_direction_degree = wind_direction_degree; } public String getWind_scale() { return wind_scale; } public void setWind_scale(String wind_scale) { this.wind_scale = wind_scale; } public String getWind_speed() { return wind_speed; } public void setWind_speed(String wind_speed) { this.wind_speed = wind_speed; } } public class Location { private String country; private String id; private String name; private String path; private String timezone; private String timezoneOffset; public String getCountry() { return country; } public void setCountry(String value) { this.country = value; } public String getid() { return id; } public void setid(String value) { this.id = value; } public String getName() { return name; } public void setName(String value) { this.name = value; } public String getPath() { return path; } public void setPath(String value) { this.path = value; } public String getTimezone() { return timezone; } public void setTimezone(String value) { this.timezone = value; } public String getTimezoneOffset() { return timezoneOffset; } public void setTimezoneOffset(String value) { this.timezoneOffset = value; } } }