-
Notifications
You must be signed in to change notification settings - Fork 30
Issue 172: Support for sh:closed sh:ByTypes
#399
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
Open
HolgerKnublauch
wants to merge
5
commits into
gh-pages
Choose a base branch
from
issue-172
base: gh-pages
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bergos
approved these changes
Jun 8, 2025
Co-authored-by: Thomas Bergwinkl
sh:closed sh:ByTypes
TallTed
requested changes
Jun 11, 2025
Comment on lines
+5861
to
+5876
|
||
function collectProperties(S) |
||
add all IRI properties that can be reached from S via the SPARQL path |
||
sh:property/sh:path |
||
if S is a SHACL instance of rdfs:Class in the shapes graph { |
||
for each triple in the shapes graph matching (S rdfs:subClassOf ?o) |
||
collectProperties(?o) |
||
for each triple in the shapes graph matching (?s sh:targetClass S) |
||
collectProperties(?s) |
||
} |
||
if S is a SHACL instance of sh:NodeShape in the shapes graph |
||
for each triple in the shapes graph matching (S sh:node ?o) |
||
collectProperties(?o) |
||
|
||
for each rdf:type T of the value node in the data graph |
||
collectProperties(T) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggested change
<code> | |
function collectProperties(S)<br /> | |
add all IRI properties that can be reached from S via the SPARQL path<br /> | |
sh:property/sh:path<br /> | |
if S is a SHACL instance of rdfs:Class in the shapes graph {<br /> | |
for each triple in the shapes graph matching (S rdfs:subClassOf ?o)<br /> | |
collectProperties(?o)<br /> | |
for each triple in the shapes graph matching (?s sh:targetClass S)<br /> | |
collectProperties(?s)<br /> | |
}<br/> | |
if S is a SHACL instance of sh:NodeShape in the shapes graph<br /> | |
for each triple in the shapes graph matching (S sh:node ?o)<br /> | |
collectProperties(?o)<br /> | |
<br /> | |
for each rdf:type T of the value node in the data graph<br /> | |
collectProperties(T)<br /> | |
<code> | |
<pre>function collectProperties(S) | |
add all IRI properties that can be reached from S via the SPARQL path | |
sh:property/sh:path | |
if S is a SHACL instance of rdfs:Class in the shapes graph, then { | |
for each triple in the shapes graph matching (S rdfs:subClassOf ?o) | |
collectProperties(?o) | |
for each triple in the shapes graph matching (?s sh:targetClass S) | |
collectProperties(?s) | |
} | |
if S is a SHACL instance of sh:NodeShape in the shapes graph, then | |
for each triple in the shapes graph matching (S sh:node ?o) | |
collectProperties(?o) | |
for each rdf:type T of the value node in the data graph | |
collectProperties(T)</pre> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The pre was adding syntax highlighting in unsuitable places in my testing. Have you tried to render your change?
Co-authored-by: Ted Thibodeau Jr
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes #172