Skip to content

Commit 2910f2c

Browse files
committed
Updating the WMS servlet build and adding information files. Adding
files to .gitignore
1 parent da698bc commit 2910f2c

File tree

5 files changed

+288
-5
lines changed

5 files changed

+288
-5
lines changed

.gitignore

+5-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,5 @@
1-
/classes
1+
/classes
2+
/package
3+
/nbproject/private/
4+
/build/
5+
/dist/

src/wmsservlet/README.txt

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
WMSServlet Package README
2+
3+
This package, built separately, creates a war file that can be loaded into tomcat or
4+
glassfish to provide a OGC WMS server. The servlet code in the war file contains
5+
everything you need, but it must be configured for your data and system configuration.
6+
7+
- The build.xml file controls the creation of the war file. You may want to modify
8+
what gets added to the war, data files and such, and where the servlet-api.jar file
9+
can be found to compile the servlet classes. It can be found in the tomcat/glassfish
10+
installations.
11+
12+
- Before you create the war file (using ant), you need to modify the WEB-INF/web.xml file,
13+
setting the port your server is running on (8080 is the default port of tomcat/glassfish),
14+
your URL request path, and the path to the properties file you are using to configure the
15+
servlet map layers. If you want to upload the properties file and have it found in the war
16+
file by simply naming the file with no path, it should work if you put it in the
17+
WEB-INF/classes directory. Otherwise, you can store the properties file anywhere on your system
18+
and specify the path in the web.xml file.
19+
20+
A sample properties file is in this directory, wms.properties. It works like the layer
21+
section of a standard openmap.properties file with a couple of extra properties.

src/wmsservlet/WEB-INF/web.xml

+5-4
Original file line numberDiff line numberDiff line change
@@ -7,24 +7,25 @@
77
<description>
88
</description>
99

10-
<!--
10+
<!-- Location of openmap.properties file to use to configure layers for WMS servlet. The value should be a path to the properties file. -->
1111
<context-param>
1212
<param-name>mapDefinition</param-name>
13-
<param-value>E:/home/tomrak/devel/tide/ommod/res/cfg/openmapexample/openmap.properties</param-value>
13+
<param-value>wms.properties</param-value>
1414
<description>
1515
Configuration file for openmap. Default value is "openmap.properties"
1616
</description>
1717
</context-param>
18-
-->
1918

19+
<!-- The port number that the servlet container (glassfish, apache) is running on. -->
2020
<context-param>
2121
<param-name>port</param-name>
22-
<param-value>7070</param-value>
22+
<param-value>8080</param-value>
2323
<description>
2424
Server port number
2525
</description>
2626
</context-param>
2727

28+
<!-- The request path used by clients (browsers, map programs), after the basic URL for the server. This is the part in front of the ? in the map request. -->
2829
<context-param>
2930
<param-name>path</param-name>
3031
<param-value>/omwms</param-value>

src/wmsservlet/build.xml

+3
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@
1212
<fileset dir="${openmap.home}/lib">
1313
<include name="**/*.jar" />
1414
</fileset>
15+
<fileset dir="${openmap.home}/ext/apache">
16+
<include name="servlet-api.jar" />
17+
</fileset>
1518
</path>
1619

1720
<target name="init">

src/wmsservlet/wms.properties

