Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat (add logical source): improve code structure #6

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

tobiasschweizer
Copy link
Collaborator

@tobiasschweizer tobiasschweizer commented Feb 7, 2025

subject map template:

PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>				
PREFIX : <http://uri.suomi.fi/datamodel/ns/mscr#>				
				
select ?sourceShapeUri ?schemaPath
where {
    ?mappingURI a <http://uri.suomi.fi/datamodel/ns/mscr#Mapping> .
    ?mappingURI :target/rdf:_1 ?target .
    ?target :uri <subject:https://shacl-play.sparna.fr/shapes/Person> .

    ?mappingURI :source ?seqBlankNode .
    ?seqBlankNode ?p ?sourceBlankNode .
    
    ?sourceBlankNode :uri ?sourceShapeUri .
    
    ?sourceShapeUri :schemaPath ?schemaPath
}

sourceShapeUri,schemaPath
mscr:schema:b2973de1-f9e6-4778-9390-039a86cb0771#root-Root-firstName,$.firstName
mscr:schema:b2973de1-f9e6-4778-9390-039a86cb0771#root-Root-lastName,$.lastName

@tobiasschweizer
Copy link
Collaborator Author

tobiasschweizer commented Feb 7, 2025

predicate object maps

PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>				
PREFIX : <http://uri.suomi.fi/datamodel/ns/mscr#>				
				
select ?sourceShapeUri ?schemaPath
where {
    ?mappingURI a <http://uri.suomi.fi/datamodel/ns/mscr#Mapping> .
    ?mappingURI :target/rdf:_1 ?target .
    ?target :uri <https://shacl-play.sparna.fr/shapes/Person_givenName> .

    ?mappingURI :source ?seqBlankNode .
    ?seqBlankNode ?p ?sourceBlankNode .
    
    ?sourceBlankNode :uri ?sourceShapeUri .
    
    ?sourceShapeUri :schemaPath ?schemaPath
}

sourceShapeUri,schemaPath
mscr:schema:b2973de1-f9e6-4778-9390-039a86cb0771#root-Root-firstName,$.firstName

@tobiasschweizer
Copy link
Collaborator Author

PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>				
PREFIX : <http://uri.suomi.fi/datamodel/ns/mscr#>				
				
select *
where {
    
    ?s a <http://www.w3.org/ns/shacl#PropertyShape>
    
}

s
mscr:schema:b2973de1-f9e6-4778-9390-039a86cb0771#root
mscr:schema:b2973de1-f9e6-4778-9390-039a86cb0771#root-Root-firstName
mscr:schema:b2973de1-f9e6-4778-9390-039a86cb0771#root-Root-lastName
mscr:schema:b2973de1-f9e6-4778-9390-039a86cb0771#root-Root-age

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant