FHIR Chat · Array values in differentials · conformance

Stream: conformance

Topic: Array values in differentials


view this post on Zulip Chris Moesel (Aug 04 2020 at 17:10):

The spec is unclear regarding how ElementDefinition properties that are arrays should be handled in differentials. The basic question is that if a parent definition has an element with foo: [a, b, c] and a profile's corresponding differential element has foo: [d], what is the resulting snapshot? Does the differential value replace the whole array (e.g., snapshot is foo: [d]) or is the differential value additive (e.g., snapshot is foo: [a, b, c, d])?

It seems that maybe it is context dependent. For example, for ElementDefinition.type, the type array in the differential element definitely replaces the inherited type array (otherwise there would be no way to narrow types). BUT... looking at some existing IGs, it looks like ElementDefinition.constraints is additive (e.g., the differential can list only new constraints, but the snapshot will contain new and inherited constraints).

Are these rules outlined anywhere? We need a definitive approach to ensure we generate the correct differentials in SUSHI.

view this post on Zulip Chris Moesel (Aug 21 2020 at 11:44):

Ping. Does no one know how this is supposed to work?

view this post on Zulip Grahame Grieve (Aug 21 2020 at 11:51):

there's an outstanding task to write this up somewhere

view this post on Zulip Grahame Grieve (Aug 21 2020 at 11:52):

there is a set answer, represented in the snap shot tests

view this post on Zulip Grahame Grieve (Aug 21 2020 at 11:52):

constraints are additive. Types are special and how that works is written up in the spec. Differentials... not sure


Last updated: Apr 12 2022 at 19:14 UTC