-
- All Implemented Interfaces:
-
org.maplibre.android.maps.MapView.OnCameraDidChangeListener,org.maplibre.android.maps.MapView.OnCameraIsChangingListener
public class MarkerViewManager implements MapView.OnCameraDidChangeListener, MapView.OnCameraIsChangingListenerClass responsible for synchronising views at a LatLng on top of a Map.
-
-
Constructor Summary
Constructors Constructor Description MarkerViewManager(MapView mapView, MapLibreMap maplibreMap)Create a MarkerViewManager.
-
Method Summary
Modifier and Type Method Description voidonDestroy()Destroys the MarkerViewManager. voidaddMarker(@NonNull() MarkerView markerView)Add a MarkerView to the map using MarkerView and LatLng. voidremoveMarker(@NonNull() MarkerView markerView)Remove an existing markerView from the map. voidonCameraDidChange(boolean animated)voidonCameraIsChanging()-
Methods inherited from class org.maplibre.android.maps.MapView.OnCameraDidChangeListener
onCameraDidChange -
Methods inherited from class org.maplibre.android.maps.MapView.OnCameraIsChangingListener
onCameraIsChanging -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
onDestroy
@UiThread() void onDestroy()
Destroys the MarkerViewManager.
Should be called before MapView#onDestroy
-
addMarker
@UiThread() void addMarker(@NonNull() MarkerView markerView)
Add a MarkerView to the map using MarkerView and LatLng.
- Parameters:
markerView- the markerView to synchronise on the map
-
removeMarker
@UiThread() void removeMarker(@NonNull() MarkerView markerView)
Remove an existing markerView from the map.
- Parameters:
markerView- the markerView to be removed from the map
-
onCameraDidChange
void onCameraDidChange(boolean animated)
-
onCameraIsChanging
void onCameraIsChanging()
-
-
-
-