regex.xml 1 <?xml version="1.0" encoding="utf-8"?> 2 <StructureDefinition xmlns="http://hl7.org/fhir"> 3 <id value="regex" /> 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/regex" /> 11 <version value="4.0.1" /> 12 <name value="regex" /> 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="A regular expression that defines the syntax for the data element to be considered valid." /> 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 <context> 41 <type value="element" /> 42 <expression value="ElementDefinition" /> 43 </context> 44 <type value="Extension" /> 45 <baseDefinition value="http://hl7.org/fhir/StructureDefinition/Extension" /> 46 <derivation value="constraint" /> 47 <snapshot> 48 <element id="Extension"> 49 <path value="Extension" /> 50 <short value="Regular expression pattern" /> 51 <definition value="A regular expression that defines the syntax for the data element to be considered valid." /> 52 <min value="0" /> 53 <max value="1" /> 54 <base> 55 <path value="Extension" /> 56 <min value="0" /> 57 <max value="*" /> 58 </base> 59 <condition value="ele-1" /> 60 <constraint> 61 <key value="ele-1" /> 62 <severity value="error" /> 63 <human value="All FHIR elements must have a @value or children" /> 64 <expression value="hasValue() or (children().count() > id.count())" /> 65 <xpath value="@value|f:*|h:div" /> 66 <source value="http://hl7.org/fhir/StructureDefinition/Element" /> 67 </constraint> 68 <constraint> 69 <key value="ext-1" /> 70 <severity value="error" /> 71 <human value="Must have either extensions or value[x], not both" /> 72 <expression value="extension.exists() != value.exists()" /> 73 <xpath value="exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])" /> 74 <source value="http://hl7.org/fhir/StructureDefinition/Extension" /> 75 </constraint> 76 <isModifier value="false" /> 77 <mapping> 78 <identity value="v2" /> 79 <map value="N/A" /> 80 </mapping> 81 <mapping> 82 <identity value="rim" /> 83 <map value="N/A (MIF-level)" /> 84 </mapping> 85 </element> 86 <element id="Extension.id"> 87 <path value="Extension.id" /> 88 <representation value="xmlAttr" /> 89 <short value="Unique id for inter-element referencing" /> 90 <definition value="Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces." /> 91 <min value="0" /> 92 <max value="1" /> 93 <base> 94 <path value="Element.id" /> 95 <min value="0" /> 96 <max value="1" /> 97 </base> 98 <type> 99 <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type"> 100 <valueUrl value="string" /> 101 </extension> 102 <code value="http://hl7.org/fhirpath/System.String" /> 103 </type> 104 <isModifier value="false" /> 105 <isSummary value="false" /> 106 <mapping> 107 <identity value="rim" /> 108 <map value="n/a" /> 109 </mapping> 110 </element> 111 <element id="Extension.extension"> 112 <path value="Extension.extension" /> 113 <slicing> 114 <discriminator> 115 <type value="value" /> 116 <path value="url" /> 117 </discriminator> 118 <description value="Extensions are always sliced by (at least) url" /> 119 <rules value="open" /> 120 </slicing> 121 <short value="Extension" /> 122 <definition value="An Extension" /> 123 <min value="0" /> 124 <max value="0" /> 125 <base> 126 <path value="Element.extension" /> 127 <min value="0" /> 128 <max value="*" /> 129 </base> 130 <type> 131 <code value="Extension" /> 132 </type> 133 <constraint> 134 <key value="ele-1" /> 135 <severity value="error" /> 136 <human value="All FHIR elements must have a @value or children" /> 137 <expression value="hasValue() or (children().count() > id.count())" /> 138 <xpath value="@value|f:*|h:div" /> 139 <source value="http://hl7.org/fhir/StructureDefinition/Element" /> 140 </constraint> 141 <constraint> 142 <key value="ext-1" /> 143 <severity value="error" /> 144 <human value="Must have either extensions or value[x], not both" /> 145 <expression value="extension.exists() != value.exists()" /> 146 <xpath value="exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])" /> 147 <source value="http://hl7.org/fhir/StructureDefinition/Extension" /> 148 </constraint> 149 <isModifier value="false" /> 150 <isSummary value="false" /> 151 </element> 152 <element id="Extension.url"> 153 <path value="Extension.url" /> 154 <representation value="xmlAttr" /> 155 <short value="identifies the meaning of the extension" /> 156 <definition value="Source of the definition for the extension code - a logical name or a URL." /> 157 <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." /> 158 <min value="1" /> 159 <max value="1" /> 160 <base> 161 <path value="Extension.url" /> 162 <min value="1" /> 163 <max value="1" /> 164 </base> 165 <type> 166 <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type"> 167 <valueUrl value="uri" /> 168 </extension> 169 <code value="http://hl7.org/fhirpath/System.String" /> 170 </type> 171 <fixedUri value="http://hl7.org/fhir/StructureDefinition/regex" /> 172 <isModifier value="false" /> 173 <isSummary value="false" /> 174 <mapping> 175 <identity value="rim" /> 176 <map value="N/A" /> 177 </mapping> 178 </element> 179 <element id="Extension.value[x]"> 180 <path value="Extension.value[x]" /> 181 <short value="Value of extension" /> 182 <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)." /> 183 <min value="1" /> 184 <max value="1" /> 185 <base> 186 <path value="Extension.value[x]" /> 187 <min value="0" /> 188 <max value="1" /> 189 </base> 190 <type> 191 <code value="string" /> 192 </type> 193 <constraint> 194 <key value="ele-1" /> 195 <severity value="error" /> 196 <human value="All FHIR elements must have a @value or children" /> 197 <expression value="hasValue() or (children().count() > id.count())" /> 198 <xpath value="@value|f:*|h:div" /> 199 <source value="http://hl7.org/fhir/StructureDefinition/Element" /> 200 </constraint> 201 <isModifier value="false" /> 202 <isSummary value="false" /> 203 <mapping> 204 <identity value="rim" /> 205 <map value="N/A" /> 206 </mapping> 207 </element> 208 </snapshot> 209 <differential> 210 <element id="Extension"> 211 <path value="Extension" /> 212 <short value="Regular expression pattern" /> 213 <definition value="A regular expression that defines the syntax for the data element to be considered valid." /> 214 <min value="0" /> 215 <max value="1" /> 216 <mapping> 217 <identity value="v2" /> 218 <map value="N/A" /> 219 </mapping> 220 <mapping> 221 <identity value="rim" /> 222 <map value="N/A (MIF-level)" /> 223 </mapping> 224 </element> 225 <element id="Extension.extension"> 226 <path value="Extension.extension" /> 227 <max value="0" /> 228 </element> 229 <element id="Extension.url"> 230 <path value="Extension.url" /> 231 <fixedUri value="http://hl7.org/fhir/StructureDefinition/regex" /> 232 </element> 233 <element id="Extension.value[x]"> 234 <path value="Extension.value[x]" /> 235 <min value="1" /> 236 <type> 237 <code value="string" /> 238 </type> 239 </element> 240 </differential> 241 </StructureDefinition>