public class ViewportData extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private ProjectionBounds |
bounds |
private EastNorth |
center |
private java.lang.Double |
scale |
Constructor and Description |
---|
ViewportData(EastNorth center,
java.lang.Double scale)
Constructs a new
ViewportData . |
ViewportData(ProjectionBounds bounds)
Create a new
ViewportData |
Modifier and Type | Method and Description |
---|---|
ProjectionBounds |
getBounds()
Return the bounds in east-north coordinate space.
|
EastNorth |
getCenter()
Return the projected coordinates of the map center
|
java.lang.Double |
getScale()
Return the scale factor in east-/north-units per pixel.
|
private final java.lang.Double scale
private final ProjectionBounds bounds
public ViewportData(EastNorth center, java.lang.Double scale)
ViewportData
.center
- Projected coordinates of the map centerscale
- Scale factor in east-/north-units per pixelpublic ViewportData(ProjectionBounds bounds)
ViewportData
bounds
- The bounds to zoom topublic EastNorth getCenter()
public java.lang.Double getScale()
public ProjectionBounds getBounds()