Ontology Version: 2.2.0

cacontology-physical-shapes:ForensicRoleTemporalShape leaf node


URI

https://cacontology.projectvic.org/physical-evidence/shapes#ForensicRoleTemporalShape

Label

Forensic Role Temporal Shape

Description

Validates gUFO temporal constraints for forensic roles.

Target Classes (1)

Shape Properties

Instances of gufo:Role can have the following properties:

PROPERTY

MIN COUNT

MAX COUNT

TYPE

gufo:Role
cacontology-infrastructure:hasRoleBeginPoint 1 xsd:dateTimeStamp
cacontology-infrastructure:hasRoleEndPoint 1 xsd:dateTimeStamp
cacontology-multi:hasRoleBeginPoint 1 xsd:dateTimeStamp
cacontology-multi:hasRoleEndPoint 1 xsd:dateTimeStamp
cacontology-partnerships:hasRoleBeginPoint 1 xsd:dateTimeStamp
cacontology-partnerships:hasRoleEndPoint 1 xsd:dateTimeStamp
cacontology-production:hasRoleBeginPoint 0 1 xsd:dateTimeStamp
cacontology-production:hasRoleEndPoint 0 1 xsd:dateTimeStamp

Implementation

@prefix cacontology-physical-shapes: <https://cacontology.projectvic.org/physical-evidence/shapes#> .
@prefix cacontology-physical1: <https://cacontology.projectvic.org/physical-evidence#> .
@prefix gufo: <http://purl.org/nemo/gufo#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix sh: <http://www.w3.org/ns/shacl#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
cacontology-physical-shapes:ForensicRoleTemporalShape a sh:NodeShape ;
    rdfs:label "Forensic Role Temporal Shape"@en ;
    rdfs:comment "Validates gUFO temporal constraints for forensic roles."@en ;
    sh:property [ sh:datatype xsd:dateTimeStamp ;
            sh:maxCount 1 ;
            sh:message "Forensic role may have begin point timestamp."@en ;
            sh:path cacontology-physical1:hasRoleBeginPoint ],
        [ sh:datatype xsd:dateTimeStamp ;
            sh:maxCount 1 ;
            sh:message "Forensic role may have end point timestamp."@en ;
            sh:path cacontology-physical1:hasRoleEndPoint ] ;
    sh:sparql [ sh:message "Role end must be after begin when both are specified."@en ;
            sh:select """
            SELECT $this
            WHERE {
                $this cacontology-physical:hasRoleBeginPoint ?start ;
                      cacontology-physical:hasRoleEndPoint ?end .
                FILTER (?end <= ?start)
            }
        """ ] ;
    sh:targetClass gufo:Role .