maxValue.xml
  1 <?xml version="1.0" encoding="utf-8"?>
  2 <StructureDefinition xmlns="http://hl7.org/fhir">
  3   <id value="maxValue" />
  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="1" />
  9   </extension>
 10   <url value="http://hl7.org/fhir/StructureDefinition/maxValue" />
 11   <version value="4.0.1" />
 12   <name value="maxValue" />
 13   <status value="draft" />
 14   <date value="2014-04-27" />
 15   <publisher value="Health Level Seven International (FHIR Infrastructure)" />
 16   <contact>
 17     <telecom>
 18       <system value="url" />
 19       <value value="http://www.hl7.org/Special/committees/fiwg" />
 20     </telecom>
 21   </contact>
 22   <description value="The inclusive upper bound on the range of allowed values for the data element." />
 23   <fhirVersion value="4.0.1" />
 24   <mapping>
 25     <identity value="v2" />
 26     <uri value="http://hl7.org/v2" />
 27     <name value="HL7 v2 Mapping" />
 28   </mapping>
 29   <mapping>
 30     <identity value="rim" />
 31     <uri value="http://hl7.org/v3" />
 32     <name value="RIM Mapping" />
 33   </mapping>
 34   <kind value="complex-type" />
 35   <abstract value="false" />
 36   <context>
 37     <type value="element" />
 38     <expression value="Questionnaire.item" />
 39   </context>
 40   <type value="Extension" />
 41   <baseDefinition value="http://hl7.org/fhir/StructureDefinition/Extension" />
 42   <derivation value="constraint" />
 43   <snapshot>
 44     <element id="Extension">
 45       <path value="Extension" />
 46       <short value="Must be <= this value" />
 47       <definition value="The inclusive upper bound on the range of allowed values for the data element." />
 48       <comment value="Data type specified must be the same as the data type for the data element." />
 49       <min value="0" />
 50       <max value="1" />
 51       <base>
 52         <path value="Extension" />
 53         <min value="0" />
 54         <max value="*" />
 55       </base>
 56       <condition value="ele-1" />
 57       <constraint>
 58         <key value="ele-1" />
 59         <severity value="error" />
 60         <human value="All FHIR elements must have a @value or children" />
 61         <expression value="hasValue() or (children().count() > id.count())" />
 62         <xpath value="@value|f:*|h:div" />
 63         <source value="http://hl7.org/fhir/StructureDefinition/Element" />
 64       </constraint>
 65       <constraint>
 66         <key value="ext-1" />
 67         <severity value="error" />
 68         <human value="Must have either extensions or value[x], not both" />
 69         <expression value="extension.exists() != value.exists()" />
 70         <xpath value="exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])" />
 71         <source value="http://hl7.org/fhir/StructureDefinition/Extension" />
 72       </constraint>
 73       <isModifier value="false" />
 74       <mapping>
 75         <identity value="v2" />
 76         <map value="N/A" />
 77       </mapping>
 78       <mapping>
 79         <identity value="rim" />
 80         <map value="N/A (MIF-level)" />
 81       </mapping>
 82     </element>
 83     <element id="Extension.id">
 84       <path value="Extension.id" />
 85       <representation value="xmlAttr" />
 86       <short value="Unique id for inter-element referencing" />
 87       <definition value="Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces." />
 88       <min value="0" />
 89       <max value="1" />
 90       <base>
 91         <path value="Element.id" />
 92         <min value="0" />
 93         <max value="1" />
 94       </base>
 95       <type>
 96         <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type">
 97           <valueUrl value="string" />
 98         </extension>
 99         <code value="http://hl7.org/fhirpath/System.String" />
