我得到了答案从stackoverflow java reverse code to get address from lattitude and longitude
。但在这个问题的答案我不能访问packege GeoApi背景下,GeocodingResult,GeocodingApi.I我写的Java Web application.could谁能告诉我什么是packege或jar文件我下载到包括那些packege 我的答案代码是java反向代码从经度和纬度获取地址
GeoApiContext gtx = new GeoApiContext().setApiKey("**<<<<your-key-here>>>>**");
try {
GeocodingResult[] gResp = GeocodingApi.newRequest(gtx)
.latlng(new LatLng(37, -121)).await();
System.out.println(gResp[0].formattedAddress);
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
https://github.com/googlemaps/google-maps-services-java – shmosel