Strabon

view endpoint/WebContent/WEB-INF/beans.xml @ 544:4657ea5fa82d

Fixes Ticket #9: http://bug.strabon.di.uoa.gr/ticket/9
author Panayiotis Smeros <psmeros@di.uoa.gr>
date Fri Sep 14 13:21:31 2012 +0300 (2012-09-14)
parents a915117ecad3
children e5930301d59c
line source
1 <?xml version="1.0" encoding="UTF-8"?>
2 <beans xmlns="http://www.springframework.org/schema/beans"
3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4 xsi:schemaLocation="http://www.springframework.org/schema/beans
5 http://www.springframework.org/schema/beans/spring-beans-2.5.xsd"
6 xmlns:jaxws="http://cxf.apache.org/jaxws"
7 jaxws:schemaLocation="http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd">
9 <bean
10 id="strabonBean"
11 class="eu.earthobservatory.org.StrabonEndpoint.StrabonBeanWrapper"
12 destroy-method="destroy">
14 <constructor-arg type="java.lang.String" >
15 <!-- Database name -->
16 <value>endpoint</value>
17 </constructor-arg>
19 <constructor-arg type="java.lang.String" >
20 <!-- Username -->
21 <value>postgres</value>
22 </constructor-arg>
24 <constructor-arg type="java.lang.String" >
25 <!-- Password -->
26 <value>postgres</value>
27 </constructor-arg>
29 <constructor-arg type="int" >
30 <!-- Port -->
31 <value>5432</value>
32 </constructor-arg>
34 <constructor-arg type="java.lang.String" >
35 <!-- Database server -->
36 <value>localhost</value>
37 </constructor-arg>
39 <constructor-arg type="boolean" >
40 <!-- Check for locks and remove them (in case of a crash) -->
41 <value>true</value>
42 </constructor-arg>
44 <constructor-arg type="java.lang.String" >
45 <!-- Database Backend (either "postgis" or "monetdb") -->
46 <value>postgis</value>
47 </constructor-arg>
49 <constructor-arg>
50 <list>
51 <list>
52 <!-- Bean -->
53 <value>Query</value>
54 <!-- Format -->
55 <value>HTML</value>
56 <!-- Label -->
57 <value>Query 1: Discover raw data and products</value>
58 <!-- Statement -->
59 <value><![CDATA[# Discovering raw data and products
60 PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
61 PREFIX clc: <http://teleios.di.uoa.gr/ontologies/clcOntology.owl#>
62 PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
63 PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
64 PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
65 PREFIX teleios: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
66 PREFIX gag: <http://www.semanticweb.org/ontologies/2011/gagKallikratis.rdf#>
67 PREFIX geo: <http://www.w3.org/2003/01/geo/wgs84_pos#>
68 PREFIX georss: <http://www.georss.org/georss/>
69 PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
70 PREFIX lgdo: <http://linkedgeodata.org/ontology/>
71 PREFIX gn: <http://www.geonames.org/ontology#>
73 SELECT ?filename
74 WHERE {?file rdf:type noa:ShpFile ;
75 noa:hasFilename ?filename ;
76 noa:hasAcquisitionTime ?sensingTime .
77 FILTER( str(?sensingTime) >= "2007-08-26T12:00:00" ) .
78 FILTER( str(?sensingTime) <= "2007-08-26T12:30:00" ) .
79 ?file noa:isDerivedFromSensor ?sensor .
80 FILTER( str(?sensor) = "MSG2" ) .
81 ?file noa:producedFromProcessingChain ?chain .
82 FILTER( str(?chain) = "StaticThresholds" ) .
83 }]]></value>
84 <value>Find all shapefiles derived from sensor MSG2 between [2007-08-26T12:00:00,2007-08-26T12:30:00], using dynamic thresholds.</value>
85 </list>
86 <list>
87 <!-- Bean -->
88 <value>Query</value>
89 <!-- Format -->
90 <value>KMZ</value>
91 <!-- Label -->
92 <value>Query 2: Discover Hotspots</value>
93 <!-- Statement -->
94 <value><![CDATA[# Get all hotspots in Pelloponesus at 2007-08-24
95 PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
96 PREFIX clc: <http://teleios.di.uoa.gr/ontologies/clcOntology.owl#>
97 PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
98 PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
99 PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
100 PREFIX teleios: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
101 PREFIX gag: <http://www.semanticweb.org/ontologies/2011/gagKallikratis.rdf#>
102 PREFIX geo: <http://www.w3.org/2003/01/geo/wgs84_pos#>
103 PREFIX georss: <http://www.georss.org/georss/>
104 PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
105 PREFIX lgdo: <http://linkedgeodata.org/ontology/>
106 PREFIX gn: <http://www.geonames.org/ontology#>
108 SELECT ?h ?hAcqTime ?hConfidence ?hConfirmation ?hProvider ?hSensor ?hSatellite (strdf:transform(?hGeo, <http://www.opengis.net/def/crs/EPSG/0/4326>) as ?geo)
109 WHERE { ?h rdf:type noa:Hotspot;
110 noa:hasGeometry ?hGeo;
111 noa:hasAcquisitionTime ?hAcqTime;
112 noa:hasConfidence ?hConfidence;
113 noa:isProducedBy ?hProvider;
114 noa:hasConfirmation ?hConfirmation;
115 noa:isDerivedFromSensor ?hSensor;
116 noa:isDerivedFromSatellite ?hSatellite ;
117 noa:producedFromProcessingChain ?hChain .
118 FILTER(str(?hChain) = "StaticThresholds").
119 FILTER(?hAcqTime = "2007-08-24T14:45:00"^^xsd:dateTime) .
120 FILTER(strdf:contains("POLYGON((21.027 38.36, 23.77 38.36, 23.77 36.05, 21.027 36.05, 21.027 38.36))"^^ strdf:WKT, ?hGeo)) .
121 }]]></value>
122 <value>Find all hotspots in Pelloponesus derived from the dynamic thresholds processing chain at 2007-08-24T14:45:00. </value>
123 </list>
124 <list>
125 <!-- Bean -->
126 <value>Update</value>
127 <!-- Format -->
128 <value>HTML</value>
129 <!-- Label -->
130 <value>Update A: Invalidate hotspots in sea</value>
131 <!-- Statement -->
132 <value><![CDATA[# Delete hotspots that lie in sea
133 PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
134 PREFIX clc: <http://teleios.di.uoa.gr/ontologies/clcOntology.owl#>
135 PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
136 PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
137 PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
138 PREFIX teleios: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
139 PREFIX gag: <http://www.semanticweb.org/ontologies/2011/gagKallikratis.rdf#>
140 PREFIX geo: <http://www.w3.org/2003/01/geo/wgs84_pos#>
141 PREFIX georss: <http://www.georss.org/georss/>
142 PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
143 PREFIX lgdo: <http://linkedgeodata.org/ontology/>
144 PREFIX gn: <http://www.geonames.org/ontology#>
145 DELETE {?h ?property ?object}
146 WHERE { ?h rdf:type noa:Hotspot;
147 noa:hasAcquisitionTime ?hAcqTime;
148 noa:producedFromProcessingChain ?hChain;
149 noa:hasGeometry ?hGeo;
150 ?property ?object.
151 FILTER(str(?hChain) = "StaticThresholds").
152 FILTER(strdf:contains("POLYGON((21.027 38.36, 23.77 38.36, 23.77 36.05, 21.027 36.05, 21.027 38.36))"^^ strdf:WKT, ?hGeo)).
153 FILTER("2007-08-24T14:45:00"^^xsd:dateTime = ?hAcqTime).
154 OPTIONAL {
155 ?c rdf:type noa:Coastline;
156 noa:hasGeometry ?cGeo.
157 FILTER(strdf:contains("POLYGON((21.027 38.36, 23.77 38.36, 23.77 36.05, 21.027 36.05, 21.027 38.36))"^^ strdf:WKT, ?cGeo)).
158 FILTER(strdf:anyInteract(?hGeo, ?cGeo)) .
159 }
160 FILTER(!bound(?c)).
161 }]]></value>
162 <value>Mark as invalid all hotspots produced by the static thresholds processing chain and are acquired at 2007-08-24T14:45:00 which are located in the sea</value>
163 </list>
164 <list>
165 <!-- Bean -->
166 <value>Update</value>
167 <!-- Format -->
168 <value>HTML</value>
169 <!-- Label -->
170 <value>Update B: Refine hotspots in sea</value>
171 <!-- Statement -->
172 <value><![CDATA[# Refine the geometry of hotspots that partially lie in sea
173 PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
174 PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
175 PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
176 PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
179 INSERT { ?h noa:isDiscarded "1"^^xsd:int .
180 ?valid rdf:type noa:Hotspot ;
181 noa:hasConfidence ?conf ;
182 noa:hasGeometry ?dif ;
183 noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ;
184 noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
185 noa:hasConfirmation noa:unknown ;
186 noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
187 noa:isProducedBy noa:noa ;
188 noa:isDerivedFromSatellite ?sat .
189 }
190 WHERE {
191 SELECT DISTINCT ?h ?hGeo (strdf:intersection(?hGeo, strdf:union(?cGeo)) AS ?dif) (BNODE() AS ?valid) ?conf ?sat
192 WHERE {
193 ?h rdf:type noa:Hotspot ;
194 noa:hasAcquisitionTime ?hAcqTime ;
195 noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
196 noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
197 noa:hasGeometry ?hGeo ;
198 noa:hasConfidence ?conf ;
199 noa:isDerivedFromSatellite ?sat .
200 FILTER("TIMESTAMP"^^xsd:dateTime = ?hAcqTime) .
201 ?c rdf:type noa:Coastline ;
202 noa:hasGeometry ?cGeo .
203 FILTER(strdf:anyInteract(?hGeo, ?cGeo)) .
204 }
205 GROUP BY ?h ?hGeo ?conf ?sat
206 HAVING strdf:overlap(?hGeo, strdf:union(?cGeo))
207 }
208 ]]></value>
209 <value>Refine hotspots acquired at 2007-08-24T14:45:00 removing the part that lies in the sea. </value>
210 </list>
211 <list>
212 <!-- Bean -->
213 <value>Query</value>
214 <!-- Format -->
215 <value>KMZ</value>
216 <!-- Label -->
217 <value>Query 3: Discover coniferous forests</value>
218 <!-- Statement -->
219 <value><![CDATA[#Get all coniferous forests in Peloponnese
220 PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
221 PREFIX clc: <http://teleios.di.uoa.gr/ontologies/clcOntology.owl#>
222 PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
223 PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
224 PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
225 PREFIX teleios: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
226 PREFIX gag: <http://www.semanticweb.org/ontologies/2011/gagKallikratis.rdf#>
227 PREFIX geo: <http://www.w3.org/2003/01/geo/wgs84_pos#>
228 PREFIX georss: <http://www.georss.org/georss/>
229 PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
230 PREFIX lgdo: <http://linkedgeodata.org/ontology/>
231 PREFIX gn: <http://www.geonames.org/ontology#>
233 SELECT ?a ?aGeo
234 WHERE{ ?a rdf:type clc:Area;
235 clc:hasLandUse ?aLandUse;
236 noa:hasGeometry ?aGeo.
237 ?aLandUse rdf:type ?aLandUseType.
238 FILTER(?aLandUseType = clc:ConiferousForest).
239 FILTER(strdf:contains("POLYGON((21.027 38.36, 23.77 38.36, 23.77 36.05, 21.027 36.05, 21.027 38.36))"^^strdf:WKT,?aGeo)).
240 }]]></value>
241 <value>Discover all coniferous forests using the clc ontology </value>
242 </list>
243 <list>
244 <!-- Bean -->
245 <value>Query</value>
246 <!-- Format -->
247 <value>KMZ</value>
248 <!-- Label -->
249 <value>Query 4: Discover primary roads</value>
250 <!-- Statement -->
251 <value><![CDATA[# Get all municipalities of Pelloponnese
252 PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
253 PREFIX clc: <http://teleios.di.uoa.gr/ontologies/clcOntology.owl#>
254 PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
255 PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
256 PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
257 PREFIX teleios: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
258 PREFIX gag: <http://www.semanticweb.org/ontologies/2011/gagKallikratis.rdf#>
259 PREFIX geo: <http://www.w3.org/2003/01/geo/wgs84_pos#>
260 PREFIX georss: <http://www.georss.org/georss/>
261 PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
262 PREFIX lgdo: <http://linkedgeodata.org/lontology/>
263 PREFIX gn: <http://www.geonames.org/ontology#>
265 SELECT ?d ?dGeo
266 WHERE { ?d rdf:type gag:Dhmos;
267 strdf:hasGeometry ?dGeo;
268 rdfs:label ?dLabel.
269 FILTER(strdf:contains("POLYGON((21.027 38.36, 23.77 38.36, 23.77 36.05, 21.027 36.05, 21.027 38.36))"^^ strdf:WKT, ?dGeo)).
270 }]]></value>
271 <value>Find all municipalities of Pelloponnese using kallikratis ontology </value>
272 </list>
273 <list>
274 <!-- Bean -->
275 <value>Query</value>
276 <!-- Format -->
277 <value>KMZ</value>
278 <!-- Label -->
279 <value>Query 5: Get all primary roads in Pelloponnese</value>
280 <!-- Statement -->
281 <value><![CDATA[# Get all primary roads in Pelloponnese
282 PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
283 PREFIX clc: <http://teleios.di.uoa.gr/ontologies/clcOntology.owl#>
284 PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
285 PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
286 PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
287 PREFIX teleios: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
288 PREFIX gag: <http://www.semanticweb.org/ontologies/2011/gagKallikratis.rdf#>
289 PREFIX geo: <http://www.w3.org/2003/01/geo/wgs84_pos#>
290 PREFIX georss: <http://www.georss.org/georss/>
291 PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
292 PREFIX lgdo: <http://linkedgeodata.org/ontology/>
293 PREFIX gn: <http://www.geonames.org/ontology#>
295 SELECT ?r ?rGeo
296 WHERE { ?r rdf:type ?rType ;
297 noa:hasGeometry ?rGeo .
298 FILTER(?rType = lgdo:Primary) .
299 FILTER(strdf:contains("POLYGON((21.027 38.36, 23.77 38.36, 23.77 36.05, 21.027 36.05,21.027 38.36))"^^strdf:WKT, ?rGeo) ).
300 }]]></value>
301 <value>Get all primary roads in Pelloponnese using the linked geodata ontology </value>
302 </list>
303 <list>
304 <!-- Bean -->
305 <value>Query</value>
306 <!-- Format -->
307 <value>KMZ</value>
308 <!-- Label -->
309 <value>Query 6: Discover hotspots</value>
310 <!-- Statement -->
311 <value><![CDATA[# Get all hotspots in Pelloponesus at 2007-08-24
312 PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
313 PREFIX clc: <http://teleios.di.uoa.gr/ontologies/clcOntology.owl#>
314 PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
315 PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
316 PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
317 PREFIX teleios: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
318 PREFIX gag: <http://www.semanticweb.org/ontologies/2011/gagKallikratis.rdf#>
319 PREFIX geo: <http://www.w3.org/2003/01/geo/wgs84_pos#>
320 PREFIX georss: <http://www.georss.org/georss/>
321 PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
322 PREFIX lgdo: <http://linkedgeodata.org/ontology/>
323 PREFIX gn: <http://www.geonames.org/ontology#>
325 SELECT ?h ?hAcqTime (strdf:transform(?hGeo, <http://www.opengis.net/def/crs/EPSG/0/4326>) as ?geo)
326 WHERE { ?h rdf:type noa:Hotspot;
327 noa:hasGeometry ?hGeo;
328 noa:hasAcquisitionTime ?hAcqTime;
329 noa:producedFromProcessingChain ?hChain .
330 FILTER(str(?hChain) = "StaticThresholds").
331 FILTER(?hAcqTime = "2007-08-24T14:45:00"^^xsd:dateTime) .
332 FILTER(strdf:contains("POLYGON((21.027 38.36, 23.77 38.36, 23.77 36.05, 21.027 36.05, 21.027 38.36))"^^ strdf:WKT, ?hGeo)) .
333 ?a rdf:type clc:Area;
334 clc:hasLandUse ?aLandUse;
335 noa:hasGeometry ?aGeo.
336 ?aLandUse rdf:type ?aLandUseType.
337 FILTER(?aLandUseType = clc:Forest).
338 FILTER(strdf:contains("POLYGON((21.027 38.36, 23.77 38.36, 23.77 36.05, 21.027 36.05, 21.027 38.36))"^^strdf:WKT,?aGeo)).
339 FILTER(strdf:overlap(?aGeo, ?hGeo)) .
340 }]]></value>
341 <value>Find all hotspots located in Pelloponnesian forests and acquired at 2007-08-24T14:45:00 using static thresholds processing chain </value>
342 </list>
343 <!-- <list> -->
344 <!-- Bean -->
345 <!-- <value>Query</value> -->
346 <!-- Format -->
347 <!-- <value>KMZ</value> -->
348 <!-- Label -->
349 <!-- <value></value> -->
350 <!-- Statement -->
351 <!-- <value></value> -->
352 <!-- </list> -->
353 </list>
354 </constructor-arg>
355 </bean>
356 </beans>