- UID
- 4954
- 注册时间
- 2014-4-14
- 在线时间
- 小时
- 最后登录
- 1970-1-1
- 精华
- 阅读权限
- 30
- 听众
- 收听
|
发表于 2022-9-25 08:10:42
|
显示全部楼层
List<Address> addresses;
geocoder = new Geocoder(this, Locale.getDefault());
addresses = geocoder.getFromLocation(latitude, longitude, 1);
String address = addresses.get(0).getAddressLine(0);
String city = addresses.get(0).getAddressLine(1);
String country = addresses.get(0).getAddressLine(2);
为openstreammap final String requestString = " CodeGo.net +
Double.toString(lat) + "&lon=" + Double.toString(lon) + "&zoom=18&addressdetails=1";
RequestBuilder builder = new RequestBuilder(RequestBuilder.GET, URL.encode(requestString));
try { |
|