You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: shacl12-core/index.html
+25-1Lines changed: 25 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1157,6 +1157,16 @@ <h4>Implicit Class Targets</h4>
1157
1157
in a <a>shapes graph</a><code>SG</code> and <code>s</code> is also a <a>SHACL instance</a> of <code>rdfs:Class</code>
1158
1158
in <code>SG</code> then the set of <a>SHACL instances</a> of <code>s</code> in a data graph <code>DG</code> is a <a>target</a> from <code>DG</code> for <code>s</code> in <code>SG</code>.
1159
1159
</div>
1160
+
<pid="ShapeClass">
1161
+
The SHACL namespace includes a dedicated metaclass <code>sh:ShapeClass</code> that can serve as a syntactic shortcut for the implicit class targets pattern.
1162
+
</p>
1163
+
<divclass="def">
1164
+
<divclass="def-header">TEXTUAL DEFINITION</div>
1165
+
The class <code>sh:ShapeClass</code> is an <code>rdfs:subClassOf</code> of both <code>sh:NodeShape</code> and <code>rdfs:Class</code>.
1166
+
<code>sh:ShapeClass</code> has itself as its <code>rdf:type</code>.
1167
+
If <code>s</code> is a <a>SHACL instance</a> of <code>sh:ShapeClass</code> in a <a>shapes graph</a><code>SG</code>
1168
+
then the set of <a>SHACL instances</a> of <code>s</code> in a data graph <code>DG</code> is a <a>target</a> from <code>DG</code> for <code>s</code> in <code>SG</code>.
1169
+
</div>
1160
1170
<p><em>The remainder of this section is informative.</em></p>
1161
1171
<p>
1162
1172
In the following example, <code>ex:Alice</code> is a focus node, because it is a <a>SHACL instance</a> of
@@ -1168,6 +1178,13 @@ <h4>Implicit Class Targets</h4>
1168
1178
<preclass="example-data">
1169
1179
<spanclass="focus-node-selected">ex:Alice</span> a ex:Person .
1170
1180
ex:NewYork a ex:Place .</pre>
1181
+
<p>
1182
+
In the following variation of the example above, <code>ex:Person</code> is declared as an instance of <code>sh:ShapeClass</code>,
1183
+
with the same interpretation.
1184
+
</p>
1185
+
<preclass="example-shapes">
1186
+
ex:Person
1187
+
<b>a sh:ShapeClass</b> .</pre>
1171
1188
</section>
1172
1189
1173
1190
<sectionid="targetSubjectsOf">
@@ -4474,12 +4491,19 @@ <h2>Acknowledgements</h2>
4474
4491
<sectionclass="appendix informative">
4475
4492
<h2>Revision History</h2>
4476
4493
<p>
4477
-
The detailed list of changes and their diffs can be found in the Git repository.
4494
+
The detailed list of changes and their diffs can be found in the <ahref="https://github.com/w3c/data-shapes">Git repository</a>.
4478
4495
</p>
4479
4496
<ul>
4480
4497
<li><b>2024-02-14</b>: New work started by cloning the main SHACL spec and splitting it into SHACL Core and SHACL-SPARQL</li>
<h2>Changes between SHACL 1.0 Core and SHACL 1.2 Core</h2>
4503
+
<ul>
4504
+
<li>Added the new metaclass <ahref="#ShapeClass"><code>sh:ShapeClass</code></a> as syntactic sugar for implicit class targets, see <ahref="https://github.com/w3c/data-shapes/issues/212">Issue 212</a></li>
Copy file name to clipboardExpand all lines: shacl12-vocabularies/shacl.ttl
+7Lines changed: 7 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -54,6 +54,13 @@ sh:PropertyShape
54
54
rdfs:subClassOf sh:Shape ;
55
55
rdfs:isDefinedBy sh: .
56
56
57
+
sh:ShapeClass
58
+
a sh:ShapeClass ;
59
+
rdfs:comment "A shape class is a class that is also a node shape. sh:ShapeClass can be used as rdf:type instead of the combination of rdfs:Class and sh:NodeShape."@en ;
0 commit comments