public class MapAttribute.MapAttributeValues extends GenericMapAttribute.GenericMapAttributeValues
MapAttribute.| Modifier and Type | Field and Description |
|---|---|
AreaOfInterest |
areaOfInterest
A GeoJSON geometry that is essentially the area of the area to draw on the map.
|
double[] |
bbox
An array of 4 doubles, minX, minY, maxX, maxY.
|
double[] |
center
An array of 2 doubles, (x, y).
|
double |
dpi
The output dpi of the printed map.
|
PArray |
layers
The json with all the layer information.
|
java.lang.Double |
scale
If center is defined then this is the scale of the map centered at center.
|
ZoomToFeatures |
zoomToFeatures
Zoom the map to the features of a specific layer or all features of the map.
|
DEFAULT_PROJECTION, dpiSensitiveStyle, longitudeFirst, projection, rotation, useAdjustBounds, useNearestScale| Constructor and Description |
|---|
MapAttribute.MapAttributeValues(Template template,
java.awt.Dimension mapSize)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
MapAttribute.MapAttributeValues |
copy(java.awt.Dimension newMapSize,
com.google.common.base.Function<MapAttribute.MapAttributeValues,java.lang.Void> updater)
Create a copy of this instance.
|
java.lang.Double |
getDpi()
Return the DPI value for the map.
|
MapBounds |
getMapBounds() |
java.lang.String |
getProjection() |
protected PArray |
getRawLayers()
Return the JSON layer definiton.
|
java.lang.Double |
getRotation() |
MapAttribute.OverriddenMapAttributeValues |
getWithOverrides(OverviewMapAttribute.OverviewMapAttributeValues paramOverrides)
Creates an
MapAttribute.OverriddenMapAttributeValues instance with the current object
and a given OverviewMapAttribute.OverviewMapAttributeValues instance. |
ZoomLevelSnapStrategy |
getZoomLevelSnapStrategy() |
java.lang.Boolean |
getZoomSnapGeodetic() |
java.lang.Double |
getZoomSnapTolerance() |
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.
|
void |
postConstruct()
Validate the values provided by the request data and construct MapBounds and parse the layers.
|
void |
recalculateBounds()
Recalculate the bounds after center or bounds have changed.
|
void |
setMapBounds(MapBounds mapBounds) |
getDpiSuggestions, getLayers, getMapSize, getRequestorDPI, getTemplate, getValueOr, getZoomLevels, isDpiSensitiveStyle, parseProjectionpublic double[] bbox
public AreaOfInterest areaOfInterest
public double[] center
public java.lang.Double scale
public ZoomToFeatures zoomToFeatures
public PArray layers
public double dpi
public MapAttribute.MapAttributeValues(Template template, java.awt.Dimension mapSize)
template - the template this map is part of.mapSize - the size of the map.public java.lang.Double getDpi()
GenericMapAttribute.GenericMapAttributeValuesgetDpi in class GenericMapAttribute.GenericMapAttributeValuesprotected final PArray getRawLayers()
GenericMapAttribute.GenericMapAttributeValuesGenericMapAttribute.GenericMapAttributeValues.getDpi().getRawLayers in class GenericMapAttribute.GenericMapAttributeValuespublic final void postConstruct()
throws org.opengis.referencing.FactoryException
GenericMapAttribute.GenericMapAttributeValuespostConstruct in class GenericMapAttribute.GenericMapAttributeValuesorg.opengis.referencing.FactoryExceptionpublic MapBounds getMapBounds()
public void setMapBounds(MapBounds mapBounds)
public void recalculateBounds()
public java.lang.String getProjection()
getProjection in class GenericMapAttribute.GenericMapAttributeValuespublic java.lang.Double getZoomSnapTolerance()
getZoomSnapTolerance in class GenericMapAttribute.GenericMapAttributeValuespublic ZoomLevelSnapStrategy getZoomLevelSnapStrategy()
getZoomLevelSnapStrategy in class GenericMapAttribute.GenericMapAttributeValuespublic java.lang.Boolean getZoomSnapGeodetic()
getZoomSnapGeodetic in class GenericMapAttribute.GenericMapAttributeValuespublic java.lang.Double getRotation()
getRotation in class GenericMapAttribute.GenericMapAttributeValuespublic java.lang.Boolean isUseNearestScale()
GenericMapAttribute.GenericMapAttributeValuesisUseNearestScale in class GenericMapAttribute.GenericMapAttributeValuespublic java.lang.Boolean isUseAdjustBounds()
GenericMapAttribute.GenericMapAttributeValuesisUseAdjustBounds in class GenericMapAttribute.GenericMapAttributeValuespublic final MapAttribute.OverriddenMapAttributeValues getWithOverrides(OverviewMapAttribute.OverviewMapAttributeValues paramOverrides)
MapAttribute.OverriddenMapAttributeValues instance with the current object
and a given OverviewMapAttribute.OverviewMapAttributeValues instance.paramOverrides - Attributes set in this instance will override attributes in
the current instance.public MapAttribute.MapAttributeValues copy(@Nonnull java.awt.Dimension newMapSize, @Nonnull com.google.common.base.Function<MapAttribute.MapAttributeValues,java.lang.Void> updater)
newMapSize - the size of the new map attribute values to createupdater - a function which will be called after copy is made but before postConstruct is called in order
to do other configuration changes.