Search in sources :

Example 1 with GoogleBaseMap

use of org.activityinfo.shared.map.GoogleBaseMap in project activityinfo by bedatadriven.

the class ImageMapRenderer method drawBasemap.

protected void drawBasemap(MapReportElement element, TileHandler tileHandler) {
    TiledMap map = createTileMap(element);
    BaseMap baseMap = element.getContent().getBaseMap();
    try {
        if (baseMap instanceof TileBaseMap) {
            drawTiledBaseMap(tileHandler, map, baseMap);
        } else if (baseMap instanceof GoogleBaseMap) {
            drawTiledBaseMap(tileHandler, map, MapboxLayers.toTileBaseMap(baseMap));
        }
    } catch (Exception e) {
        LOGGER.log(Level.WARNING, "Exception drawing basemap", e);
    }
}
Also used : TileBaseMap(org.activityinfo.shared.map.TileBaseMap) TiledMap(org.activityinfo.server.report.generator.map.TiledMap) GoogleBaseMap(org.activityinfo.shared.map.GoogleBaseMap) GoogleBaseMap(org.activityinfo.shared.map.GoogleBaseMap) BaseMap(org.activityinfo.shared.map.BaseMap) TileBaseMap(org.activityinfo.shared.map.TileBaseMap) IOException(java.io.IOException)

Aggregations

IOException (java.io.IOException)1 TiledMap (org.activityinfo.server.report.generator.map.TiledMap)1 BaseMap (org.activityinfo.shared.map.BaseMap)1 GoogleBaseMap (org.activityinfo.shared.map.GoogleBaseMap)1 TileBaseMap (org.activityinfo.shared.map.TileBaseMap)1