|
| 1 | +@prefix bahnhof: <https://lod.bahnhof.de/vocabulary/db/>. |
| 2 | +@prefix codeforde: <https://lod.codefor.de/vocabulary/codeforde/>. |
| 3 | +@prefix dct: <http://purl.org/dc/terms/>. |
| 4 | +@prefix dbo: <https://dbpedia.org/ontology/>. |
| 5 | +@prefix foaf: <http://xmlns.com/foaf/0.1/>. |
| 6 | +@prefix geo: <http://www.opengis.net/ont/geosparql#>. |
| 7 | +@prefix gn: <http://www.geonames.org/ontology#>. |
| 8 | +@prefix juso: <http://rdfs.co/juso/>. |
| 9 | +@prefix netex: <https://lod.bahnhof.de/vocabulary/netex/>. |
| 10 | +@prefix owl: <http://www.w3.org/2002/07/owl#>. |
| 11 | +@prefix ql: <http://semweb.mmlab.be/ns/ql#>. |
| 12 | +@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>. |
| 13 | +@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>. |
| 14 | +@prefix rml: <http://semweb.mmlab.be/ns/rml#>. |
| 15 | +@prefix rr: <http://www.w3.org/ns/r2rml#>. |
| 16 | +@prefix schema: <http://schema.org/>. |
| 17 | +@prefix status: <http://www.w3.org/2003/06/sw-vocab-status/ns#>. |
| 18 | +@prefix wdt: <http://www.wikidata.org/prop/direct/>. |
| 19 | +@prefix xsd: <http://www.w3.org/2001/XMLSchema#>. |
| 20 | + |
| 21 | +# level 1 (stop place) |
| 22 | + |
| 23 | +[ a rr:TriplesMap ] |
| 24 | + rml:logicalSource [ |
| 25 | + rml:source "data/source.json"; |
| 26 | + rml:referenceFormulation ql:JSONPath; |
| 27 | + rml:iterator "$[?(@.Type == 'S')]" |
| 28 | + ]; |
| 29 | + rr:subjectMap [ |
| 30 | + rr:template "resource/by-key/ifopt/{.DHID}"; |
| 31 | + rr:class netex:StopPlace |
| 32 | + ]; |
| 33 | + rr:predicateObjectMap [ |
| 34 | + rr:predicate netex:topographicPlace; |
| 35 | + rr:objectMap [ |
| 36 | + rr:termType rr:IRI; |
| 37 | + rr:template "resource/by-key/ags/{.MunicipalityCode}" |
| 38 | + ] |
| 39 | + ], [ |
| 40 | + rr:predicate bahnhof:ifoptStopId; |
| 41 | + rr:objectMap [ |
| 42 | + rr:datatype xsd:string; |
| 43 | + rr:termType rr:Literal; |
| 44 | + rml:reference "$.DHID" |
| 45 | + ] |
| 46 | + ], [ |
| 47 | + rr:predicate netex:name; |
| 48 | + rr:objectMap [ |
| 49 | + rr:datatype xsd:string; |
| 50 | + rr:termType rr:Literal; |
| 51 | + rml:reference "$.Name" |
| 52 | + ] |
| 53 | + ]. |
| 54 | + # todo: other attributes |
| 55 | + |
| 56 | +# todo: level 2 (quay - platform), level 3 (quay - platform edge) |
0 commit comments