File tree Expand file tree Collapse file tree 1 file changed +14
-8
lines changed Expand file tree Collapse file tree 1 file changed +14
-8
lines changed Original file line number Diff line number Diff line change @@ -37,16 +37,22 @@ weatherMap.getCityWeather(city, new WeatherCallback() {
37
37
public void success (WeatherResponseModel response ) {
38
38
Weather weather[] = response. getWeather();
39
39
String weatherMain = weather[0 ]. getMain();
40
- Double temperature = TempUnitConverter . convertToCelsius(response. getMain(). getTemp());
41
- String location = response. getName();
42
-
43
- String humidity= response. getMain(). getHumidity();
44
- String pressure = response. getMain(). getPressure();
45
- String windSpeed = response. getWind(). getSpeed();
46
-
47
- String iconLink = weather[0 ]. getIconLink();
48
40
}
49
41
```
42
+ To get temperature in specific units you can use:
43
+ ```Java
44
+ Double temperature = TempUnitConverter . convertToCelsius(response. getMain(). getTemp());
45
+ ```
46
+
47
+ To get other details you can use:
48
+ ```Java
49
+ Double temperature = TempUnitConverter . convertToCelsius(response. getMain(). getTemp());
50
+ String location = response. getName();
51
+ String humidity= response. getMain(). getHumidity();
52
+ String pressure = response. getMain(). getPressure();
53
+ String windSpeed = response. getWind(). getSpeed();
54
+ String iconLink = weather[0 ]. getIconLink();
55
+ ```
50
56
** By Location Coordinates ** :
51
57
```Java
52
58
weatherMap.getLocationWeather (latitude , longitude , new WeatherCallback () {
You can’t perform that action at this time.
0 commit comments