Skip to content

Commit

Permalink
ISSUE-131: Removed shapesGraph argument from sh:hasShape
Browse files Browse the repository at this point in the history
  • Loading branch information
HolgerKnublauch committed Sep 27, 2016
1 parent f7998db commit f16dc01
Showing 1 changed file with 9 additions and 13 deletions.
22 changes: 9 additions & 13 deletions shacl/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,7 @@ <h2>Revision History</h2>
The detailed list of changes and their diffs can be found in the <a href="https://github.com/w3c/data-shapes/commits/gh-pages/shacl/index.html">Git repository</a>.
</p>
<ul>
<li><b>2016-09-27</b>: Removed shapesGraph argument from sh:hasShape</li>
<li><b>2016-09-15</b>: Added proposed SPARQL prefix handling section (<a href="http://www.w3.org/2014/data-shapes/track/issues/105">ISSUE-105</a>)</li>
<li><b>2016-09-15</b>: Added sh:languageIn (<a href="http://www.w3.org/2014/data-shapes/track/issues/137">ISSUE-137</a>)</li>
<li><b>2016-08-26</b>: Remove special treatment of sh:Violation (<a href="http://www.w3.org/2014/data-shapes/track/issues/150">ISSUE-150</a>)</li>
Expand Down Expand Up @@ -2598,7 +2599,7 @@ <h3>sh:not</h3>
<pre class="def-sparql-body">
SELECT $this ?failure
WHERE {
BIND (sh:hasShape($this, $not, $shapesGraph) AS ?hasShape) .
BIND (sh:hasShape($this, $not) AS ?hasShape) .
BIND (!bound(?hasShape) AS ?failure) .
FILTER (?failure || ?hasShape) .
}</pre>
Expand All @@ -2609,7 +2610,7 @@ <h3>sh:not</h3>
SELECT $this ?value ?failure
WHERE {
$this $PATH ?value .
BIND (sh:hasShape($this, $not, $shapesGraph) AS ?hasShape) .
BIND (sh:hasShape($this, $not) AS ?hasShape) .
BIND (!bound(?hasShape) AS ?failure) .
FILTER (?failure || ?hasShape) .
}</pre>
Expand Down Expand Up @@ -2836,7 +2837,7 @@ <h4>sh:shape</h4>
<pre class="def-sparql-body">
SELECT $this ?failure
WHERE {
BIND (sh:hasShape($this, $shape, $shapesGraph) AS ?hasShape) .
BIND (sh:hasShape($this, $shape) AS ?hasShape) .
BIND (!bound(?hasShape) AS ?failure) .
FILTER (?failure || !?hasShape) .
}</pre>
Expand All @@ -2847,7 +2848,7 @@ <h4>sh:shape</h4>
SELECT $this ?value ?failure
WHERE {
$this $PATH ?value .
BIND (sh:hasShape(?value, $shape, $shapesGraph) AS ?hasShape) .
BIND (sh:hasShape(?value, $shape) AS ?hasShape) .
BIND (!bound(?hasShape) AS ?failure) .
FILTER (?failure || !?hasShape) .
}</pre>
Expand Down Expand Up @@ -2935,7 +2936,7 @@ <h4>sh:qualifiedValueShape, sh:qualifiedMinCount, sh:qualifiedMaxCount</h4>
WHERE {
{
$this $PATH ?value .
BIND (sh:hasShape(?value, $qualifiedValueShape, $shapesGraph) AS ?hasShape) .
BIND (sh:hasShape(?value, $qualifiedValueShape) AS ?hasShape) .
FILTER (!bound(?hasShape) || ?hasShape) .
}
BIND (IF(!bound(?hasShape), 1, 0) AS ?failed) .
Expand Down Expand Up @@ -2967,7 +2968,7 @@ <h4>sh:qualifiedValueShape, sh:qualifiedMinCount, sh:qualifiedMaxCount</h4>
WHERE {
{
$this $PATH ?value .
BIND (sh:hasShape(?value, $qualifiedValueShape, $shapesGraph) AS ?hasShape) .
BIND (sh:hasShape(?value, $qualifiedValueShape) AS ?hasShape) .
FILTER (!bound(?hasShape) || ?hasShape) .
}
BIND (IF(!bound(?hasShape), 1, 0) AS ?failed) .
Expand Down Expand Up @@ -4392,21 +4393,16 @@ <h2>The Function sh:hasShape</h2>
<td><code>rdfs:Resource</code></td>
<td>The <a>shape</a> to validate the focus node against.</td>
</tr>
<tr>
<td><code>shapesGraph</code></td>
<td><code>rdfs:Resource</code></td>
<td>The IRI of the current <a>shapes graph</a>.</td>
</tr>
</table>
<p>
An example call of this function is
</p>
<pre>
<code>BIND (sh:hasShape(ex:JohnDoe, ex:PersonShape, $shapesGraph) AS ?hasShape)</code>
<code>BIND (sh:hasShape(ex:JohnDoe, ex:PersonShape) AS ?hasShape)</code>
</pre>
<p>
None of the <a>parameters</a> can be unbound.
The result of the <code>sh:hasShape</code> function is either <code>true</code>, <code>false</code> or an <span class="term">error</span>:
The result of the <code>sh:hasShape</code> function is either:
</p>
<ul>
<li><code>true</code> if the <a>validation</a> of the <code>focusNode</code> against the given <code>shape</code> produces no <a>validation results</a>.</li>
Expand Down

0 comments on commit f16dc01

Please sign in to comment.