Ontology Version: 2.2.0

cacontology-sentencing:SentencingCrossReferenceShape leaf node


URI

https://cacontology.projectvic.org/sentencing#SentencingCrossReferenceShape

Label

Sentencing Cross Reference Shape

Description

Validates cross-references between sentencing and related entities.

Implementation

@prefix cacontology-sentencing: <https://cacontology.projectvic.org/sentencing#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix sh: <http://www.w3.org/ns/shacl#> .
cacontology-sentencing:SentencingCrossReferenceShape a sh:NodeShape ;
    rdfs:label "Sentencing Cross Reference Shape"@en ;
    rdfs:comment "Validates cross-references between sentencing and related entities."@en ;
    sh:sparql [ sh:message "Sentencing outcome must result from at least one legal charge."@en ;
            sh:select """
            SELECT $this
            WHERE {
                $this a cacontology-sentencing:SentencingOutcome .
                FILTER NOT EXISTS {
                    $this cacontology-sentencing:resultsFromCharge ?charge .
                }
            }
        """ ] ;
    sh:targetClass cacontology-sentencing:SentencingOutcome .