David Price

Merge branch 'drilling-rdwed'

This diff could not be displayed because it is too large.
SELECT DISTINCT ?RDLDesignation ?RDLDefinition ?EntityType ?RDLSuperclass ?ERHLocalname ?ERHOntology
SELECT DISTINCT ?RDLDesignation ?RDLDefinition ?EntityType ?RDLSuperclass ?RDLSuperclassId ?ERHLocalname ?ERHOntology
WHERE {
?s pca-rdl:hasDesignation ?RDLDesignation .
?s pca-rdl:hasDefinition ?RDLDefinition .
......@@ -8,6 +8,7 @@ WHERE {
?spec ISO-15926-2_2003:hasSubclass ?s .
?spec ISO-15926-2_2003:hasSuperclass ?sup .
?sup pca-rdl:hasDesignation ?RDLSuperclass .
?sup pca-rdl:hasIdPCA ?RDLSuperclassId .
}
?erh owl:sameAs ?s .
......
SELECT DISTINCT ?RDLDesignation ?RDLDefinition ?EntityType ?CoPossessor ?ERHLocalname ?ERHOntology
WHERE {
?s pca-rdl:hasDesignation ?RDLDesignation .
?s ISO-15926-2_2003:hasClassOfPossessor ?CoPossessor .
?s pca-rdl:hasDefinition ?RDLDefinition .
?s rdf:type ?p2 .
BIND (afn:localname(?p2) AS ?EntityType )
OPTIONAL {
?spec ISO-15926-2_2003:hasSubclass ?s .
?spec ISO-15926-2_2003:hasSuperclass ?sup .
?sup pca-rdl:hasDesignation ?RDLSuperclass .
?sup pca-rdl:hasIdPCA ?RDLSuperclassId .
}
?erh owl:sameAs ?s .
BIND (afn:localname(?erh) AS ?ERHLocalname )
BIND (afn:namespace(?erh) AS ?ERHOntology )
}
\ No newline at end of file
......@@ -25,6 +25,225 @@
owl:imports <http://rds.posccaesar.org/2008/02/OWL/ISO-15926-2_2003> , <http://rds.posccaesar.org/2008/06/OWL/RDL-annotations> , <http://spinrdf.org/spin> , <http://www.reportinghub.no/ep/schema/1.0/drilling> ;
owl:versionInfo "Created with TopBraid Composer"^^xsd:string .
rdfs:Class
spin:rule
[ rdf:type sp:Construct ;
rdfs:comment "0180 Set URI and designation for EHR RD Class"^^xsd:string ;
sp:templates ([ sp:object
[ sp:varName "thisrduri"^^xsd:string
] ;
sp:predicate owl:sameAs ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "desigation"^^xsd:string
] ;
sp:predicate <http://posccaesar.org/rdl/hasDesignation> ;
sp:subject
[ sp:varName "thisrduri"^^xsd:string
]
] [ sp:object
[ sp:varName "definition"^^xsd:string
] ;
sp:predicate <http://posccaesar.org/rdl/hasDefinition> ;
sp:subject
[ sp:varName "thisrduri"^^xsd:string
]
] [ sp:object
[ sp:varName "pcaid"^^xsd:string
] ;
sp:predicate <http://posccaesar.org/rdl/hasIdPCA> ;
sp:subject
[ sp:varName "thisrduri"^^xsd:string
]
] [ sp:object "RDFS Class" ;
sp:predicate rdfs:comment ;
sp:subject
[ sp:varName "thisrduri"^^xsd:string
]
]) ;
sp:where ([ rdf:type sp:NotExists ;
sp:elements ([ sp:object owl:Class ;
sp:predicate rdf:type ;
sp:subject spin:_this
])
] [ rdf:type sp:NotExists ;
sp:elements ([ sp:object
[ sp:varName "same"^^xsd:string
] ;
sp:predicate owl:sameAs ;
sp:subject spin:_this
])
] [ rdf:type sp:NotExists ;
sp:elements ([ sp:object
[ sp:varName "seerd"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/ep/schema/core#seeReferenceData> ;
sp:subject spin:_this
])
] [ rdf:type sp:Filter ;
sp:expression
[ rdf:type sp:ne ;
sp:arg1 [ rdf:type afn:namespace ;
sp:arg1 spin:_this
] ;
sp:arg2 "http://www.linkedmodel.org/schema/vaem#"
]
] [ sp:object
[ sp:varName "definition"^^xsd:string
] ;
sp:predicate rdfs:comment ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "label"^^xsd:string
] ;
sp:predicate rdfs:label ;
sp:subject spin:_this
] [ rdf:type sp:Bind ;
sp:expression
[ rdf:type spif:generateUUID
] ;
sp:variable
[ sp:varName "uuid"^^xsd:string
]
] [ rdf:type sp:Bind ;
sp:expression
[ rdf:type fn:concat ;
sp:arg1 "ERH" ;
sp:arg2 [ sp:varName "uuid"^^xsd:string
]
] ;
sp:variable
[ sp:varName "pcaid"^^xsd:string
]
] [ rdf:type sp:Bind ;
sp:expression
[ rdf:type spif:buildURI ;
sp:arg1 "<http://posccaesar.org/rdl/{?pcaid}>"
] ;
sp:variable
[ sp:varName "thisrduri"^^xsd:string
]
] [ rdf:type sp:Bind ;
sp:expression
[ rdf:type fn:upper-case ;
sp:arg1 [ sp:varName "label"^^xsd:string
]
] ;
sp:variable
[ sp:varName "desigation"^^xsd:string
]
])
] ;
spin:rule
[ rdf:type sp:Construct ;
rdfs:comment "0185 Handle subclasses"^^xsd:string ;
sp:templates ([ sp:object ISO-15926-2_2003:Specialization ;
sp:predicate rdf:type ;
sp:subject
[ sp:varName "specuri"^^xsd:string
]
] [ sp:object
[ sp:varName "thisrduri"^^xsd:string
] ;
sp:predicate ISO-15926-2_2003:hasSubclass ;
sp:subject
[ sp:varName "specuri"^^xsd:string
]
] [ sp:object
[ sp:varName "superclassrduri"^^xsd:string
] ;
sp:predicate ISO-15926-2_2003:hasSuperclass ;
sp:subject
[ sp:varName "specuri"^^xsd:string
]
]) ;
sp:where ([ rdf:type sp:NotExists ;
sp:elements ([ sp:object owl:Class ;
sp:predicate rdf:type ;
sp:subject spin:_this
])
] [ sp:object
[ sp:varName "superclass"^^xsd:string
] ;
sp:predicate rdfs:subClassOf ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "thisrduri"^^xsd:string
] ;
sp:predicate owl:sameAs ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "superclassrduri"^^xsd:string
] ;
sp:predicate owl:sameAs ;
sp:subject
[ sp:varName "superclass"^^xsd:string
]
] [ rdf:type sp:Bind ;
sp:expression
[ rdf:type spif:generateUUID
] ;
sp:variable
[ sp:varName "uuid"^^xsd:string
]
] [ rdf:type sp:Bind ;
sp:expression
[ rdf:type fn:concat ;
sp:arg1 "ERH" ;
sp:arg2 [ sp:varName "uuid"^^xsd:string
]
] ;
sp:variable
[ sp:varName "pcaid"^^xsd:string
]
] [ rdf:type sp:Bind ;
sp:expression
[ rdf:type spif:buildURI ;
sp:arg1 "<http://posccaesar.org/rdl/{?pcaid}>"
] ;
sp:variable
[ sp:varName "specuri"^^xsd:string
]
])
] ;
spin:rule
[ rdf:type sp:Construct ;
rdfs:comment "0190 Set sameAs for RD items already in PCA RDL"^^xsd:string ;
sp:templates ([ sp:object
[ sp:varName "rduri"^^xsd:string
] ;
sp:predicate owl:sameAs ;
sp:subject spin:_this
]) ;
sp:where ([ rdf:type sp:NotExists ;
sp:elements ([ sp:object owl:Class ;
sp:predicate rdf:type ;
sp:subject spin:_this
])
] [ rdf:type sp:NotExists ;
sp:elements ([ sp:object
[ sp:varName "same"^^xsd:string
] ;
sp:predicate owl:sameAs ;
sp:subject spin:_this
])
] [ sp:object
[ sp:varName "seerd"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/ep/schema/core#seeReferenceData> ;
sp:subject spin:_this
] [ rdf:type sp:Bind ;
sp:expression
[ rdf:type smf:buildURI ;
sp:arg1 [ sp:varName "seerd"^^xsd:string
]
] ;
sp:variable
[ sp:varName "rduri"^^xsd:string
]
])
] .
owl:Class
spin:rule
[ rdf:type sp:Construct ;
......