The update is intended to expose This update exposes Weave map engines as a WMS service, but the . The bundle can also be used to create URL's that can be called from external application applications to create custom map images, this is because the . The bundle supports additional parameters beyond those required by WMS which and allows for more customised map output.
A new configuration describes a map context that is similar to that which is setup for a map view in a client configuration, and . It is generated in a similar way to the maps that are included in a BIRT report.
There can be multiple map context setupsetups, that each describe different map setups.
Code Block | ||||
---|---|---|---|---|
| ||||
<?xml version="1.0" encoding="UTF-8"?> <config xmlns="urn:com.cohga.server.config#1.0" xmlns:wmsserver="urn:com.cohga.server.wms#1.0"> <wmsserver:context id="test"> <mapengine id="mapengine.raster"> <layer>satellite</layer> </mapengine> <mapengine id="mapengine.vector"> <layer>property</layer> <layer>road</layer> <layer>suburb</layer> <layer>mccbound</layer> </mapengine> <mapengine id="mapengine.parks" opacity="0.75"> <layer>Reserve Images</layer> </mapengine> </wmsserver:context> </config> |
The above example will expose exposes a new WMS service at /weave/wms/test
that will contain the layers listed (and only those layers).
And, when When the WMS client tries to draw the map, Weave will use the three map engines to generate the individual images and combine them into a single map image to return to the client.
This service should be supported in any WMS compliant client.
...
Name | Description | WMS Compliant |
---|---|---|
srs | Coordinate reference system of the coordinates specified in the URL | X |
width | Width of generated image in pixels | X |
height | Height of generated image in pixels | X |
format | Output format of the generated image | X |
bgcolor | Background colour | X |
transparent | true if transparent images should be created, false if opaque images should be generated | X |
bbox | Comma separated minx, miny, maxx and maxy of the generated image | X |
layers | List of layers to draw, all layers will be drawn if not set at all, and no layers drawn if layers is set to no value | X |
exceptions | Method used to return errors to the caller | X |
size | Comma separated width and height of generated image in pixels | |
dpi | DPI of generated image, to ensure scale dependencies are calculated correctly | |
minx | Left X coordinate | |
miny | Bottom Y coordinate | |
maxx | Right X Coordinate | |
maxy | Top Y coordinate | |
x | Centre X coordinate | |
y | Centre Y coordinate | |
centre | Comma separated X and Y coordinate. Both | |
scale | Scale to generate map at | |
entity | Entity to use to determine map extent and draw highlight | |
ids | Identifiers of entities to zoom to and highlight | |
filter | Filters to be applied to 'ids' before calculating the extent. For use if external system uses different id's for the underlying GIS data | |
buffer | Amount to scale entity extent by to calculate extent, e.g. 1.2 to place a 20% buffer around the entity bounds | |
minscale | Minimum scale to zoom to when zooming to an entity | |
highlight | false if the entity highlight should not be drawn, true if it should be drawn | |
hlcolor | Vector highlight colour | |
mcolor | Marker highlight colour. Should be blue, brown, dark, green, orange, purple, red, silver or yellow. The default is green. The mcolor 'dark' is a dark grey. |
Note |
---|
When specifying the map bounding box setting minx, miny, maxx and maxy is the same as specifying just bbox, and bbox will take precedence if both are persent. |
...
Extended Context Example Requests
The following example examples assume the following map context and are the equivalent of the above.
Code Block | ||||
---|---|---|---|---|
| ||||
<?xml version="1.0" encoding="UTF-8"?> <config xmlns="urn:com.cohga.server.config#1.0" xmlns:wmsserver="urn:com.cohga.server.wms#1.0"> <wmsserver:context id="test"> <minscale>2500</minscale> <buffer>1.2</buffer> <width>800</width> <height>600</height> <format>png32</format> <entity>property</entity> <mapengine id="mapengine.raster"> <layer>satellite</layer> </mapengine> <mapengine id="mapengine.vector"> <layer>property</layer> <layer>road</layer> <layer>suburb</layer> <layer>mccbound</layer> </mapengine> <mapengine id="mapengine.parks" opacity="0.75"> <layer>Reserve Images</layer> </mapengine> </wmsserver:context> </config> |
...
Note |
---|
The last example specifies the layer as |
...