Package org.mapsforge.map.layer.renderer
Class DatabaseRenderer
- java.lang.Object
-
- org.mapsforge.map.layer.renderer.StandardRenderer
-
- org.mapsforge.map.layer.renderer.DatabaseRenderer
-
- All Implemented Interfaces:
RenderCallback
public class DatabaseRenderer extends StandardRenderer
The DatabaseRenderer renders map tiles by reading from aMapDataStore.
-
-
Field Summary
-
Fields inherited from class org.mapsforge.map.layer.renderer.StandardRenderer
graphicFactory, hillsRenderConfig, mapDataStore
-
-
Constructor Summary
Constructors Constructor Description DatabaseRenderer(MapDataStore mapDataStore, org.mapsforge.core.graphics.GraphicFactory graphicFactory, TileCache tileCache, TileBasedLabelStore labelStore, boolean renderLabels, boolean cacheLabels, HillsRenderConfig hillsRenderConfig)Constructs a new DatabaseRenderer.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.mapsforge.core.graphics.TileBitmapexecuteJob(RendererJob rendererJob)Called when a job needs to be executed.MapDataStoregetMapDatabase()-
Methods inherited from class org.mapsforge.map.layer.renderer.StandardRenderer
getStartPosition, getStartZoomLevel, getZoomLevelMax, processReadMapData, renderArea, renderAreaCaption, renderAreaSymbol, renderPointOfInterest, renderPointOfInterestCaption, renderPointOfInterestCircle, renderPointOfInterestSymbol, renderWaterBackground, renderWay, renderWay, renderWaySymbol, renderWayText
-
-
-
-
Constructor Detail
-
DatabaseRenderer
public DatabaseRenderer(MapDataStore mapDataStore, org.mapsforge.core.graphics.GraphicFactory graphicFactory, TileCache tileCache, TileBasedLabelStore labelStore, boolean renderLabels, boolean cacheLabels, HillsRenderConfig hillsRenderConfig)
Constructs a new DatabaseRenderer. There are three possible configurations: 1) render labels directly onto tiles: renderLabels == true && tileCache != null 2) do not render labels but cache them: renderLabels == false && labelStore != null 3) do not render or cache labels: renderLabels == false && labelStore == null- Parameters:
mapDataStore- the data source.graphicFactory- the graphic factory.tileCache- where tiles are cached (needed if labels are drawn directly onto tiles, otherwise null)labelStore- where labels are cached.renderLabels- if labels should be rendered.cacheLabels- if labels should be cached.hillsRenderConfig- the hillshading setup to be used (can be null).
-
-
Method Detail
-
executeJob
public org.mapsforge.core.graphics.TileBitmap executeJob(RendererJob rendererJob)
Called when a job needs to be executed.- Parameters:
rendererJob- the job that should be executed.
-
getMapDatabase
public MapDataStore getMapDatabase()
-
-