Package org.geotools.tile.impl.osm
Class OSMTileFactory
- Object
-
- TileFactory
-
- WebMercatorTileFactory
-
- OSMTileFactory
-
public class OSMTileFactory extends WebMercatorTileFactory
The tile factory implementation for the OpenStreetMap family- Since:
- 12
- Author:
- Tobias Sauerwein, Ugo Taddei
-
-
Constructor Summary
Constructors Constructor Description OSMTileFactory()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Tilecreate(TileIdentifier identifier, TileService service)Creates a new tile for the given position using a service.TilefindLowerNeighbour(Tile tile, TileService service)Finds the tile for a service at the given position and zoom level, which is immediately below the the passed tile.TilefindRightNeighbour(Tile tile, TileService service)Finds the tile for a service at the given position and zoom level, which is immediately to the right of the passed tile.TilefindTileAtCoordinate(double lon, double lat, ZoomLevel zoomLevel, TileService service)Finds the tile for a service at the given position and zoom level.static doublemoveInRange(double value, double min, double max)This method ensures that value is between min and max.-
Methods inherited from class WebMercatorTileFactory
getExtentFromTileName, getZoomLevel, tile2lat, tile2lon
-
Methods inherited from class TileFactory
normalizeDegreeValue
-
-
-
-
Method Detail
-
create
public Tile create(TileIdentifier identifier, TileService service)
Description copied from class:TileFactoryCreates a new tile for the given position using a service.- Specified by:
createin classTileFactory- Returns:
-
findTileAtCoordinate
public Tile findTileAtCoordinate(double lon, double lat, ZoomLevel zoomLevel, TileService service)
Description copied from class:TileFactoryFinds the tile for a service at the given position and zoom level.- Specified by:
findTileAtCoordinatein classTileFactory- Parameters:
lon- the longitudelat- the latitudezoomLevel- the zoom levelservice- the service- Returns:
- a tile
-
moveInRange
public static double moveInRange(double value, double min, double max)This method ensures that value is between min and max. If value < min, min is returned. If value > max, max is returned. Otherwise value.
-
findRightNeighbour
public Tile findRightNeighbour(Tile tile, TileService service)
Description copied from class:TileFactoryFinds the tile for a service at the given position and zoom level, which is immediately to the right of the passed tile.- Specified by:
findRightNeighbourin classTileFactory- Parameters:
tile- the reference tile
-
findLowerNeighbour
public Tile findLowerNeighbour(Tile tile, TileService service)
Description copied from class:TileFactoryFinds the tile for a service at the given position and zoom level, which is immediately below the the passed tile.- Specified by:
findLowerNeighbourin classTileFactory- Parameters:
tile- the reference tile
-
-