Constraint Descriptor : constraint_iti44patientadd_ihehl7v3002 (type: ERROR, kind: )

Constraint : constraint_iti44patientadd_ihehl7v3002

Constraint Name
constraint_iti44patientadd_ihehl7v3002 (type: ERROR, kind: )
Constraint Class
ITI44PatientAddPatientSpec
Package
ITI44PatientAdd
Description
When the Patient role is scoped by a Provider organization, only patient IDs assigned by the provider organization are allowed in the Patient class, the root element of the patient IDs shall match the root element of the provider organization ID.
OCL
(self.providerOrganization.oclIsUndefined() or self.providerOrganization.id->size() = 0)
xor
self.id->forAll(ii: II |
self.providerOrganization.id->exists(orgid: II | not (orgid.root.oclIsUndefined()) and orgid.root = ii.root))