Package org.mapfish.print.map.image.wms
Class WmsLayerParam
- java.lang.Object
-
- org.mapfish.print.map.AbstractLayerParams
-
- org.mapfish.print.map.tiled.AbstractTiledLayerParams
-
- org.mapfish.print.map.tiled.AbstractWMXLayerParams
-
- org.mapfish.print.map.image.wms.WmsLayerParam
-
- Direct Known Subclasses:
TiledWmsLayerParam
public class WmsLayerParam extends AbstractWMXLayerParams
Layer parameters for WMS layer.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
WmsLayerParam.ServerType
The WMS server type.
-
Field Summary
Fields Modifier and Type Field Description java.lang.String
baseURL
The base URL for the WMS.java.lang.String
imageFormat
The format of the image.java.lang.String[]
layers
The wms layer to request in the GetMap request.org.springframework.http.HttpMethod
method
The HTTP verb to use for fetching the images.WmsLayerParam.ServerType
serverType
The server type ("mapserver", "geoserver" or "qgisserver").java.lang.String[]
styles
The styles to apply to the layers.boolean
useNativeAngle
If true transform the map angle to customParams.angle for GeoServer, and MapServer.java.lang.String
version
The WMS version to use when making requests.-
Fields inherited from class org.mapfish.print.map.tiled.AbstractWMXLayerParams
customParams, mergeableParams
-
Fields inherited from class org.mapfish.print.map.tiled.AbstractTiledLayerParams
rasterStyle
-
Fields inherited from class org.mapfish.print.map.AbstractLayerParams
failOnError, name, opacity
-
-
Constructor Summary
Constructors Constructor Description WmsLayerParam()
Constructor.WmsLayerParam(WmsLayerParam other)
Copy constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getBaseUrl()
Get the base url for all tile requests.void
postConstruct()
Validate some of the properties of this layer.-
Methods inherited from class org.mapfish.print.map.tiled.AbstractWMXLayerParams
createCommonUrl, getCustomParams, getMergeableParams, setCustomParam, validateBaseUrl
-
-
-
-
Field Detail
-
baseURL
public java.lang.String baseURL
The base URL for the WMS. Used for making WMS requests.
-
layers
public java.lang.String[] layers
The wms layer to request in the GetMap request. The order is important. It is the order that they will appear in the request.As with the WMS specification, the first layer will be the first layer drawn on the map (the bottom/base layer) of the map. This means that layer at position 0 in the array will covered by layer 1 (where not transparent) and so on.
-
styles
public java.lang.String[] styles
The styles to apply to the layers. If this is defined there should be the same number as the layers and the style are applied to the layer in thelayers
field.
-
version
public java.lang.String version
The WMS version to use when making requests.
-
useNativeAngle
public boolean useNativeAngle
If true transform the map angle to customParams.angle for GeoServer, and MapServer.
-
serverType
public WmsLayerParam.ServerType serverType
The server type ("mapserver", "geoserver" or "qgisserver"). By specifying the server type vendor specific parameters (like for the DPI value) can be used when making the request.
-
imageFormat
public java.lang.String imageFormat
The format of the image. for example image/png, image/jpeg, etc...
-
method
public org.springframework.http.HttpMethod method
The HTTP verb to use for fetching the images. Can be either "GET" (the default) or "POST".In case of "POST", the parameters are send in the body of the request using an "application/x-www-form-urlencoded" content type. This can be used when the parameters are too long. Tested only with GeoServer.
-
-
Constructor Detail
-
WmsLayerParam
public WmsLayerParam()
Constructor.
-
WmsLayerParam
public WmsLayerParam(WmsLayerParam other)
Copy constructor.- Parameters:
other
- the object to copy
-
-
Method Detail
-
getBaseUrl
public final java.lang.String getBaseUrl()
Description copied from class:AbstractTiledLayerParams
Get the base url for all tile requests. For example it might be 'http://server .com/geoserver/gwc/service/wmts'.- Specified by:
getBaseUrl
in classAbstractTiledLayerParams
-
postConstruct
public void postConstruct() throws java.net.URISyntaxException
Validate some of the properties of this layer.- Throws:
java.net.URISyntaxException
-
-