Get current location using Snapshot API
suggest change// Remember to intialize your client as described in the Remarks section Awareness.SnapshotApi.getLocation(client) .setResultCallback(new ResultCallback<LocationResult>() { @Override public void onResult(@NonNull LocationResult locationResult) { Location location = locationResult.getLocation(); Log.i(getClass().getSimpleName(), "Coordinates: "location.getLatitude() + "," + location.getLongitude() + ", radius : " + location.getAccuracy()); } });
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents