use of com.google.android.gms.location.LocationRequest in project Android-ReactiveLocation by mcharmas.
the class MockLocationsActivity method onLocationPermissionGranted.
@Override
protected void onLocationPermissionGranted() {
mockModeToggleButton.setChecked(true);
final LocationRequest locationRequest = LocationRequest.create().setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY).setInterval(2000);
updatedLocationSubscription = locationProvider.getUpdatedLocation(locationRequest).map(new LocationToStringFunc()).map(new Func1<String, String>() {
int count = 0;
@Override
public String call(String s) {
return s + " " + count++;
}
}).subscribe(new DisplayTextOnViewAction(updatedLocationView));
}
Aggregations