1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
| for (int i = 0; i < confList.size(); i++) {
final String label = confList.get(i).getTitreConf();
final int j =i;
if (!label.equals("-")){
System.out.println("geocoder");
new Geocoder ().getLatLng(confList.get(i).getLieu(),
new LatLngCallback(){
@Override
public void onFailure() {
System.out.println("va mourir");
}
@Override
public void onSuccess(LatLng point) {
System.out.println("oui je suis dans onsuccess");
LatLng addressLatlng = LatLng.newInstance(point.getLatitude(), point.getLongitude());
confList.get(j).setLatLng(addressLatlng);
k = k-1;
System.out.println(k);
}
});
System.out.println("geocoder fin");
}
} |
Partager