FirelyTeam / firely-validator-api

Firely's official FHIR validator API for validating HL7 FHIR resources against profiles.
Other
8 stars 2 forks source link

[Valdator] Support dependent profiles #137

Open ewoutkramer opened 1 year ago

ewoutkramer commented 1 year ago

HL7 has published a few extensions that we could implement and influence validation of profiles:

That last one looks like an optimization to me, and we already have this logic implemented in the new validator (if an instance is valid against a profile X, the instance is also valid against all parent profiles of X).

ewoutkramer commented 2 months ago

Operationally, I don't see what the results of that validation would do - except if you want to mark meta.profile with profiles against we have validated conformance. Then you can put both there.

The first one is basically saying: after finishing validation, continue with the profile given in the extension. I'd say just start a new validation and include the results in the end schema. We might want to double check that the locations and messages make sense if we have multiple profiles in use, but we do something like that when we validate meta.profile, an extension (which is another structdef) or a referenced profile (typeRef.profile), so it is not new.