Closed MiguelAraCo closed 7 years ago
This example would basically look for triples such as "Hello!" ex:somePath ?value, but these cannot exist. But in principle there is nothing wrong here and no results should be produced. However, if you had sh:minCount 1 it would fail with a sh:MinCountConstraintComponent violation. Does this make sense? Please close if satisfied.
Thank you for answering so quickly.
What you just said makes me wonder if that logic applies to other places as well. For example:
<PropertyShape>
sh:targetClass ex:TargetClass;
sh:property [
sh:path ex:theProperty;
sh:uniqueLang "true"^^xsd:boolean
].
<FocusNode>
a ex:TargetClass;
ex:theProperty <SomeRandomIRI>.
In that case the restriction says that the property ex:theProperty
can't have values with repeated languages. But <SomeRandomIRI>
is an IRI so it can't have a language tag to begin with. In theory there's nothing wrong with that. So following the logic of your answer it shouldn't produce a result.
If this is true, then results should only be produced when the restriction is being violated directly. If the restriction can't be evaluated it won't produce a result (unless stated otherwise in the W3C recommendation).
Is this correct?
Yes, according to the spec there need to be at least two values with the same language tag, but in your example there is not even one. Each constraint component has individual rules.
That makes sense. I'll follow that model in the implementation I'm working on. Thanks!
Example:
Should the processor produce a result? And if so, what
sh:sourceConstraintComponent
should the result have?