public interface AirMapInterface
| Modifier and Type | Field and Description |
|---|---|
static int |
CIRCLE_BORDER_COLOR |
static int |
CIRCLE_BORDER_WIDTH |
static int |
CIRCLE_FILL_COLOR |
| Modifier and Type | Method and Description |
|---|---|
void |
addMarker(AirMapMarker marker)
Add the given marker to the map
|
<T> void |
addPolygon(AirMapPolygon<T> polygon)
Add the given polygon to the map
|
<T> void |
addPolyline(AirMapPolyline<T> polyline)
Add the given polyline to the map
|
void |
animateCenter(LatLng latLng)
Animate the map to center the given
LatLng. |
void |
animateCenterZoom(LatLng latLng,
int zoom)
Animate the center of the map to the given location and zoom level
|
void |
clearGeoJsonLayer()
Remove GeoJson layer from map, if any.
|
void |
clearMarkers()
Clear all markers from the map
|
void |
drawCircle(LatLng latLng,
int radius)
Draw a circle at the given LatLng, with the given radius
|
void |
drawCircle(LatLng latLng,
int radius,
int borderColor)
Draw a circle at the given LatLng, with the given radius and stroke width
|
void |
drawCircle(LatLng latLng,
int radius,
int borderColor,
int borderWidth)
Draw a circle at the given LatLng, with the given radius, stroke width, and stroke color
|
void |
drawCircle(LatLng latLng,
int radius,
int borderColor,
int borderWidth,
int fillColor)
Draw a circle at the given LatLng, with the given radius, stroke width, stroke and fill colors
|
LatLng |
getCenter() |
void |
getMapScreenBounds(OnMapBoundsCallback callback)
Returns the map screen bounds to the supplied
OnMapBoundsCallback |
void |
getScreenLocation(LatLng latLng,
OnLatLngScreenLocationCallback callback)
Returns the point coordinates of the LatLng in the container to the supplied
OnLatLngScreenLocationCallback |
void |
getSnapshot(OnSnapshotReadyListener listener)
Get a Bitmap snapshot of the current
|
int |
getZoom() |
boolean |
isInitialized() |
boolean |
isMyLocationEnabled()
Check if the user location is being tracked and shown on te map.
|
void |
moveMarker(AirMapMarker marker,
LatLng to)
Move the marker to the given coordinates
|
void |
onLocationPermissionsGranted()
Getting called when runtime location permissions got granted.
|
void |
removeMarker(AirMapMarker marker)
Remove the given marker from the map
|
void |
removePolygon(AirMapPolygon polygon)
Remove the given
AirMapPolygon |
void |
removePolyline(AirMapPolyline polyline)
Remove the given
AirMapPolyline |
void |
setCenter(LatLng latLng)
Center the map to the given
LatLng |
void |
setCenter(LatLngBounds latLngBounds,
int boundsPadding)
Sets the given
LatLngBounds on the map with the specified padding |
void |
setCenterZoom(LatLng latLng,
int zoom)
Set the center of the map, and zoom level
|
void |
setGeoJsonLayer(AirMapGeoJsonLayer layer)
Adds a GeoJson layer to the map.
|
void |
setInfoWindowCreator(GoogleMap.InfoWindowAdapter adapter,
InfoWindowCreator creator)
Specific to Google Play Services maps.
|
void |
setMapToolbarEnabled(boolean enabled)
Enable a toolbar that displays various context-dependent actions.
|
void |
setMapType(MapType type)
Sets the type of map tiles that should be displayed
|
void |
setMyLocationEnabled(boolean enabled)
Enable an indicator for the user's location on the map.
|
void |
setOnCameraChangeListener(OnCameraChangeListener onCameraChangeListener)
Register a callback to be invoked when the camera of the map has changed
|
void |
setOnInfoWindowClickListener(OnInfoWindowClickListener listener)
Set the callback for info window click events
|
void |
setOnMapClickListener(OnMapClickListener listener)
Register a callback to be invoked when the map is clicked
|
void |
setOnMapLoadedListener(OnMapLoadedListener onMapLoadedListener) |
void |
setOnMarkerClickListener(OnMapMarkerClickListener listener)
Register a callback to be invoked when a map marker is clicked
|
void |
setOnMarkerDragListener(OnMapMarkerDragListener listener)
Register a callback to be invoked when a map marker is dragged
|
void |
setPadding(int left,
int top,
int right,
int bottom)
Set the map's padding.
|
void |
setZoom(int zoom)
Set the map zoom level
|
static final int CIRCLE_FILL_COLOR
static final int CIRCLE_BORDER_COLOR
static final int CIRCLE_BORDER_WIDTH
boolean isInitialized()
void clearMarkers()
void addMarker(AirMapMarker marker)
marker - AirMapMarker instance to addvoid moveMarker(AirMapMarker marker, LatLng to)
marker - AirMapMarker instance to moveto - LatLng new destination of the markervoid removeMarker(AirMapMarker marker)
marker - AirMapMarker instance to removevoid setOnInfoWindowClickListener(OnInfoWindowClickListener listener)
listener - OnInfoWindowClickListener
instancevoid setInfoWindowCreator(GoogleMap.InfoWindowAdapter adapter,
InfoWindowCreator creator)
GoogleMap.InfoWindowAdapter and InfoWindowCreatorvoid drawCircle(LatLng latLng,
int radius)
void drawCircle(LatLng latLng,
int radius,
int borderColor)
void drawCircle(LatLng latLng,
int radius,
int borderColor,
int borderWidth)
void drawCircle(LatLng latLng,
int radius,
int borderColor,
int borderWidth,
int fillColor)
void getMapScreenBounds(OnMapBoundsCallback callback)
OnMapBoundsCallbackvoid getScreenLocation(LatLng latLng,
OnLatLngScreenLocationCallback callback)
OnLatLngScreenLocationCallbackvoid setCenter(LatLngBounds latLngBounds,
int boundsPadding)
LatLngBounds on the map with the specified paddingvoid setZoom(int zoom)
void animateCenter(LatLng latLng)
LatLng. Web maps will currently only center the map
(no animation).void setCenter(LatLng latLng)
LatLngLatLng getCenter()
LatLng of the center of the mapint getZoom()
void setOnCameraChangeListener(OnCameraChangeListener onCameraChangeListener)
void setOnMapLoadedListener(OnMapLoadedListener onMapLoadedListener)
void setCenterZoom(LatLng latLng,
int zoom)
latLng - the LatLng to set as centerzoom - the zoom levelvoid animateCenterZoom(LatLng latLng,
int zoom)
latLng - the LatLng to animate to centerzoom - the zoom levelvoid setOnMarkerClickListener(OnMapMarkerClickListener listener)
listener - OnMapMarkerClickListener
callbackvoid setOnMarkerDragListener(OnMapMarkerDragListener listener)
listener - OnMapMarkerDragListener
callbackvoid setOnMapClickListener(OnMapClickListener listener)
listener - OnMapClickListener callbackvoid setPadding(int left,
int top,
int right,
int bottom)
void setMyLocationEnabled(boolean enabled)
boolean isMyLocationEnabled()
void setMapToolbarEnabled(boolean enabled)
<T> void addPolyline(AirMapPolyline<T> polyline)
polyline - AirMapPolyline instance to addvoid removePolyline(AirMapPolyline polyline)
AirMapPolylinepolyline - the AirMapPolyline to removevoid setMapType(MapType type)
void onLocationPermissionsGranted()
<T> void addPolygon(AirMapPolygon<T> polygon)
polygon - AirMapPolygon instance to addvoid removePolygon(AirMapPolygon polygon)
AirMapPolygonpolygon - the AirMapPolygon to removevoid setGeoJsonLayer(AirMapGeoJsonLayer layer) throws org.json.JSONException
layer - An AirMapGeoJsonLayer layer with GeoJson and optional styling attributesorg.json.JSONExceptionvoid clearGeoJsonLayer()
void getSnapshot(OnSnapshotReadyListener listener)