Back to project page android-cd-travis-example.
The source code is released under:
MIT License
If you think the Android project android-cd-travis-example listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.ruenzuo.weatherapp.requests; //from w w w . j a va 2 s . com import android.location.Location; import com.octo.android.robospice.request.springandroid.SpringAndroidSpiceRequest; import com.ruenzuo.weatherapp.pojos.ListCities; public class CityJsonRequest extends SpringAndroidSpiceRequest<ListCities> { private Location location; public CityJsonRequest(Location location) { super(ListCities.class); this.location = location; } @Override public ListCities loadDataFromNetwork() throws Exception { return getRestTemplate(). getForObject("http://api.openweathermap.org/data/2.5/find?lat=" + location.getLatitude() + "&lon=" + location.getLongitude() + "&cnt=100&type=json", ListCities.class); } }