public static class SlippyMapBBoxChooser.RenamedSourceDecorator extends Object implements TileSource
TileSource.TileUpdate
Modifier and Type | Field and Description |
---|---|
private String |
name |
private TileSource |
source |
Constructor and Description |
---|
RenamedSourceDecorator(TileSource source,
String name) |
Modifier and Type | Method and Description |
---|---|
Image |
getAttributionImage() |
String |
getAttributionImageURL() |
String |
getAttributionLinkURL() |
String |
getAttributionText(int zoom,
Coordinate topLeft,
Coordinate botRight) |
int |
getMaxZoom()
Specifies the maximum zoom value.
|
int |
getMinZoom()
Specifies the minimum zoom value.
|
String |
getName()
A tile layer name has to be unique and has to consist only of characters
valid for filenames.
|
String |
getTermsOfUseText() |
String |
getTermsOfUseURL() |
int |
getTileSize()
Specifies how large each tile is.
|
String |
getTileType()
Specifies the tile image type.
|
TileSource.TileUpdate |
getTileUpdate() |
String |
getTileUrl(int zoom,
int tilex,
int tiley)
Constructs the tile url.
|
double |
latToTileY(double lat,
int zoom) |
double |
lonToTileX(double lon,
int zoom) |
boolean |
requiresAttribution() |
double |
tileXToLon(int x,
int zoom) |
double |
tileYToLat(int y,
int zoom) |
private final TileSource source
public RenamedSourceDecorator(TileSource source, String name)
public String getName()
TileSource
getName
in interface TileSource
public int getMaxZoom()
TileSource
TileSource.getMaxZoom()
].getMaxZoom
in interface TileSource
JMapViewer.MAX_ZOOM
public int getMinZoom()
TileSource
getMinZoom
in interface TileSource
public int getTileSize()
TileSource
getTileSize
in interface TileSource
public String getTileType()
TileSource
"png"
.getTileType
in interface TileSource
public TileSource.TileUpdate getTileUpdate()
getTileUpdate
in interface TileSource
TileSource.TileUpdate
public String getTileUrl(int zoom, int tilex, int tiley) throws IOException
TileSource
getTileUrl
in interface TileSource
IOException
public boolean requiresAttribution()
requiresAttribution
in interface Attributed
public String getAttributionText(int zoom, Coordinate topLeft, Coordinate botRight)
getAttributionText
in interface Attributed
zoom
- The optional zoom level for the view.topLeft
- The top left of the bounding box for attribution.botRight
- The bottom right of the bounding box for attribution.public String getAttributionLinkURL()
getAttributionLinkURL
in interface Attributed
public Image getAttributionImage()
getAttributionImage
in interface Attributed
public String getAttributionImageURL()
getAttributionImageURL
in interface Attributed
public String getTermsOfUseText()
getTermsOfUseText
in interface Attributed
public String getTermsOfUseURL()
getTermsOfUseURL
in interface Attributed
public double latToTileY(double lat, int zoom)
latToTileY
in interface TileSource
public double lonToTileX(double lon, int zoom)
lonToTileX
in interface TileSource
public double tileYToLat(int y, int zoom)
tileYToLat
in interface TileSource
public double tileXToLon(int x, int zoom)
tileXToLon
in interface TileSource