100       </type>
101       <isModifier value="false" />
102       <isSummary value="false" />
103       <mapping>
104         <identity value="rim" />
105         <map value="n/a" />
106       </mapping>
107     </element>
108     <element id="Extension.extension">
109       <path value="Extension.extension" />
110       <slicing>
111         <discriminator>
112           <type value="value" />
113           <path value="url" />
114         </discriminator>
115         <description value="Extensions are always sliced by (at least) url" />
116         <rules value="open" />
117       </slicing>
118       <short value="Extension" />
119       <definition value="An Extension" />
120       <min value="0" />
121       <max value="0" />
122       <base>
123         <path value="Element.extension" />
124         <min value="0" />
125         <max value="*" />
126       </base>
127       <type>
128         <code value="Extension" />
129       </type>
130       <constraint>
131         <key value="ele-1" />
132         <severity value="error" />
133         <human value="All FHIR elements must have a @value or children" />
134         <expression value="hasValue() or (children().count() > id.count())" />
135         <xpath value="@value|f:*|h:div" />
136         <source value="http://hl7.org/fhir/StructureDefinition/Element" />
137       </constraint>
138       <constraint>
139         <key value="ext-1" />
140         <severity value="error" />
141         <human value="Must have either extensions or value[x], not both" />
142         <expression value="extension.exists() != value.exists()" />
143         <xpath value="exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])" />
144         <source value="http://hl7.org/fhir/StructureDefinition/Extension" />
145       </constraint>
146       <isModifier value="false" />
147       <isSummary value="false" />
148     </element>
149     <element id="Extension.url">
150       <path value="Extension.url" />
151       <representation value="xmlAttr" />
152       <short value="identifies the meaning of the extension" />
153       <definition value="Source of the definition for the extension code - a logical name or a URL." />
154       <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." />
155       <min value="1" />
156       <max value="1" />
157       <base>
158         <path value="Extension.url" />
159         <min value="1" />
160         <max value="1" />
161       </base>
162       <type>
163         <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type">
164           <valueUrl value="uri" />
165         </extension>
166         <code value="http://hl7.org/fhirpath/System.String" />
167       </type>
168       <fixedUri value="http://hl7.org/fhir/StructureDefinition/maxValue" />
169       <isModifier value="false" />
170       <isSummary value="false" />
171       <mapping>
172         <identity value="rim" />
173         <map value="N/A" />
174       </mapping>
175     </element>
176     <element id="Extension.value[x]">
177       <path value="Extension.value[x]" />
178       <short value="Value of extension" />
179       <definition value="Value of extension - must be one of a constrained set of the data types (see [Extensibility](http://hl7.org/fhir/extensibility.html) for a list)." />
180       <min value="1" />
181       <max value="1" />
182       <base>
183         <path value="Extension.value[x]" />
184         <min value="0" />
185         <max value="1" />
186       </base>
187       <type>
188         <code value="date" />
189       </type>
190       <type>
191         <code value="dateTime" />
192       </type>
193       <type>
194         <code value="time" />
195       </type>
196       <type>
197         <code value="instant" />
198       </type>
199       <type>
200         <code value="decimal" />
201       </type>
202       <type>
203         <code value="integer" />
204       </type>
205       <constraint>
206         <key value="ele-1" />
207         <severity value="error" />
208         <human value="All FHIR elements must have a @value or children" />
209         <expression value="hasValue() or (children().count() > id.count())" />
210         <xpath value="@value|f:*|h:div" />
211         <source value="http://hl7.org/fhir/StructureDefinition/Element" />
212       </constraint>
213       <isModifier value="false" />
214       <isSummary value="false" />
215       <mapping>
216         <identity value="rim" />
217         <map value="N/A" />
218       </mapping>
219     </element>
220   </snapshot>
221   <differential>
222     <element id="Extension">
223       <path value="Extension" />
224       <short value="Must be <= this value" />
225       <definition value="The inclusive upper bound on the range of allowed values for the data element." />
226       <comment value="Data type specified must be the same as the data type for the data element." />
227       <min value="0" />
228       <max value="1" />
229       <mapping>
230         <identity value="v2" />
231         <map value="N/A" />
232       </mapping>
233       <mapping>
234         <identity value="rim" />
235         <map value="N/A (MIF-level)" />
236       </mapping>
237     </element>
238     <element id="Extension.extension">
239       <path value="Extension.extension" />
240       <max value="0" />
241     </element>
242     <element id="Extension.url">
243       <path value="Extension.url" />
244       <fixedUri value="http://hl7.org/fhir/StructureDefinition/maxValue" />
245     </element>
246     <element id="Extension.value[x]">
247       <path value="Extension.value[x]" />
248       <min value="1" />
249       <type>
250         <code value="date" />
251       </type>
252       <type>
253         <code value="dateTime" />
254       </type>
255       <type>
256         <code value="time" />
257       </type>
258       <type>
259         <code value="instant" />
260       </type>
261       <type>
262         <code value="decimal" />
263       </type>
264       <type>
265         <code value="integer" />
266       </type>
267     </element>
268   </differential>
269 </StructureDefinition>