Skip to content

Instantly share code, notes, and snippets.

@ahmadazimi
Last active January 1, 2019 04:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ahmadazimi/2ea2e52f6d75796e9da936a451eb10ad to your computer and use it in GitHub Desktop.
Save ahmadazimi/2ea2e52f6d75796e9da936a451eb10ad to your computer and use it in GitHub Desktop.
// Initializing map
private void initMap(){
// add Standard_day map to layer BASE_MAP_INDEX
map.getOptions().setZoomRange(new Range(4.5f, 18f));
map.getLayers().insert(BASE_MAP_INDEX, NeshanServices.createBaseMap(NeshanMapStyle.STANDARD_DAY));
// Setting map focal position to a fixed position and setting camera zoom
map.setFocalPointPosition(new LngLat(51.330743, 35.767234),0 );
map.setZoom(14,0);
// adding traffic layer to TRAFFIC_INDEX
map.getLayers().insert(1, NeshanServices.createTrafficLayer());
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment