StructureDefinition-sdc-questionnaire-candidateExpression.xml 1 <?xml version="1.0" encoding="utf-8"?> 2 <StructureDefinition xmlns="http://hl7.org/fhir"> 3 <id value="sdc-questionnaire-candidateExpression" /> 4 <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-wg"> 5 <valueCode value="fhir" /> 6 </extension> 7 <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm"> 8 <valueInteger value="4"> 9 <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-conformance-derivedFrom"> 10 <valueCanonical value="http://hl7.org/fhir/uv/sdc/ImplementationGuide/hl7.fhir.uv.sdc" /> 11 </extension> 12 </valueInteger> 13 </extension> 14 <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status"> 15 <valueCode value="trial-use"> 16 <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-conformance-derivedFrom"> 17 <valueCanonical value="http://hl7.org/fhir/uv/sdc/ImplementationGuide/hl7.fhir.uv.sdc" /> 18 </extension> 19 </valueCode> 20 </extension> 21 <url value="http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-candidateExpression" /> 22 <identifier> 23 <system value="urn:ietf:rfc:3986" /> 24 <value value="urn:oid:2.16.840.1.113883.4.642.40.17.42.18" /> 25 </identifier> 26 <version value="4.0.0-ballot" /> 27 <name value="CandidateExpressionExtension" /> 28 <title value="Candidate Answers Expression" /> 29 <status value="active" /> 30 <date value="2024-12-22T04:48:38.0000000+01:00" /> 31 <publisher value="HL7 International / FHIR Infrastructure" /> 32 <contact> 33 <name value="HL7 International / FHIR Infrastructure" /> 34 <telecom> 35 <system value="url" /> 36 <value value="http://www.hl7.org/Special/committees/fiwg" /> 37 </telecom> 38 </contact> 39 <contact> 40 <telecom> 41 <system value="url" /> 42 <value value="http://www.hl7.org/Special/committees/fiwg" /> 43 </telecom> 44 </contact> 45 <description value="A FHIRPath or CQL expression, or FHIR Query that resolves to a list of candidate answers for the question item or that establishes context for a group item. The user may select from among the candidates to choose answers for the question." /> 46 <jurisdiction> 47 <coding> 48 <system value="http://unstats.un.org/unsd/methods/m49/m49.htm" /> 49 <code value="001" /> 50 <display value="World" /> 51 </coding> 52 </jurisdiction> 53 <fhirVersion value="4.0.1" /> 54 <mapping> 55 <identity value="rim" /> 56 <uri value="http://hl7.org/v3" /> 57 <name value="RIM Mapping" /> 58 </mapping> 59 <kind value="complex-type" /> 60 <abstract value="false" /> 61 <context> 62 <type value="element" /> 63 <expression value="Questionnaire.item" /> 64 </context> 65 <context> 66 <type value="element" /> 67 <expression value="ElementDefinition" /> 68 </context> 69 <type value="Extension" /> 70 <baseDefinition value="http://hl7.org/fhir/StructureDefinition/Extension" /> 71 <derivation value="constraint" /> 72 <snapshot> 73 <element id="Extension"> 74 <path value="Extension" /> 75 <short value="Expression for possible answers" /> 76 <definition value="A FHIRPath or CQL expression, or FHIR Query that resolves to a list of candidate answers for the question item or that establishes context for a group item. The user may select from among the candidates to choose answers for the question." /> 77 <comment value="The results of the expression must correspond to the item type of the question the element appears on or must correspond to a resource, backbone element or complex data type for a group item. Resources are considered a match for the Reference item type. Quantity can be a match for decimal and integer items so long as a questionnaire-unit extension is present. If the expression returns coded data, it **SHALL* return the information as either code or Coding, not CodeableConcept. If the expression returns elements of type 'code', when the user selects one or more candidates, the code will be matched against the allowed Codings (from answerValueSet, answerOptions, or answerExpresssion). In this case, it is an error if there is more than one Coding with the same code." /> 78 <min value="0" /> 79 <max value="1" /> 80 <base> 81 <path value="Extension" /> 82 <min value="0" /> 83 <max value="*" /> 84 </base> 85 <condition value="ele-1" /> 86 <constraint> 87 <key value="ele-1" /> 88 <severity value="error" /> 89 <human value="All FHIR elements must have a @value or children" /> 90 <expression value="hasValue() or (children().count() > id.count())" /> 91 <xpath value="@value|f:*|h:div" /> 92 <source value="http://hl7.org/fhir/StructureDefinition/Element" /> 93 </constraint> 94 <constraint> 95 <key value="ext-1" /> 96 <severity value="error" /> 97 <human value="Must have either extensions or value[x], not both" /> 98 <expression value="extension.exists() != value.exists()" /> 99 <xpath value="exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])" /> 100 <source value="http://hl7.org/fhir/StructureDefinition/Extension" /> 101 </constraint> 102 <isModifier value="false" /> 103 </element> 104 <element id="Extension.id"> 105 <path value="Extension.id" /> 106 <representation value="xmlAttr" /> 107 <short value="Unique id for inter-element referencing" /> 108 <definition value="Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces." /> 109 <min value="0" /> 110 <max value="1" /> 111 <base> 112 <path value="Element.id" /> 113 <min value="0" /> 114 <max value="1" /> 115 </base> 116 <type> 117 <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type"> 118 <valueUrl value="string" /> 119 </extension> 120 <code value="http://hl7.org/fhirpath/System.String" /> 121 </type> 122 <isModifier value="false" /> 123 <isSummary value="false" /> 124 <mapping> 125 <identity value="rim" /> 126 <map value="n/a" /> 127 </mapping> 128 </element> 129 <element id="Extension.extension"> 130 <path value="Extension.extension" /> 131 <slicing> 132 <discriminator> 133 <type value="value" /> 134 <path value="url" /> 135 </discriminator> 136 <description value="Extensions are always sliced by (at least) url" /> 137 <rules value="open" /> 138 </slicing> 139 <short value="Extension" /> 140 <definition value="An Extension" /> 141 <min value="0" /> 142 <max value="0" /> 143 <base> 144 <path value="Element.extension" /> 145 <min value="0" /> 146 <max value="*" /> 147 </base> 148 <type> 149 <code value="Extension" /> 150 </type> 151 <constraint> 152 <key value="ele-1" /> 153 <severity value="error" /> 154 <human value="All FHIR elements must have a @value or children" /> 155 <expression value="hasValue() or (children().count() > id.count())" /> 156 <xpath value="@value|f:*|h:div" /> 157 <source value="http://hl7.org/fhir/StructureDefinition/Element" /> 158 </constraint> 159 <constraint> 160 <key value="ext-1" /> 161 <severity value="error" /> 162 <human value="Must have either extensions or value[x], not both" /> 163 <expression value="extension.exists() != value.exists()" /> 164 <xpath value="exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])" /> 165 <source value="http://hl7.org/fhir/StructureDefinition/Extension" /> 166 </constraint> 167 <isModifier value="false" /> 168 <isSummary value="false" /> 169 </element> 170 <element id="Extension.url"> 171 <path value="Extension.url" /> 172 <representation value="xmlAttr" /> 173 <short value="identifies the meaning of the extension" /> 174 <definition value="Source of the definition for the extension code - a logical name or a URL." /> 175 <comment value="The definition may point directly to a computable or human-readable definition of the extensibility codes, or it may be a logical URI as declared in some other specification. The definition SHALL be a URI for the Structure Definition defining the extension." /> 176 <min value="1" /> 177 <max value="1" /> 178 <base> 179 <path value="Extension.url" /> 180 <min value="1" /> 181 <max value="1" /> 182 </base> 183 <type> 184 <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type"> 185 <valueUrl value="uri" /> 186 </extension> 187 <code value="http://hl7.org/fhirpath/System.String" /> 188 </type> 189 <fixedUri value="http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-candidateExpression" /> 190 <isModifier value="false" /> 191 <isSummary value="false" /> 192 <mapping> 193 <identity value="rim" /> 194 <map value="N/A" /> 195 </mapping> 196 </element> 197 <element id="Extension.value[x]"> 198 <path value="Extension.value[x]" /> 199 <short value="Value of extension" /> 200 <definition value="Value of extension - must be one of a constrained set of the data types (see [Extensibility](http://hl7.org/fhir/R4/extensibility.html) for a list)." /> 201 <min value="0" /> 202 <max value="1" /> 203 <base> 204 <path value="Extension.value[x]" /> 205 <min value="0" /> 206 <max value="1" /> 207 </base> 208 <type> 209 <code value="Expression" /> 210 </type> 211 <constraint> 212 <key value="ele-1" /> 213 <severity value="error" /> 214 <human value="All FHIR elements must have a @value or children" /> 215 <expression value="hasValue() or (children().count() > id.count())" /> 216 <xpath value="@value|f:*|h:div" /> 217 <source value="http://hl7.org/fhir/StructureDefinition/Element" /> 218 </constraint> 219 <isModifier value="false" /> 220 <isSummary value="false" /> 221 <mapping> 222 <identity value="rim" /> 223 <map value="N/A" /> 224 </mapping> 225 </element> 226 </snapshot> 227 <differential> 228 <element id="Extension"> 229 <path value="Extension" /> 230 <short value="Expression for possible answers" /> 231 <definition value="A FHIRPath or CQL expression, or FHIR Query that resolves to a list of candidate answers for the question item or that establishes context for a group item. The user may select from among the candidates to choose answers for the question." /> 232 <comment value="The results of the expression must correspond to the item type of the question the element appears on or must correspond to a resource, backbone element or complex data type for a group item. Resources are considered a match for the Reference item type. Quantity can be a match for decimal and integer items so long as a questionnaire-unit extension is present. If the expression returns coded data, it **SHALL* return the information as either code or Coding, not CodeableConcept. If the expression returns elements of type 'code', when the user selects one or more candidates, the code will be matched against the allowed Codings (from answerValueSet, answerOptions, or answerExpresssion). In this case, it is an error if there is more than one Coding with the same code." /> 233 <max value="1" /> 234 </element> 235 <element id="Extension.extension"> 236 <path value="Extension.extension" /> 237 <max value="0" /> 238 </element> 239 <element id="Extension.url"> 240 <path value="Extension.url" /> 241 <fixedUri value="http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-candidateExpression" /> 242 </element> 243 <element id="Extension.value[x]"> 244 <path value="Extension.value[x]" /> 245 <type> 246 <code value="Expression" /> 247 </type> 248 </element> 249 </differential> 250 </StructureDefinition>