在我的android应用程序中,我想从当前位置的5个最近地点搜索地图。此参数用于设置边界lowerLeftLatitude,lowerLeftLongitude,upperRightLatitude,upperRightLongitude。但我不知道设置它们的值。搜索距离我当前位置最近的地方Android地图
该代码给出了5个plces:
try {
List<Address> addressList =geocoder.getFromLocationName(staddress, 5);//, lowerLeftLatitude, lowerLeftLongitude, upperRightLatitude, upperRightLongitude;
if(adr.getCountryName()!=null)
str+=adr.getCountryName().toString();
}
Log.v(addressList.toString(),"result");
editText.setText(addressList.toString());
} catch (IOException e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
}
我如何设置最近的地方,这些价值从我的位置或是任何其他方式来获得最近的地方呢?
你目前的代码给你5个最近的地址,没有指定边界坐标。那么你还需要什么? – Sameer
是的,如果你得到5个最近的地址,你还需要什么?更具体一点吧 – Aamirkhan
我想获得特定半径的地方.. – TamiL