|
Groovy Documentation | |||||||
| FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectorg.jdesktop.swingx.mapviewer.TileFactoryInfo
public class TileFactoryInfo extends Object
A TileFactoryInfo encapsulates all information specific to a map server. This includes everything from the url to load the map tiles from to the size and depth of the tiles. Theoretically any map server can be used by installing a customized TileFactoryInfo. Currently
| Field Summary | |
|---|---|
protected String |
baseURL
The base url for loading tiles from. |
private int |
defaultZoomLevel
|
private double[] |
longitudeDegreeWidthInPixels
An array of doubles that contain the number of pixels per degree of longitude at a give zoom level. |
private double[] |
longitudeRadianWidthInPixels
An array of doubles that contain the number of radians per degree of longitude at a given zoom level (where longitudeRadianWidthInPixels[0] is the most zoomed out) |
private Point2D[] |
mapCenterInPixelsAtZoom
An array of coordinates in pixels that indicates the center in the world map for the given zoom level. |
private int[] |
mapWidthInTilesAtZoom
|
private int |
maximumZoomLevel
|
private int |
minimumZoomLevel
|
private String |
name
|
private int |
tileSize
|
private int |
totalMapZoom
|
private String |
xparam
|
private boolean |
xr2l
|
private String |
yparam
|
private boolean |
yt2b
|
private String |
zparam
|
| Constructor Summary | |
TileFactoryInfo(int minimumZoomLevel, int maximumZoomLevel, int totalMapZoom, int tileSize, boolean xr2l, boolean yt2b, String baseURL, String xparam, String yparam, String zparam)
Creates a new instance of TileFactoryInfo. |
|
TileFactoryInfo(String name, int minimumZoomLevel, int maximumZoomLevel, int totalMapZoom, int tileSize, boolean xr2l, boolean yt2b, String baseURL, String xparam, String yparam, String zparam)
Creates a new instance of TileFactoryInfo. |
|
| Method Summary | |
|---|---|
int
|
getDefaultZoomLevel()
|
double
|
getLongitudeDegreeWidthInPixels(int zoom)
A property indicating if the X coordinates of tiles go from right to left or left to right. |
double
|
getLongitudeRadianWidthInPixels(int zoom)
A property indicating if the X coordinates of tiles go from right to left or left to right. |
Point2D
|
getMapCenterInPixelsAtZoom(int zoom)
|
int
|
getMapWidthInTilesAtZoom(int zoom)
@return
|
int
|
getMaximumZoomLevel()
@return |
int
|
getMinimumZoomLevel()
@return |
String
|
getName()
|
int
|
getTileSize(int zoom)
Get the tile size. |
String
|
getTileUrl(int x, int y, int zoom)
|
int
|
getTotalMapZoom()
@return
|
boolean
|
isXr2l()
A property indicating if the Y coordinates of tiles go from right to left or left to right. |
boolean
|
isYt2b()
|
void
|
setDefaultZoomLevel(int defaultZoomLevel)
|
void
|
setXr2l(boolean xr2l)
A property indicating if the Y coordinates of tiles go from right to left or left to right. |
void
|
setYt2b(boolean yt2b)
The name of this info. |
| Methods inherited from class Object | |
|---|---|
| wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll |
| Field Detail |
|---|
protected String baseURL
private int defaultZoomLevel
private double[] longitudeDegreeWidthInPixels
private double[] longitudeRadianWidthInPixels
private Point2D[] mapCenterInPixelsAtZoom
private int[] mapWidthInTilesAtZoom
private int maximumZoomLevel
private int minimumZoomLevel
private String name
private int tileSize
private int totalMapZoom
private String xparam
private boolean xr2l
private String yparam
private boolean yt2b
private String zparam
| Constructor Detail |
|---|
public TileFactoryInfo(int minimumZoomLevel, int maximumZoomLevel, int totalMapZoom, int tileSize, boolean xr2l, boolean yt2b, String baseURL, String xparam, String yparam, String zparam)
minimumZoomLevel - The minimum zoom levelmaximumZoomLevel - the maximum zoom leveltotalMapZoom - the top zoom level, essentially the height of the pyramidtileSize - the size of the tiles in pixels (must be square)xr2l - if the x goes r to l (is this backwards?)yt2b - if the y goes top to bottombaseURL - the base url for grabbing tilesxparam - the x parameter for the tile urlyparam - the y parameter for the tile urlzparam - the z parameter for the tile url
public TileFactoryInfo(String name, int minimumZoomLevel, int maximumZoomLevel, int totalMapZoom, int tileSize, boolean xr2l, boolean yt2b, String baseURL, String xparam, String yparam, String zparam)
name - A name to identify this information.minimumZoomLevel - The minimum zoom levelmaximumZoomLevel - the maximum zoom leveltotalMapZoom - the top zoom level, essentially the height of the pyramidtileSize - the size of the tiles in pixels (must be square)xr2l - if the x goes r to l (is this backwards?)yt2b - if the y goes top to bottombaseURL - the base url for grabbing tilesxparam - the x parameter for the tile urlyparam - the y parameter for the tile urlzparam - the z parameter for the tile url
| Method Detail |
|---|
public int getDefaultZoomLevel()
public double getLongitudeDegreeWidthInPixels(int zoom)
public double getLongitudeRadianWidthInPixels(int zoom)
public Point2D getMapCenterInPixelsAtZoom(int zoom)
public int getMapWidthInTilesAtZoom(int zoom)
public int getMaximumZoomLevel()
public int getMinimumZoomLevel()
public String getName()
public int getTileSize(int zoom)
public String getTileUrl(int x, int y, int zoom)
public int getTotalMapZoom()
public boolean isXr2l()
public boolean isYt2b()
public void setDefaultZoomLevel(int defaultZoomLevel)
public void setXr2l(boolean xr2l)
public void setYt2b(boolean yt2b)
Groovy Documentation