Class Veery
getPois()
Get the list of last known POIs of the user.
Parameters
none
Returns
Veery.Pois object
Usage / Example
The following example prints the POIs to a mMap Google Maps object
JSONObject[] geoJsonData = veery.getPois().toGeoJSONArray(); if (geoJsonData!= null){ // JSONObject contains circles arround the POI for (int i = 0; i < geoJsonData.length; i++) { JSONObject object = geoJsonData[i]; GeoJsonLayer layer = new GeoJsonLayer(mMap, object); // Draw the circles layer.addLayerToMap(); Location loc = veery.getPois().toArray()[i]; LatLng latlon = new LatLng(loc.getLatitude(), loc.getLongitude()); // Draw a marker in the middle of the POIs zone mMap.addMarker(new MarkerOptions().position(latlon); } }
Info
GeoJsonLayer classes are available on Google Maps API
User interaction
none
See also
getPois
Get last known list of POIs for that user.
requestPoiUpdate
Request for a callback event when a new set of POIs is computed by the Veery Backend.
stopPoiUpdate
Cancel the call to requestPoiUpdate.
Pois.toArray
Return an array of Location object.
Pois.toGeoJSONArray
Return an array of GeoJSON (circles around the POIs).
Pois.count
Return the amount of POIs known.
Pois.getWeight
Return the percentage of time spent at the specified POI.
PoiUpdate.onPoiUpdate
Callback triggered every time a new set of POIs is computed by the Veery backend.