public class GroupLayer extends Layer
| Modifier and Type | Field and Description |
|---|---|
java.util.List<Layer> |
layers
The group of other layers.
|
displayModel| Constructor and Description |
|---|
GroupLayer() |
| Modifier and Type | Method and Description |
|---|---|
void |
draw(org.mapsforge.core.model.BoundingBox boundingBox,
byte zoomLevel,
org.mapsforge.core.graphics.Canvas canvas,
org.mapsforge.core.model.Point topLeftPoint)
Draws this
Layer on the given canvas. |
void |
onDestroy() |
boolean |
onLongPress(org.mapsforge.core.model.LatLong tapLatLong,
org.mapsforge.core.model.Point layerXY,
org.mapsforge.core.model.Point tapXY)
GroupLayer does not have a position, layerXY is null.
|
boolean |
onTap(org.mapsforge.core.model.LatLong tapLatLong,
org.mapsforge.core.model.Point layerXY,
org.mapsforge.core.model.Point tapXY)
GroupLayer does not have a position, layerXY is null.
|
void |
setDisplayModel(DisplayModel displayModel)
The DisplayModel comes from a MapView, so is generally not known when the layer itself is created.
|
getDisplayModel, getPosition, isVisible, onAdd, onRemove, requestRedraw, setVisible, setVisiblepublic final java.util.List<Layer> layers
public void draw(org.mapsforge.core.model.BoundingBox boundingBox,
byte zoomLevel,
org.mapsforge.core.graphics.Canvas canvas,
org.mapsforge.core.model.Point topLeftPoint)
LayerLayer on the given canvas.draw in class LayerboundingBox - the geographical area which should be drawn.zoomLevel - the zoom level at which this Layer should draw itself.canvas - the canvas on which this Layer should draw itself.topLeftPoint - the top-left pixel position of the canvas relative to the top-left map position.public boolean onLongPress(org.mapsforge.core.model.LatLong tapLatLong,
org.mapsforge.core.model.Point layerXY,
org.mapsforge.core.model.Point tapXY)
onLongPress in class LayertapLatLong - the geographic position of the long press.layerXY - the xy position of the layer element (if available)tapXY - the xy position of the tappublic boolean onTap(org.mapsforge.core.model.LatLong tapLatLong,
org.mapsforge.core.model.Point layerXY,
org.mapsforge.core.model.Point tapXY)
public void setDisplayModel(DisplayModel displayModel)
LayersetDisplayModel in class LayerdisplayModel - the displayModel to use.