Strabon

view examples/teleios/refinePartialSeaHotspots.rq @ 795:bf41e1f04c52

* Modified stSPARQL extension function to comply with the OGC Simple Features Access
- removed functions covers and covered_by
- renamed function inside to within
- added function crosses
* Modified the TELEIOS scripts to comply with the new function names
* Modified the SpatialTests class (runtime) to comply with the new function names
- BUG (known issue): The functions sf-overlaps and sf-crosses are not implemented correctly.
We should modify the PostGISQueryBuilder to use the ST_Overlaps and the
ST_Crosses functions respectively.
- TODO Verify the tests using MonetDB as a spatially enabled back end.
author Kostis Kyzirakos <kkyzir@di.uoa.gr>
date Mon Dec 10 22:27:44 2012 +0200 (2012-12-10)
parents fd5b6c160777
children a0c85ff6a60e
line source
1 PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
2 PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
3 PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
4 PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
5 PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
8 INSERT { ?h noa:isDiscarded "1"^^xsd:int .
9 ?valid rdf:type noa:Hotspot ;
10 noa:hasConfidence ?conf ;
11 noa:hasGeometry ?dif ;
12 gag:hasMunicipality ?muni ;
13 noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ;
14 noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
15 noa:hasConfirmation noa:unknown ;
16 noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
17 noa:isProducedBy noa:noa ;
18 noa:isDerivedFromSatellite "SAT"^^xsd:string ;
19 noa:refinedBy noa:coastlineRefinement ;
20 noa:refinedBy ?refined .
21 }
22 WHERE {
23 SELECT ?h (strdf:intersection(?hGeo, strdf:union(?cGeo)) AS ?dif) (URI(CONCAT(STR(?h),"/refined")) AS ?valid) ?conf ?muni
24 WHERE {
25 ?h noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime;
26 noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
27 noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
28 noa:hasGeometry ?hGeo ;
29 gag:hasMunicipality ?muni ;
30 noa:hasConfidence ?conf .
31 ?c rdf:type gag:GeometryPart ;
32 gag:hasGeometry ?cGeo .
33 FILTER(strdf:mbbOverlaps(?hGeo, ?cGeo)) .
34 OPTIONAL { ?h noa:refinedBy ?refined } .
35 }
36 GROUP BY ?h ?hGeo ?conf ?muni
37 HAVING strdf:overlaps(?hGeo, strdf:union(?cGeo))
38 }