Class Info |
|---|
public class Situation implements Parcelable Current weather information. The information includes the weather ID, humidity, atmospheric temperature (Celsius and Fahrenheit), somatosensory temperature (Celsius and Fahrenheit), wind direction, wind level, wind speed, atmospheric pressure, UV intensity, and update time. |
Qualifier and Type | Method Name |
|---|---|
int | |
String | |
long | |
long | |
long | |
long | |
String | |
int | |
int | |
long | |
long | |
int |
Method |
|---|
public int getWeatherId() Obtains the weather ID. Weather IDs vary with the current weather. For example, 1 indicates sunny, 7 indicates cloudy, and 18 indicates rain. For details about the weather specified by a weather ID, please refer to WeatherId. |
Type | Description |
|---|---|
int | Weather ID. |
Method |
|---|
public String getHumidity() Obtains the humidity, in percentage. |
Type | Description |
|---|---|
String | Humidity, in percentage. |
Method |
|---|
public long getTemperatureC() Obtains the current atmospheric temperature (Celsius). |
Type | Description |
|---|---|
long | Current atmospheric temperature (Celsius). |
Method |
|---|
public long getTemperatureF() Obtains the current temperature (Fahrenheit). |
Type | Description |
|---|---|
long | Current temperature (Fahrenheit). |
Method |
|---|
public long getRealFeelC() Obtains the somatosensory temperature (Celsius). |
Type | Description |
|---|---|
long | Somatosensory temperature (Celsius). |
Method |
|---|
public long getRealFeelF() Obtains the somatosensory temperature (Fahrenheit). |
Type | Description |
|---|---|
long | Somatosensory temperature (Fahrenheit). |
Method |
|---|
public String getWindDir() Obtains the wind direction. The options are NE (northeast), E (east), SE (southeast), S (south), SW (southwest), W (west), N (north), and NW (northwest). |
Type | Description |
|---|---|
String | Wind direction. The options are NE (northeast), E (east), SE (southeast), S (south), SW (southwest), W (west), N (north), and NW (northwest). |
Method |
|---|
public int getWindLevel() Obtains the wind level. The value ranges from 0 to 17. 0: no wind |
Type | Description |
|---|---|
int | Wind level. The value ranges from 0 to 17. 0: no wind |
Method |
|---|
public int getWindSpeed() Obtains the wind speed (unit: km/h). |
Type | Description |
|---|---|
int | Wind speed (unit: km/h). |
Method |
|---|
public long getUpdateTime() Obtains the release time of the weather broadcast. |
Type | Description |
|---|---|
long | Release timestamp of the weather broadcast. |
Method |
|---|
public long getPressure() Obtains the atmospheric pressure, in hPa. |
Type | Description |
|---|---|
long | Atmospheric pressure, in hPa. |
Method |
|---|
public int getUvIndex() Obtains the current UV intensity. For details about the UV light levels, please refer to WeatherStatus. |
Type | Description |
|---|---|
int | UV intensity. |