+254
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,254 @@
1+
## Sample properties file for WMS servlet
2+
3+
# Antialiased map [optional]
4+
openmap.wms.antialiasing=true
5+
# Class that handles Feature Info Requests [optional]
6+
openmap.wms.featureInfoResponse.class=
7+
# Special WMS layers that follow com.bbn.openmap.image.wms.iWMSLayer interface, they
8+
# are handled a little differently and can respond to more metadata requests. [optional]
9+
wms.layers=
10+
11+
# Image formatters, notice that the formatters list provide scoping words for actual
12+
# formatters class properties.
13+
formatters=gif jpeg png png8 png32
14+
gif.class =com.bbn.openmap.image.AcmeGifFormatter
15+
jpeg.class=com.bbn.openmap.image.SunJPEGFormatter
16+
png.class=com.bbn.openmap.image.PNGImageIOFormatter
17+
png8.class=com.bbn.openmap.image.PNG8ImageFormatter
18+
png32.class=com.bbn.openmap.image.PNG32ImageFormatter
19+
20+
# OpenMap layers, these are general layer definitions. These keywords are
21+
# used for the layer name by the client in the WMS request.
22+
openmap.layers=daynight graticule shapePolitical
23+
24+
### -daynight- layer properties
25+
daynight.addToBeanContext=true
26+
daynight.autoPalette=false
27+
daynight.background=false
28+
daynight.class=com.bbn.openmap.layer.daynight.DayNightLayer
29+
daynight.consumeEvents=false
30+
daynight.currentTime=true
31+
daynight.daytimeColor=ffffff
32+
daynight.doPolyTerminator=true
33+
daynight.interruptable=true
34+
daynight.nighttimeColor=64000000
35+
daynight.overlayTime=0
36+
daynight.pcp.class=com.bbn.openmap.layer.policy.StandardPCPolicy
37+
daynight.prettyName=Day/Night Shading
38+
daynight.projectionChangePolicy=pcp
39+
daynight.removable=true
40+
daynight.renderPolicy=rp
41+
daynight.rp.class=com.bbn.openmap.layer.policy.StandardRenderPolicy
42+
daynight.termFade=0.1
43+
daynight.terminatorVerts=512
44+
daynight.transparency=1.0
45+
daynight.updateInterval=300000
46+
daynight.useCurrentTime=true
47+
### end of -daynight- properties
48+
49+
### -graticule- layer properties
50+
graticule.10DegreeColor=99000000
51+
graticule.1DegreeColor=99003300
52+
graticule.5DegreeColor=99009900
53+
graticule.Below1DegreeColor=9900ff00
54+
graticule.addToBeanContext=true
55+
graticule.autoPalette=false
56+
graticule.background=false
57+
graticule.class=com.bbn.openmap.layer.GraticuleLayer
58+
graticule.consumeEvents=false
59+
graticule.dateLineColor=99000000
60+
graticule.datelineColor=ff000099
61+
graticule.equatorColor=99ff0000
62+
graticule.fontSize=10
63+
graticule.interruptable=true
64+
graticule.pcp.class=com.bbn.openmap.layer.policy.StandardPCPolicy
65+
graticule.prettyName=Graticule
66+
graticule.projectionChangePolicy=pcp
67+
graticule.removable=true
68+
graticule.renderPolicy=rp
69+
graticule.rp.class=com.bbn.openmap.layer.policy.BufferedImageRenderPolicy
70+
graticule.show1And5Lines=true
71+
graticule.showBelow1Lines=false
72+
graticule.showRuler=true
73+
graticule.specialLineColor=99000000
74+
graticule.textColor=99000000
75+
graticule.threshold=2
76+
graticule.transparency=1.0
77+
### end of -graticule- properties
78+
79+
### -shapePolitical- layer properties
80+
shapePolitical.1.cap=2
81+
shapePolitical.1.dashPattern=
82+
shapePolitical.1.dashPhase=
83+
shapePolitical.1.fillColor=fff0f0f0
84+
shapePolitical.1.fillPattern=
85+
shapePolitical.1.join=0
86+
shapePolitical.1.key=COLOR_MAP
87+
shapePolitical.1.lineColor=ff000000
88+
shapePolitical.1.lineWidth=1.0
89+
shapePolitical.1.matted=false
90+
shapePolitical.1.mattingColor=ff000000
91+
shapePolitical.1.miterLimit=10.0
92+
shapePolitical.1.op=equals
93+
shapePolitical.1.pointOval=false
94+
shapePolitical.1.pointRadius=2
95+
shapePolitical.1.render=true
96+
shapePolitical.1.selectColor=ff000000
97+
shapePolitical.1.val=1
98+
shapePolitical.2.cap=2
99+
shapePolitical.2.dashPattern=
100+
shapePolitical.2.dashPhase=
101+
shapePolitical.2.fillColor=ffe9e9e9
102+
shapePolitical.2.fillPattern=
103+
shapePolitical.2.join=0
104+
shapePolitical.2.key=COLOR_MAP
105+
shapePolitical.2.lineColor=ff000000
106+
shapePolitical.2.lineWidth=1.0
107+
shapePolitical.2.matted=false
108+
shapePolitical.2.mattingColor=ff000000
109+
shapePolitical.2.miterLimit=10.0
110+
shapePolitical.2.op=equals
111+
shapePolitical.2.pointOval=false
112+
shapePolitical.2.pointRadius=2
113+
shapePolitical.2.render=true
114+
shapePolitical.2.selectColor=ff000000
115+
shapePolitical.2.val=2
116+
shapePolitical.3.cap=2
117+
shapePolitical.3.dashPattern=
118+
shapePolitical.3.dashPhase=
119+
shapePolitical.3.fillColor=ffe0e0e0
120+
shapePolitical.3.fillPattern=
121+
shapePolitical.3.join=0
122+
shapePolitical.3.key=COLOR_MAP
123+
shapePolitical.3.lineColor=ff000000
124+
shapePolitical.3.lineWidth=1.0
125+
shapePolitical.3.matted=false
126+
shapePolitical.3.mattingColor=ff000000
127+
shapePolitical.3.miterLimit=10.0
128+
shapePolitical.3.op=equals
129+
shapePolitical.3.pointOval=false
130+
shapePolitical.3.pointRadius=2
131+
shapePolitical.3.render=true
132+
shapePolitical.3.selectColor=ff000000
133+
shapePolitical.3.val=3
134+
shapePolitical.4.cap=2
135+
shapePolitical.4.dashPattern=
136+
shapePolitical.4.dashPhase=
137+
shapePolitical.4.fillColor=ffd9d9d9
138+
shapePolitical.4.fillPattern=
139+
shapePolitical.4.join=0
140+
shapePolitical.4.key=COLOR_MAP
141+
shapePolitical.4.lineColor=ff000000
142+
shapePolitical.4.lineWidth=1.0
143+
shapePolitical.4.matted=false
144+
shapePolitical.4.mattingColor=ff000000
145+
shapePolitical.4.miterLimit=10.0
146+
shapePolitical.4.op=equals
147+
shapePolitical.4.pointOval=false
148+
shapePolitical.4.pointRadius=2
149+
shapePolitical.4.render=true
150+
shapePolitical.4.selectColor=ff000000
151+
shapePolitical.4.val=4
152+
shapePolitical.5.cap=2
153+
shapePolitical.5.dashPattern=
154+
shapePolitical.5.dashPhase=
155+
shapePolitical.5.fillColor=ffd0d0d0
156+
shapePolitical.5.fillPattern=
157+
shapePolitical.5.join=0
158+
shapePolitical.5.key=COLOR_MAP
159+
shapePolitical.5.lineColor=ff000000
160+
shapePolitical.5.lineWidth=1.0
161+
shapePolitical.5.matted=false
162+
shapePolitical.5.mattingColor=ff000000
163+
shapePolitical.5.miterLimit=10.0
164+
shapePolitical.5.op=equals
165+
shapePolitical.5.pointOval=false
166+
shapePolitical.5.pointRadius=2
167+
shapePolitical.5.render=true
168+
shapePolitical.5.selectColor=ff000000
169+
shapePolitical.5.val=5
170+
shapePolitical.6.cap=2
171+
shapePolitical.6.dashPattern=
172+
shapePolitical.6.dashPhase=
173+
shapePolitical.6.fillColor=ffc9c9c9
174+
shapePolitical.6.fillPattern=
175+
shapePolitical.6.join=0
176+
shapePolitical.6.key=COLOR_MAP
177+
shapePolitical.6.lineColor=ff000000
178+
shapePolitical.6.lineWidth=1.0
179+
shapePolitical.6.matted=false
180+
shapePolitical.6.mattingColor=ff000000
181+
shapePolitical.6.miterLimit=10.0
182+
shapePolitical.6.op=equals
183+
shapePolitical.6.pointOval=false
184+
shapePolitical.6.pointRadius=2
185+
shapePolitical.6.render=true
186+
shapePolitical.6.selectColor=ff000000
187+
shapePolitical.6.val=6
188+
shapePolitical.7.cap=2
189+
shapePolitical.7.dashPattern=
190+
shapePolitical.7.dashPhase=
191+
shapePolitical.7.fillColor=ffc0c0c0
192+
shapePolitical.7.fillPattern=
193+
shapePolitical.7.join=0
194+
shapePolitical.7.key=COLOR_MAP
195+
shapePolitical.7.lineColor=ff000000
196+
shapePolitical.7.lineWidth=1.0
197+
shapePolitical.7.matted=false
198+
shapePolitical.7.mattingColor=ff000000
199+
shapePolitical.7.miterLimit=10.0
200+
shapePolitical.7.op=equals
201+
shapePolitical.7.pointOval=false
202+
shapePolitical.7.pointRadius=2
203+
shapePolitical.7.render=true
204+
shapePolitical.7.selectColor=ff000000
205+
shapePolitical.7.val=7
206+
shapePolitical.8.cap=2
207+
shapePolitical.8.dashPattern=
208+
shapePolitical.8.dashPhase=
209+
shapePolitical.8.fillColor=ffb9b9b9
210+
shapePolitical.8.fillPattern=
211+
shapePolitical.8.join=0
212+
shapePolitical.8.key=COLOR_MAP
213+
shapePolitical.8.lineColor=ff000000
214+
shapePolitical.8.lineWidth=1.0
215+
shapePolitical.8.matted=false
216+
shapePolitical.8.mattingColor=ff000000
217+
shapePolitical.8.miterLimit=10.0
218+
shapePolitical.8.op=equals
219+
shapePolitical.8.pointOval=false
220+
shapePolitical.8.pointRadius=2
221+
shapePolitical.8.render=true
222+
shapePolitical.8.selectColor=ff000000
223+
shapePolitical.8.val=8
224+
shapePolitical.addToBeanContext=true
225+
shapePolitical.autoPalette=false
226+
shapePolitical.background=true
227+
shapePolitical.cap=2
228+
shapePolitical.class=com.bbn.openmap.layer.shape.ShapeLayer
229+
shapePolitical.consumeEvents=false
230+
shapePolitical.dashPattern=
231+
shapePolitical.dashPhase=
232+
shapePolitical.fillColor=ffdad5cb
233+
shapePolitical.fillPattern=
234+
shapePolitical.interruptable=true
235+
shapePolitical.join=0
236+
shapePolitical.lineColor=ff000000
237+
shapePolitical.lineWidth=1.0
238+
shapePolitical.matted=false
239+
shapePolitical.mattingColor=ff000000
240+
shapePolitical.miterLimit=10.0
241+
shapePolitical.pcp.class=com.bbn.openmap.layer.policy.ListResetPCPolicy
242+
shapePolitical.pointImageURL=
243+
shapePolitical.pointOval=false
244+
shapePolitical.pointRadius=2
245+
shapePolitical.prettyName=Political Boundaries
246+
shapePolitical.projectionChangePolicy=pcp
247+
shapePolitical.removable=true
248+
shapePolitical.rules=1 2 3 4 5 6 7 8
249+
shapePolitical.selectColor=ff000000
250+
shapePolitical.shadowX=0
251+
shapePolitical.shadowY=0
252+
shapePolitical.shapeFile=/Volumes/data/shape/world/cntry02/cntry02.shp
253+
shapePolitical.transparency=1.0
254+
### end of -shapePolitical- properties

0 commit comments

Comments
 (0)