public abstract class GenericMapAttribute.GenericMapAttributeValues
extends java.lang.Object
GenericMapAttribute.| Modifier and Type | Field and Description |
|---|---|
protected static java.lang.String |
DEFAULT_PROJECTION
The default projection.
|
boolean |
dpiSensitiveStyle
Should the vector style definitions be adapted to the target DPI resolution? (Default: true)
|
java.lang.Integer |
height
The height of the map.
|
java.lang.Boolean |
longitudeFirst
By default the normal axis order as specified in EPSG code will be used when parsing projections.
|
java.lang.String |
projection
The projection of the map.
|
java.lang.Double |
rotation
The rotation of the map.
|
java.lang.Boolean |
useAdjustBounds
Indicates if the map should adjust its bounds.
|
java.lang.Boolean |
useNearestScale
Indicates if the map should adjust its scale/zoom level to be equal to one of those defined in the
configuration file.
|
java.lang.Integer |
width
The width of the map.
|
| Constructor and Description |
|---|
GenericMapAttributeValues(Template template)
Constructor.
|
GenericMapAttributeValues(Template template,
java.lang.Integer width,
java.lang.Integer height)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
abstract java.lang.Double |
getDpi()
Return the DPI value for the map.
|
double[] |
getDpiSuggestions() |
java.lang.Integer |
getHeight() |
java.util.List<MapLayer> |
getLayers() |
java.awt.Dimension |
getMapSize() |
java.lang.String |
getProjection() |
abstract PArray |
getRawLayers()
Return the JSON layer definition.
|
java.lang.Double |
getRotation()
Gets the rotation.
|
Template |
getTemplate() |
protected <T> T |
getValueOr(T value,
T defaultValue) |
java.lang.Integer |
getWidth() |
ZoomLevels |
getZoomLevels() |
ZoomLevelSnapStrategy |
getZoomLevelSnapStrategy() |
java.lang.Boolean |
getZoomSnapGeodetic() |
java.lang.Double |
getZoomSnapTolerance() |
boolean |
isDpiSensitiveStyle() |
java.lang.Boolean |
isUseAdjustBounds()
Return true if requestData has useNearestScale and configuration has some zoom levels defined.
|
java.lang.Boolean |
isUseNearestScale()
Return true if requestData has useNearestScale and configuration has some zoom levels defined.
|
protected org.opengis.referencing.crs.CoordinateReferenceSystem |
parseProjection()
Parse the projection from a string.
|
void |
postConstruct()
Validate the values provided by the request data and construct MapBounds and parse the layers.
|
abstract void |
setRawLayers(PArray layers)
Set the JSON layer definition.
|
protected static final java.lang.String DEFAULT_PROJECTION
public java.lang.Integer width
public java.lang.Integer height
public java.lang.String projection
public java.lang.Double rotation
public java.lang.Boolean useNearestScale
isUseNearestScale()public java.lang.Boolean useAdjustBounds
isUseAdjustBounds()public java.lang.Boolean longitudeFirst
public boolean dpiSensitiveStyle
public GenericMapAttributeValues(Template template)
template - the template this map is part of.public GenericMapAttributeValues(Template template, java.lang.Integer width, java.lang.Integer height)
template - the template this map is part of.width - the width of the map.height - the height of the map.public void postConstruct()
throws org.opengis.referencing.FactoryException
org.opengis.referencing.FactoryExceptionprotected final org.opengis.referencing.crs.CoordinateReferenceSystem parseProjection()
public abstract java.lang.Double getDpi()
public abstract PArray getRawLayers()
getDpi().public abstract void setRawLayers(PArray layers)
getDpi().layers - the new layerspublic java.util.List<MapLayer> getLayers()
public final Template getTemplate()
public final java.awt.Dimension getMapSize()
public final java.lang.Integer getWidth()
public final java.lang.Integer getHeight()
public java.lang.Double getRotation()
public java.lang.String getProjection()
public java.lang.Boolean isUseNearestScale()
public java.lang.Boolean isUseAdjustBounds()
public final boolean isDpiSensitiveStyle()
public ZoomLevels getZoomLevels()
public java.lang.Double getZoomSnapTolerance()
public ZoomLevelSnapStrategy getZoomLevelSnapStrategy()
public java.lang.Boolean getZoomSnapGeodetic()
public double[] getDpiSuggestions()
protected final <T> T getValueOr(T value,
T defaultValue)
T - A type.value - The value or null.defaultValue - The default value.