public abstract class GenericMapAttribute extends ReflectiveAttribute<GenericMapAttribute.GenericMapAttributeValues>
CreateMapProcessor and CreateOverviewMapProcessor.| Modifier and Type | Class and Description |
|---|---|
class |
GenericMapAttribute.GenericMapAttributeValues
The value of
GenericMapAttribute. |
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
JSON_DPI_SUGGESTIONS
The json key for the suggested DPI values in the client config.
|
static java.lang.String |
JSON_MAP_HEIGHT
The json key for the height of the map in the client config.
|
static java.lang.String |
JSON_MAP_WIDTH
The json key for the width of the map in the client config.
|
static java.lang.String |
JSON_MAX_DPI
The json key for the max DPI value in the client config.
|
static java.lang.String |
JSON_MAX_HEIGHT
The json key for the max height of the map in the client config (for mapExport).
|
static java.lang.String |
JSON_MAX_WIDTH
The json key for the max width of the map in the client config (for mapExport).
|
JSON_ATTRIBUTE_DEFAULT, JSON_ATTRIBUTE_EMBEDDED_TYPE, JSON_ATTRIBUTE_IS_ARRAY, JSON_ATTRIBUTE_TYPE, JSON_CLIENT_INFO, JSON_CLIENT_PARAMS, JSON_NAME| Constructor and Description |
|---|
GenericMapAttribute() |
| Modifier and Type | Method and Description |
|---|---|
protected java.util.Optional<org.json.JSONObject> |
getClientInfo()
Return an object that will be added to the client config with the key clientInfo.
|
double[] |
getDpiSuggestions()
Get DPI suggestions.
|
java.lang.Integer |
getHeight() |
java.lang.Double |
getMaxDpi() |
java.lang.Integer |
getMaxHeight() |
java.lang.Integer |
getMaxWidth() |
java.lang.Integer |
getWidth() |
static org.opengis.referencing.crs.CoordinateReferenceSystem |
parseProjection(java.lang.String projection,
java.lang.Boolean longitudeFirst)
Parse the given projection.
|
void |
setDpiSuggestions(double[] dpiSuggestions)
Suggestions for DPI values to use.
|
void |
setHeight(java.lang.Integer height)
The height of the map in pixels.
|
void |
setMaxDpi(java.lang.Double maxDpi)
The maximum DPI allowed for maps.
|
void |
setMaxHeight(java.lang.Integer maxHeight)
Limits the maximum height of the map.
|
void |
setMaxWidth(java.lang.Integer maxWidth)
Limits the maximum width of the map.
|
void |
setWidth(java.lang.Integer width)
The width of the map in pixels.
|
void |
setZoomLevels(ZoomLevels zoomLevels)
The list of Zoom Levels.
|
void |
setZoomLevelSnapStrategy(ZoomLevelSnapStrategy zoomLevelSnapStrategy)
The strategy to use to compute the actual zoom level to use.
|
void |
setZoomSnapGeodetic(java.lang.Boolean zoomSnapGeodetic)
If true, snap to geodetic scales.
|
void |
setZoomSnapTolerance(java.lang.Double zoomSnapTolerance)
The zoom level tolerance.
|
void |
validate(java.util.List<java.lang.Throwable> validationErrors,
Configuration configuration)
validate that the configuration was correct.
|
createValue, getAttributeName, getDefaultValue, getValue, getValueType, printClientConfig, setConfigName, setDefaultpublic static final java.lang.String JSON_DPI_SUGGESTIONS
public static final java.lang.String JSON_MAX_DPI
public static final java.lang.String JSON_MAP_WIDTH
public static final java.lang.String JSON_MAP_HEIGHT
public static final java.lang.String JSON_MAX_WIDTH
public static final java.lang.String JSON_MAX_HEIGHT
public static org.opengis.referencing.crs.CoordinateReferenceSystem parseProjection(java.lang.String projection,
java.lang.Boolean longitudeFirst)
projection - The projection string.longitudeFirst - longitudeFirstpublic final java.lang.Double getMaxDpi()
public final void setMaxDpi(java.lang.Double maxDpi)
If a request is made with a higher DPI, the request fails.
maxDpi - the valuepublic final double[] getDpiSuggestions()
public final void setDpiSuggestions(double[] dpiSuggestions)
dpiSuggestions - DPI suggestionspublic final java.lang.Integer getWidth()
public final void setWidth(java.lang.Integer width)
width - Widthpublic final java.lang.Integer getHeight()
public final void setHeight(java.lang.Integer height)
height - Heightpublic final java.lang.Integer getMaxWidth()
public final void setMaxWidth(java.lang.Integer maxWidth)
maxWidth - the valuepublic final java.lang.Integer getMaxHeight()
public final void setMaxHeight(java.lang.Integer maxHeight)
maxHeight - the valuepublic final void setZoomLevels(ZoomLevels zoomLevels)
Depending on the zoomLevelSnapStrategy, this will be used to compute the actual zoom level of the map.
zoomLevels - the valuepublic final void setZoomSnapTolerance(java.lang.Double zoomSnapTolerance)
Used in ZoomLevelSnapStrategy.HIGHER_SCALE and ZoomLevelSnapStrategy.LOWER_SCALE to specify the cutoff value.
zoomSnapTolerance - the valuepublic final void setZoomLevelSnapStrategy(ZoomLevelSnapStrategy zoomLevelSnapStrategy)
If you specify this value, you must set the zoomLevels as well.
Possible values are:
zoomLevelSnapStrategy - the valueZoomLevelSnapStrategypublic final void setZoomSnapGeodetic(java.lang.Boolean zoomSnapGeodetic)
zoomSnapGeodetic - the valuepublic void validate(java.util.List<java.lang.Throwable> validationErrors,
Configuration configuration)
ConfigurationObjectvalidationErrors - a list to add any detected errors to.configuration - the containing configurationprotected final java.util.Optional<org.json.JSONObject> getClientInfo()
throws org.json.JSONException
ReflectiveAttributegetClientInfo in class ReflectiveAttribute<GenericMapAttribute.GenericMapAttributeValues>org.json.JSONException