Lines Matching refs:location
30 import android.location.Address;
31 import android.location.Criteria;
32 import android.location.Geocoder;
33 import android.location.Location;
34 import android.location.LocationManager;
143 Location location = null; in computeMostGranularCommonLocation() local
147 location = (provider != null) ? locationManager.getLastKnownLocation(provider) : null; in computeMostGranularCommonLocation()
148 if (location != null) in computeMostGranularCommonLocation()
154 if (location != null) { in computeMostGranularCommonLocation()
155 Address currentAddress = lookupAddress(location.getLatitude(), location.getLongitude()); in computeMostGranularCommonLocation()
311 String location = null; in getReverseGeocodedLocation() local
320 location = addr.getAddressLine(0); in getReverseGeocodedLocation()
321 if (location != null && !("null".equals(location))) { in getReverseGeocodedLocation()
324 location = addr.getThoroughfare(); in getReverseGeocodedLocation()
325 if (location != null && !("null".equals(location))) { in getReverseGeocodedLocation()
328 location = addr.getFeatureName(); in getReverseGeocodedLocation()
329 if (location != null && !("null".equals(location))) { in getReverseGeocodedLocation()
336 return location; in getReverseGeocodedLocation()
341 if (location != null && location.length() > 0) { in getReverseGeocodedLocation()
342 location += ", " + locality; in getReverseGeocodedLocation()
344 location = locality; in getReverseGeocodedLocation()
350 return location; in getReverseGeocodedLocation()
355 if (location != null && location.length() > 0) { in getReverseGeocodedLocation()
356 location += ", " + adminArea; in getReverseGeocodedLocation()
358 location = adminArea; in getReverseGeocodedLocation()
364 return location; in getReverseGeocodedLocation()
369 if (location != null && location.length() > 0) { in getReverseGeocodedLocation()
370 location += ", " + countryCode; in getReverseGeocodedLocation()
372 location = addr.getCountryName(); in getReverseGeocodedLocation()
377 return location; in getReverseGeocodedLocation()