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
#288: Added sh:SelectExpression, with test cases and TTL changes (#297)
* #288: Added sh:SelectExpression, with test cases and TTL changes
* #222, #288: Update SHACL-SHACL for general NodeExpression and SelectExpression
Signed-off-by: Alex Nelson <[email protected]>
* #222, #288: Undo update SHACL-SHACL for general NodeExpression and SelectExpression
This patch undoes commit 8632a3e. This was done manually instead of with `git revert`.
Signed-off-by: Alex Nelson <[email protected]>
* Update shacl12-vocabularies/shacl.ttl
Co-authored-by: Ted Thibodeau Jr <[email protected]>
---------
Signed-off-by: Alex Nelson <[email protected]>
Co-authored-by: Alex Nelson <[email protected]>
Co-authored-by: Ted Thibodeau Jr <[email protected]>
@@ -1206,6 +1212,118 @@ <h3>Validation with SPARQL-based Constraint Components</h3>
1206
1212
</section>
1207
1213
</section>
1208
1214
1215
+
<sectionid="sparql-node-expressions">
1216
+
<h2>SPARQL-based Node Expressions</h2>
1217
+
<p>
1218
+
This section introduces <a>node expression functions</a> based on SPARQL.
1219
+
</p>
1220
+
1221
+
<sectionid="SelectExpression">
1222
+
<h3>Select Expressions</h3>
1223
+
<p>
1224
+
A <a>node expression</a> that has a <a>value</a> for <code>sh:select</code> is called a <dfn>select expression</dfn> with the <a>function name</a>
1225
+
<code>sh:SelectExpression</code>.
1226
+
</p>
1227
+
<pclass="syntax">
1228
+
<spandata-syntax-rule="SelectExpression-syntax">A node in an RDF graph is a <a>well-formed</a><a>select expression</a> if it is a <a>blank node</a>
1229
+
that is the <a>subject</a> of exactly one <a>triple</a> with <code>sh:select</code> as <a>predicate</a> and a <a>literal</a> as <a>object</a>
1230
+
with <a>datatype</a><code>xsd:string</code>.</span>
1231
+
<spandata-syntax-rule="SelectExpression-query-valid">Using the <ahref="#sparql-prefixes">prefix handling rules</a>, the value of <code>sh:select</code> is a valid SPARQL 1.2 SELECT query.</span>
1232
+
<spandata-syntax-rule="SelectExpression-query-output-nodes">The SPARQL query derived from the value of <code>sh:select</code><adata-cite="sparql12-query/#selectproject">projects</a> exactly one variable in the SELECT clause.</span>
<divclass="def-header">EVALUATION OF SELECT EXPRESSIONS</div>
1236
+
<p>
1237
+
The <a>output nodes</a> of a <a>select expression</a> are the list <code>resultNodes</code> consisting of exactly the bindings of the (only)
1238
+
variable that is projected from the SELECT clause.
1239
+
If present in the <a>scope</a>, the value of the scope variable <code>focusNode</code> MUST be <a>pre-bound</a> as the value of the SPARQL variable <code>this</code>.
<h2>Changes between SHACL 1.0 SPARQL and SHACL 1.2 SPARQL Extensions</h2>
1659
+
<ul>
1660
+
<li>Added the <a>node expression function</a><ahref="#SelectExpression"><code>sh:SelectExpression</code></a>, see <ahref="https://github.com/w3c/data-shapes/issues/288">Issue 288</a></li>
0 commit comments