Closed eroux closed 5 years ago
The above pattern is accomplished in shacl via:
powla:Corpus
a sh:NodeShape ;
rdfs:subClassOf powla:Document ;
sh:property [
a sh:PropertyShape ;
sh:path powla:hasSuperDocument ;
sh:class powla:Document ;
sh:maxCount 0 ;
] ;
.
powla:Document
a sh:NodeShape ;
sh:property [
a sh:PropertyShape ;
sh:path powla:hasSuperDocument ;
sh:class powla:Document ;
] ;
.
A common use of owl:equivalentClass
is to attach property restrictions to a named class to clarify allowed membership. The same is done in shacl via defining shapes that express constraints on the properties that apply to members of a class.
There's already some examples of this pattern in the bdo.shapes.ttl
For me the take-away is to consider using sh:maxCount 0
as a way of signaling a root.
I'm not sure we want to use it but I thought it was an interesting thing to consider. The powla ontology has an interesting pattern where a
Corpus
is aDocument
with no super document, it's expressed in terms of owl equivalence: