Skip to content

Instantly share code, notes, and snippets.

@FilHazer
Last active January 22, 2016 17:00
Show Gist options
  • Save FilHazer/74ed13a0eb6836efa8d3 to your computer and use it in GitHub Desktop.
Save FilHazer/74ed13a0eb6836efa8d3 to your computer and use it in GitHub Desktop.
public class GeofenceController {
..
public GoogleApiClient getGoogleApiClient(){
return googleApiClient;
}
public GeofencingRequest getAddGeofencingRequest() {
List<Geofence> geofencesToAdd = new ArrayList<>();
geofencesToAdd.add(geofence);
GeofencingRequest.Builder builder = new GeofencingRequest.Builder();
builder.setInitialTrigger(GeofencingRequest.INITIAL_TRIGGER_ENTER);
builder.addGeofences(geofencesToAdd);
return builder.build();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment