Package mil.nga.geopackage.map.geom
Class GoogleMapShapeMarkers
- java.lang.Object
-
- mil.nga.geopackage.map.geom.GoogleMapShapeMarkers
-
public class GoogleMapShapeMarkers extends Object
Google Map Shape with markers
-
-
Constructor Summary
Constructors Constructor Description GoogleMapShapeMarkers()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(Marker marker)Add a marker with no shapevoidadd(Marker marker, ShapeMarkers shapeMarkers)Add the marker to the shapevoidadd(String markerId, ShapeMarkers shapeMarkers)Add the marker id to the shapevoidadd(List<Marker> markers)Add a list of markers with no shapevoidadd(GoogleMapShapeMarkers googleShapeMarkers)Add an embedded shape markersvoidadd(ShapeMarkers shapeMarkers)Add all markers in the shapestatic voidaddMarkerAsPolygon(Marker marker, List<Marker> markers)Polygon add a marker in the list of markers to where it is closest to the the surrounding pointsstatic voidaddMarkerAsPolyline(Marker marker, List<Marker> markers)Polyline add a marker in the list of markers to where it is closest to the the surrounding pointsbooleancontains(Marker marker)Check if contains the markerbooleancontains(String markerId)Check if contains the marker idbooleandelete(Marker marker)Get the shape markers for a marker, only returns a value of shapes that can be editedGoogleMapShapegetShape()Get the map shapeShapeMarkersgetShapeMarkers(Marker marker)Get the shape markers for a marker, only returns a value of shapes that can be editedShapeMarkersgetShapeMarkers(String markerId)Get the shape markers for a marker id, only returns a value of shapes that can be editedMap<String,ShapeMarkers>getShapeMarkersMap()Get the shape markers mapbooleanisEmpty()Check if the shape markers is emptybooleanisValid()Determines if the shape is in a valid statevoidremove()Removes all objects added to the mapvoidsetShape(GoogleMapShape shape)Set the map shapevoidsetVisible(boolean visible)Updates visibility of all objectsvoidsetVisibleMarkers(boolean visible)Updates visibility of the shape representing markersvoidsetZIndex(float zIndex)Set the z indexintsize()Get the shape markers sizevoidupdate()Updates all objects that could have changed from moved markers
-
-
-
Method Detail
-
add
public void add(Marker marker, ShapeMarkers shapeMarkers)
Add the marker to the shape- Parameters:
marker- markershapeMarkers- shape markers
-
add
public void add(String markerId, ShapeMarkers shapeMarkers)
Add the marker id to the shape- Parameters:
markerId- marker idshapeMarkers- shape markers
-
add
public void add(ShapeMarkers shapeMarkers)
Add all markers in the shape- Parameters:
shapeMarkers- shape markers
-
add
public void add(Marker marker)
Add a marker with no shape- Parameters:
marker- marker
-
add
public void add(List<Marker> markers)
Add a list of markers with no shape- Parameters:
markers- list of markers
-
add
public void add(GoogleMapShapeMarkers googleShapeMarkers)
Add an embedded shape markers- Parameters:
googleShapeMarkers- google map shape markers
-
getShape
public GoogleMapShape getShape()
Get the map shape- Returns:
- map shape
-
setShape
public void setShape(GoogleMapShape shape)
Set the map shape- Parameters:
shape- map shape
-
getShapeMarkersMap
public Map<String,ShapeMarkers> getShapeMarkersMap()
Get the shape markers map- Returns:
- shape markers map
- Since:
- 1.3.2
-
contains
public boolean contains(Marker marker)
Check if contains the marker- Parameters:
marker- marker- Returns:
- contains flag
-
contains
public boolean contains(String markerId)
Check if contains the marker id- Parameters:
markerId- marker id- Returns:
- contains flag
-
getShapeMarkers
public ShapeMarkers getShapeMarkers(Marker marker)
Get the shape markers for a marker, only returns a value of shapes that can be edited- Parameters:
marker- marker- Returns:
- shape markers
-
getShapeMarkers
public ShapeMarkers getShapeMarkers(String markerId)
Get the shape markers for a marker id, only returns a value of shapes that can be edited- Parameters:
markerId- marker id- Returns:
- shape markers
-
delete
public boolean delete(Marker marker)
Get the shape markers for a marker, only returns a value of shapes that can be edited- Parameters:
marker- marker- Returns:
- deleted flag
-
remove
public void remove()
Removes all objects added to the map
-
update
public void update()
Updates all objects that could have changed from moved markers
-
isValid
public boolean isValid()
Determines if the shape is in a valid state- Returns:
- valid flag
-
addMarkerAsPolygon
public static void addMarkerAsPolygon(Marker marker, List<Marker> markers)
Polygon add a marker in the list of markers to where it is closest to the the surrounding points- Parameters:
marker- markermarkers- list of markers
-
addMarkerAsPolyline
public static void addMarkerAsPolyline(Marker marker, List<Marker> markers)
Polyline add a marker in the list of markers to where it is closest to the the surrounding points- Parameters:
marker- markermarkers- list of markers
-
setVisible
public void setVisible(boolean visible)
Updates visibility of all objects- Parameters:
visible- visible flag- Since:
- 1.3.2
-
setVisibleMarkers
public void setVisibleMarkers(boolean visible)
Updates visibility of the shape representing markers- Parameters:
visible- visible flag- Since:
- 1.3.2
-
setZIndex
public void setZIndex(float zIndex)
Set the z index- Parameters:
zIndex- z index- Since:
- 2.0.1
-
size
public int size()
Get the shape markers size- Returns:
- size
- Since:
- 1.3.2
-
isEmpty
public boolean isEmpty()
Check if the shape markers is empty- Returns:
- true if empty
- Since:
- 1.3.2
-
-