comparison flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/RiverAxisState.java @ 954:a5ea28339e5b

Set the extent of created WMSLayerFacets. flys-artifacts/trunk@2372 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Wed, 20 Jul 2011 12:42:06 +0000
parents 796c54058dc4
children ae198bef4ba0
comparison
equal deleted inserted replaced
953:6f8873fca927 954:a5ea28339e5b
8 8
9 import de.intevation.artifactdatabase.state.Facet; 9 import de.intevation.artifactdatabase.state.Facet;
10 10
11 import de.intevation.flys.artifacts.FLYSArtifact; 11 import de.intevation.flys.artifacts.FLYSArtifact;
12 import de.intevation.flys.artifacts.model.WMSLayerFacet; 12 import de.intevation.flys.artifacts.model.WMSLayerFacet;
13 import de.intevation.flys.artifacts.resources.Resources;
13 import de.intevation.flys.artifacts.states.DefaultState.ComputeType; 14 import de.intevation.flys.artifacts.states.DefaultState.ComputeType;
14 15
15 16
16 public class RiverAxisState extends OutputState { 17 public class RiverAxisState extends OutputState {
18
19 public static final String I18N_DESCRIPTION = "floodmap.riveraxis";
20
17 21
18 private static final Logger logger = Logger.getLogger(RiverAxisState.class); 22 private static final Logger logger = Logger.getLogger(RiverAxisState.class);
19 23
20 @Override 24 @Override
21 public Object computeInit( 25 public Object computeInit(
24 CallMeta meta, 28 CallMeta meta,
25 List<Facet> facets 29 List<Facet> facets
26 ) { 30 ) {
27 logger.debug("RiverAxisState.computeInit()"); 31 logger.debug("RiverAxisState.computeInit()");
28 32
33 // TODO Add config for background layer
29 WMSLayerFacet facet = new WMSLayerFacet( 34 WMSLayerFacet facet = new WMSLayerFacet(
30 0, 35 0,
31 FLOODMAP_RIVERAXIS, 36 FLOODMAP_RIVERAXIS,
32 "RIVER AXIS", 37 Resources.getMsg(meta, I18N_DESCRIPTION, I18N_DESCRIPTION),
33 ComputeType.INIT, 38 ComputeType.INIT,
34 getID(), hash, 39 getID(), hash,
35 "http://localhost/wms/"); // TODO add correct WMS URL 40 "http://denmark.atlas/cgi-bin/flys-wms"); // TODO add correct WMS URL
36 41
37 facet.addLayer("riveraxis"); 42 facet.addLayer("riveraxis");
43
44 // TODO determine extent based on the given geometry
45 facet.setExtent("6.5 49.1 7.0 49.7");
38 46
39 facets.add(facet); 47 facets.add(facet);
40 48
41 return null; 49 return null;
42 } 50 }

http://dive4elements.wald.intevation.org