001package org.hl7.fhir.r5.model; 002 003/*- 004 * #%L 005 * org.hl7.fhir.r5 006 * %% 007 * Copyright (C) 2014 - 2019 Health Level 7 008 * %% 009 * Licensed under the Apache License, Version 2.0 (the "License"); 010 * you may not use this file except in compliance with the License. 011 * You may obtain a copy of the License at 012 * 013 * http://www.apache.org/licenses/LICENSE-2.0 014 * 015 * Unless required by applicable law or agreed to in writing, software 016 * distributed under the License is distributed on an "AS IS" BASIS, 017 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 018 * See the License for the specific language governing permissions and 019 * limitations under the License. 020 * #L% 021 */ 022 023/* 024 Copyright (c) 2011+, HL7, Inc. 025 All rights reserved. 026 027 Redistribution and use in source and binary forms, with or without modification, 028 are permitted provided that the following conditions are met: 029 030 * Redistributions of source code must retain the above copyright notice, this 031 list of conditions and the following disclaimer. 032 * Redistributions in binary form must reproduce the above copyright notice, 033 this list of conditions and the following disclaimer in the documentation 034 and/or other materials provided with the distribution. 035 * Neither the name of HL7 nor the names of its contributors may be used to 036 endorse or promote products derived from this software without specific 037 prior written permission. 038 039 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 040 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 041 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 042 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 043 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 044 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 045 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 046 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 047 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 048 POSSIBILITY OF SUCH DAMAGE. 049 050*/ 051 052// Generated on Thu, Dec 13, 2018 14:07+1100 for FHIR v4.0.0 053import java.util.ArrayList; 054import java.util.Date; 055import java.util.List; 056import org.hl7.fhir.exceptions.FHIRException; 057import org.hl7.fhir.instance.model.api.ICompositeType; 058 059import org.hl7.fhir.instance.model.api.IBaseDatatypeElement; 060import org.hl7.fhir.utilities.Utilities; 061import org.hl7.fhir.r5.model.Enumerations.*; 062import ca.uhn.fhir.model.api.annotation.ResourceDef; 063import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 064import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 065import ca.uhn.fhir.model.api.annotation.Child; 066import ca.uhn.fhir.model.api.annotation.ChildOrder; 067import ca.uhn.fhir.model.api.annotation.Description; 068import ca.uhn.fhir.model.api.annotation.Block; 069/** 070 * The CodeSystem resource is used to declare the existence of and describe a code system or code system supplement and its key properties, and optionally define a part or all of its content. 071 */ 072@ResourceDef(name="CodeSystem", profile="http://hl7.org/fhir/StructureDefinition/CodeSystem") 073@ChildOrder(names={"url", "identifier", "version", "name", "title", "status", "experimental", "date", "publisher", "contact", "description", "useContext", "jurisdiction", "purpose", "copyright", "caseSensitive", "valueSet", "hierarchyMeaning", "compositional", "versionNeeded", "content", "supplements", "count", "filter", "property", "concept"}) 074public class CodeSystem extends MetadataResource { 075 076 public enum CodeSystemHierarchyMeaning { 077 /** 078 * No particular relationship between the concepts can be assumed, except what can be determined by inspection of the definitions of the elements (possible reasons to use this: importing from a source where this is not defined, or where various parts of the hierarchy have different meanings). 079 */ 080 GROUPEDBY, 081 /** 082 * A hierarchy where the child concepts have an IS-A relationship with the parents - that is, all the properties of the parent are also true for its child concepts. Not that is-a is a property of the concepts, so additional subsumption relationships may be defined using properties or the [subsumes](extension-codesystem-subsumes.html) extension. 083 */ 084 ISA, 085 /** 086 * Child elements list the individual parts of a composite whole (e.g. body site). 087 */ 088 PARTOF, 089 /** 090 * Child concepts in the hierarchy may have only one parent, and there is a presumption that the code system is a "closed world" meaning all things must be in the hierarchy. This results in concepts such as "not otherwise classified.". 091 */ 092 CLASSIFIEDWITH, 093 /** 094 * added to help the parsers with the generic types 095 */ 096 NULL; 097 public static CodeSystemHierarchyMeaning fromCode(String codeString) throws FHIRException { 098 if (codeString == null || "".equals(codeString)) 099 return null; 100 if ("grouped-by".equals(codeString)) 101 return GROUPEDBY; 102 if ("is-a".equals(codeString)) 103 return ISA; 104 if ("part-of".equals(codeString)) 105 return PARTOF; 106 if ("classified-with".equals(codeString)) 107 return CLASSIFIEDWITH; 108 if (Configuration.isAcceptInvalidEnums()) 109 return null; 110 else 111 throw new FHIRException("Unknown CodeSystemHierarchyMeaning code '"+codeString+"'"); 112 } 113 public String toCode() { 114 switch (this) { 115 case GROUPEDBY: return "grouped-by"; 116 case ISA: return "is-a"; 117 case PARTOF: return "part-of"; 118 case CLASSIFIEDWITH: return "classified-with"; 119 default: return "?"; 120 } 121 } 122 public String getSystem() { 123 switch (this) { 124 case GROUPEDBY: return "http://hl7.org/fhir/codesystem-hierarchy-meaning"; 125 case ISA: return "http://hl7.org/fhir/codesystem-hierarchy-meaning"; 126 case PARTOF: return "http://hl7.org/fhir/codesystem-hierarchy-meaning"; 127 case CLASSIFIEDWITH: return "http://hl7.org/fhir/codesystem-hierarchy-meaning"; 128 default: return "?"; 129 } 130 } 131 public String getDefinition() { 132 switch (this) { 133 case GROUPEDBY: return "No particular relationship between the concepts can be assumed, except what can be determined by inspection of the definitions of the elements (possible reasons to use this: importing from a source where this is not defined, or where various parts of the hierarchy have different meanings)."; 134 case ISA: return "A hierarchy where the child concepts have an IS-A relationship with the parents - that is, all the properties of the parent are also true for its child concepts. Not that is-a is a property of the concepts, so additional subsumption relationships may be defined using properties or the [subsumes](extension-codesystem-subsumes.html) extension."; 135 case PARTOF: return "Child elements list the individual parts of a composite whole (e.g. body site)."; 136 case CLASSIFIEDWITH: return "Child concepts in the hierarchy may have only one parent, and there is a presumption that the code system is a \"closed world\" meaning all things must be in the hierarchy. This results in concepts such as \"not otherwise classified.\"."; 137 default: return "?"; 138 } 139 } 140 public String getDisplay() { 141 switch (this) { 142 case GROUPEDBY: return "Grouped By"; 143 case ISA: return "Is-A"; 144 case PARTOF: return "Part Of"; 145 case CLASSIFIEDWITH: return "Classified With"; 146 default: return "?"; 147 } 148 } 149 } 150 151 public static class CodeSystemHierarchyMeaningEnumFactory implements EnumFactory<CodeSystemHierarchyMeaning> { 152 public CodeSystemHierarchyMeaning fromCode(String codeString) throws IllegalArgumentException { 153 if (codeString == null || "".equals(codeString)) 154 if (codeString == null || "".equals(codeString)) 155 return null; 156 if ("grouped-by".equals(codeString)) 157 return CodeSystemHierarchyMeaning.GROUPEDBY; 158 if ("is-a".equals(codeString)) 159 return CodeSystemHierarchyMeaning.ISA; 160 if ("part-of".equals(codeString)) 161 return CodeSystemHierarchyMeaning.PARTOF; 162 if ("classified-with".equals(codeString)) 163 return CodeSystemHierarchyMeaning.CLASSIFIEDWITH; 164 throw new IllegalArgumentException("Unknown CodeSystemHierarchyMeaning code '"+codeString+"'"); 165 } 166 public Enumeration<CodeSystemHierarchyMeaning> fromType(Base code) throws FHIRException { 167 if (code == null) 168 return null; 169 if (code.isEmpty()) 170 return new Enumeration<CodeSystemHierarchyMeaning>(this); 171 String codeString = ((PrimitiveType) code).asStringValue(); 172 if (codeString == null || "".equals(codeString)) 173 return null; 174 if ("grouped-by".equals(codeString)) 175 return new Enumeration<CodeSystemHierarchyMeaning>(this, CodeSystemHierarchyMeaning.GROUPEDBY); 176 if ("is-a".equals(codeString)) 177 return new Enumeration<CodeSystemHierarchyMeaning>(this, CodeSystemHierarchyMeaning.ISA); 178 if ("part-of".equals(codeString)) 179 return new Enumeration<CodeSystemHierarchyMeaning>(this, CodeSystemHierarchyMeaning.PARTOF); 180 if ("classified-with".equals(codeString)) 181 return new Enumeration<CodeSystemHierarchyMeaning>(this, CodeSystemHierarchyMeaning.CLASSIFIEDWITH); 182 throw new FHIRException("Unknown CodeSystemHierarchyMeaning code '"+codeString+"'"); 183 } 184 public String toCode(CodeSystemHierarchyMeaning code) { 185 if (code == CodeSystemHierarchyMeaning.GROUPEDBY) 186 return "grouped-by"; 187 if (code == CodeSystemHierarchyMeaning.ISA) 188 return "is-a"; 189 if (code == CodeSystemHierarchyMeaning.PARTOF) 190 return "part-of"; 191 if (code == CodeSystemHierarchyMeaning.CLASSIFIEDWITH) 192 return "classified-with"; 193 return "?"; 194 } 195 public String toSystem(CodeSystemHierarchyMeaning code) { 196 return code.getSystem(); 197 } 198 } 199 200 public enum CodeSystemContentMode { 201 /** 202 * None of the concepts defined by the code system are included in the code system resource. 203 */ 204 NOTPRESENT, 205 /** 206 * A few representative concepts are included in the code system resource. There is no useful intent in the subset choice and there's no process to make it workable: it's not intended to be workable. 207 */ 208 EXAMPLE, 209 /** 210 * A subset of the code system concepts are included in the code system resource. This is a curated subset released for a specific purpose under the governance of the code system steward, and that the intent, bounds and consequences of the fragmentation are clearly defined in the fragment or the code system documentation. Fragments are also known as partitions. 211 */ 212 FRAGMENT, 213 /** 214 * All the concepts defined by the code system are included in the code system resource. 215 */ 216 COMPLETE, 217 /** 218 * The resource doesn't define any new concepts; it just provides additional designations and properties to another code system. 219 */ 220 SUPPLEMENT, 221 /** 222 * added to help the parsers with the generic types 223 */ 224 NULL; 225 public static CodeSystemContentMode fromCode(String codeString) throws FHIRException { 226 if (codeString == null || "".equals(codeString)) 227 return null; 228 if ("not-present".equals(codeString)) 229 return NOTPRESENT; 230 if ("example".equals(codeString)) 231 return EXAMPLE; 232 if ("fragment".equals(codeString)) 233 return FRAGMENT; 234 if ("complete".equals(codeString)) 235 return COMPLETE; 236 if ("supplement".equals(codeString)) 237 return SUPPLEMENT; 238 if (Configuration.isAcceptInvalidEnums()) 239 return null; 240 else 241 throw new FHIRException("Unknown CodeSystemContentMode code '"+codeString+"'"); 242 } 243 public String toCode() { 244 switch (this) { 245 case NOTPRESENT: return "not-present"; 246 case EXAMPLE: return "example"; 247 case FRAGMENT: return "fragment"; 248 case COMPLETE: return "complete"; 249 case SUPPLEMENT: return "supplement"; 250 default: return "?"; 251 } 252 } 253 public String getSystem() { 254 switch (this) { 255 case NOTPRESENT: return "http://hl7.org/fhir/codesystem-content-mode"; 256 case EXAMPLE: return "http://hl7.org/fhir/codesystem-content-mode"; 257 case FRAGMENT: return "http://hl7.org/fhir/codesystem-content-mode"; 258 case COMPLETE: return "http://hl7.org/fhir/codesystem-content-mode"; 259 case SUPPLEMENT: return "http://hl7.org/fhir/codesystem-content-mode"; 260 default: return "?"; 261 } 262 } 263 public String getDefinition() { 264 switch (this) { 265 case NOTPRESENT: return "None of the concepts defined by the code system are included in the code system resource."; 266 case EXAMPLE: return "A few representative concepts are included in the code system resource. There is no useful intent in the subset choice and there's no process to make it workable: it's not intended to be workable."; 267 case FRAGMENT: return "A subset of the code system concepts are included in the code system resource. This is a curated subset released for a specific purpose under the governance of the code system steward, and that the intent, bounds and consequences of the fragmentation are clearly defined in the fragment or the code system documentation. Fragments are also known as partitions."; 268 case COMPLETE: return "All the concepts defined by the code system are included in the code system resource."; 269 case SUPPLEMENT: return "The resource doesn't define any new concepts; it just provides additional designations and properties to another code system."; 270 default: return "?"; 271 } 272 } 273 public String getDisplay() { 274 switch (this) { 275 case NOTPRESENT: return "Not Present"; 276 case EXAMPLE: return "Example"; 277 case FRAGMENT: return "Fragment"; 278 case COMPLETE: return "Complete"; 279 case SUPPLEMENT: return "Supplement"; 280 default: return "?"; 281 } 282 } 283 } 284 285 public static class CodeSystemContentModeEnumFactory implements EnumFactory<CodeSystemContentMode> { 286 public CodeSystemContentMode fromCode(String codeString) throws IllegalArgumentException { 287 if (codeString == null || "".equals(codeString)) 288 if (codeString == null || "".equals(codeString)) 289 return null; 290 if ("not-present".equals(codeString)) 291 return CodeSystemContentMode.NOTPRESENT; 292 if ("example".equals(codeString)) 293 return CodeSystemContentMode.EXAMPLE; 294 if ("fragment".equals(codeString)) 295 return CodeSystemContentMode.FRAGMENT; 296 if ("complete".equals(codeString)) 297 return CodeSystemContentMode.COMPLETE; 298 if ("supplement".equals(codeString)) 299 return CodeSystemContentMode.SUPPLEMENT; 300 throw new IllegalArgumentException("Unknown CodeSystemContentMode code '"+codeString+"'"); 301 } 302 public Enumeration<CodeSystemContentMode> fromType(Base code) throws FHIRException { 303 if (code == null) 304 return null; 305 if (code.isEmpty()) 306 return new Enumeration<CodeSystemContentMode>(this); 307 String codeString = ((PrimitiveType) code).asStringValue(); 308 if (codeString == null || "".equals(codeString)) 309 return null; 310 if ("not-present".equals(codeString)) 311 return new Enumeration<CodeSystemContentMode>(this, CodeSystemContentMode.NOTPRESENT); 312 if ("example".equals(codeString)) 313 return new Enumeration<CodeSystemContentMode>(this, CodeSystemContentMode.EXAMPLE); 314 if ("fragment".equals(codeString)) 315 return new Enumeration<CodeSystemContentMode>(this, CodeSystemContentMode.FRAGMENT); 316 if ("complete".equals(codeString)) 317 return new Enumeration<CodeSystemContentMode>(this, CodeSystemContentMode.COMPLETE); 318 if ("supplement".equals(codeString)) 319 return new Enumeration<CodeSystemContentMode>(this, CodeSystemContentMode.SUPPLEMENT); 320 throw new FHIRException("Unknown CodeSystemContentMode code '"+codeString+"'"); 321 } 322 public String toCode(CodeSystemContentMode code) { 323 if (code == CodeSystemContentMode.NOTPRESENT) 324 return "not-present"; 325 if (code == CodeSystemContentMode.EXAMPLE) 326 return "example"; 327 if (code == CodeSystemContentMode.FRAGMENT) 328 return "fragment"; 329 if (code == CodeSystemContentMode.COMPLETE) 330 return "complete"; 331 if (code == CodeSystemContentMode.SUPPLEMENT) 332 return "supplement"; 333 return "?"; 334 } 335 public String toSystem(CodeSystemContentMode code) { 336 return code.getSystem(); 337 } 338 } 339 340 public enum FilterOperator { 341 /** 342 * The specified property of the code equals the provided value. 343 */ 344 EQUAL, 345 /** 346 * Includes all concept ids that have a transitive is-a relationship with the concept Id provided as the value, including the provided concept itself (include descendant codes and self). 347 */ 348 ISA, 349 /** 350 * Includes all concept ids that have a transitive is-a relationship with the concept Id provided as the value, excluding the provided concept itself i.e. include descendant codes only). 351 */ 352 DESCENDENTOF, 353 /** 354 * The specified property of the code does not have an is-a relationship with the provided value. 355 */ 356 ISNOTA, 357 /** 358 * The specified property of the code matches the regex specified in the provided value. 359 */ 360 REGEX, 361 /** 362 * The specified property of the code is in the set of codes or concepts specified in the provided value (comma separated list). 363 */ 364 IN, 365 /** 366 * The specified property of the code is not in the set of codes or concepts specified in the provided value (comma separated list). 367 */ 368 NOTIN, 369 /** 370 * Includes all concept ids that have a transitive is-a relationship from the concept Id provided as the value, including the provided concept itself (i.e. include ancestor codes and self). 371 */ 372 GENERALIZES, 373 /** 374 * The specified property of the code has at least one value (if the specified value is true; if the specified value is false, then matches when the specified property of the code has no values). 375 */ 376 EXISTS, 377 /** 378 * added to help the parsers with the generic types 379 */ 380 NULL; 381 public static FilterOperator fromCode(String codeString) throws FHIRException { 382 if (codeString == null || "".equals(codeString)) 383 return null; 384 if ("=".equals(codeString)) 385 return EQUAL; 386 if ("is-a".equals(codeString)) 387 return ISA; 388 if ("descendent-of".equals(codeString)) 389 return DESCENDENTOF; 390 if ("is-not-a".equals(codeString)) 391 return ISNOTA; 392 if ("regex".equals(codeString)) 393 return REGEX; 394 if ("in".equals(codeString)) 395 return IN; 396 if ("not-in".equals(codeString)) 397 return NOTIN; 398 if ("generalizes".equals(codeString)) 399 return GENERALIZES; 400 if ("exists".equals(codeString)) 401 return EXISTS; 402 if (Configuration.isAcceptInvalidEnums()) 403 return null; 404 else 405 throw new FHIRException("Unknown FilterOperator code '"+codeString+"'"); 406 } 407 public String toCode() { 408 switch (this) { 409 case EQUAL: return "="; 410 case ISA: return "is-a"; 411 case DESCENDENTOF: return "descendent-of"; 412 case ISNOTA: return "is-not-a"; 413 case REGEX: return "regex"; 414 case IN: return "in"; 415 case NOTIN: return "not-in"; 416 case GENERALIZES: return "generalizes"; 417 case EXISTS: return "exists"; 418 default: return "?"; 419 } 420 } 421 public String getSystem() { 422 switch (this) { 423 case EQUAL: return "http://hl7.org/fhir/filter-operator"; 424 case ISA: return "http://hl7.org/fhir/filter-operator"; 425 case DESCENDENTOF: return "http://hl7.org/fhir/filter-operator"; 426 case ISNOTA: return "http://hl7.org/fhir/filter-operator"; 427 case REGEX: return "http://hl7.org/fhir/filter-operator"; 428 case IN: return "http://hl7.org/fhir/filter-operator"; 429 case NOTIN: return "http://hl7.org/fhir/filter-operator"; 430 case GENERALIZES: return "http://hl7.org/fhir/filter-operator"; 431 case EXISTS: return "http://hl7.org/fhir/filter-operator"; 432 default: return "?"; 433 } 434 } 435 public String getDefinition() { 436 switch (this) { 437 case EQUAL: return "The specified property of the code equals the provided value."; 438 case ISA: return "Includes all concept ids that have a transitive is-a relationship with the concept Id provided as the value, including the provided concept itself (include descendant codes and self)."; 439 case DESCENDENTOF: return "Includes all concept ids that have a transitive is-a relationship with the concept Id provided as the value, excluding the provided concept itself i.e. include descendant codes only)."; 440 case ISNOTA: return "The specified property of the code does not have an is-a relationship with the provided value."; 441 case REGEX: return "The specified property of the code matches the regex specified in the provided value."; 442 case IN: return "The specified property of the code is in the set of codes or concepts specified in the provided value (comma separated list)."; 443 case NOTIN: return "The specified property of the code is not in the set of codes or concepts specified in the provided value (comma separated list)."; 444 case GENERALIZES: return "Includes all concept ids that have a transitive is-a relationship from the concept Id provided as the value, including the provided concept itself (i.e. include ancestor codes and self)."; 445 case EXISTS: return "The specified property of the code has at least one value (if the specified value is true; if the specified value is false, then matches when the specified property of the code has no values)."; 446 default: return "?"; 447 } 448 } 449 public String getDisplay() { 450 switch (this) { 451 case EQUAL: return "Equals"; 452 case ISA: return "Is A (by subsumption)"; 453 case DESCENDENTOF: return "Descendent Of (by subsumption)"; 454 case ISNOTA: return "Not (Is A) (by subsumption)"; 455 case REGEX: return "Regular Expression"; 456 case IN: return "In Set"; 457 case NOTIN: return "Not in Set"; 458 case GENERALIZES: return "Generalizes (by Subsumption)"; 459 case EXISTS: return "Exists"; 460 default: return "?"; 461 } 462 } 463 } 464 465 public static class FilterOperatorEnumFactory implements EnumFactory<FilterOperator> { 466 public FilterOperator fromCode(String codeString) throws IllegalArgumentException { 467 if (codeString == null || "".equals(codeString)) 468 if (codeString == null || "".equals(codeString)) 469 return null; 470 if ("=".equals(codeString)) 471 return FilterOperator.EQUAL; 472 if ("is-a".equals(codeString)) 473 return FilterOperator.ISA; 474 if ("descendent-of".equals(codeString)) 475 return FilterOperator.DESCENDENTOF; 476 if ("is-not-a".equals(codeString)) 477 return FilterOperator.ISNOTA; 478 if ("regex".equals(codeString)) 479 return FilterOperator.REGEX; 480 if ("in".equals(codeString)) 481 return FilterOperator.IN; 482 if ("not-in".equals(codeString)) 483 return FilterOperator.NOTIN; 484 if ("generalizes".equals(codeString)) 485 return FilterOperator.GENERALIZES; 486 if ("exists".equals(codeString)) 487 return FilterOperator.EXISTS; 488 throw new IllegalArgumentException("Unknown FilterOperator code '"+codeString+"'"); 489 } 490 public Enumeration<FilterOperator> fromType(Base code) throws FHIRException { 491 if (code == null) 492 return null; 493 if (code.isEmpty()) 494 return new Enumeration<FilterOperator>(this); 495 String codeString = ((PrimitiveType) code).asStringValue(); 496 if (codeString == null || "".equals(codeString)) 497 return null; 498 if ("=".equals(codeString)) 499 return new Enumeration<FilterOperator>(this, FilterOperator.EQUAL); 500 if ("is-a".equals(codeString)) 501 return new Enumeration<FilterOperator>(this, FilterOperator.ISA); 502 if ("descendent-of".equals(codeString)) 503 return new Enumeration<FilterOperator>(this, FilterOperator.DESCENDENTOF); 504 if ("is-not-a".equals(codeString)) 505 return new Enumeration<FilterOperator>(this, FilterOperator.ISNOTA); 506 if ("regex".equals(codeString)) 507 return new Enumeration<FilterOperator>(this, FilterOperator.REGEX); 508 if ("in".equals(codeString)) 509 return new Enumeration<FilterOperator>(this, FilterOperator.IN); 510 if ("not-in".equals(codeString)) 511 return new Enumeration<FilterOperator>(this, FilterOperator.NOTIN); 512 if ("generalizes".equals(codeString)) 513 return new Enumeration<FilterOperator>(this, FilterOperator.GENERALIZES); 514 if ("exists".equals(codeString)) 515 return new Enumeration<FilterOperator>(this, FilterOperator.EXISTS); 516 throw new FHIRException("Unknown FilterOperator code '"+codeString+"'"); 517 } 518 public String toCode(FilterOperator code) { 519 if (code == FilterOperator.EQUAL) 520 return "="; 521 if (code == FilterOperator.ISA) 522 return "is-a"; 523 if (code == FilterOperator.DESCENDENTOF) 524 return "descendent-of"; 525 if (code == FilterOperator.ISNOTA) 526 return "is-not-a"; 527 if (code == FilterOperator.REGEX) 528 return "regex"; 529 if (code == FilterOperator.IN) 530 return "in"; 531 if (code == FilterOperator.NOTIN) 532 return "not-in"; 533 if (code == FilterOperator.GENERALIZES) 534 return "generalizes"; 535 if (code == FilterOperator.EXISTS) 536 return "exists"; 537 return "?"; 538 } 539 public String toSystem(FilterOperator code) { 540 return code.getSystem(); 541 } 542 } 543 544 public enum PropertyType { 545 /** 546 * The property value is a code that identifies a concept defined in the code system. 547 */ 548 CODE, 549 /** 550 * The property value is a code defined in an external code system. This may be used for translations, but is not the intent. 551 */ 552 CODING, 553 /** 554 * The property value is a string. 555 */ 556 STRING, 557 /** 558 * The property value is a string (often used to assign ranking values to concepts for supporting score assessments). 559 */ 560 INTEGER, 561 /** 562 * The property value is a boolean true | false. 563 */ 564 BOOLEAN, 565 /** 566 * The property is a date or a date + time. 567 */ 568 DATETIME, 569 /** 570 * The property value is a decimal number. 571 */ 572 DECIMAL, 573 /** 574 * added to help the parsers with the generic types 575 */ 576 NULL; 577 public static PropertyType fromCode(String codeString) throws FHIRException { 578 if (codeString == null || "".equals(codeString)) 579 return null; 580 if ("code".equals(codeString)) 581 return CODE; 582 if ("Coding".equals(codeString)) 583 return CODING; 584 if ("string".equals(codeString)) 585 return STRING; 586 if ("integer".equals(codeString)) 587 return INTEGER; 588 if ("boolean".equals(codeString)) 589 return BOOLEAN; 590 if ("dateTime".equals(codeString)) 591 return DATETIME; 592 if ("decimal".equals(codeString)) 593 return DECIMAL; 594 if (Configuration.isAcceptInvalidEnums()) 595 return null; 596 else 597 throw new FHIRException("Unknown PropertyType code '"+codeString+"'"); 598 } 599 public String toCode() { 600 switch (this) { 601 case CODE: return "code"; 602 case CODING: return "Coding"; 603 case STRING: return "string"; 604 case INTEGER: return "integer"; 605 case BOOLEAN: return "boolean"; 606 case DATETIME: return "dateTime"; 607 case DECIMAL: return "decimal"; 608 default: return "?"; 609 } 610 } 611 public String getSystem() { 612 switch (this) { 613 case CODE: return "http://hl7.org/fhir/concept-property-type"; 614 case CODING: return "http://hl7.org/fhir/concept-property-type"; 615 case STRING: return "http://hl7.org/fhir/concept-property-type"; 616 case INTEGER: return "http://hl7.org/fhir/concept-property-type"; 617 case BOOLEAN: return "http://hl7.org/fhir/concept-property-type"; 618 case DATETIME: return "http://hl7.org/fhir/concept-property-type"; 619 case DECIMAL: return "http://hl7.org/fhir/concept-property-type"; 620 default: return "?"; 621 } 622 } 623 public String getDefinition() { 624 switch (this) { 625 case CODE: return "The property value is a code that identifies a concept defined in the code system."; 626 case CODING: return "The property value is a code defined in an external code system. This may be used for translations, but is not the intent."; 627 case STRING: return "The property value is a string."; 628 case INTEGER: return "The property value is a string (often used to assign ranking values to concepts for supporting score assessments)."; 629 case BOOLEAN: return "The property value is a boolean true | false."; 630 case DATETIME: return "The property is a date or a date + time."; 631 case DECIMAL: return "The property value is a decimal number."; 632 default: return "?"; 633 } 634 } 635 public String getDisplay() { 636 switch (this) { 637 case CODE: return "code (internal reference)"; 638 case CODING: return "Coding (external reference)"; 639 case STRING: return "string"; 640 case INTEGER: return "integer"; 641 case BOOLEAN: return "boolean"; 642 case DATETIME: return "dateTime"; 643 case DECIMAL: return "decimal"; 644 default: return "?"; 645 } 646 } 647 } 648 649 public static class PropertyTypeEnumFactory implements EnumFactory<PropertyType> { 650 public PropertyType fromCode(String codeString) throws IllegalArgumentException { 651 if (codeString == null || "".equals(codeString)) 652 if (codeString == null || "".equals(codeString)) 653 return null; 654 if ("code".equals(codeString)) 655 return PropertyType.CODE; 656 if ("Coding".equals(codeString)) 657 return PropertyType.CODING; 658 if ("string".equals(codeString)) 659 return PropertyType.STRING; 660 if ("integer".equals(codeString)) 661 return PropertyType.INTEGER; 662 if ("boolean".equals(codeString)) 663 return PropertyType.BOOLEAN; 664 if ("dateTime".equals(codeString)) 665 return PropertyType.DATETIME; 666 if ("decimal".equals(codeString)) 667 return PropertyType.DECIMAL; 668 throw new IllegalArgumentException("Unknown PropertyType code '"+codeString+"'"); 669 } 670 public Enumeration<PropertyType> fromType(Base code) throws FHIRException { 671 if (code == null) 672 return null; 673 if (code.isEmpty()) 674 return new Enumeration<PropertyType>(this); 675 String codeString = ((PrimitiveType) code).asStringValue(); 676 if (codeString == null || "".equals(codeString)) 677 return null; 678 if ("code".equals(codeString)) 679 return new Enumeration<PropertyType>(this, PropertyType.CODE); 680 if ("Coding".equals(codeString)) 681 return new Enumeration<PropertyType>(this, PropertyType.CODING); 682 if ("string".equals(codeString)) 683 return new Enumeration<PropertyType>(this, PropertyType.STRING); 684 if ("integer".equals(codeString)) 685 return new Enumeration<PropertyType>(this, PropertyType.INTEGER); 686 if ("boolean".equals(codeString)) 687 return new Enumeration<PropertyType>(this, PropertyType.BOOLEAN); 688 if ("dateTime".equals(codeString)) 689 return new Enumeration<PropertyType>(this, PropertyType.DATETIME); 690 if ("decimal".equals(codeString)) 691 return new Enumeration<PropertyType>(this, PropertyType.DECIMAL); 692 throw new FHIRException("Unknown PropertyType code '"+codeString+"'"); 693 } 694 public String toCode(PropertyType code) { 695 if (code == PropertyType.CODE) 696 return "code"; 697 if (code == PropertyType.CODING) 698 return "Coding"; 699 if (code == PropertyType.STRING) 700 return "string"; 701 if (code == PropertyType.INTEGER) 702 return "integer"; 703 if (code == PropertyType.BOOLEAN) 704 return "boolean"; 705 if (code == PropertyType.DATETIME) 706 return "dateTime"; 707 if (code == PropertyType.DECIMAL) 708 return "decimal"; 709 return "?"; 710 } 711 public String toSystem(PropertyType code) { 712 return code.getSystem(); 713 } 714 } 715 716 @Block() 717 public static class CodeSystemFilterComponent extends BackboneElement implements IBaseBackboneElement { 718 /** 719 * The code that identifies this filter when it is used as a filter in [[[ValueSet]]].compose.include.filter. 720 */ 721 @Child(name = "code", type = {CodeType.class}, order=1, min=1, max=1, modifier=false, summary=true) 722 @Description(shortDefinition="Code that identifies the filter", formalDefinition="The code that identifies this filter when it is used as a filter in [[[ValueSet]]].compose.include.filter." ) 723 protected CodeType code; 724 725 /** 726 * A description of how or why the filter is used. 727 */ 728 @Child(name = "description", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=true) 729 @Description(shortDefinition="How or why the filter is used", formalDefinition="A description of how or why the filter is used." ) 730 protected StringType description; 731 732 /** 733 * A list of operators that can be used with the filter. 734 */ 735 @Child(name = "operator", type = {CodeType.class}, order=3, min=1, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 736 @Description(shortDefinition="= | is-a | descendent-of | is-not-a | regex | in | not-in | generalizes | exists", formalDefinition="A list of operators that can be used with the filter." ) 737 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/filter-operator") 738 protected List<Enumeration<FilterOperator>> operator; 739 740 /** 741 * A description of what the value for the filter should be. 742 */ 743 @Child(name = "value", type = {StringType.class}, order=4, min=1, max=1, modifier=false, summary=true) 744 @Description(shortDefinition="What to use for the value", formalDefinition="A description of what the value for the filter should be." ) 745 protected StringType value; 746 747 private static final long serialVersionUID = -1087409836L; 748 749 /** 750 * Constructor 751 */ 752 public CodeSystemFilterComponent() { 753 super(); 754 } 755 756 /** 757 * Constructor 758 */ 759 public CodeSystemFilterComponent(CodeType code, StringType value) { 760 super(); 761 this.code = code; 762 this.value = value; 763 } 764 765 /** 766 * @return {@link #code} (The code that identifies this filter when it is used as a filter in [[[ValueSet]]].compose.include.filter.). This is the underlying object with id, value and extensions. The accessor "getCode" gives direct access to the value 767 */ 768 public CodeType getCodeElement() { 769 if (this.code == null) 770 if (Configuration.errorOnAutoCreate()) 771 throw new Error("Attempt to auto-create CodeSystemFilterComponent.code"); 772 else if (Configuration.doAutoCreate()) 773 this.code = new CodeType(); // bb 774 return this.code; 775 } 776 777 public boolean hasCodeElement() { 778 return this.code != null && !this.code.isEmpty(); 779 } 780 781 public boolean hasCode() { 782 return this.code != null && !this.code.isEmpty(); 783 } 784 785 /** 786 * @param value {@link #code} (The code that identifies this filter when it is used as a filter in [[[ValueSet]]].compose.include.filter.). This is the underlying object with id, value and extensions. The accessor "getCode" gives direct access to the value 787 */ 788 public CodeSystemFilterComponent setCodeElement(CodeType value) { 789 this.code = value; 790 return this; 791 } 792 793 /** 794 * @return The code that identifies this filter when it is used as a filter in [[[ValueSet]]].compose.include.filter. 795 */ 796 public String getCode() { 797 return this.code == null ? null : this.code.getValue(); 798 } 799 800 /** 801 * @param value The code that identifies this filter when it is used as a filter in [[[ValueSet]]].compose.include.filter. 802 */ 803 public CodeSystemFilterComponent setCode(String value) { 804 if (this.code == null) 805 this.code = new CodeType(); 806 this.code.setValue(value); 807 return this; 808 } 809 810 /** 811 * @return {@link #description} (A description of how or why the filter is used.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 812 */ 813 public StringType getDescriptionElement() { 814 if (this.description == null) 815 if (Configuration.errorOnAutoCreate()) 816 throw new Error("Attempt to auto-create CodeSystemFilterComponent.description"); 817 else if (Configuration.doAutoCreate()) 818 this.description = new StringType(); // bb 819 return this.description; 820 } 821 822 public boolean hasDescriptionElement() { 823 return this.description != null && !this.description.isEmpty(); 824 } 825 826 public boolean hasDescription() { 827 return this.description != null && !this.description.isEmpty(); 828 } 829 830 /** 831 * @param value {@link #description} (A description of how or why the filter is used.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 832 */ 833 public CodeSystemFilterComponent setDescriptionElement(StringType value) { 834 this.description = value; 835 return this; 836 } 837 838 /** 839 * @return A description of how or why the filter is used. 840 */ 841 public String getDescription() { 842 return this.description == null ? null : this.description.getValue(); 843 } 844 845 /** 846 * @param value A description of how or why the filter is used. 847 */ 848 public CodeSystemFilterComponent setDescription(String value) { 849 if (Utilities.noString(value)) 850 this.description = null; 851 else { 852 if (this.description == null) 853 this.description = new StringType(); 854 this.description.setValue(value); 855 } 856 return this; 857 } 858 859 /** 860 * @return {@link #operator} (A list of operators that can be used with the filter.) 861 */ 862 public List<Enumeration<FilterOperator>> getOperator() { 863 if (this.operator == null) 864 this.operator = new ArrayList<Enumeration<FilterOperator>>(); 865 return this.operator; 866 } 867 868 /** 869 * @return Returns a reference to <code>this</code> for easy method chaining 870 */ 871 public CodeSystemFilterComponent setOperator(List<Enumeration<FilterOperator>> theOperator) { 872 this.operator = theOperator; 873 return this; 874 } 875 876 public boolean hasOperator() { 877 if (this.operator == null) 878 return false; 879 for (Enumeration<FilterOperator> item : this.operator) 880 if (!item.isEmpty()) 881 return true; 882 return false; 883 } 884 885 /** 886 * @return {@link #operator} (A list of operators that can be used with the filter.) 887 */ 888 public Enumeration<FilterOperator> addOperatorElement() {//2 889 Enumeration<FilterOperator> t = new Enumeration<FilterOperator>(new FilterOperatorEnumFactory()); 890 if (this.operator == null) 891 this.operator = new ArrayList<Enumeration<FilterOperator>>(); 892 this.operator.add(t); 893 return t; 894 } 895 896 /** 897 * @param value {@link #operator} (A list of operators that can be used with the filter.) 898 */ 899 public CodeSystemFilterComponent addOperator(FilterOperator value) { //1 900 Enumeration<FilterOperator> t = new Enumeration<FilterOperator>(new FilterOperatorEnumFactory()); 901 t.setValue(value); 902 if (this.operator == null) 903 this.operator = new ArrayList<Enumeration<FilterOperator>>(); 904 this.operator.add(t); 905 return this; 906 } 907 908 /** 909 * @param value {@link #operator} (A list of operators that can be used with the filter.) 910 */ 911 public boolean hasOperator(FilterOperator value) { 912 if (this.operator == null) 913 return false; 914 for (Enumeration<FilterOperator> v : this.operator) 915 if (v.getValue().equals(value)) // code 916 return true; 917 return false; 918 } 919 920 /** 921 * @return {@link #value} (A description of what the value for the filter should be.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 922 */ 923 public StringType getValueElement() { 924 if (this.value == null) 925 if (Configuration.errorOnAutoCreate()) 926 throw new Error("Attempt to auto-create CodeSystemFilterComponent.value"); 927 else if (Configuration.doAutoCreate()) 928 this.value = new StringType(); // bb 929 return this.value; 930 } 931 932 public boolean hasValueElement() { 933 return this.value != null && !this.value.isEmpty(); 934 } 935 936 public boolean hasValue() { 937 return this.value != null && !this.value.isEmpty(); 938 } 939 940 /** 941 * @param value {@link #value} (A description of what the value for the filter should be.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 942 */ 943 public CodeSystemFilterComponent setValueElement(StringType value) { 944 this.value = value; 945 return this; 946 } 947 948 /** 949 * @return A description of what the value for the filter should be. 950 */ 951 public String getValue() { 952 return this.value == null ? null : this.value.getValue(); 953 } 954 955 /** 956 * @param value A description of what the value for the filter should be. 957 */ 958 public CodeSystemFilterComponent setValue(String value) { 959 if (this.value == null) 960 this.value = new StringType(); 961 this.value.setValue(value); 962 return this; 963 } 964 965 protected void listChildren(List<Property> children) { 966 super.listChildren(children); 967 children.add(new Property("code", "code", "The code that identifies this filter when it is used as a filter in [[[ValueSet]]].compose.include.filter.", 0, 1, code)); 968 children.add(new Property("description", "string", "A description of how or why the filter is used.", 0, 1, description)); 969 children.add(new Property("operator", "code", "A list of operators that can be used with the filter.", 0, java.lang.Integer.MAX_VALUE, operator)); 970 children.add(new Property("value", "string", "A description of what the value for the filter should be.", 0, 1, value)); 971 } 972 973 @Override 974 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 975 switch (_hash) { 976 case 3059181: /*code*/ return new Property("code", "code", "The code that identifies this filter when it is used as a filter in [[[ValueSet]]].compose.include.filter.", 0, 1, code); 977 case -1724546052: /*description*/ return new Property("description", "string", "A description of how or why the filter is used.", 0, 1, description); 978 case -500553564: /*operator*/ return new Property("operator", "code", "A list of operators that can be used with the filter.", 0, java.lang.Integer.MAX_VALUE, operator); 979 case 111972721: /*value*/ return new Property("value", "string", "A description of what the value for the filter should be.", 0, 1, value); 980 default: return super.getNamedProperty(_hash, _name, _checkValid); 981 } 982 983 } 984 985 @Override 986 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 987 switch (hash) { 988 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeType 989 case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType 990 case -500553564: /*operator*/ return this.operator == null ? new Base[0] : this.operator.toArray(new Base[this.operator.size()]); // Enumeration<FilterOperator> 991 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // StringType 992 default: return super.getProperty(hash, name, checkValid); 993 } 994 995 } 996 997 @Override 998 public Base setProperty(int hash, String name, Base value) throws FHIRException { 999 switch (hash) { 1000 case 3059181: // code 1001 this.code = castToCode(value); // CodeType 1002 return value; 1003 case -1724546052: // description 1004 this.description = castToString(value); // StringType 1005 return value; 1006 case -500553564: // operator 1007 value = new FilterOperatorEnumFactory().fromType(castToCode(value)); 1008 this.getOperator().add((Enumeration) value); // Enumeration<FilterOperator> 1009 return value; 1010 case 111972721: // value 1011 this.value = castToString(value); // StringType 1012 return value; 1013 default: return super.setProperty(hash, name, value); 1014 } 1015 1016 } 1017 1018 @Override 1019 public Base setProperty(String name, Base value) throws FHIRException { 1020 if (name.equals("code")) { 1021 this.code = castToCode(value); // CodeType 1022 } else if (name.equals("description")) { 1023 this.description = castToString(value); // StringType 1024 } else if (name.equals("operator")) { 1025 value = new FilterOperatorEnumFactory().fromType(castToCode(value)); 1026 this.getOperator().add((Enumeration) value); 1027 } else if (name.equals("value")) { 1028 this.value = castToString(value); // StringType 1029 } else 1030 return super.setProperty(name, value); 1031 return value; 1032 } 1033 1034 @Override 1035 public Base makeProperty(int hash, String name) throws FHIRException { 1036 switch (hash) { 1037 case 3059181: return getCodeElement(); 1038 case -1724546052: return getDescriptionElement(); 1039 case -500553564: return addOperatorElement(); 1040 case 111972721: return getValueElement(); 1041 default: return super.makeProperty(hash, name); 1042 } 1043 1044 } 1045 1046 @Override 1047 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1048 switch (hash) { 1049 case 3059181: /*code*/ return new String[] {"code"}; 1050 case -1724546052: /*description*/ return new String[] {"string"}; 1051 case -500553564: /*operator*/ return new String[] {"code"}; 1052 case 111972721: /*value*/ return new String[] {"string"}; 1053 default: return super.getTypesForProperty(hash, name); 1054 } 1055 1056 } 1057 1058 @Override 1059 public Base addChild(String name) throws FHIRException { 1060 if (name.equals("code")) { 1061 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.code"); 1062 } 1063 else if (name.equals("description")) { 1064 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.description"); 1065 } 1066 else if (name.equals("operator")) { 1067 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.operator"); 1068 } 1069 else if (name.equals("value")) { 1070 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.value"); 1071 } 1072 else 1073 return super.addChild(name); 1074 } 1075 1076 public CodeSystemFilterComponent copy() { 1077 CodeSystemFilterComponent dst = new CodeSystemFilterComponent(); 1078 copyValues(dst); 1079 return dst; 1080 } 1081 1082 public void copyValues(CodeSystemFilterComponent dst) { 1083 super.copyValues(dst); 1084 dst.code = code == null ? null : code.copy(); 1085 dst.description = description == null ? null : description.copy(); 1086 if (operator != null) { 1087 dst.operator = new ArrayList<Enumeration<FilterOperator>>(); 1088 for (Enumeration<FilterOperator> i : operator) 1089 dst.operator.add(i.copy()); 1090 }; 1091 dst.value = value == null ? null : value.copy(); 1092 } 1093 1094 @Override 1095 public boolean equalsDeep(Base other_) { 1096 if (!super.equalsDeep(other_)) 1097 return false; 1098 if (!(other_ instanceof CodeSystemFilterComponent)) 1099 return false; 1100 CodeSystemFilterComponent o = (CodeSystemFilterComponent) other_; 1101 return compareDeep(code, o.code, true) && compareDeep(description, o.description, true) && compareDeep(operator, o.operator, true) 1102 && compareDeep(value, o.value, true); 1103 } 1104 1105 @Override 1106 public boolean equalsShallow(Base other_) { 1107 if (!super.equalsShallow(other_)) 1108 return false; 1109 if (!(other_ instanceof CodeSystemFilterComponent)) 1110 return false; 1111 CodeSystemFilterComponent o = (CodeSystemFilterComponent) other_; 1112 return compareValues(code, o.code, true) && compareValues(description, o.description, true) && compareValues(operator, o.operator, true) 1113 && compareValues(value, o.value, true); 1114 } 1115 1116 public boolean isEmpty() { 1117 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, description, operator 1118 , value); 1119 } 1120 1121 public String fhirType() { 1122 return "CodeSystem.filter"; 1123 1124 } 1125 1126 } 1127 1128 @Block() 1129 public static class PropertyComponent extends BackboneElement implements IBaseBackboneElement { 1130 /** 1131 * A code that is used to identify the property. The code is used internally (in CodeSystem.concept.property.code) and also externally, such as in property filters. 1132 */ 1133 @Child(name = "code", type = {CodeType.class}, order=1, min=1, max=1, modifier=false, summary=true) 1134 @Description(shortDefinition="Identifies the property on the concepts, and when referred to in operations", formalDefinition="A code that is used to identify the property. The code is used internally (in CodeSystem.concept.property.code) and also externally, such as in property filters." ) 1135 protected CodeType code; 1136 1137 /** 1138 * Reference to the formal meaning of the property. One possible source of meaning is the [Concept Properties](codesystem-concept-properties.html) code system. 1139 */ 1140 @Child(name = "uri", type = {UriType.class}, order=2, min=0, max=1, modifier=false, summary=true) 1141 @Description(shortDefinition="Formal identifier for the property", formalDefinition="Reference to the formal meaning of the property. One possible source of meaning is the [Concept Properties](codesystem-concept-properties.html) code system." ) 1142 protected UriType uri; 1143 1144 /** 1145 * A description of the property- why it is defined, and how its value might be used. 1146 */ 1147 @Child(name = "description", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=true) 1148 @Description(shortDefinition="Why the property is defined, and/or what it conveys", formalDefinition="A description of the property- why it is defined, and how its value might be used." ) 1149 protected StringType description; 1150 1151 /** 1152 * The type of the property value. Properties of type "code" contain a code defined by the code system (e.g. a reference to another defined concept). 1153 */ 1154 @Child(name = "type", type = {CodeType.class}, order=4, min=1, max=1, modifier=false, summary=true) 1155 @Description(shortDefinition="code | Coding | string | integer | boolean | dateTime | decimal", formalDefinition="The type of the property value. Properties of type \"code\" contain a code defined by the code system (e.g. a reference to another defined concept)." ) 1156 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/concept-property-type") 1157 protected Enumeration<PropertyType> type; 1158 1159 private static final long serialVersionUID = -1810713373L; 1160 1161 /** 1162 * Constructor 1163 */ 1164 public PropertyComponent() { 1165 super(); 1166 } 1167 1168 /** 1169 * Constructor 1170 */ 1171 public PropertyComponent(CodeType code, Enumeration<PropertyType> type) { 1172 super(); 1173 this.code = code; 1174 this.type = type; 1175 } 1176 1177 /** 1178 * @return {@link #code} (A code that is used to identify the property. The code is used internally (in CodeSystem.concept.property.code) and also externally, such as in property filters.). This is the underlying object with id, value and extensions. The accessor "getCode" gives direct access to the value 1179 */ 1180 public CodeType getCodeElement() { 1181 if (this.code == null) 1182 if (Configuration.errorOnAutoCreate()) 1183 throw new Error("Attempt to auto-create PropertyComponent.code"); 1184 else if (Configuration.doAutoCreate()) 1185 this.code = new CodeType(); // bb 1186 return this.code; 1187 } 1188 1189 public boolean hasCodeElement() { 1190 return this.code != null && !this.code.isEmpty(); 1191 } 1192 1193 public boolean hasCode() { 1194 return this.code != null && !this.code.isEmpty(); 1195 } 1196 1197 /** 1198 * @param value {@link #code} (A code that is used to identify the property. The code is used internally (in CodeSystem.concept.property.code) and also externally, such as in property filters.). This is the underlying object with id, value and extensions. The accessor "getCode" gives direct access to the value 1199 */ 1200 public PropertyComponent setCodeElement(CodeType value) { 1201 this.code = value; 1202 return this; 1203 } 1204 1205 /** 1206 * @return A code that is used to identify the property. The code is used internally (in CodeSystem.concept.property.code) and also externally, such as in property filters. 1207 */ 1208 public String getCode() { 1209 return this.code == null ? null : this.code.getValue(); 1210 } 1211 1212 /** 1213 * @param value A code that is used to identify the property. The code is used internally (in CodeSystem.concept.property.code) and also externally, such as in property filters. 1214 */ 1215 public PropertyComponent setCode(String value) { 1216 if (this.code == null) 1217 this.code = new CodeType(); 1218 this.code.setValue(value); 1219 return this; 1220 } 1221 1222 /** 1223 * @return {@link #uri} (Reference to the formal meaning of the property. One possible source of meaning is the [Concept Properties](codesystem-concept-properties.html) code system.). This is the underlying object with id, value and extensions. The accessor "getUri" gives direct access to the value 1224 */ 1225 public UriType getUriElement() { 1226 if (this.uri == null) 1227 if (Configuration.errorOnAutoCreate()) 1228 throw new Error("Attempt to auto-create PropertyComponent.uri"); 1229 else if (Configuration.doAutoCreate()) 1230 this.uri = new UriType(); // bb 1231 return this.uri; 1232 } 1233 1234 public boolean hasUriElement() { 1235 return this.uri != null && !this.uri.isEmpty(); 1236 } 1237 1238 public boolean hasUri() { 1239 return this.uri != null && !this.uri.isEmpty(); 1240 } 1241 1242 /** 1243 * @param value {@link #uri} (Reference to the formal meaning of the property. One possible source of meaning is the [Concept Properties](codesystem-concept-properties.html) code system.). This is the underlying object with id, value and extensions. The accessor "getUri" gives direct access to the value 1244 */ 1245 public PropertyComponent setUriElement(UriType value) { 1246 this.uri = value; 1247 return this; 1248 } 1249 1250 /** 1251 * @return Reference to the formal meaning of the property. One possible source of meaning is the [Concept Properties](codesystem-concept-properties.html) code system. 1252 */ 1253 public String getUri() { 1254 return this.uri == null ? null : this.uri.getValue(); 1255 } 1256 1257 /** 1258 * @param value Reference to the formal meaning of the property. One possible source of meaning is the [Concept Properties](codesystem-concept-properties.html) code system. 1259 */ 1260 public PropertyComponent setUri(String value) { 1261 if (Utilities.noString(value)) 1262 this.uri = null; 1263 else { 1264 if (this.uri == null) 1265 this.uri = new UriType(); 1266 this.uri.setValue(value); 1267 } 1268 return this; 1269 } 1270 1271 /** 1272 * @return {@link #description} (A description of the property- why it is defined, and how its value might be used.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 1273 */ 1274 public StringType getDescriptionElement() { 1275 if (this.description == null) 1276 if (Configuration.errorOnAutoCreate()) 1277 throw new Error("Attempt to auto-create PropertyComponent.description"); 1278 else if (Configuration.doAutoCreate()) 1279 this.description = new StringType(); // bb 1280 return this.description; 1281 } 1282 1283 public boolean hasDescriptionElement() { 1284 return this.description != null && !this.description.isEmpty(); 1285 } 1286 1287 public boolean hasDescription() { 1288 return this.description != null && !this.description.isEmpty(); 1289 } 1290 1291 /** 1292 * @param value {@link #description} (A description of the property- why it is defined, and how its value might be used.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 1293 */ 1294 public PropertyComponent setDescriptionElement(StringType value) { 1295 this.description = value; 1296 return this; 1297 } 1298 1299 /** 1300 * @return A description of the property- why it is defined, and how its value might be used. 1301 */ 1302 public String getDescription() { 1303 return this.description == null ? null : this.description.getValue(); 1304 } 1305 1306 /** 1307 * @param value A description of the property- why it is defined, and how its value might be used. 1308 */ 1309 public PropertyComponent setDescription(String value) { 1310 if (Utilities.noString(value)) 1311 this.description = null; 1312 else { 1313 if (this.description == null) 1314 this.description = new StringType(); 1315 this.description.setValue(value); 1316 } 1317 return this; 1318 } 1319 1320 /** 1321 * @return {@link #type} (The type of the property value. Properties of type "code" contain a code defined by the code system (e.g. a reference to another defined concept).). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value 1322 */ 1323 public Enumeration<PropertyType> getTypeElement() { 1324 if (this.type == null) 1325 if (Configuration.errorOnAutoCreate()) 1326 throw new Error("Attempt to auto-create PropertyComponent.type"); 1327 else if (Configuration.doAutoCreate()) 1328 this.type = new Enumeration<PropertyType>(new PropertyTypeEnumFactory()); // bb 1329 return this.type; 1330 } 1331 1332 public boolean hasTypeElement() { 1333 return this.type != null && !this.type.isEmpty(); 1334 } 1335 1336 public boolean hasType() { 1337 return this.type != null && !this.type.isEmpty(); 1338 } 1339 1340 /** 1341 * @param value {@link #type} (The type of the property value. Properties of type "code" contain a code defined by the code system (e.g. a reference to another defined concept).). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value 1342 */ 1343 public PropertyComponent setTypeElement(Enumeration<PropertyType> value) { 1344 this.type = value; 1345 return this; 1346 } 1347 1348 /** 1349 * @return The type of the property value. Properties of type "code" contain a code defined by the code system (e.g. a reference to another defined concept). 1350 */ 1351 public PropertyType getType() { 1352 return this.type == null ? null : this.type.getValue(); 1353 } 1354 1355 /** 1356 * @param value The type of the property value. Properties of type "code" contain a code defined by the code system (e.g. a reference to another defined concept). 1357 */ 1358 public PropertyComponent setType(PropertyType value) { 1359 if (this.type == null) 1360 this.type = new Enumeration<PropertyType>(new PropertyTypeEnumFactory()); 1361 this.type.setValue(value); 1362 return this; 1363 } 1364 1365 protected void listChildren(List<Property> children) { 1366 super.listChildren(children); 1367 children.add(new Property("code", "code", "A code that is used to identify the property. The code is used internally (in CodeSystem.concept.property.code) and also externally, such as in property filters.", 0, 1, code)); 1368 children.add(new Property("uri", "uri", "Reference to the formal meaning of the property. One possible source of meaning is the [Concept Properties](codesystem-concept-properties.html) code system.", 0, 1, uri)); 1369 children.add(new Property("description", "string", "A description of the property- why it is defined, and how its value might be used.", 0, 1, description)); 1370 children.add(new Property("type", "code", "The type of the property value. Properties of type \"code\" contain a code defined by the code system (e.g. a reference to another defined concept).", 0, 1, type)); 1371 } 1372 1373 @Override 1374 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1375 switch (_hash) { 1376 case 3059181: /*code*/ return new Property("code", "code", "A code that is used to identify the property. The code is used internally (in CodeSystem.concept.property.code) and also externally, such as in property filters.", 0, 1, code); 1377 case 116076: /*uri*/ return new Property("uri", "uri", "Reference to the formal meaning of the property. One possible source of meaning is the [Concept Properties](codesystem-concept-properties.html) code system.", 0, 1, uri); 1378 case -1724546052: /*description*/ return new Property("description", "string", "A description of the property- why it is defined, and how its value might be used.", 0, 1, description); 1379 case 3575610: /*type*/ return new Property("type", "code", "The type of the property value. Properties of type \"code\" contain a code defined by the code system (e.g. a reference to another defined concept).", 0, 1, type); 1380 default: return super.getNamedProperty(_hash, _name, _checkValid); 1381 } 1382 1383 } 1384 1385 @Override 1386 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1387 switch (hash) { 1388 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeType 1389 case 116076: /*uri*/ return this.uri == null ? new Base[0] : new Base[] {this.uri}; // UriType 1390 case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType 1391 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // Enumeration<PropertyType> 1392 default: return super.getProperty(hash, name, checkValid); 1393 } 1394 1395 } 1396 1397 @Override 1398 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1399 switch (hash) { 1400 case 3059181: // code 1401 this.code = castToCode(value); // CodeType 1402 return value; 1403 case 116076: // uri 1404 this.uri = castToUri(value); // UriType 1405 return value; 1406 case -1724546052: // description 1407 this.description = castToString(value); // StringType 1408 return value; 1409 case 3575610: // type 1410 value = new PropertyTypeEnumFactory().fromType(castToCode(value)); 1411 this.type = (Enumeration) value; // Enumeration<PropertyType> 1412 return value; 1413 default: return super.setProperty(hash, name, value); 1414 } 1415 1416 } 1417 1418 @Override 1419 public Base setProperty(String name, Base value) throws FHIRException { 1420 if (name.equals("code")) { 1421 this.code = castToCode(value); // CodeType 1422 } else if (name.equals("uri")) { 1423 this.uri = castToUri(value); // UriType 1424 } else if (name.equals("description")) { 1425 this.description = castToString(value); // StringType 1426 } else if (name.equals("type")) { 1427 value = new PropertyTypeEnumFactory().fromType(castToCode(value)); 1428 this.type = (Enumeration) value; // Enumeration<PropertyType> 1429 } else 1430 return super.setProperty(name, value); 1431 return value; 1432 } 1433 1434 @Override 1435 public Base makeProperty(int hash, String name) throws FHIRException { 1436 switch (hash) { 1437 case 3059181: return getCodeElement(); 1438 case 116076: return getUriElement(); 1439 case -1724546052: return getDescriptionElement(); 1440 case 3575610: return getTypeElement(); 1441 default: return super.makeProperty(hash, name); 1442 } 1443 1444 } 1445 1446 @Override 1447 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1448 switch (hash) { 1449 case 3059181: /*code*/ return new String[] {"code"}; 1450 case 116076: /*uri*/ return new String[] {"uri"}; 1451 case -1724546052: /*description*/ return new String[] {"string"}; 1452 case 3575610: /*type*/ return new String[] {"code"}; 1453 default: return super.getTypesForProperty(hash, name); 1454 } 1455 1456 } 1457 1458 @Override 1459 public Base addChild(String name) throws FHIRException { 1460 if (name.equals("code")) { 1461 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.code"); 1462 } 1463 else if (name.equals("uri")) { 1464 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.uri"); 1465 } 1466 else if (name.equals("description")) { 1467 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.description"); 1468 } 1469 else if (name.equals("type")) { 1470 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.type"); 1471 } 1472 else 1473 return super.addChild(name); 1474 } 1475 1476 public PropertyComponent copy() { 1477 PropertyComponent dst = new PropertyComponent(); 1478 copyValues(dst); 1479 return dst; 1480 } 1481 1482 public void copyValues(PropertyComponent dst) { 1483 super.copyValues(dst); 1484 dst.code = code == null ? null : code.copy(); 1485 dst.uri = uri == null ? null : uri.copy(); 1486 dst.description = description == null ? null : description.copy(); 1487 dst.type = type == null ? null : type.copy(); 1488 } 1489 1490 @Override 1491 public boolean equalsDeep(Base other_) { 1492 if (!super.equalsDeep(other_)) 1493 return false; 1494 if (!(other_ instanceof PropertyComponent)) 1495 return false; 1496 PropertyComponent o = (PropertyComponent) other_; 1497 return compareDeep(code, o.code, true) && compareDeep(uri, o.uri, true) && compareDeep(description, o.description, true) 1498 && compareDeep(type, o.type, true); 1499 } 1500 1501 @Override 1502 public boolean equalsShallow(Base other_) { 1503 if (!super.equalsShallow(other_)) 1504 return false; 1505 if (!(other_ instanceof PropertyComponent)) 1506 return false; 1507 PropertyComponent o = (PropertyComponent) other_; 1508 return compareValues(code, o.code, true) && compareValues(uri, o.uri, true) && compareValues(description, o.description, true) 1509 && compareValues(type, o.type, true); 1510 } 1511 1512 public boolean isEmpty() { 1513 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, uri, description, type 1514 ); 1515 } 1516 1517 public String fhirType() { 1518 return "CodeSystem.property"; 1519 1520 } 1521 1522 } 1523 1524 @Block() 1525 public static class ConceptDefinitionComponent extends BackboneElement implements IBaseBackboneElement { 1526 /** 1527 * A code - a text symbol - that uniquely identifies the concept within the code system. 1528 */ 1529 @Child(name = "code", type = {CodeType.class}, order=1, min=1, max=1, modifier=false, summary=false) 1530 @Description(shortDefinition="Code that identifies concept", formalDefinition="A code - a text symbol - that uniquely identifies the concept within the code system." ) 1531 protected CodeType code; 1532 1533 /** 1534 * A human readable string that is the recommended default way to present this concept to a user. 1535 */ 1536 @Child(name = "display", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false) 1537 @Description(shortDefinition="Text to display to the user", formalDefinition="A human readable string that is the recommended default way to present this concept to a user." ) 1538 protected StringType display; 1539 1540 /** 1541 * The formal definition of the concept. The code system resource does not make formal definitions required, because of the prevalence of legacy systems. However, they are highly recommended, as without them there is no formal meaning associated with the concept. 1542 */ 1543 @Child(name = "definition", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false) 1544 @Description(shortDefinition="Formal definition", formalDefinition="The formal definition of the concept. The code system resource does not make formal definitions required, because of the prevalence of legacy systems. However, they are highly recommended, as without them there is no formal meaning associated with the concept." ) 1545 protected StringType definition; 1546 1547 /** 1548 * Additional representations for the concept - other languages, aliases, specialized purposes, used for particular purposes, etc. 1549 */ 1550 @Child(name = "designation", type = {}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1551 @Description(shortDefinition="Additional representations for the concept", formalDefinition="Additional representations for the concept - other languages, aliases, specialized purposes, used for particular purposes, etc." ) 1552 protected List<ConceptDefinitionDesignationComponent> designation; 1553 1554 /** 1555 * A property value for this concept. 1556 */ 1557 @Child(name = "property", type = {}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1558 @Description(shortDefinition="Property value for the concept", formalDefinition="A property value for this concept." ) 1559 protected List<ConceptPropertyComponent> property; 1560 1561 /** 1562 * Defines children of a concept to produce a hierarchy of concepts. The nature of the relationships is variable (is-a/contains/categorizes) - see hierarchyMeaning. 1563 */ 1564 @Child(name = "concept", type = {ConceptDefinitionComponent.class}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1565 @Description(shortDefinition="Child Concepts (is-a/contains/categorizes)", formalDefinition="Defines children of a concept to produce a hierarchy of concepts. The nature of the relationships is variable (is-a/contains/categorizes) - see hierarchyMeaning." ) 1566 protected List<ConceptDefinitionComponent> concept; 1567 1568 private static final long serialVersionUID = 878320988L; 1569 1570 /** 1571 * Constructor 1572 */ 1573 public ConceptDefinitionComponent() { 1574 super(); 1575 } 1576 1577 /** 1578 * Constructor 1579 */ 1580 public ConceptDefinitionComponent(CodeType code) { 1581 super(); 1582 this.code = code; 1583 } 1584 1585 /** 1586 * @return {@link #code} (A code - a text symbol - that uniquely identifies the concept within the code system.). This is the underlying object with id, value and extensions. The accessor "getCode" gives direct access to the value 1587 */ 1588 public CodeType getCodeElement() { 1589 if (this.code == null) 1590 if (Configuration.errorOnAutoCreate()) 1591 throw new Error("Attempt to auto-create ConceptDefinitionComponent.code"); 1592 else if (Configuration.doAutoCreate()) 1593 this.code = new CodeType(); // bb 1594 return this.code; 1595 } 1596 1597 public boolean hasCodeElement() { 1598 return this.code != null && !this.code.isEmpty(); 1599 } 1600 1601 public boolean hasCode() { 1602 return this.code != null && !this.code.isEmpty(); 1603 } 1604 1605 /** 1606 * @param value {@link #code} (A code - a text symbol - that uniquely identifies the concept within the code system.). This is the underlying object with id, value and extensions. The accessor "getCode" gives direct access to the value 1607 */ 1608 public ConceptDefinitionComponent setCodeElement(CodeType value) { 1609 this.code = value; 1610 return this; 1611 } 1612 1613 /** 1614 * @return A code - a text symbol - that uniquely identifies the concept within the code system. 1615 */ 1616 public String getCode() { 1617 return this.code == null ? null : this.code.getValue(); 1618 } 1619 1620 /** 1621 * @param value A code - a text symbol - that uniquely identifies the concept within the code system. 1622 */ 1623 public ConceptDefinitionComponent setCode(String value) { 1624 if (this.code == null) 1625 this.code = new CodeType(); 1626 this.code.setValue(value); 1627 return this; 1628 } 1629 1630 /** 1631 * @return {@link #display} (A human readable string that is the recommended default way to present this concept to a user.). This is the underlying object with id, value and extensions. The accessor "getDisplay" gives direct access to the value 1632 */ 1633 public StringType getDisplayElement() { 1634 if (this.display == null) 1635 if (Configuration.errorOnAutoCreate()) 1636 throw new Error("Attempt to auto-create ConceptDefinitionComponent.display"); 1637 else if (Configuration.doAutoCreate()) 1638 this.display = new StringType(); // bb 1639 return this.display; 1640 } 1641 1642 public boolean hasDisplayElement() { 1643 return this.display != null && !this.display.isEmpty(); 1644 } 1645 1646 public boolean hasDisplay() { 1647 return this.display != null && !this.display.isEmpty(); 1648 } 1649 1650 /** 1651 * @param value {@link #display} (A human readable string that is the recommended default way to present this concept to a user.). This is the underlying object with id, value and extensions. The accessor "getDisplay" gives direct access to the value 1652 */ 1653 public ConceptDefinitionComponent setDisplayElement(StringType value) { 1654 this.display = value; 1655 return this; 1656 } 1657 1658 /** 1659 * @return A human readable string that is the recommended default way to present this concept to a user. 1660 */ 1661 public String getDisplay() { 1662 return this.display == null ? null : this.display.getValue(); 1663 } 1664 1665 /** 1666 * @param value A human readable string that is the recommended default way to present this concept to a user. 1667 */ 1668 public ConceptDefinitionComponent setDisplay(String value) { 1669 if (Utilities.noString(value)) 1670 this.display = null; 1671 else { 1672 if (this.display == null) 1673 this.display = new StringType(); 1674 this.display.setValue(value); 1675 } 1676 return this; 1677 } 1678 1679 /** 1680 * @return {@link #definition} (The formal definition of the concept. The code system resource does not make formal definitions required, because of the prevalence of legacy systems. However, they are highly recommended, as without them there is no formal meaning associated with the concept.). This is the underlying object with id, value and extensions. The accessor "getDefinition" gives direct access to the value 1681 */ 1682 public StringType getDefinitionElement() { 1683 if (this.definition == null) 1684 if (Configuration.errorOnAutoCreate()) 1685 throw new Error("Attempt to auto-create ConceptDefinitionComponent.definition"); 1686 else if (Configuration.doAutoCreate()) 1687 this.definition = new StringType(); // bb 1688 return this.definition; 1689 } 1690 1691 public boolean hasDefinitionElement() { 1692 return this.definition != null && !this.definition.isEmpty(); 1693 } 1694 1695 public boolean hasDefinition() { 1696 return this.definition != null && !this.definition.isEmpty(); 1697 } 1698 1699 /** 1700 * @param value {@link #definition} (The formal definition of the concept. The code system resource does not make formal definitions required, because of the prevalence of legacy systems. However, they are highly recommended, as without them there is no formal meaning associated with the concept.). This is the underlying object with id, value and extensions. The accessor "getDefinition" gives direct access to the value 1701 */ 1702 public ConceptDefinitionComponent setDefinitionElement(StringType value) { 1703 this.definition = value; 1704 return this; 1705 } 1706 1707 /** 1708 * @return The formal definition of the concept. The code system resource does not make formal definitions required, because of the prevalence of legacy systems. However, they are highly recommended, as without them there is no formal meaning associated with the concept. 1709 */ 1710 public String getDefinition() { 1711 return this.definition == null ? null : this.definition.getValue(); 1712 } 1713 1714 /** 1715 * @param value The formal definition of the concept. The code system resource does not make formal definitions required, because of the prevalence of legacy systems. However, they are highly recommended, as without them there is no formal meaning associated with the concept. 1716 */ 1717 public ConceptDefinitionComponent setDefinition(String value) { 1718 if (Utilities.noString(value)) 1719 this.definition = null; 1720 else { 1721 if (this.definition == null) 1722 this.definition = new StringType(); 1723 this.definition.setValue(value); 1724 } 1725 return this; 1726 } 1727 1728 /** 1729 * @return {@link #designation} (Additional representations for the concept - other languages, aliases, specialized purposes, used for particular purposes, etc.) 1730 */ 1731 public List<ConceptDefinitionDesignationComponent> getDesignation() { 1732 if (this.designation == null) 1733 this.designation = new ArrayList<ConceptDefinitionDesignationComponent>(); 1734 return this.designation; 1735 } 1736 1737 /** 1738 * @return Returns a reference to <code>this</code> for easy method chaining 1739 */ 1740 public ConceptDefinitionComponent setDesignation(List<ConceptDefinitionDesignationComponent> theDesignation) { 1741 this.designation = theDesignation; 1742 return this; 1743 } 1744 1745 public boolean hasDesignation() { 1746 if (this.designation == null) 1747 return false; 1748 for (ConceptDefinitionDesignationComponent item : this.designation) 1749 if (!item.isEmpty()) 1750 return true; 1751 return false; 1752 } 1753 1754 public ConceptDefinitionDesignationComponent addDesignation() { //3 1755 ConceptDefinitionDesignationComponent t = new ConceptDefinitionDesignationComponent(); 1756 if (this.designation == null) 1757 this.designation = new ArrayList<ConceptDefinitionDesignationComponent>(); 1758 this.designation.add(t); 1759 return t; 1760 } 1761 1762 public ConceptDefinitionComponent addDesignation(ConceptDefinitionDesignationComponent t) { //3 1763 if (t == null) 1764 return this; 1765 if (this.designation == null) 1766 this.designation = new ArrayList<ConceptDefinitionDesignationComponent>(); 1767 this.designation.add(t); 1768 return this; 1769 } 1770 1771 /** 1772 * @return The first repetition of repeating field {@link #designation}, creating it if it does not already exist 1773 */ 1774 public ConceptDefinitionDesignationComponent getDesignationFirstRep() { 1775 if (getDesignation().isEmpty()) { 1776 addDesignation(); 1777 } 1778 return getDesignation().get(0); 1779 } 1780 1781 /** 1782 * @return {@link #property} (A property value for this concept.) 1783 */ 1784 public List<ConceptPropertyComponent> getProperty() { 1785 if (this.property == null) 1786 this.property = new ArrayList<ConceptPropertyComponent>(); 1787 return this.property; 1788 } 1789 1790 /** 1791 * @return Returns a reference to <code>this</code> for easy method chaining 1792 */ 1793 public ConceptDefinitionComponent setProperty(List<ConceptPropertyComponent> theProperty) { 1794 this.property = theProperty; 1795 return this; 1796 } 1797 1798 public boolean hasProperty() { 1799 if (this.property == null) 1800 return false; 1801 for (ConceptPropertyComponent item : this.property) 1802 if (!item.isEmpty()) 1803 return true; 1804 return false; 1805 } 1806 1807 public ConceptPropertyComponent addProperty() { //3 1808 ConceptPropertyComponent t = new ConceptPropertyComponent(); 1809 if (this.property == null) 1810 this.property = new ArrayList<ConceptPropertyComponent>(); 1811 this.property.add(t); 1812 return t; 1813 } 1814 1815 public ConceptDefinitionComponent addProperty(ConceptPropertyComponent t) { //3 1816 if (t == null) 1817 return this; 1818 if (this.property == null) 1819 this.property = new ArrayList<ConceptPropertyComponent>(); 1820 this.property.add(t); 1821 return this; 1822 } 1823 1824 /** 1825 * @return The first repetition of repeating field {@link #property}, creating it if it does not already exist 1826 */ 1827 public ConceptPropertyComponent getPropertyFirstRep() { 1828 if (getProperty().isEmpty()) { 1829 addProperty(); 1830 } 1831 return getProperty().get(0); 1832 } 1833 1834 /** 1835 * @return {@link #concept} (Defines children of a concept to produce a hierarchy of concepts. The nature of the relationships is variable (is-a/contains/categorizes) - see hierarchyMeaning.) 1836 */ 1837 public List<ConceptDefinitionComponent> getConcept() { 1838 if (this.concept == null) 1839 this.concept = new ArrayList<ConceptDefinitionComponent>(); 1840 return this.concept; 1841 } 1842 1843 /** 1844 * @return Returns a reference to <code>this</code> for easy method chaining 1845 */ 1846 public ConceptDefinitionComponent setConcept(List<ConceptDefinitionComponent> theConcept) { 1847 this.concept = theConcept; 1848 return this; 1849 } 1850 1851 public boolean hasConcept() { 1852 if (this.concept == null) 1853 return false; 1854 for (ConceptDefinitionComponent item : this.concept) 1855 if (!item.isEmpty()) 1856 return true; 1857 return false; 1858 } 1859 1860 public ConceptDefinitionComponent addConcept() { //3 1861 ConceptDefinitionComponent t = new ConceptDefinitionComponent(); 1862 if (this.concept == null) 1863 this.concept = new ArrayList<ConceptDefinitionComponent>(); 1864 this.concept.add(t); 1865 return t; 1866 } 1867 1868 public ConceptDefinitionComponent addConcept(ConceptDefinitionComponent t) { //3 1869 if (t == null) 1870 return this; 1871 if (this.concept == null) 1872 this.concept = new ArrayList<ConceptDefinitionComponent>(); 1873 this.concept.add(t); 1874 return this; 1875 } 1876 1877 /** 1878 * @return The first repetition of repeating field {@link #concept}, creating it if it does not already exist 1879 */ 1880 public ConceptDefinitionComponent getConceptFirstRep() { 1881 if (getConcept().isEmpty()) { 1882 addConcept(); 1883 } 1884 return getConcept().get(0); 1885 } 1886 1887 protected void listChildren(List<Property> children) { 1888 super.listChildren(children); 1889 children.add(new Property("code", "code", "A code - a text symbol - that uniquely identifies the concept within the code system.", 0, 1, code)); 1890 children.add(new Property("display", "string", "A human readable string that is the recommended default way to present this concept to a user.", 0, 1, display)); 1891 children.add(new Property("definition", "string", "The formal definition of the concept. The code system resource does not make formal definitions required, because of the prevalence of legacy systems. However, they are highly recommended, as without them there is no formal meaning associated with the concept.", 0, 1, definition)); 1892 children.add(new Property("designation", "", "Additional representations for the concept - other languages, aliases, specialized purposes, used for particular purposes, etc.", 0, java.lang.Integer.MAX_VALUE, designation)); 1893 children.add(new Property("property", "", "A property value for this concept.", 0, java.lang.Integer.MAX_VALUE, property)); 1894 children.add(new Property("concept", "@CodeSystem.concept", "Defines children of a concept to produce a hierarchy of concepts. The nature of the relationships is variable (is-a/contains/categorizes) - see hierarchyMeaning.", 0, java.lang.Integer.MAX_VALUE, concept)); 1895 } 1896 1897 @Override 1898 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1899 switch (_hash) { 1900 case 3059181: /*code*/ return new Property("code", "code", "A code - a text symbol - that uniquely identifies the concept within the code system.", 0, 1, code); 1901 case 1671764162: /*display*/ return new Property("display", "string", "A human readable string that is the recommended default way to present this concept to a user.", 0, 1, display); 1902 case -1014418093: /*definition*/ return new Property("definition", "string", "The formal definition of the concept. The code system resource does not make formal definitions required, because of the prevalence of legacy systems. However, they are highly recommended, as without them there is no formal meaning associated with the concept.", 0, 1, definition); 1903 case -900931593: /*designation*/ return new Property("designation", "", "Additional representations for the concept - other languages, aliases, specialized purposes, used for particular purposes, etc.", 0, java.lang.Integer.MAX_VALUE, designation); 1904 case -993141291: /*property*/ return new Property("property", "", "A property value for this concept.", 0, java.lang.Integer.MAX_VALUE, property); 1905 case 951024232: /*concept*/ return new Property("concept", "@CodeSystem.concept", "Defines children of a concept to produce a hierarchy of concepts. The nature of the relationships is variable (is-a/contains/categorizes) - see hierarchyMeaning.", 0, java.lang.Integer.MAX_VALUE, concept); 1906 default: return super.getNamedProperty(_hash, _name, _checkValid); 1907 } 1908 1909 } 1910 1911 @Override 1912 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1913 switch (hash) { 1914 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeType 1915 case 1671764162: /*display*/ return this.display == null ? new Base[0] : new Base[] {this.display}; // StringType 1916 case -1014418093: /*definition*/ return this.definition == null ? new Base[0] : new Base[] {this.definition}; // StringType 1917 case -900931593: /*designation*/ return this.designation == null ? new Base[0] : this.designation.toArray(new Base[this.designation.size()]); // ConceptDefinitionDesignationComponent 1918 case -993141291: /*property*/ return this.property == null ? new Base[0] : this.property.toArray(new Base[this.property.size()]); // ConceptPropertyComponent 1919 case 951024232: /*concept*/ return this.concept == null ? new Base[0] : this.concept.toArray(new Base[this.concept.size()]); // ConceptDefinitionComponent 1920 default: return super.getProperty(hash, name, checkValid); 1921 } 1922 1923 } 1924 1925 @Override 1926 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1927 switch (hash) { 1928 case 3059181: // code 1929 this.code = castToCode(value); // CodeType 1930 return value; 1931 case 1671764162: // display 1932 this.display = castToString(value); // StringType 1933 return value; 1934 case -1014418093: // definition 1935 this.definition = castToString(value); // StringType 1936 return value; 1937 case -900931593: // designation 1938 this.getDesignation().add((ConceptDefinitionDesignationComponent) value); // ConceptDefinitionDesignationComponent 1939 return value; 1940 case -993141291: // property 1941 this.getProperty().add((ConceptPropertyComponent) value); // ConceptPropertyComponent 1942 return value; 1943 case 951024232: // concept 1944 this.getConcept().add((ConceptDefinitionComponent) value); // ConceptDefinitionComponent 1945 return value; 1946 default: return super.setProperty(hash, name, value); 1947 } 1948 1949 } 1950 1951 @Override 1952 public Base setProperty(String name, Base value) throws FHIRException { 1953 if (name.equals("code")) { 1954 this.code = castToCode(value); // CodeType 1955 } else if (name.equals("display")) { 1956 this.display = castToString(value); // StringType 1957 } else if (name.equals("definition")) { 1958 this.definition = castToString(value); // StringType 1959 } else if (name.equals("designation")) { 1960 this.getDesignation().add((ConceptDefinitionDesignationComponent) value); 1961 } else if (name.equals("property")) { 1962 this.getProperty().add((ConceptPropertyComponent) value); 1963 } else if (name.equals("concept")) { 1964 this.getConcept().add((ConceptDefinitionComponent) value); 1965 } else 1966 return super.setProperty(name, value); 1967 return value; 1968 } 1969 1970 @Override 1971 public Base makeProperty(int hash, String name) throws FHIRException { 1972 switch (hash) { 1973 case 3059181: return getCodeElement(); 1974 case 1671764162: return getDisplayElement(); 1975 case -1014418093: return getDefinitionElement(); 1976 case -900931593: return addDesignation(); 1977 case -993141291: return addProperty(); 1978 case 951024232: return addConcept(); 1979 default: return super.makeProperty(hash, name); 1980 } 1981 1982 } 1983 1984 @Override 1985 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1986 switch (hash) { 1987 case 3059181: /*code*/ return new String[] {"code"}; 1988 case 1671764162: /*display*/ return new String[] {"string"}; 1989 case -1014418093: /*definition*/ return new String[] {"string"}; 1990 case -900931593: /*designation*/ return new String[] {}; 1991 case -993141291: /*property*/ return new String[] {}; 1992 case 951024232: /*concept*/ return new String[] {"@CodeSystem.concept"}; 1993 default: return super.getTypesForProperty(hash, name); 1994 } 1995 1996 } 1997 1998 @Override 1999 public Base addChild(String name) throws FHIRException { 2000 if (name.equals("code")) { 2001 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.code"); 2002 } 2003 else if (name.equals("display")) { 2004 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.display"); 2005 } 2006 else if (name.equals("definition")) { 2007 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.definition"); 2008 } 2009 else if (name.equals("designation")) { 2010 return addDesignation(); 2011 } 2012 else if (name.equals("property")) { 2013 return addProperty(); 2014 } 2015 else if (name.equals("concept")) { 2016 return addConcept(); 2017 } 2018 else 2019 return super.addChild(name); 2020 } 2021 2022 public ConceptDefinitionComponent copy() { 2023 ConceptDefinitionComponent dst = new ConceptDefinitionComponent(); 2024 copyValues(dst); 2025 return dst; 2026 } 2027 2028 public void copyValues(ConceptDefinitionComponent dst) { 2029 super.copyValues(dst); 2030 dst.code = code == null ? null : code.copy(); 2031 dst.display = display == null ? null : display.copy(); 2032 dst.definition = definition == null ? null : definition.copy(); 2033 if (designation != null) { 2034 dst.designation = new ArrayList<ConceptDefinitionDesignationComponent>(); 2035 for (ConceptDefinitionDesignationComponent i : designation) 2036 dst.designation.add(i.copy()); 2037 }; 2038 if (property != null) { 2039 dst.property = new ArrayList<ConceptPropertyComponent>(); 2040 for (ConceptPropertyComponent i : property) 2041 dst.property.add(i.copy()); 2042 }; 2043 if (concept != null) { 2044 dst.concept = new ArrayList<ConceptDefinitionComponent>(); 2045 for (ConceptDefinitionComponent i : concept) 2046 dst.concept.add(i.copy()); 2047 }; 2048 } 2049 2050 @Override 2051 public boolean equalsDeep(Base other_) { 2052 if (!super.equalsDeep(other_)) 2053 return false; 2054 if (!(other_ instanceof ConceptDefinitionComponent)) 2055 return false; 2056 ConceptDefinitionComponent o = (ConceptDefinitionComponent) other_; 2057 return compareDeep(code, o.code, true) && compareDeep(display, o.display, true) && compareDeep(definition, o.definition, true) 2058 && compareDeep(designation, o.designation, true) && compareDeep(property, o.property, true) && compareDeep(concept, o.concept, true) 2059 ; 2060 } 2061 2062 @Override 2063 public boolean equalsShallow(Base other_) { 2064 if (!super.equalsShallow(other_)) 2065 return false; 2066 if (!(other_ instanceof ConceptDefinitionComponent)) 2067 return false; 2068 ConceptDefinitionComponent o = (ConceptDefinitionComponent) other_; 2069 return compareValues(code, o.code, true) && compareValues(display, o.display, true) && compareValues(definition, o.definition, true) 2070 ; 2071 } 2072 2073 public boolean isEmpty() { 2074 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, display, definition 2075 , designation, property, concept); 2076 } 2077 2078 public String fhirType() { 2079 return "CodeSystem.concept"; 2080 2081 } 2082 2083 } 2084 2085 @Block() 2086 public static class ConceptDefinitionDesignationComponent extends BackboneElement implements IBaseBackboneElement { 2087 /** 2088 * The language this designation is defined for. 2089 */ 2090 @Child(name = "language", type = {CodeType.class}, order=1, min=0, max=1, modifier=false, summary=false) 2091 @Description(shortDefinition="Human language of the designation", formalDefinition="The language this designation is defined for." ) 2092 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/languages") 2093 protected CodeType language; 2094 2095 /** 2096 * A code that details how this designation would be used. 2097 */ 2098 @Child(name = "use", type = {Coding.class}, order=2, min=0, max=1, modifier=false, summary=false) 2099 @Description(shortDefinition="Details how this designation would be used", formalDefinition="A code that details how this designation would be used." ) 2100 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/designation-use") 2101 protected Coding use; 2102 2103 /** 2104 * The text value for this designation. 2105 */ 2106 @Child(name = "value", type = {StringType.class}, order=3, min=1, max=1, modifier=false, summary=false) 2107 @Description(shortDefinition="The text value for this designation", formalDefinition="The text value for this designation." ) 2108 protected StringType value; 2109 2110 private static final long serialVersionUID = 1515662414L; 2111 2112 /** 2113 * Constructor 2114 */ 2115 public ConceptDefinitionDesignationComponent() { 2116 super(); 2117 } 2118 2119 /** 2120 * Constructor 2121 */ 2122 public ConceptDefinitionDesignationComponent(StringType value) { 2123 super(); 2124 this.value = value; 2125 } 2126 2127 /** 2128 * @return {@link #language} (The language this designation is defined for.). This is the underlying object with id, value and extensions. The accessor "getLanguage" gives direct access to the value 2129 */ 2130 public CodeType getLanguageElement() { 2131 if (this.language == null) 2132 if (Configuration.errorOnAutoCreate()) 2133 throw new Error("Attempt to auto-create ConceptDefinitionDesignationComponent.language"); 2134 else if (Configuration.doAutoCreate()) 2135 this.language = new CodeType(); // bb 2136 return this.language; 2137 } 2138 2139 public boolean hasLanguageElement() { 2140 return this.language != null && !this.language.isEmpty(); 2141 } 2142 2143 public boolean hasLanguage() { 2144 return this.language != null && !this.language.isEmpty(); 2145 } 2146 2147 /** 2148 * @param value {@link #language} (The language this designation is defined for.). This is the underlying object with id, value and extensions. The accessor "getLanguage" gives direct access to the value 2149 */ 2150 public ConceptDefinitionDesignationComponent setLanguageElement(CodeType value) { 2151 this.language = value; 2152 return this; 2153 } 2154 2155 /** 2156 * @return The language this designation is defined for. 2157 */ 2158 public String getLanguage() { 2159 return this.language == null ? null : this.language.getValue(); 2160 } 2161 2162 /** 2163 * @param value The language this designation is defined for. 2164 */ 2165 public ConceptDefinitionDesignationComponent setLanguage(String value) { 2166 if (Utilities.noString(value)) 2167 this.language = null; 2168 else { 2169 if (this.language == null) 2170 this.language = new CodeType(); 2171 this.language.setValue(value); 2172 } 2173 return this; 2174 } 2175 2176 /** 2177 * @return {@link #use} (A code that details how this designation would be used.) 2178 */ 2179 public Coding getUse() { 2180 if (this.use == null) 2181 if (Configuration.errorOnAutoCreate()) 2182 throw new Error("Attempt to auto-create ConceptDefinitionDesignationComponent.use"); 2183 else if (Configuration.doAutoCreate()) 2184 this.use = new Coding(); // cc 2185 return this.use; 2186 } 2187 2188 public boolean hasUse() { 2189 return this.use != null && !this.use.isEmpty(); 2190 } 2191 2192 /** 2193 * @param value {@link #use} (A code that details how this designation would be used.) 2194 */ 2195 public ConceptDefinitionDesignationComponent setUse(Coding value) { 2196 this.use = value; 2197 return this; 2198 } 2199 2200 /** 2201 * @return {@link #value} (The text value for this designation.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 2202 */ 2203 public StringType getValueElement() { 2204 if (this.value == null) 2205 if (Configuration.errorOnAutoCreate()) 2206 throw new Error("Attempt to auto-create ConceptDefinitionDesignationComponent.value"); 2207 else if (Configuration.doAutoCreate()) 2208 this.value = new StringType(); // bb 2209 return this.value; 2210 } 2211 2212 public boolean hasValueElement() { 2213 return this.value != null && !this.value.isEmpty(); 2214 } 2215 2216 public boolean hasValue() { 2217 return this.value != null && !this.value.isEmpty(); 2218 } 2219 2220 /** 2221 * @param value {@link #value} (The text value for this designation.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 2222 */ 2223 public ConceptDefinitionDesignationComponent setValueElement(StringType value) { 2224 this.value = value; 2225 return this; 2226 } 2227 2228 /** 2229 * @return The text value for this designation. 2230 */ 2231 public String getValue() { 2232 return this.value == null ? null : this.value.getValue(); 2233 } 2234 2235 /** 2236 * @param value The text value for this designation. 2237 */ 2238 public ConceptDefinitionDesignationComponent setValue(String value) { 2239 if (this.value == null) 2240 this.value = new StringType(); 2241 this.value.setValue(value); 2242 return this; 2243 } 2244 2245 protected void listChildren(List<Property> children) { 2246 super.listChildren(children); 2247 children.add(new Property("language", "code", "The language this designation is defined for.", 0, 1, language)); 2248 children.add(new Property("use", "Coding", "A code that details how this designation would be used.", 0, 1, use)); 2249 children.add(new Property("value", "string", "The text value for this designation.", 0, 1, value)); 2250 } 2251 2252 @Override 2253 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2254 switch (_hash) { 2255 case -1613589672: /*language*/ return new Property("language", "code", "The language this designation is defined for.", 0, 1, language); 2256 case 116103: /*use*/ return new Property("use", "Coding", "A code that details how this designation would be used.", 0, 1, use); 2257 case 111972721: /*value*/ return new Property("value", "string", "The text value for this designation.", 0, 1, value); 2258 default: return super.getNamedProperty(_hash, _name, _checkValid); 2259 } 2260 2261 } 2262 2263 @Override 2264 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2265 switch (hash) { 2266 case -1613589672: /*language*/ return this.language == null ? new Base[0] : new Base[] {this.language}; // CodeType 2267 case 116103: /*use*/ return this.use == null ? new Base[0] : new Base[] {this.use}; // Coding 2268 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // StringType 2269 default: return super.getProperty(hash, name, checkValid); 2270 } 2271 2272 } 2273 2274 @Override 2275 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2276 switch (hash) { 2277 case -1613589672: // language 2278 this.language = castToCode(value); // CodeType 2279 return value; 2280 case 116103: // use 2281 this.use = castToCoding(value); // Coding 2282 return value; 2283 case 111972721: // value 2284 this.value = castToString(value); // StringType 2285 return value; 2286 default: return super.setProperty(hash, name, value); 2287 } 2288 2289 } 2290 2291 @Override 2292 public Base setProperty(String name, Base value) throws FHIRException { 2293 if (name.equals("language")) { 2294 this.language = castToCode(value); // CodeType 2295 } else if (name.equals("use")) { 2296 this.use = castToCoding(value); // Coding 2297 } else if (name.equals("value")) { 2298 this.value = castToString(value); // StringType 2299 } else 2300 return super.setProperty(name, value); 2301 return value; 2302 } 2303 2304 @Override 2305 public Base makeProperty(int hash, String name) throws FHIRException { 2306 switch (hash) { 2307 case -1613589672: return getLanguageElement(); 2308 case 116103: return getUse(); 2309 case 111972721: return getValueElement(); 2310 default: return super.makeProperty(hash, name); 2311 } 2312 2313 } 2314 2315 @Override 2316 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2317 switch (hash) { 2318 case -1613589672: /*language*/ return new String[] {"code"}; 2319 case 116103: /*use*/ return new String[] {"Coding"}; 2320 case 111972721: /*value*/ return new String[] {"string"}; 2321 default: return super.getTypesForProperty(hash, name); 2322 } 2323 2324 } 2325 2326 @Override 2327 public Base addChild(String name) throws FHIRException { 2328 if (name.equals("language")) { 2329 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.language"); 2330 } 2331 else if (name.equals("use")) { 2332 this.use = new Coding(); 2333 return this.use; 2334 } 2335 else if (name.equals("value")) { 2336 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.value"); 2337 } 2338 else 2339 return super.addChild(name); 2340 } 2341 2342 public ConceptDefinitionDesignationComponent copy() { 2343 ConceptDefinitionDesignationComponent dst = new ConceptDefinitionDesignationComponent(); 2344 copyValues(dst); 2345 return dst; 2346 } 2347 2348 public void copyValues(ConceptDefinitionDesignationComponent dst) { 2349 super.copyValues(dst); 2350 dst.language = language == null ? null : language.copy(); 2351 dst.use = use == null ? null : use.copy(); 2352 dst.value = value == null ? null : value.copy(); 2353 } 2354 2355 @Override 2356 public boolean equalsDeep(Base other_) { 2357 if (!super.equalsDeep(other_)) 2358 return false; 2359 if (!(other_ instanceof ConceptDefinitionDesignationComponent)) 2360 return false; 2361 ConceptDefinitionDesignationComponent o = (ConceptDefinitionDesignationComponent) other_; 2362 return compareDeep(language, o.language, true) && compareDeep(use, o.use, true) && compareDeep(value, o.value, true) 2363 ; 2364 } 2365 2366 @Override 2367 public boolean equalsShallow(Base other_) { 2368 if (!super.equalsShallow(other_)) 2369 return false; 2370 if (!(other_ instanceof ConceptDefinitionDesignationComponent)) 2371 return false; 2372 ConceptDefinitionDesignationComponent o = (ConceptDefinitionDesignationComponent) other_; 2373 return compareValues(language, o.language, true) && compareValues(value, o.value, true); 2374 } 2375 2376 public boolean isEmpty() { 2377 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(language, use, value); 2378 } 2379 2380 public String fhirType() { 2381 return "CodeSystem.concept.designation"; 2382 2383 } 2384 2385 } 2386 2387 @Block() 2388 public static class ConceptPropertyComponent extends BackboneElement implements IBaseBackboneElement { 2389 /** 2390 * A code that is a reference to CodeSystem.property.code. 2391 */ 2392 @Child(name = "code", type = {CodeType.class}, order=1, min=1, max=1, modifier=false, summary=false) 2393 @Description(shortDefinition="Reference to CodeSystem.property.code", formalDefinition="A code that is a reference to CodeSystem.property.code." ) 2394 protected CodeType code; 2395 2396 /** 2397 * The value of this property. 2398 */ 2399 @Child(name = "value", type = {CodeType.class, Coding.class, StringType.class, IntegerType.class, BooleanType.class, DateTimeType.class, DecimalType.class}, order=2, min=1, max=1, modifier=false, summary=false) 2400 @Description(shortDefinition="Value of the property for this concept", formalDefinition="The value of this property." ) 2401 protected Type value; 2402 2403 private static final long serialVersionUID = 1742812311L; 2404 2405 /** 2406 * Constructor 2407 */ 2408 public ConceptPropertyComponent() { 2409 super(); 2410 } 2411 2412 /** 2413 * Constructor 2414 */ 2415 public ConceptPropertyComponent(CodeType code, Type value) { 2416 super(); 2417 this.code = code; 2418 this.value = value; 2419 } 2420 2421 /** 2422 * @return {@link #code} (A code that is a reference to CodeSystem.property.code.). This is the underlying object with id, value and extensions. The accessor "getCode" gives direct access to the value 2423 */ 2424 public CodeType getCodeElement() { 2425 if (this.code == null) 2426 if (Configuration.errorOnAutoCreate()) 2427 throw new Error("Attempt to auto-create ConceptPropertyComponent.code"); 2428 else if (Configuration.doAutoCreate()) 2429 this.code = new CodeType(); // bb 2430 return this.code; 2431 } 2432 2433 public boolean hasCodeElement() { 2434 return this.code != null && !this.code.isEmpty(); 2435 } 2436 2437 public boolean hasCode() { 2438 return this.code != null && !this.code.isEmpty(); 2439 } 2440 2441 /** 2442 * @param value {@link #code} (A code that is a reference to CodeSystem.property.code.). This is the underlying object with id, value and extensions. The accessor "getCode" gives direct access to the value 2443 */ 2444 public ConceptPropertyComponent setCodeElement(CodeType value) { 2445 this.code = value; 2446 return this; 2447 } 2448 2449 /** 2450 * @return A code that is a reference to CodeSystem.property.code. 2451 */ 2452 public String getCode() { 2453 return this.code == null ? null : this.code.getValue(); 2454 } 2455 2456 /** 2457 * @param value A code that is a reference to CodeSystem.property.code. 2458 */ 2459 public ConceptPropertyComponent setCode(String value) { 2460 if (this.code == null) 2461 this.code = new CodeType(); 2462 this.code.setValue(value); 2463 return this; 2464 } 2465 2466 /** 2467 * @return {@link #value} (The value of this property.) 2468 */ 2469 public Type getValue() { 2470 return this.value; 2471 } 2472 2473 /** 2474 * @return {@link #value} (The value of this property.) 2475 */ 2476 public CodeType getValueCodeType() throws FHIRException { 2477 if (this.value == null) 2478 this.value = new CodeType(); 2479 if (!(this.value instanceof CodeType)) 2480 throw new FHIRException("Type mismatch: the type CodeType was expected, but "+this.value.getClass().getName()+" was encountered"); 2481 return (CodeType) this.value; 2482 } 2483 2484 public boolean hasValueCodeType() { 2485 return this != null && this.value instanceof CodeType; 2486 } 2487 2488 /** 2489 * @return {@link #value} (The value of this property.) 2490 */ 2491 public Coding getValueCoding() throws FHIRException { 2492 if (this.value == null) 2493 this.value = new Coding(); 2494 if (!(this.value instanceof Coding)) 2495 throw new FHIRException("Type mismatch: the type Coding was expected, but "+this.value.getClass().getName()+" was encountered"); 2496 return (Coding) this.value; 2497 } 2498 2499 public boolean hasValueCoding() { 2500 return this != null && this.value instanceof Coding; 2501 } 2502 2503 /** 2504 * @return {@link #value} (The value of this property.) 2505 */ 2506 public StringType getValueStringType() throws FHIRException { 2507 if (this.value == null) 2508 this.value = new StringType(); 2509 if (!(this.value instanceof StringType)) 2510 throw new FHIRException("Type mismatch: the type StringType was expected, but "+this.value.getClass().getName()+" was encountered"); 2511 return (StringType) this.value; 2512 } 2513 2514 public boolean hasValueStringType() { 2515 return this != null && this.value instanceof StringType; 2516 } 2517 2518 /** 2519 * @return {@link #value} (The value of this property.) 2520 */ 2521 public IntegerType getValueIntegerType() throws FHIRException { 2522 if (this.value == null) 2523 this.value = new IntegerType(); 2524 if (!(this.value instanceof IntegerType)) 2525 throw new FHIRException("Type mismatch: the type IntegerType was expected, but "+this.value.getClass().getName()+" was encountered"); 2526 return (IntegerType) this.value; 2527 } 2528 2529 public boolean hasValueIntegerType() { 2530 return this != null && this.value instanceof IntegerType; 2531 } 2532 2533 /** 2534 * @return {@link #value} (The value of this property.) 2535 */ 2536 public BooleanType getValueBooleanType() throws FHIRException { 2537 if (this.value == null) 2538 this.value = new BooleanType(); 2539 if (!(this.value instanceof BooleanType)) 2540 throw new FHIRException("Type mismatch: the type BooleanType was expected, but "+this.value.getClass().getName()+" was encountered"); 2541 return (BooleanType) this.value; 2542 } 2543 2544 public boolean hasValueBooleanType() { 2545 return this != null && this.value instanceof BooleanType; 2546 } 2547 2548 /** 2549 * @return {@link #value} (The value of this property.) 2550 */ 2551 public DateTimeType getValueDateTimeType() throws FHIRException { 2552 if (this.value == null) 2553 this.value = new DateTimeType(); 2554 if (!(this.value instanceof DateTimeType)) 2555 throw new FHIRException("Type mismatch: the type DateTimeType was expected, but "+this.value.getClass().getName()+" was encountered"); 2556 return (DateTimeType) this.value; 2557 } 2558 2559 public boolean hasValueDateTimeType() { 2560 return this != null && this.value instanceof DateTimeType; 2561 } 2562 2563 /** 2564 * @return {@link #value} (The value of this property.) 2565 */ 2566 public DecimalType getValueDecimalType() throws FHIRException { 2567 if (this.value == null) 2568 this.value = new DecimalType(); 2569 if (!(this.value instanceof DecimalType)) 2570 throw new FHIRException("Type mismatch: the type DecimalType was expected, but "+this.value.getClass().getName()+" was encountered"); 2571 return (DecimalType) this.value; 2572 } 2573 2574 public boolean hasValueDecimalType() { 2575 return this != null && this.value instanceof DecimalType; 2576 } 2577 2578 public boolean hasValue() { 2579 return this.value != null && !this.value.isEmpty(); 2580 } 2581 2582 /** 2583 * @param value {@link #value} (The value of this property.) 2584 */ 2585 public ConceptPropertyComponent setValue(Type value) { 2586 if (value != null && !(value instanceof CodeType || value instanceof Coding || value instanceof StringType || value instanceof IntegerType || value instanceof BooleanType || value instanceof DateTimeType || value instanceof DecimalType)) 2587 throw new Error("Not the right type for CodeSystem.concept.property.value[x]: "+value.fhirType()); 2588 this.value = value; 2589 return this; 2590 } 2591 2592 protected void listChildren(List<Property> children) { 2593 super.listChildren(children); 2594 children.add(new Property("code", "code", "A code that is a reference to CodeSystem.property.code.", 0, 1, code)); 2595 children.add(new Property("value[x]", "code|Coding|string|integer|boolean|dateTime|decimal", "The value of this property.", 0, 1, value)); 2596 } 2597 2598 @Override 2599 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2600 switch (_hash) { 2601 case 3059181: /*code*/ return new Property("code", "code", "A code that is a reference to CodeSystem.property.code.", 0, 1, code); 2602 case -1410166417: /*value[x]*/ return new Property("value[x]", "code|Coding|string|integer|boolean|dateTime|decimal", "The value of this property.", 0, 1, value); 2603 case 111972721: /*value*/ return new Property("value[x]", "code|Coding|string|integer|boolean|dateTime|decimal", "The value of this property.", 0, 1, value); 2604 case -766209282: /*valueCode*/ return new Property("value[x]", "code|Coding|string|integer|boolean|dateTime|decimal", "The value of this property.", 0, 1, value); 2605 case -1887705029: /*valueCoding*/ return new Property("value[x]", "code|Coding|string|integer|boolean|dateTime|decimal", "The value of this property.", 0, 1, value); 2606 case -1424603934: /*valueString*/ return new Property("value[x]", "code|Coding|string|integer|boolean|dateTime|decimal", "The value of this property.", 0, 1, value); 2607 case -1668204915: /*valueInteger*/ return new Property("value[x]", "code|Coding|string|integer|boolean|dateTime|decimal", "The value of this property.", 0, 1, value); 2608 case 733421943: /*valueBoolean*/ return new Property("value[x]", "code|Coding|string|integer|boolean|dateTime|decimal", "The value of this property.", 0, 1, value); 2609 case 1047929900: /*valueDateTime*/ return new Property("value[x]", "code|Coding|string|integer|boolean|dateTime|decimal", "The value of this property.", 0, 1, value); 2610 case -2083993440: /*valueDecimal*/ return new Property("value[x]", "code|Coding|string|integer|boolean|dateTime|decimal", "The value of this property.", 0, 1, value); 2611 default: return super.getNamedProperty(_hash, _name, _checkValid); 2612 } 2613 2614 } 2615 2616 @Override 2617 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2618 switch (hash) { 2619 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeType 2620 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // Type 2621 default: return super.getProperty(hash, name, checkValid); 2622 } 2623 2624 } 2625 2626 @Override 2627 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2628 switch (hash) { 2629 case 3059181: // code 2630 this.code = castToCode(value); // CodeType 2631 return value; 2632 case 111972721: // value 2633 this.value = castToType(value); // Type 2634 return value; 2635 default: return super.setProperty(hash, name, value); 2636 } 2637 2638 } 2639 2640 @Override 2641 public Base setProperty(String name, Base value) throws FHIRException { 2642 if (name.equals("code")) { 2643 this.code = castToCode(value); // CodeType 2644 } else if (name.equals("value[x]")) { 2645 this.value = castToType(value); // Type 2646 } else 2647 return super.setProperty(name, value); 2648 return value; 2649 } 2650 2651 @Override 2652 public Base makeProperty(int hash, String name) throws FHIRException { 2653 switch (hash) { 2654 case 3059181: return getCodeElement(); 2655 case -1410166417: return getValue(); 2656 case 111972721: return getValue(); 2657 default: return super.makeProperty(hash, name); 2658 } 2659 2660 } 2661 2662 @Override 2663 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2664 switch (hash) { 2665 case 3059181: /*code*/ return new String[] {"code"}; 2666 case 111972721: /*value*/ return new String[] {"code", "Coding", "string", "integer", "boolean", "dateTime", "decimal"}; 2667 default: return super.getTypesForProperty(hash, name); 2668 } 2669 2670 } 2671 2672 @Override 2673 public Base addChild(String name) throws FHIRException { 2674 if (name.equals("code")) { 2675 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.code"); 2676 } 2677 else if (name.equals("valueCode")) { 2678 this.value = new CodeType(); 2679 return this.value; 2680 } 2681 else if (name.equals("valueCoding")) { 2682 this.value = new Coding(); 2683 return this.value; 2684 } 2685 else if (name.equals("valueString")) { 2686 this.value = new StringType(); 2687 return this.value; 2688 } 2689 else if (name.equals("valueInteger")) { 2690 this.value = new IntegerType(); 2691 return this.value; 2692 } 2693 else if (name.equals("valueBoolean")) { 2694 this.value = new BooleanType(); 2695 return this.value; 2696 } 2697 else if (name.equals("valueDateTime")) { 2698 this.value = new DateTimeType(); 2699 return this.value; 2700 } 2701 else if (name.equals("valueDecimal")) { 2702 this.value = new DecimalType(); 2703 return this.value; 2704 } 2705 else 2706 return super.addChild(name); 2707 } 2708 2709 public ConceptPropertyComponent copy() { 2710 ConceptPropertyComponent dst = new ConceptPropertyComponent(); 2711 copyValues(dst); 2712 return dst; 2713 } 2714 2715 public void copyValues(ConceptPropertyComponent dst) { 2716 super.copyValues(dst); 2717 dst.code = code == null ? null : code.copy(); 2718 dst.value = value == null ? null : value.copy(); 2719 } 2720 2721 @Override 2722 public boolean equalsDeep(Base other_) { 2723 if (!super.equalsDeep(other_)) 2724 return false; 2725 if (!(other_ instanceof ConceptPropertyComponent)) 2726 return false; 2727 ConceptPropertyComponent o = (ConceptPropertyComponent) other_; 2728 return compareDeep(code, o.code, true) && compareDeep(value, o.value, true); 2729 } 2730 2731 @Override 2732 public boolean equalsShallow(Base other_) { 2733 if (!super.equalsShallow(other_)) 2734 return false; 2735 if (!(other_ instanceof ConceptPropertyComponent)) 2736 return false; 2737 ConceptPropertyComponent o = (ConceptPropertyComponent) other_; 2738 return compareValues(code, o.code, true); 2739 } 2740 2741 public boolean isEmpty() { 2742 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, value); 2743 } 2744 2745 public String fhirType() { 2746 return "CodeSystem.concept.property"; 2747 2748 } 2749 2750 } 2751 2752 /** 2753 * A formal identifier that is used to identify this code system when it is represented in other formats, or referenced in a specification, model, design or an instance. 2754 */ 2755 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 2756 @Description(shortDefinition="Additional identifier for the code system (business identifier)", formalDefinition="A formal identifier that is used to identify this code system when it is represented in other formats, or referenced in a specification, model, design or an instance." ) 2757 protected List<Identifier> identifier; 2758 2759 /** 2760 * Explanation of why this code system is needed and why it has been designed as it has. 2761 */ 2762 @Child(name = "purpose", type = {MarkdownType.class}, order=1, min=0, max=1, modifier=false, summary=false) 2763 @Description(shortDefinition="Why this code system is defined", formalDefinition="Explanation of why this code system is needed and why it has been designed as it has." ) 2764 protected MarkdownType purpose; 2765 2766 /** 2767 * A copyright statement relating to the code system and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the code system. 2768 */ 2769 @Child(name = "copyright", type = {MarkdownType.class}, order=2, min=0, max=1, modifier=false, summary=false) 2770 @Description(shortDefinition="Use and/or publishing restrictions", formalDefinition="A copyright statement relating to the code system and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the code system." ) 2771 protected MarkdownType copyright; 2772 2773 /** 2774 * If code comparison is case sensitive when codes within this system are compared to each other. 2775 */ 2776 @Child(name = "caseSensitive", type = {BooleanType.class}, order=3, min=0, max=1, modifier=false, summary=true) 2777 @Description(shortDefinition="If code comparison is case sensitive", formalDefinition="If code comparison is case sensitive when codes within this system are compared to each other." ) 2778 protected BooleanType caseSensitive; 2779 2780 /** 2781 * Canonical reference to the value set that contains the entire code system. 2782 */ 2783 @Child(name = "valueSet", type = {CanonicalType.class}, order=4, min=0, max=1, modifier=false, summary=true) 2784 @Description(shortDefinition="Canonical reference to the value set with entire code system", formalDefinition="Canonical reference to the value set that contains the entire code system." ) 2785 protected CanonicalType valueSet; 2786 2787 /** 2788 * The meaning of the hierarchy of concepts as represented in this resource. 2789 */ 2790 @Child(name = "hierarchyMeaning", type = {CodeType.class}, order=5, min=0, max=1, modifier=false, summary=true) 2791 @Description(shortDefinition="grouped-by | is-a | part-of | classified-with", formalDefinition="The meaning of the hierarchy of concepts as represented in this resource." ) 2792 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/codesystem-hierarchy-meaning") 2793 protected Enumeration<CodeSystemHierarchyMeaning> hierarchyMeaning; 2794 2795 /** 2796 * The code system defines a compositional (post-coordination) grammar. 2797 */ 2798 @Child(name = "compositional", type = {BooleanType.class}, order=6, min=0, max=1, modifier=false, summary=true) 2799 @Description(shortDefinition="If code system defines a compositional grammar", formalDefinition="The code system defines a compositional (post-coordination) grammar." ) 2800 protected BooleanType compositional; 2801 2802 /** 2803 * This flag is used to signify that the code system does not commit to concept permanence across versions. If true, a version must be specified when referencing this code system. 2804 */ 2805 @Child(name = "versionNeeded", type = {BooleanType.class}, order=7, min=0, max=1, modifier=false, summary=true) 2806 @Description(shortDefinition="If definitions are not stable", formalDefinition="This flag is used to signify that the code system does not commit to concept permanence across versions. If true, a version must be specified when referencing this code system." ) 2807 protected BooleanType versionNeeded; 2808 2809 /** 2810 * The extent of the content of the code system (the concepts and codes it defines) are represented in this resource instance. 2811 */ 2812 @Child(name = "content", type = {CodeType.class}, order=8, min=1, max=1, modifier=false, summary=true) 2813 @Description(shortDefinition="not-present | example | fragment | complete | supplement", formalDefinition="The extent of the content of the code system (the concepts and codes it defines) are represented in this resource instance." ) 2814 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/codesystem-content-mode") 2815 protected Enumeration<CodeSystemContentMode> content; 2816 2817 /** 2818 * The canonical URL of the code system that this code system supplement is adding designations and properties to. 2819 */ 2820 @Child(name = "supplements", type = {CanonicalType.class}, order=9, min=0, max=1, modifier=false, summary=true) 2821 @Description(shortDefinition="Canonical URL of Code System this adds designations and properties to", formalDefinition="The canonical URL of the code system that this code system supplement is adding designations and properties to." ) 2822 protected CanonicalType supplements; 2823 2824 /** 2825 * The total number of concepts defined by the code system. Where the code system has a compositional grammar, the basis of this count is defined by the system steward. 2826 */ 2827 @Child(name = "count", type = {UnsignedIntType.class}, order=10, min=0, max=1, modifier=false, summary=true) 2828 @Description(shortDefinition="Total concepts in the code system", formalDefinition="The total number of concepts defined by the code system. Where the code system has a compositional grammar, the basis of this count is defined by the system steward." ) 2829 protected UnsignedIntType count; 2830 2831 /** 2832 * A filter that can be used in a value set compose statement when selecting concepts using a filter. 2833 */ 2834 @Child(name = "filter", type = {}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 2835 @Description(shortDefinition="Filter that can be used in a value set", formalDefinition="A filter that can be used in a value set compose statement when selecting concepts using a filter." ) 2836 protected List<CodeSystemFilterComponent> filter; 2837 2838 /** 2839 * A property defines an additional slot through which additional information can be provided about a concept. 2840 */ 2841 @Child(name = "property", type = {}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 2842 @Description(shortDefinition="Additional information supplied about each concept", formalDefinition="A property defines an additional slot through which additional information can be provided about a concept." ) 2843 protected List<PropertyComponent> property; 2844 2845 /** 2846 * Concepts that are in the code system. The concept definitions are inherently hierarchical, but the definitions must be consulted to determine what the meanings of the hierarchical relationships are. 2847 */ 2848 @Child(name = "concept", type = {}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2849 @Description(shortDefinition="Concepts in the code system", formalDefinition="Concepts that are in the code system. The concept definitions are inherently hierarchical, but the definitions must be consulted to determine what the meanings of the hierarchical relationships are." ) 2850 protected List<ConceptDefinitionComponent> concept; 2851 2852 private static final long serialVersionUID = -1735124584L; 2853 2854 /** 2855 * Constructor 2856 */ 2857 public CodeSystem() { 2858 super(); 2859 } 2860 2861 /** 2862 * Constructor 2863 */ 2864 public CodeSystem(Enumeration<PublicationStatus> status, Enumeration<CodeSystemContentMode> content) { 2865 super(); 2866 this.status = status; 2867 this.content = content; 2868 } 2869 2870 /** 2871 * @return {@link #url} (An absolute URI that is used to identify this code system when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this code system is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the code system is stored on different servers. This is used in [Coding](datatypes.html#Coding).system.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 2872 */ 2873 public UriType getUrlElement() { 2874 if (this.url == null) 2875 if (Configuration.errorOnAutoCreate()) 2876 throw new Error("Attempt to auto-create CodeSystem.url"); 2877 else if (Configuration.doAutoCreate()) 2878 this.url = new UriType(); // bb 2879 return this.url; 2880 } 2881 2882 public boolean hasUrlElement() { 2883 return this.url != null && !this.url.isEmpty(); 2884 } 2885 2886 public boolean hasUrl() { 2887 return this.url != null && !this.url.isEmpty(); 2888 } 2889 2890 /** 2891 * @param value {@link #url} (An absolute URI that is used to identify this code system when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this code system is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the code system is stored on different servers. This is used in [Coding](datatypes.html#Coding).system.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 2892 */ 2893 public CodeSystem setUrlElement(UriType value) { 2894 this.url = value; 2895 return this; 2896 } 2897 2898 /** 2899 * @return An absolute URI that is used to identify this code system when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this code system is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the code system is stored on different servers. This is used in [Coding](datatypes.html#Coding).system. 2900 */ 2901 public String getUrl() { 2902 return this.url == null ? null : this.url.getValue(); 2903 } 2904 2905 /** 2906 * @param value An absolute URI that is used to identify this code system when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this code system is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the code system is stored on different servers. This is used in [Coding](datatypes.html#Coding).system. 2907 */ 2908 public CodeSystem setUrl(String value) { 2909 if (Utilities.noString(value)) 2910 this.url = null; 2911 else { 2912 if (this.url == null) 2913 this.url = new UriType(); 2914 this.url.setValue(value); 2915 } 2916 return this; 2917 } 2918 2919 /** 2920 * @return {@link #identifier} (A formal identifier that is used to identify this code system when it is represented in other formats, or referenced in a specification, model, design or an instance.) 2921 */ 2922 public List<Identifier> getIdentifier() { 2923 if (this.identifier == null) 2924 this.identifier = new ArrayList<Identifier>(); 2925 return this.identifier; 2926 } 2927 2928 /** 2929 * @return Returns a reference to <code>this</code> for easy method chaining 2930 */ 2931 public CodeSystem setIdentifier(List<Identifier> theIdentifier) { 2932 this.identifier = theIdentifier; 2933 return this; 2934 } 2935 2936 public boolean hasIdentifier() { 2937 if (this.identifier == null) 2938 return false; 2939 for (Identifier item : this.identifier) 2940 if (!item.isEmpty()) 2941 return true; 2942 return false; 2943 } 2944 2945 public Identifier addIdentifier() { //3 2946 Identifier t = new Identifier(); 2947 if (this.identifier == null) 2948 this.identifier = new ArrayList<Identifier>(); 2949 this.identifier.add(t); 2950 return t; 2951 } 2952 2953 public CodeSystem addIdentifier(Identifier t) { //3 2954 if (t == null) 2955 return this; 2956 if (this.identifier == null) 2957 this.identifier = new ArrayList<Identifier>(); 2958 this.identifier.add(t); 2959 return this; 2960 } 2961 2962 /** 2963 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist 2964 */ 2965 public Identifier getIdentifierFirstRep() { 2966 if (getIdentifier().isEmpty()) { 2967 addIdentifier(); 2968 } 2969 return getIdentifier().get(0); 2970 } 2971 2972 /** 2973 * @return {@link #version} (The identifier that is used to identify this version of the code system when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the code system author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. This is used in [Coding](datatypes.html#Coding).version.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value 2974 */ 2975 public StringType getVersionElement() { 2976 if (this.version == null) 2977 if (Configuration.errorOnAutoCreate()) 2978 throw new Error("Attempt to auto-create CodeSystem.version"); 2979 else if (Configuration.doAutoCreate()) 2980 this.version = new StringType(); // bb 2981 return this.version; 2982 } 2983 2984 public boolean hasVersionElement() { 2985 return this.version != null && !this.version.isEmpty(); 2986 } 2987 2988 public boolean hasVersion() { 2989 return this.version != null && !this.version.isEmpty(); 2990 } 2991 2992 /** 2993 * @param value {@link #version} (The identifier that is used to identify this version of the code system when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the code system author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. This is used in [Coding](datatypes.html#Coding).version.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value 2994 */ 2995 public CodeSystem setVersionElement(StringType value) { 2996 this.version = value; 2997 return this; 2998 } 2999 3000 /** 3001 * @return The identifier that is used to identify this version of the code system when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the code system author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. This is used in [Coding](datatypes.html#Coding).version. 3002 */ 3003 public String getVersion() { 3004 return this.version == null ? null : this.version.getValue(); 3005 } 3006 3007 /** 3008 * @param value The identifier that is used to identify this version of the code system when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the code system author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. This is used in [Coding](datatypes.html#Coding).version. 3009 */ 3010 public CodeSystem setVersion(String value) { 3011 if (Utilities.noString(value)) 3012 this.version = null; 3013 else { 3014 if (this.version == null) 3015 this.version = new StringType(); 3016 this.version.setValue(value); 3017 } 3018 return this; 3019 } 3020 3021 /** 3022 * @return {@link #name} (A natural language name identifying the code system. This name should be usable as an identifier for the module by machine processing applications such as code generation.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 3023 */ 3024 public StringType getNameElement() { 3025 if (this.name == null) 3026 if (Configuration.errorOnAutoCreate()) 3027 throw new Error("Attempt to auto-create CodeSystem.name"); 3028 else if (Configuration.doAutoCreate()) 3029 this.name = new StringType(); // bb 3030 return this.name; 3031 } 3032 3033 public boolean hasNameElement() { 3034 return this.name != null && !this.name.isEmpty(); 3035 } 3036 3037 public boolean hasName() { 3038 return this.name != null && !this.name.isEmpty(); 3039 } 3040 3041 /** 3042 * @param value {@link #name} (A natural language name identifying the code system. This name should be usable as an identifier for the module by machine processing applications such as code generation.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 3043 */ 3044 public CodeSystem setNameElement(StringType value) { 3045 this.name = value; 3046 return this; 3047 } 3048 3049 /** 3050 * @return A natural language name identifying the code system. This name should be usable as an identifier for the module by machine processing applications such as code generation. 3051 */ 3052 public String getName() { 3053 return this.name == null ? null : this.name.getValue(); 3054 } 3055 3056 /** 3057 * @param value A natural language name identifying the code system. This name should be usable as an identifier for the module by machine processing applications such as code generation. 3058 */ 3059 public CodeSystem setName(String value) { 3060 if (Utilities.noString(value)) 3061 this.name = null; 3062 else { 3063 if (this.name == null) 3064 this.name = new StringType(); 3065 this.name.setValue(value); 3066 } 3067 return this; 3068 } 3069 3070 /** 3071 * @return {@link #title} (A short, descriptive, user-friendly title for the code system.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 3072 */ 3073 public StringType getTitleElement() { 3074 if (this.title == null) 3075 if (Configuration.errorOnAutoCreate()) 3076 throw new Error("Attempt to auto-create CodeSystem.title"); 3077 else if (Configuration.doAutoCreate()) 3078 this.title = new StringType(); // bb 3079 return this.title; 3080 } 3081 3082 public boolean hasTitleElement() { 3083 return this.title != null && !this.title.isEmpty(); 3084 } 3085 3086 public boolean hasTitle() { 3087 return this.title != null && !this.title.isEmpty(); 3088 } 3089 3090 /** 3091 * @param value {@link #title} (A short, descriptive, user-friendly title for the code system.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 3092 */ 3093 public CodeSystem setTitleElement(StringType value) { 3094 this.title = value; 3095 return this; 3096 } 3097 3098 /** 3099 * @return A short, descriptive, user-friendly title for the code system. 3100 */ 3101 public String getTitle() { 3102 return this.title == null ? null : this.title.getValue(); 3103 } 3104 3105 /** 3106 * @param value A short, descriptive, user-friendly title for the code system. 3107 */ 3108 public CodeSystem setTitle(String value) { 3109 if (Utilities.noString(value)) 3110 this.title = null; 3111 else { 3112 if (this.title == null) 3113 this.title = new StringType(); 3114 this.title.setValue(value); 3115 } 3116 return this; 3117 } 3118 3119 /** 3120 * @return {@link #status} (The date (and optionally time) when the code system resource was created or revised.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 3121 */ 3122 public Enumeration<PublicationStatus> getStatusElement() { 3123 if (this.status == null) 3124 if (Configuration.errorOnAutoCreate()) 3125 throw new Error("Attempt to auto-create CodeSystem.status"); 3126 else if (Configuration.doAutoCreate()) 3127 this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); // bb 3128 return this.status; 3129 } 3130 3131 public boolean hasStatusElement() { 3132 return this.status != null && !this.status.isEmpty(); 3133 } 3134 3135 public boolean hasStatus() { 3136 return this.status != null && !this.status.isEmpty(); 3137 } 3138 3139 /** 3140 * @param value {@link #status} (The date (and optionally time) when the code system resource was created or revised.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 3141 */ 3142 public CodeSystem setStatusElement(Enumeration<PublicationStatus> value) { 3143 this.status = value; 3144 return this; 3145 } 3146 3147 /** 3148 * @return The date (and optionally time) when the code system resource was created or revised. 3149 */ 3150 public PublicationStatus getStatus() { 3151 return this.status == null ? null : this.status.getValue(); 3152 } 3153 3154 /** 3155 * @param value The date (and optionally time) when the code system resource was created or revised. 3156 */ 3157 public CodeSystem setStatus(PublicationStatus value) { 3158 if (this.status == null) 3159 this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); 3160 this.status.setValue(value); 3161 return this; 3162 } 3163 3164 /** 3165 * @return {@link #experimental} (A Boolean value to indicate that this code system is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.). This is the underlying object with id, value and extensions. The accessor "getExperimental" gives direct access to the value 3166 */ 3167 public BooleanType getExperimentalElement() { 3168 if (this.experimental == null) 3169 if (Configuration.errorOnAutoCreate()) 3170 throw new Error("Attempt to auto-create CodeSystem.experimental"); 3171 else if (Configuration.doAutoCreate()) 3172 this.experimental = new BooleanType(); // bb 3173 return this.experimental; 3174 } 3175 3176 public boolean hasExperimentalElement() { 3177 return this.experimental != null && !this.experimental.isEmpty(); 3178 } 3179 3180 public boolean hasExperimental() { 3181 return this.experimental != null && !this.experimental.isEmpty(); 3182 } 3183 3184 /** 3185 * @param value {@link #experimental} (A Boolean value to indicate that this code system is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.). This is the underlying object with id, value and extensions. The accessor "getExperimental" gives direct access to the value 3186 */ 3187 public CodeSystem setExperimentalElement(BooleanType value) { 3188 this.experimental = value; 3189 return this; 3190 } 3191 3192 /** 3193 * @return A Boolean value to indicate that this code system is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage. 3194 */ 3195 public boolean getExperimental() { 3196 return this.experimental == null || this.experimental.isEmpty() ? false : this.experimental.getValue(); 3197 } 3198 3199 /** 3200 * @param value A Boolean value to indicate that this code system is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage. 3201 */ 3202 public CodeSystem setExperimental(boolean value) { 3203 if (this.experimental == null) 3204 this.experimental = new BooleanType(); 3205 this.experimental.setValue(value); 3206 return this; 3207 } 3208 3209 /** 3210 * @return {@link #date} (The date (and optionally time) when the code system was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the code system changes.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value 3211 */ 3212 public DateTimeType getDateElement() { 3213 if (this.date == null) 3214 if (Configuration.errorOnAutoCreate()) 3215 throw new Error("Attempt to auto-create CodeSystem.date"); 3216 else if (Configuration.doAutoCreate()) 3217 this.date = new DateTimeType(); // bb 3218 return this.date; 3219 } 3220 3221 public boolean hasDateElement() { 3222 return this.date != null && !this.date.isEmpty(); 3223 } 3224 3225 public boolean hasDate() { 3226 return this.date != null && !this.date.isEmpty(); 3227 } 3228 3229 /** 3230 * @param value {@link #date} (The date (and optionally time) when the code system was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the code system changes.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value 3231 */ 3232 public CodeSystem setDateElement(DateTimeType value) { 3233 this.date = value; 3234 return this; 3235 } 3236 3237 /** 3238 * @return The date (and optionally time) when the code system was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the code system changes. 3239 */ 3240 public Date getDate() { 3241 return this.date == null ? null : this.date.getValue(); 3242 } 3243 3244 /** 3245 * @param value The date (and optionally time) when the code system was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the code system changes. 3246 */ 3247 public CodeSystem setDate(Date value) { 3248 if (value == null) 3249 this.date = null; 3250 else { 3251 if (this.date == null) 3252 this.date = new DateTimeType(); 3253 this.date.setValue(value); 3254 } 3255 return this; 3256 } 3257 3258 /** 3259 * @return {@link #publisher} (The name of the organization or individual that published the code system.). This is the underlying object with id, value and extensions. The accessor "getPublisher" gives direct access to the value 3260 */ 3261 public StringType getPublisherElement() { 3262 if (this.publisher == null) 3263 if (Configuration.errorOnAutoCreate()) 3264 throw new Error("Attempt to auto-create CodeSystem.publisher"); 3265 else if (Configuration.doAutoCreate()) 3266 this.publisher = new StringType(); // bb 3267 return this.publisher; 3268 } 3269 3270 public boolean hasPublisherElement() { 3271 return this.publisher != null && !this.publisher.isEmpty(); 3272 } 3273 3274 public boolean hasPublisher() { 3275 return this.publisher != null && !this.publisher.isEmpty(); 3276 } 3277 3278 /** 3279 * @param value {@link #publisher} (The name of the organization or individual that published the code system.). This is the underlying object with id, value and extensions. The accessor "getPublisher" gives direct access to the value 3280 */ 3281 public CodeSystem setPublisherElement(StringType value) { 3282 this.publisher = value; 3283 return this; 3284 } 3285 3286 /** 3287 * @return The name of the organization or individual that published the code system. 3288 */ 3289 public String getPublisher() { 3290 return this.publisher == null ? null : this.publisher.getValue(); 3291 } 3292 3293 /** 3294 * @param value The name of the organization or individual that published the code system. 3295 */ 3296 public CodeSystem setPublisher(String value) { 3297 if (Utilities.noString(value)) 3298 this.publisher = null; 3299 else { 3300 if (this.publisher == null) 3301 this.publisher = new StringType(); 3302 this.publisher.setValue(value); 3303 } 3304 return this; 3305 } 3306 3307 /** 3308 * @return {@link #contact} (Contact details to assist a user in finding and communicating with the publisher.) 3309 */ 3310 public List<ContactDetail> getContact() { 3311 if (this.contact == null) 3312 this.contact = new ArrayList<ContactDetail>(); 3313 return this.contact; 3314 } 3315 3316 /** 3317 * @return Returns a reference to <code>this</code> for easy method chaining 3318 */ 3319 public CodeSystem setContact(List<ContactDetail> theContact) { 3320 this.contact = theContact; 3321 return this; 3322 } 3323 3324 public boolean hasContact() { 3325 if (this.contact == null) 3326 return false; 3327 for (ContactDetail item : this.contact) 3328 if (!item.isEmpty()) 3329 return true; 3330 return false; 3331 } 3332 3333 public ContactDetail addContact() { //3 3334 ContactDetail t = new ContactDetail(); 3335 if (this.contact == null) 3336 this.contact = new ArrayList<ContactDetail>(); 3337 this.contact.add(t); 3338 return t; 3339 } 3340 3341 public CodeSystem addContact(ContactDetail t) { //3 3342 if (t == null) 3343 return this; 3344 if (this.contact == null) 3345 this.contact = new ArrayList<ContactDetail>(); 3346 this.contact.add(t); 3347 return this; 3348 } 3349 3350 /** 3351 * @return The first repetition of repeating field {@link #contact}, creating it if it does not already exist 3352 */ 3353 public ContactDetail getContactFirstRep() { 3354 if (getContact().isEmpty()) { 3355 addContact(); 3356 } 3357 return getContact().get(0); 3358 } 3359 3360 /** 3361 * @return {@link #description} (A free text natural language description of the code system from a consumer's perspective.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 3362 */ 3363 public MarkdownType getDescriptionElement() { 3364 if (this.description == null) 3365 if (Configuration.errorOnAutoCreate()) 3366 throw new Error("Attempt to auto-create CodeSystem.description"); 3367 else if (Configuration.doAutoCreate()) 3368 this.description = new MarkdownType(); // bb 3369 return this.description; 3370 } 3371 3372 public boolean hasDescriptionElement() { 3373 return this.description != null && !this.description.isEmpty(); 3374 } 3375 3376 public boolean hasDescription() { 3377 return this.description != null && !this.description.isEmpty(); 3378 } 3379 3380 /** 3381 * @param value {@link #description} (A free text natural language description of the code system from a consumer's perspective.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 3382 */ 3383 public CodeSystem setDescriptionElement(MarkdownType value) { 3384 this.description = value; 3385 return this; 3386 } 3387 3388 /** 3389 * @return A free text natural language description of the code system from a consumer's perspective. 3390 */ 3391 public String getDescription() { 3392 return this.description == null ? null : this.description.getValue(); 3393 } 3394 3395 /** 3396 * @param value A free text natural language description of the code system from a consumer's perspective. 3397 */ 3398 public CodeSystem setDescription(String value) { 3399 if (value == null) 3400 this.description = null; 3401 else { 3402 if (this.description == null) 3403 this.description = new MarkdownType(); 3404 this.description.setValue(value); 3405 } 3406 return this; 3407 } 3408 3409 /** 3410 * @return {@link #useContext} (The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate code system instances.) 3411 */ 3412 public List<UsageContext> getUseContext() { 3413 if (this.useContext == null) 3414 this.useContext = new ArrayList<UsageContext>(); 3415 return this.useContext; 3416 } 3417 3418 /** 3419 * @return Returns a reference to <code>this</code> for easy method chaining 3420 */ 3421 public CodeSystem setUseContext(List<UsageContext> theUseContext) { 3422 this.useContext = theUseContext; 3423 return this; 3424 } 3425 3426 public boolean hasUseContext() { 3427 if (this.useContext == null) 3428 return false; 3429 for (UsageContext item : this.useContext) 3430 if (!item.isEmpty()) 3431 return true; 3432 return false; 3433 } 3434 3435 public UsageContext addUseContext() { //3 3436 UsageContext t = new UsageContext(); 3437 if (this.useContext == null) 3438 this.useContext = new ArrayList<UsageContext>(); 3439 this.useContext.add(t); 3440 return t; 3441 } 3442 3443 public CodeSystem addUseContext(UsageContext t) { //3 3444 if (t == null) 3445 return this; 3446 if (this.useContext == null) 3447 this.useContext = new ArrayList<UsageContext>(); 3448 this.useContext.add(t); 3449 return this; 3450 } 3451 3452 /** 3453 * @return The first repetition of repeating field {@link #useContext}, creating it if it does not already exist 3454 */ 3455 public UsageContext getUseContextFirstRep() { 3456 if (getUseContext().isEmpty()) { 3457 addUseContext(); 3458 } 3459 return getUseContext().get(0); 3460 } 3461 3462 /** 3463 * @return {@link #jurisdiction} (A legal or geographic region in which the code system is intended to be used.) 3464 */ 3465 public List<CodeableConcept> getJurisdiction() { 3466 if (this.jurisdiction == null) 3467 this.jurisdiction = new ArrayList<CodeableConcept>(); 3468 return this.jurisdiction; 3469 } 3470 3471 /** 3472 * @return Returns a reference to <code>this</code> for easy method chaining 3473 */ 3474 public CodeSystem setJurisdiction(List<CodeableConcept> theJurisdiction) { 3475 this.jurisdiction = theJurisdiction; 3476 return this; 3477 } 3478 3479 public boolean hasJurisdiction() { 3480 if (this.jurisdiction == null) 3481 return false; 3482 for (CodeableConcept item : this.jurisdiction) 3483 if (!item.isEmpty()) 3484 return true; 3485 return false; 3486 } 3487 3488 public CodeableConcept addJurisdiction() { //3 3489 CodeableConcept t = new CodeableConcept(); 3490 if (this.jurisdiction == null) 3491 this.jurisdiction = new ArrayList<CodeableConcept>(); 3492 this.jurisdiction.add(t); 3493 return t; 3494 } 3495 3496 public CodeSystem addJurisdiction(CodeableConcept t) { //3 3497 if (t == null) 3498 return this; 3499 if (this.jurisdiction == null) 3500 this.jurisdiction = new ArrayList<CodeableConcept>(); 3501 this.jurisdiction.add(t); 3502 return this; 3503 } 3504 3505 /** 3506 * @return The first repetition of repeating field {@link #jurisdiction}, creating it if it does not already exist 3507 */ 3508 public CodeableConcept getJurisdictionFirstRep() { 3509 if (getJurisdiction().isEmpty()) { 3510 addJurisdiction(); 3511 } 3512 return getJurisdiction().get(0); 3513 } 3514 3515 /** 3516 * @return {@link #purpose} (Explanation of why this code system is needed and why it has been designed as it has.). This is the underlying object with id, value and extensions. The accessor "getPurpose" gives direct access to the value 3517 */ 3518 public MarkdownType getPurposeElement() { 3519 if (this.purpose == null) 3520 if (Configuration.errorOnAutoCreate()) 3521 throw new Error("Attempt to auto-create CodeSystem.purpose"); 3522 else if (Configuration.doAutoCreate()) 3523 this.purpose = new MarkdownType(); // bb 3524 return this.purpose; 3525 } 3526 3527 public boolean hasPurposeElement() { 3528 return this.purpose != null && !this.purpose.isEmpty(); 3529 } 3530 3531 public boolean hasPurpose() { 3532 return this.purpose != null && !this.purpose.isEmpty(); 3533 } 3534 3535 /** 3536 * @param value {@link #purpose} (Explanation of why this code system is needed and why it has been designed as it has.). This is the underlying object with id, value and extensions. The accessor "getPurpose" gives direct access to the value 3537 */ 3538 public CodeSystem setPurposeElement(MarkdownType value) { 3539 this.purpose = value; 3540 return this; 3541 } 3542 3543 /** 3544 * @return Explanation of why this code system is needed and why it has been designed as it has. 3545 */ 3546 public String getPurpose() { 3547 return this.purpose == null ? null : this.purpose.getValue(); 3548 } 3549 3550 /** 3551 * @param value Explanation of why this code system is needed and why it has been designed as it has. 3552 */ 3553 public CodeSystem setPurpose(String value) { 3554 if (value == null) 3555 this.purpose = null; 3556 else { 3557 if (this.purpose == null) 3558 this.purpose = new MarkdownType(); 3559 this.purpose.setValue(value); 3560 } 3561 return this; 3562 } 3563 3564 /** 3565 * @return {@link #copyright} (A copyright statement relating to the code system and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the code system.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value 3566 */ 3567 public MarkdownType getCopyrightElement() { 3568 if (this.copyright == null) 3569 if (Configuration.errorOnAutoCreate()) 3570 throw new Error("Attempt to auto-create CodeSystem.copyright"); 3571 else if (Configuration.doAutoCreate()) 3572 this.copyright = new MarkdownType(); // bb 3573 return this.copyright; 3574 } 3575 3576 public boolean hasCopyrightElement() { 3577 return this.copyright != null && !this.copyright.isEmpty(); 3578 } 3579 3580 public boolean hasCopyright() { 3581 return this.copyright != null && !this.copyright.isEmpty(); 3582 } 3583 3584 /** 3585 * @param value {@link #copyright} (A copyright statement relating to the code system and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the code system.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value 3586 */ 3587 public CodeSystem setCopyrightElement(MarkdownType value) { 3588 this.copyright = value; 3589 return this; 3590 } 3591 3592 /** 3593 * @return A copyright statement relating to the code system and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the code system. 3594 */ 3595 public String getCopyright() { 3596 return this.copyright == null ? null : this.copyright.getValue(); 3597 } 3598 3599 /** 3600 * @param value A copyright statement relating to the code system and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the code system. 3601 */ 3602 public CodeSystem setCopyright(String value) { 3603 if (value == null) 3604 this.copyright = null; 3605 else { 3606 if (this.copyright == null) 3607 this.copyright = new MarkdownType(); 3608 this.copyright.setValue(value); 3609 } 3610 return this; 3611 } 3612 3613 /** 3614 * @return {@link #caseSensitive} (If code comparison is case sensitive when codes within this system are compared to each other.). This is the underlying object with id, value and extensions. The accessor "getCaseSensitive" gives direct access to the value 3615 */ 3616 public BooleanType getCaseSensitiveElement() { 3617 if (this.caseSensitive == null) 3618 if (Configuration.errorOnAutoCreate()) 3619 throw new Error("Attempt to auto-create CodeSystem.caseSensitive"); 3620 else if (Configuration.doAutoCreate()) 3621 this.caseSensitive = new BooleanType(); // bb 3622 return this.caseSensitive; 3623 } 3624 3625 public boolean hasCaseSensitiveElement() { 3626 return this.caseSensitive != null && !this.caseSensitive.isEmpty(); 3627 } 3628 3629 public boolean hasCaseSensitive() { 3630 return this.caseSensitive != null && !this.caseSensitive.isEmpty(); 3631 } 3632 3633 /** 3634 * @param value {@link #caseSensitive} (If code comparison is case sensitive when codes within this system are compared to each other.). This is the underlying object with id, value and extensions. The accessor "getCaseSensitive" gives direct access to the value 3635 */ 3636 public CodeSystem setCaseSensitiveElement(BooleanType value) { 3637 this.caseSensitive = value; 3638 return this; 3639 } 3640 3641 /** 3642 * @return If code comparison is case sensitive when codes within this system are compared to each other. 3643 */ 3644 public boolean getCaseSensitive() { 3645 return this.caseSensitive == null || this.caseSensitive.isEmpty() ? false : this.caseSensitive.getValue(); 3646 } 3647 3648 /** 3649 * @param value If code comparison is case sensitive when codes within this system are compared to each other. 3650 */ 3651 public CodeSystem setCaseSensitive(boolean value) { 3652 if (this.caseSensitive == null) 3653 this.caseSensitive = new BooleanType(); 3654 this.caseSensitive.setValue(value); 3655 return this; 3656 } 3657 3658 /** 3659 * @return {@link #valueSet} (Canonical reference to the value set that contains the entire code system.). This is the underlying object with id, value and extensions. The accessor "getValueSet" gives direct access to the value 3660 */ 3661 public CanonicalType getValueSetElement() { 3662 if (this.valueSet == null) 3663 if (Configuration.errorOnAutoCreate()) 3664 throw new Error("Attempt to auto-create CodeSystem.valueSet"); 3665 else if (Configuration.doAutoCreate()) 3666 this.valueSet = new CanonicalType(); // bb 3667 return this.valueSet; 3668 } 3669 3670 public boolean hasValueSetElement() { 3671 return this.valueSet != null && !this.valueSet.isEmpty(); 3672 } 3673 3674 public boolean hasValueSet() { 3675 return this.valueSet != null && !this.valueSet.isEmpty(); 3676 } 3677 3678 /** 3679 * @param value {@link #valueSet} (Canonical reference to the value set that contains the entire code system.). This is the underlying object with id, value and extensions. The accessor "getValueSet" gives direct access to the value 3680 */ 3681 public CodeSystem setValueSetElement(CanonicalType value) { 3682 this.valueSet = value; 3683 return this; 3684 } 3685 3686 /** 3687 * @return Canonical reference to the value set that contains the entire code system. 3688 */ 3689 public String getValueSet() { 3690 return this.valueSet == null ? null : this.valueSet.getValue(); 3691 } 3692 3693 /** 3694 * @param value Canonical reference to the value set that contains the entire code system. 3695 */ 3696 public CodeSystem setValueSet(String value) { 3697 if (Utilities.noString(value)) 3698 this.valueSet = null; 3699 else { 3700 if (this.valueSet == null) 3701 this.valueSet = new CanonicalType(); 3702 this.valueSet.setValue(value); 3703 } 3704 return this; 3705 } 3706 3707 /** 3708 * @return {@link #hierarchyMeaning} (The meaning of the hierarchy of concepts as represented in this resource.). This is the underlying object with id, value and extensions. The accessor "getHierarchyMeaning" gives direct access to the value 3709 */ 3710 public Enumeration<CodeSystemHierarchyMeaning> getHierarchyMeaningElement() { 3711 if (this.hierarchyMeaning == null) 3712 if (Configuration.errorOnAutoCreate()) 3713 throw new Error("Attempt to auto-create CodeSystem.hierarchyMeaning"); 3714 else if (Configuration.doAutoCreate()) 3715 this.hierarchyMeaning = new Enumeration<CodeSystemHierarchyMeaning>(new CodeSystemHierarchyMeaningEnumFactory()); // bb 3716 return this.hierarchyMeaning; 3717 } 3718 3719 public boolean hasHierarchyMeaningElement() { 3720 return this.hierarchyMeaning != null && !this.hierarchyMeaning.isEmpty(); 3721 } 3722 3723 public boolean hasHierarchyMeaning() { 3724 return this.hierarchyMeaning != null && !this.hierarchyMeaning.isEmpty(); 3725 } 3726 3727 /** 3728 * @param value {@link #hierarchyMeaning} (The meaning of the hierarchy of concepts as represented in this resource.). This is the underlying object with id, value and extensions. The accessor "getHierarchyMeaning" gives direct access to the value 3729 */ 3730 public CodeSystem setHierarchyMeaningElement(Enumeration<CodeSystemHierarchyMeaning> value) { 3731 this.hierarchyMeaning = value; 3732 return this; 3733 } 3734 3735 /** 3736 * @return The meaning of the hierarchy of concepts as represented in this resource. 3737 */ 3738 public CodeSystemHierarchyMeaning getHierarchyMeaning() { 3739 return this.hierarchyMeaning == null ? null : this.hierarchyMeaning.getValue(); 3740 } 3741 3742 /** 3743 * @param value The meaning of the hierarchy of concepts as represented in this resource. 3744 */ 3745 public CodeSystem setHierarchyMeaning(CodeSystemHierarchyMeaning value) { 3746 if (value == null) 3747 this.hierarchyMeaning = null; 3748 else { 3749 if (this.hierarchyMeaning == null) 3750 this.hierarchyMeaning = new Enumeration<CodeSystemHierarchyMeaning>(new CodeSystemHierarchyMeaningEnumFactory()); 3751 this.hierarchyMeaning.setValue(value); 3752 } 3753 return this; 3754 } 3755 3756 /** 3757 * @return {@link #compositional} (The code system defines a compositional (post-coordination) grammar.). This is the underlying object with id, value and extensions. The accessor "getCompositional" gives direct access to the value 3758 */ 3759 public BooleanType getCompositionalElement() { 3760 if (this.compositional == null) 3761 if (Configuration.errorOnAutoCreate()) 3762 throw new Error("Attempt to auto-create CodeSystem.compositional"); 3763 else if (Configuration.doAutoCreate()) 3764 this.compositional = new BooleanType(); // bb 3765 return this.compositional; 3766 } 3767 3768 public boolean hasCompositionalElement() { 3769 return this.compositional != null && !this.compositional.isEmpty(); 3770 } 3771 3772 public boolean hasCompositional() { 3773 return this.compositional != null && !this.compositional.isEmpty(); 3774 } 3775 3776 /** 3777 * @param value {@link #compositional} (The code system defines a compositional (post-coordination) grammar.). This is the underlying object with id, value and extensions. The accessor "getCompositional" gives direct access to the value 3778 */ 3779 public CodeSystem setCompositionalElement(BooleanType value) { 3780 this.compositional = value; 3781 return this; 3782 } 3783 3784 /** 3785 * @return The code system defines a compositional (post-coordination) grammar. 3786 */ 3787 public boolean getCompositional() { 3788 return this.compositional == null || this.compositional.isEmpty() ? false : this.compositional.getValue(); 3789 } 3790 3791 /** 3792 * @param value The code system defines a compositional (post-coordination) grammar. 3793 */ 3794 public CodeSystem setCompositional(boolean value) { 3795 if (this.compositional == null) 3796 this.compositional = new BooleanType(); 3797 this.compositional.setValue(value); 3798 return this; 3799 } 3800 3801 /** 3802 * @return {@link #versionNeeded} (This flag is used to signify that the code system does not commit to concept permanence across versions. If true, a version must be specified when referencing this code system.). This is the underlying object with id, value and extensions. The accessor "getVersionNeeded" gives direct access to the value 3803 */ 3804 public BooleanType getVersionNeededElement() { 3805 if (this.versionNeeded == null) 3806 if (Configuration.errorOnAutoCreate()) 3807 throw new Error("Attempt to auto-create CodeSystem.versionNeeded"); 3808 else if (Configuration.doAutoCreate()) 3809 this.versionNeeded = new BooleanType(); // bb 3810 return this.versionNeeded; 3811 } 3812 3813 public boolean hasVersionNeededElement() { 3814 return this.versionNeeded != null && !this.versionNeeded.isEmpty(); 3815 } 3816 3817 public boolean hasVersionNeeded() { 3818 return this.versionNeeded != null && !this.versionNeeded.isEmpty(); 3819 } 3820 3821 /** 3822 * @param value {@link #versionNeeded} (This flag is used to signify that the code system does not commit to concept permanence across versions. If true, a version must be specified when referencing this code system.). This is the underlying object with id, value and extensions. The accessor "getVersionNeeded" gives direct access to the value 3823 */ 3824 public CodeSystem setVersionNeededElement(BooleanType value) { 3825 this.versionNeeded = value; 3826 return this; 3827 } 3828 3829 /** 3830 * @return This flag is used to signify that the code system does not commit to concept permanence across versions. If true, a version must be specified when referencing this code system. 3831 */ 3832 public boolean getVersionNeeded() { 3833 return this.versionNeeded == null || this.versionNeeded.isEmpty() ? false : this.versionNeeded.getValue(); 3834 } 3835 3836 /** 3837 * @param value This flag is used to signify that the code system does not commit to concept permanence across versions. If true, a version must be specified when referencing this code system. 3838 */ 3839 public CodeSystem setVersionNeeded(boolean value) { 3840 if (this.versionNeeded == null) 3841 this.versionNeeded = new BooleanType(); 3842 this.versionNeeded.setValue(value); 3843 return this; 3844 } 3845 3846 /** 3847 * @return {@link #content} (The extent of the content of the code system (the concepts and codes it defines) are represented in this resource instance.). This is the underlying object with id, value and extensions. The accessor "getContent" gives direct access to the value 3848 */ 3849 public Enumeration<CodeSystemContentMode> getContentElement() { 3850 if (this.content == null) 3851 if (Configuration.errorOnAutoCreate()) 3852 throw new Error("Attempt to auto-create CodeSystem.content"); 3853 else if (Configuration.doAutoCreate()) 3854 this.content = new Enumeration<CodeSystemContentMode>(new CodeSystemContentModeEnumFactory()); // bb 3855 return this.content; 3856 } 3857 3858 public boolean hasContentElement() { 3859 return this.content != null && !this.content.isEmpty(); 3860 } 3861 3862 public boolean hasContent() { 3863 return this.content != null && !this.content.isEmpty(); 3864 } 3865 3866 /** 3867 * @param value {@link #content} (The extent of the content of the code system (the concepts and codes it defines) are represented in this resource instance.). This is the underlying object with id, value and extensions. The accessor "getContent" gives direct access to the value 3868 */ 3869 public CodeSystem setContentElement(Enumeration<CodeSystemContentMode> value) { 3870 this.content = value; 3871 return this; 3872 } 3873 3874 /** 3875 * @return The extent of the content of the code system (the concepts and codes it defines) are represented in this resource instance. 3876 */ 3877 public CodeSystemContentMode getContent() { 3878 return this.content == null ? null : this.content.getValue(); 3879 } 3880 3881 /** 3882 * @param value The extent of the content of the code system (the concepts and codes it defines) are represented in this resource instance. 3883 */ 3884 public CodeSystem setContent(CodeSystemContentMode value) { 3885 if (this.content == null) 3886 this.content = new Enumeration<CodeSystemContentMode>(new CodeSystemContentModeEnumFactory()); 3887 this.content.setValue(value); 3888 return this; 3889 } 3890 3891 /** 3892 * @return {@link #supplements} (The canonical URL of the code system that this code system supplement is adding designations and properties to.). This is the underlying object with id, value and extensions. The accessor "getSupplements" gives direct access to the value 3893 */ 3894 public CanonicalType getSupplementsElement() { 3895 if (this.supplements == null) 3896 if (Configuration.errorOnAutoCreate()) 3897 throw new Error("Attempt to auto-create CodeSystem.supplements"); 3898 else if (Configuration.doAutoCreate()) 3899 this.supplements = new CanonicalType(); // bb 3900 return this.supplements; 3901 } 3902 3903 public boolean hasSupplementsElement() { 3904 return this.supplements != null && !this.supplements.isEmpty(); 3905 } 3906 3907 public boolean hasSupplements() { 3908 return this.supplements != null && !this.supplements.isEmpty(); 3909 } 3910 3911 /** 3912 * @param value {@link #supplements} (The canonical URL of the code system that this code system supplement is adding designations and properties to.). This is the underlying object with id, value and extensions. The accessor "getSupplements" gives direct access to the value 3913 */ 3914 public CodeSystem setSupplementsElement(CanonicalType value) { 3915 this.supplements = value; 3916 return this; 3917 } 3918 3919 /** 3920 * @return The canonical URL of the code system that this code system supplement is adding designations and properties to. 3921 */ 3922 public String getSupplements() { 3923 return this.supplements == null ? null : this.supplements.getValue(); 3924 } 3925 3926 /** 3927 * @param value The canonical URL of the code system that this code system supplement is adding designations and properties to. 3928 */ 3929 public CodeSystem setSupplements(String value) { 3930 if (Utilities.noString(value)) 3931 this.supplements = null; 3932 else { 3933 if (this.supplements == null) 3934 this.supplements = new CanonicalType(); 3935 this.supplements.setValue(value); 3936 } 3937 return this; 3938 } 3939 3940 /** 3941 * @return {@link #count} (The total number of concepts defined by the code system. Where the code system has a compositional grammar, the basis of this count is defined by the system steward.). This is the underlying object with id, value and extensions. The accessor "getCount" gives direct access to the value 3942 */ 3943 public UnsignedIntType getCountElement() { 3944 if (this.count == null) 3945 if (Configuration.errorOnAutoCreate()) 3946 throw new Error("Attempt to auto-create CodeSystem.count"); 3947 else if (Configuration.doAutoCreate()) 3948 this.count = new UnsignedIntType(); // bb 3949 return this.count; 3950 } 3951 3952 public boolean hasCountElement() { 3953 return this.count != null && !this.count.isEmpty(); 3954 } 3955 3956 public boolean hasCount() { 3957 return this.count != null && !this.count.isEmpty(); 3958 } 3959 3960 /** 3961 * @param value {@link #count} (The total number of concepts defined by the code system. Where the code system has a compositional grammar, the basis of this count is defined by the system steward.). This is the underlying object with id, value and extensions. The accessor "getCount" gives direct access to the value 3962 */ 3963 public CodeSystem setCountElement(UnsignedIntType value) { 3964 this.count = value; 3965 return this; 3966 } 3967 3968 /** 3969 * @return The total number of concepts defined by the code system. Where the code system has a compositional grammar, the basis of this count is defined by the system steward. 3970 */ 3971 public int getCount() { 3972 return this.count == null || this.count.isEmpty() ? 0 : this.count.getValue(); 3973 } 3974 3975 /** 3976 * @param value The total number of concepts defined by the code system. Where the code system has a compositional grammar, the basis of this count is defined by the system steward. 3977 */ 3978 public CodeSystem setCount(int value) { 3979 if (this.count == null) 3980 this.count = new UnsignedIntType(); 3981 this.count.setValue(value); 3982 return this; 3983 } 3984 3985 /** 3986 * @return {@link #filter} (A filter that can be used in a value set compose statement when selecting concepts using a filter.) 3987 */ 3988 public List<CodeSystemFilterComponent> getFilter() { 3989 if (this.filter == null) 3990 this.filter = new ArrayList<CodeSystemFilterComponent>(); 3991 return this.filter; 3992 } 3993 3994 /** 3995 * @return Returns a reference to <code>this</code> for easy method chaining 3996 */ 3997 public CodeSystem setFilter(List<CodeSystemFilterComponent> theFilter) { 3998 this.filter = theFilter; 3999 return this; 4000 } 4001 4002 public boolean hasFilter() { 4003 if (this.filter == null) 4004 return false; 4005 for (CodeSystemFilterComponent item : this.filter) 4006 if (!item.isEmpty()) 4007 return true; 4008 return false; 4009 } 4010 4011 public CodeSystemFilterComponent addFilter() { //3 4012 CodeSystemFilterComponent t = new CodeSystemFilterComponent(); 4013 if (this.filter == null) 4014 this.filter = new ArrayList<CodeSystemFilterComponent>(); 4015 this.filter.add(t); 4016 return t; 4017 } 4018 4019 public CodeSystem addFilter(CodeSystemFilterComponent t) { //3 4020 if (t == null) 4021 return this; 4022 if (this.filter == null) 4023 this.filter = new ArrayList<CodeSystemFilterComponent>(); 4024 this.filter.add(t); 4025 return this; 4026 } 4027 4028 /** 4029 * @return The first repetition of repeating field {@link #filter}, creating it if it does not already exist 4030 */ 4031 public CodeSystemFilterComponent getFilterFirstRep() { 4032 if (getFilter().isEmpty()) { 4033 addFilter(); 4034 } 4035 return getFilter().get(0); 4036 } 4037 4038 /** 4039 * @return {@link #property} (A property defines an additional slot through which additional information can be provided about a concept.) 4040 */ 4041 public List<PropertyComponent> getProperty() { 4042 if (this.property == null) 4043 this.property = new ArrayList<PropertyComponent>(); 4044 return this.property; 4045 } 4046 4047 /** 4048 * @return Returns a reference to <code>this</code> for easy method chaining 4049 */ 4050 public CodeSystem setProperty(List<PropertyComponent> theProperty) { 4051 this.property = theProperty; 4052 return this; 4053 } 4054 4055 public boolean hasProperty() { 4056 if (this.property == null) 4057 return false; 4058 for (PropertyComponent item : this.property) 4059 if (!item.isEmpty()) 4060 return true; 4061 return false; 4062 } 4063 4064 public PropertyComponent addProperty() { //3 4065 PropertyComponent t = new PropertyComponent(); 4066 if (this.property == null) 4067 this.property = new ArrayList<PropertyComponent>(); 4068 this.property.add(t); 4069 return t; 4070 } 4071 4072 public CodeSystem addProperty(PropertyComponent t) { //3 4073 if (t == null) 4074 return this; 4075 if (this.property == null) 4076 this.property = new ArrayList<PropertyComponent>(); 4077 this.property.add(t); 4078 return this; 4079 } 4080 4081 /** 4082 * @return The first repetition of repeating field {@link #property}, creating it if it does not already exist 4083 */ 4084 public PropertyComponent getPropertyFirstRep() { 4085 if (getProperty().isEmpty()) { 4086 addProperty(); 4087 } 4088 return getProperty().get(0); 4089 } 4090 4091 /** 4092 * @return {@link #concept} (Concepts that are in the code system. The concept definitions are inherently hierarchical, but the definitions must be consulted to determine what the meanings of the hierarchical relationships are.) 4093 */ 4094 public List<ConceptDefinitionComponent> getConcept() { 4095 if (this.concept == null) 4096 this.concept = new ArrayList<ConceptDefinitionComponent>(); 4097 return this.concept; 4098 } 4099 4100 /** 4101 * @return Returns a reference to <code>this</code> for easy method chaining 4102 */ 4103 public CodeSystem setConcept(List<ConceptDefinitionComponent> theConcept) { 4104 this.concept = theConcept; 4105 return this; 4106 } 4107 4108 public boolean hasConcept() { 4109 if (this.concept == null) 4110 return false; 4111 for (ConceptDefinitionComponent item : this.concept) 4112 if (!item.isEmpty()) 4113 return true; 4114 return false; 4115 } 4116 4117 public ConceptDefinitionComponent addConcept() { //3 4118 ConceptDefinitionComponent t = new ConceptDefinitionComponent(); 4119 if (this.concept == null) 4120 this.concept = new ArrayList<ConceptDefinitionComponent>(); 4121 this.concept.add(t); 4122 return t; 4123 } 4124 4125 public CodeSystem addConcept(ConceptDefinitionComponent t) { //3 4126 if (t == null) 4127 return this; 4128 if (this.concept == null) 4129 this.concept = new ArrayList<ConceptDefinitionComponent>(); 4130 this.concept.add(t); 4131 return this; 4132 } 4133 4134 /** 4135 * @return The first repetition of repeating field {@link #concept}, creating it if it does not already exist 4136 */ 4137 public ConceptDefinitionComponent getConceptFirstRep() { 4138 if (getConcept().isEmpty()) { 4139 addConcept(); 4140 } 4141 return getConcept().get(0); 4142 } 4143 4144 protected void listChildren(List<Property> children) { 4145 super.listChildren(children); 4146 children.add(new Property("url", "uri", "An absolute URI that is used to identify this code system when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this code system is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the code system is stored on different servers. This is used in [Coding](datatypes.html#Coding).system.", 0, 1, url)); 4147 children.add(new Property("identifier", "Identifier", "A formal identifier that is used to identify this code system when it is represented in other formats, or referenced in a specification, model, design or an instance.", 0, java.lang.Integer.MAX_VALUE, identifier)); 4148 children.add(new Property("version", "string", "The identifier that is used to identify this version of the code system when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the code system author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. This is used in [Coding](datatypes.html#Coding).version.", 0, 1, version)); 4149 children.add(new Property("name", "string", "A natural language name identifying the code system. This name should be usable as an identifier for the module by machine processing applications such as code generation.", 0, 1, name)); 4150 children.add(new Property("title", "string", "A short, descriptive, user-friendly title for the code system.", 0, 1, title)); 4151 children.add(new Property("status", "code", "The date (and optionally time) when the code system resource was created or revised.", 0, 1, status)); 4152 children.add(new Property("experimental", "boolean", "A Boolean value to indicate that this code system is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.", 0, 1, experimental)); 4153 children.add(new Property("date", "dateTime", "The date (and optionally time) when the code system was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the code system changes.", 0, 1, date)); 4154 children.add(new Property("publisher", "string", "The name of the organization or individual that published the code system.", 0, 1, publisher)); 4155 children.add(new Property("contact", "ContactDetail", "Contact details to assist a user in finding and communicating with the publisher.", 0, java.lang.Integer.MAX_VALUE, contact)); 4156 children.add(new Property("description", "markdown", "A free text natural language description of the code system from a consumer's perspective.", 0, 1, description)); 4157 children.add(new Property("useContext", "UsageContext", "The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate code system instances.", 0, java.lang.Integer.MAX_VALUE, useContext)); 4158 children.add(new Property("jurisdiction", "CodeableConcept", "A legal or geographic region in which the code system is intended to be used.", 0, java.lang.Integer.MAX_VALUE, jurisdiction)); 4159 children.add(new Property("purpose", "markdown", "Explanation of why this code system is needed and why it has been designed as it has.", 0, 1, purpose)); 4160 children.add(new Property("copyright", "markdown", "A copyright statement relating to the code system and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the code system.", 0, 1, copyright)); 4161 children.add(new Property("caseSensitive", "boolean", "If code comparison is case sensitive when codes within this system are compared to each other.", 0, 1, caseSensitive)); 4162 children.add(new Property("valueSet", "canonical(ValueSet)", "Canonical reference to the value set that contains the entire code system.", 0, 1, valueSet)); 4163 children.add(new Property("hierarchyMeaning", "code", "The meaning of the hierarchy of concepts as represented in this resource.", 0, 1, hierarchyMeaning)); 4164 children.add(new Property("compositional", "boolean", "The code system defines a compositional (post-coordination) grammar.", 0, 1, compositional)); 4165 children.add(new Property("versionNeeded", "boolean", "This flag is used to signify that the code system does not commit to concept permanence across versions. If true, a version must be specified when referencing this code system.", 0, 1, versionNeeded)); 4166 children.add(new Property("content", "code", "The extent of the content of the code system (the concepts and codes it defines) are represented in this resource instance.", 0, 1, content)); 4167 children.add(new Property("supplements", "canonical(CodeSystem)", "The canonical URL of the code system that this code system supplement is adding designations and properties to.", 0, 1, supplements)); 4168 children.add(new Property("count", "unsignedInt", "The total number of concepts defined by the code system. Where the code system has a compositional grammar, the basis of this count is defined by the system steward.", 0, 1, count)); 4169 children.add(new Property("filter", "", "A filter that can be used in a value set compose statement when selecting concepts using a filter.", 0, java.lang.Integer.MAX_VALUE, filter)); 4170 children.add(new Property("property", "", "A property defines an additional slot through which additional information can be provided about a concept.", 0, java.lang.Integer.MAX_VALUE, property)); 4171 children.add(new Property("concept", "", "Concepts that are in the code system. The concept definitions are inherently hierarchical, but the definitions must be consulted to determine what the meanings of the hierarchical relationships are.", 0, java.lang.Integer.MAX_VALUE, concept)); 4172 } 4173 4174 @Override 4175 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 4176 switch (_hash) { 4177 case 116079: /*url*/ return new Property("url", "uri", "An absolute URI that is used to identify this code system when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this code system is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the code system is stored on different servers. This is used in [Coding](datatypes.html#Coding).system.", 0, 1, url); 4178 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "A formal identifier that is used to identify this code system when it is represented in other formats, or referenced in a specification, model, design or an instance.", 0, java.lang.Integer.MAX_VALUE, identifier); 4179 case 351608024: /*version*/ return new Property("version", "string", "The identifier that is used to identify this version of the code system when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the code system author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. This is used in [Coding](datatypes.html#Coding).version.", 0, 1, version); 4180 case 3373707: /*name*/ return new Property("name", "string", "A natural language name identifying the code system. This name should be usable as an identifier for the module by machine processing applications such as code generation.", 0, 1, name); 4181 case 110371416: /*title*/ return new Property("title", "string", "A short, descriptive, user-friendly title for the code system.", 0, 1, title); 4182 case -892481550: /*status*/ return new Property("status", "code", "The date (and optionally time) when the code system resource was created or revised.", 0, 1, status); 4183 case -404562712: /*experimental*/ return new Property("experimental", "boolean", "A Boolean value to indicate that this code system is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.", 0, 1, experimental); 4184 case 3076014: /*date*/ return new Property("date", "dateTime", "The date (and optionally time) when the code system was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the code system changes.", 0, 1, date); 4185 case 1447404028: /*publisher*/ return new Property("publisher", "string", "The name of the organization or individual that published the code system.", 0, 1, publisher); 4186 case 951526432: /*contact*/ return new Property("contact", "ContactDetail", "Contact details to assist a user in finding and communicating with the publisher.", 0, java.lang.Integer.MAX_VALUE, contact); 4187 case -1724546052: /*description*/ return new Property("description", "markdown", "A free text natural language description of the code system from a consumer's perspective.", 0, 1, description); 4188 case -669707736: /*useContext*/ return new Property("useContext", "UsageContext", "The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate code system instances.", 0, java.lang.Integer.MAX_VALUE, useContext); 4189 case -507075711: /*jurisdiction*/ return new Property("jurisdiction", "CodeableConcept", "A legal or geographic region in which the code system is intended to be used.", 0, java.lang.Integer.MAX_VALUE, jurisdiction); 4190 case -220463842: /*purpose*/ return new Property("purpose", "markdown", "Explanation of why this code system is needed and why it has been designed as it has.", 0, 1, purpose); 4191 case 1522889671: /*copyright*/ return new Property("copyright", "markdown", "A copyright statement relating to the code system and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the code system.", 0, 1, copyright); 4192 case -35616442: /*caseSensitive*/ return new Property("caseSensitive", "boolean", "If code comparison is case sensitive when codes within this system are compared to each other.", 0, 1, caseSensitive); 4193 case -1410174671: /*valueSet*/ return new Property("valueSet", "canonical(ValueSet)", "Canonical reference to the value set that contains the entire code system.", 0, 1, valueSet); 4194 case 1913078280: /*hierarchyMeaning*/ return new Property("hierarchyMeaning", "code", "The meaning of the hierarchy of concepts as represented in this resource.", 0, 1, hierarchyMeaning); 4195 case 1248023381: /*compositional*/ return new Property("compositional", "boolean", "The code system defines a compositional (post-coordination) grammar.", 0, 1, compositional); 4196 case 617270957: /*versionNeeded*/ return new Property("versionNeeded", "boolean", "This flag is used to signify that the code system does not commit to concept permanence across versions. If true, a version must be specified when referencing this code system.", 0, 1, versionNeeded); 4197 case 951530617: /*content*/ return new Property("content", "code", "The extent of the content of the code system (the concepts and codes it defines) are represented in this resource instance.", 0, 1, content); 4198 case -596951334: /*supplements*/ return new Property("supplements", "canonical(CodeSystem)", "The canonical URL of the code system that this code system supplement is adding designations and properties to.", 0, 1, supplements); 4199 case 94851343: /*count*/ return new Property("count", "unsignedInt", "The total number of concepts defined by the code system. Where the code system has a compositional grammar, the basis of this count is defined by the system steward.", 0, 1, count); 4200 case -1274492040: /*filter*/ return new Property("filter", "", "A filter that can be used in a value set compose statement when selecting concepts using a filter.", 0, java.lang.Integer.MAX_VALUE, filter); 4201 case -993141291: /*property*/ return new Property("property", "", "A property defines an additional slot through which additional information can be provided about a concept.", 0, java.lang.Integer.MAX_VALUE, property); 4202 case 951024232: /*concept*/ return new Property("concept", "", "Concepts that are in the code system. The concept definitions are inherently hierarchical, but the definitions must be consulted to determine what the meanings of the hierarchical relationships are.", 0, java.lang.Integer.MAX_VALUE, concept); 4203 default: return super.getNamedProperty(_hash, _name, _checkValid); 4204 } 4205 4206 } 4207 4208 @Override 4209 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 4210 switch (hash) { 4211 case 116079: /*url*/ return this.url == null ? new Base[0] : new Base[] {this.url}; // UriType 4212 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 4213 case 351608024: /*version*/ return this.version == null ? new Base[0] : new Base[] {this.version}; // StringType 4214 case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType 4215 case 110371416: /*title*/ return this.title == null ? new Base[0] : new Base[] {this.title}; // StringType 4216 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<PublicationStatus> 4217 case -404562712: /*experimental*/ return this.experimental == null ? new Base[0] : new Base[] {this.experimental}; // BooleanType 4218 case 3076014: /*date*/ return this.date == null ? new Base[0] : new Base[] {this.date}; // DateTimeType 4219 case 1447404028: /*publisher*/ return this.publisher == null ? new Base[0] : new Base[] {this.publisher}; // StringType 4220 case 951526432: /*contact*/ return this.contact == null ? new Base[0] : this.contact.toArray(new Base[this.contact.size()]); // ContactDetail 4221 case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // MarkdownType 4222 case -669707736: /*useContext*/ return this.useContext == null ? new Base[0] : this.useContext.toArray(new Base[this.useContext.size()]); // UsageContext 4223 case -507075711: /*jurisdiction*/ return this.jurisdiction == null ? new Base[0] : this.jurisdiction.toArray(new Base[this.jurisdiction.size()]); // CodeableConcept 4224 case -220463842: /*purpose*/ return this.purpose == null ? new Base[0] : new Base[] {this.purpose}; // MarkdownType 4225 case 1522889671: /*copyright*/ return this.copyright == null ? new Base[0] : new Base[] {this.copyright}; // MarkdownType 4226 case -35616442: /*caseSensitive*/ return this.caseSensitive == null ? new Base[0] : new Base[] {this.caseSensitive}; // BooleanType 4227 case -1410174671: /*valueSet*/ return this.valueSet == null ? new Base[0] : new Base[] {this.valueSet}; // CanonicalType 4228 case 1913078280: /*hierarchyMeaning*/ return this.hierarchyMeaning == null ? new Base[0] : new Base[] {this.hierarchyMeaning}; // Enumeration<CodeSystemHierarchyMeaning> 4229 case 1248023381: /*compositional*/ return this.compositional == null ? new Base[0] : new Base[] {this.compositional}; // BooleanType 4230 case 617270957: /*versionNeeded*/ return this.versionNeeded == null ? new Base[0] : new Base[] {this.versionNeeded}; // BooleanType 4231 case 951530617: /*content*/ return this.content == null ? new Base[0] : new Base[] {this.content}; // Enumeration<CodeSystemContentMode> 4232 case -596951334: /*supplements*/ return this.supplements == null ? new Base[0] : new Base[] {this.supplements}; // CanonicalType 4233 case 94851343: /*count*/ return this.count == null ? new Base[0] : new Base[] {this.count}; // UnsignedIntType 4234 case -1274492040: /*filter*/ return this.filter == null ? new Base[0] : this.filter.toArray(new Base[this.filter.size()]); // CodeSystemFilterComponent 4235 case -993141291: /*property*/ return this.property == null ? new Base[0] : this.property.toArray(new Base[this.property.size()]); // PropertyComponent 4236 case 951024232: /*concept*/ return this.concept == null ? new Base[0] : this.concept.toArray(new Base[this.concept.size()]); // ConceptDefinitionComponent 4237 default: return super.getProperty(hash, name, checkValid); 4238 } 4239 4240 } 4241 4242 @Override 4243 public Base setProperty(int hash, String name, Base value) throws FHIRException { 4244 switch (hash) { 4245 case 116079: // url 4246 this.url = castToUri(value); // UriType 4247 return value; 4248 case -1618432855: // identifier 4249 this.getIdentifier().add(castToIdentifier(value)); // Identifier 4250 return value; 4251 case 351608024: // version 4252 this.version = castToString(value); // StringType 4253 return value; 4254 case 3373707: // name 4255 this.name = castToString(value); // StringType 4256 return value; 4257 case 110371416: // title 4258 this.title = castToString(value); // StringType 4259 return value; 4260 case -892481550: // status 4261 value = new PublicationStatusEnumFactory().fromType(castToCode(value)); 4262 this.status = (Enumeration) value; // Enumeration<PublicationStatus> 4263 return value; 4264 case -404562712: // experimental 4265 this.experimental = castToBoolean(value); // BooleanType 4266 return value; 4267 case 3076014: // date 4268 this.date = castToDateTime(value); // DateTimeType 4269 return value; 4270 case 1447404028: // publisher 4271 this.publisher = castToString(value); // StringType 4272 return value; 4273 case 951526432: // contact 4274 this.getContact().add(castToContactDetail(value)); // ContactDetail 4275 return value; 4276 case -1724546052: // description 4277 this.description = castToMarkdown(value); // MarkdownType 4278 return value; 4279 case -669707736: // useContext 4280 this.getUseContext().add(castToUsageContext(value)); // UsageContext 4281 return value; 4282 case -507075711: // jurisdiction 4283 this.getJurisdiction().add(castToCodeableConcept(value)); // CodeableConcept 4284 return value; 4285 case -220463842: // purpose 4286 this.purpose = castToMarkdown(value); // MarkdownType 4287 return value; 4288 case 1522889671: // copyright 4289 this.copyright = castToMarkdown(value); // MarkdownType 4290 return value; 4291 case -35616442: // caseSensitive 4292 this.caseSensitive = castToBoolean(value); // BooleanType 4293 return value; 4294 case -1410174671: // valueSet 4295 this.valueSet = castToCanonical(value); // CanonicalType 4296 return value; 4297 case 1913078280: // hierarchyMeaning 4298 value = new CodeSystemHierarchyMeaningEnumFactory().fromType(castToCode(value)); 4299 this.hierarchyMeaning = (Enumeration) value; // Enumeration<CodeSystemHierarchyMeaning> 4300 return value; 4301 case 1248023381: // compositional 4302 this.compositional = castToBoolean(value); // BooleanType 4303 return value; 4304 case 617270957: // versionNeeded 4305 this.versionNeeded = castToBoolean(value); // BooleanType 4306 return value; 4307 case 951530617: // content 4308 value = new CodeSystemContentModeEnumFactory().fromType(castToCode(value)); 4309 this.content = (Enumeration) value; // Enumeration<CodeSystemContentMode> 4310 return value; 4311 case -596951334: // supplements 4312 this.supplements = castToCanonical(value); // CanonicalType 4313 return value; 4314 case 94851343: // count 4315 this.count = castToUnsignedInt(value); // UnsignedIntType 4316 return value; 4317 case -1274492040: // filter 4318 this.getFilter().add((CodeSystemFilterComponent) value); // CodeSystemFilterComponent 4319 return value; 4320 case -993141291: // property 4321 this.getProperty().add((PropertyComponent) value); // PropertyComponent 4322 return value; 4323 case 951024232: // concept 4324 this.getConcept().add((ConceptDefinitionComponent) value); // ConceptDefinitionComponent 4325 return value; 4326 default: return super.setProperty(hash, name, value); 4327 } 4328 4329 } 4330 4331 @Override 4332 public Base setProperty(String name, Base value) throws FHIRException { 4333 if (name.equals("url")) { 4334 this.url = castToUri(value); // UriType 4335 } else if (name.equals("identifier")) { 4336 this.getIdentifier().add(castToIdentifier(value)); 4337 } else if (name.equals("version")) { 4338 this.version = castToString(value); // StringType 4339 } else if (name.equals("name")) { 4340 this.name = castToString(value); // StringType 4341 } else if (name.equals("title")) { 4342 this.title = castToString(value); // StringType 4343 } else if (name.equals("status")) { 4344 value = new PublicationStatusEnumFactory().fromType(castToCode(value)); 4345 this.status = (Enumeration) value; // Enumeration<PublicationStatus> 4346 } else if (name.equals("experimental")) { 4347 this.experimental = castToBoolean(value); // BooleanType 4348 } else if (name.equals("date")) { 4349 this.date = castToDateTime(value); // DateTimeType 4350 } else if (name.equals("publisher")) { 4351 this.publisher = castToString(value); // StringType 4352 } else if (name.equals("contact")) { 4353 this.getContact().add(castToContactDetail(value)); 4354 } else if (name.equals("description")) { 4355 this.description = castToMarkdown(value); // MarkdownType 4356 } else if (name.equals("useContext")) { 4357 this.getUseContext().add(castToUsageContext(value)); 4358 } else if (name.equals("jurisdiction")) { 4359 this.getJurisdiction().add(castToCodeableConcept(value)); 4360 } else if (name.equals("purpose")) { 4361 this.purpose = castToMarkdown(value); // MarkdownType 4362 } else if (name.equals("copyright")) { 4363 this.copyright = castToMarkdown(value); // MarkdownType 4364 } else if (name.equals("caseSensitive")) { 4365 this.caseSensitive = castToBoolean(value); // BooleanType 4366 } else if (name.equals("valueSet")) { 4367 this.valueSet = castToCanonical(value); // CanonicalType 4368 } else if (name.equals("hierarchyMeaning")) { 4369 value = new CodeSystemHierarchyMeaningEnumFactory().fromType(castToCode(value)); 4370 this.hierarchyMeaning = (Enumeration) value; // Enumeration<CodeSystemHierarchyMeaning> 4371 } else if (name.equals("compositional")) { 4372 this.compositional = castToBoolean(value); // BooleanType 4373 } else if (name.equals("versionNeeded")) { 4374 this.versionNeeded = castToBoolean(value); // BooleanType 4375 } else if (name.equals("content")) { 4376 value = new CodeSystemContentModeEnumFactory().fromType(castToCode(value)); 4377 this.content = (Enumeration) value; // Enumeration<CodeSystemContentMode> 4378 } else if (name.equals("supplements")) { 4379 this.supplements = castToCanonical(value); // CanonicalType 4380 } else if (name.equals("count")) { 4381 this.count = castToUnsignedInt(value); // UnsignedIntType 4382 } else if (name.equals("filter")) { 4383 this.getFilter().add((CodeSystemFilterComponent) value); 4384 } else if (name.equals("property")) { 4385 this.getProperty().add((PropertyComponent) value); 4386 } else if (name.equals("concept")) { 4387 this.getConcept().add((ConceptDefinitionComponent) value); 4388 } else 4389 return super.setProperty(name, value); 4390 return value; 4391 } 4392 4393 @Override 4394 public Base makeProperty(int hash, String name) throws FHIRException { 4395 switch (hash) { 4396 case 116079: return getUrlElement(); 4397 case -1618432855: return addIdentifier(); 4398 case 351608024: return getVersionElement(); 4399 case 3373707: return getNameElement(); 4400 case 110371416: return getTitleElement(); 4401 case -892481550: return getStatusElement(); 4402 case -404562712: return getExperimentalElement(); 4403 case 3076014: return getDateElement(); 4404 case 1447404028: return getPublisherElement(); 4405 case 951526432: return addContact(); 4406 case -1724546052: return getDescriptionElement(); 4407 case -669707736: return addUseContext(); 4408 case -507075711: return addJurisdiction(); 4409 case -220463842: return getPurposeElement(); 4410 case 1522889671: return getCopyrightElement(); 4411 case -35616442: return getCaseSensitiveElement(); 4412 case -1410174671: return getValueSetElement(); 4413 case 1913078280: return getHierarchyMeaningElement(); 4414 case 1248023381: return getCompositionalElement(); 4415 case 617270957: return getVersionNeededElement(); 4416 case 951530617: return getContentElement(); 4417 case -596951334: return getSupplementsElement(); 4418 case 94851343: return getCountElement(); 4419 case -1274492040: return addFilter(); 4420 case -993141291: return addProperty(); 4421 case 951024232: return addConcept(); 4422 default: return super.makeProperty(hash, name); 4423 } 4424 4425 } 4426 4427 @Override 4428 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 4429 switch (hash) { 4430 case 116079: /*url*/ return new String[] {"uri"}; 4431 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 4432 case 351608024: /*version*/ return new String[] {"string"}; 4433 case 3373707: /*name*/ return new String[] {"string"}; 4434 case 110371416: /*title*/ return new String[] {"string"}; 4435 case -892481550: /*status*/ return new String[] {"code"}; 4436 case -404562712: /*experimental*/ return new String[] {"boolean"}; 4437 case 3076014: /*date*/ return new String[] {"dateTime"}; 4438 case 1447404028: /*publisher*/ return new String[] {"string"}; 4439 case 951526432: /*contact*/ return new String[] {"ContactDetail"}; 4440 case -1724546052: /*description*/ return new String[] {"markdown"}; 4441 case -669707736: /*useContext*/ return new String[] {"UsageContext"}; 4442 case -507075711: /*jurisdiction*/ return new String[] {"CodeableConcept"}; 4443 case -220463842: /*purpose*/ return new String[] {"markdown"}; 4444 case 1522889671: /*copyright*/ return new String[] {"markdown"}; 4445 case -35616442: /*caseSensitive*/ return new String[] {"boolean"}; 4446 case -1410174671: /*valueSet*/ return new String[] {"canonical"}; 4447 case 1913078280: /*hierarchyMeaning*/ return new String[] {"code"}; 4448 case 1248023381: /*compositional*/ return new String[] {"boolean"}; 4449 case 617270957: /*versionNeeded*/ return new String[] {"boolean"}; 4450 case 951530617: /*content*/ return new String[] {"code"}; 4451 case -596951334: /*supplements*/ return new String[] {"canonical"}; 4452 case 94851343: /*count*/ return new String[] {"unsignedInt"}; 4453 case -1274492040: /*filter*/ return new String[] {}; 4454 case -993141291: /*property*/ return new String[] {}; 4455 case 951024232: /*concept*/ return new String[] {}; 4456 default: return super.getTypesForProperty(hash, name); 4457 } 4458 4459 } 4460 4461 @Override 4462 public Base addChild(String name) throws FHIRException { 4463 if (name.equals("url")) { 4464 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.url"); 4465 } 4466 else if (name.equals("identifier")) { 4467 return addIdentifier(); 4468 } 4469 else if (name.equals("version")) { 4470 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.version"); 4471 } 4472 else if (name.equals("name")) { 4473 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.name"); 4474 } 4475 else if (name.equals("title")) { 4476 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.title"); 4477 } 4478 else if (name.equals("status")) { 4479 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.status"); 4480 } 4481 else if (name.equals("experimental")) { 4482 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.experimental"); 4483 } 4484 else if (name.equals("date")) { 4485 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.date"); 4486 } 4487 else if (name.equals("publisher")) { 4488 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.publisher"); 4489 } 4490 else if (name.equals("contact")) { 4491 return addContact(); 4492 } 4493 else if (name.equals("description")) { 4494 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.description"); 4495 } 4496 else if (name.equals("useContext")) { 4497 return addUseContext(); 4498 } 4499 else if (name.equals("jurisdiction")) { 4500 return addJurisdiction(); 4501 } 4502 else if (name.equals("purpose")) { 4503 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.purpose"); 4504 } 4505 else if (name.equals("copyright")) { 4506 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.copyright"); 4507 } 4508 else if (name.equals("caseSensitive")) { 4509 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.caseSensitive"); 4510 } 4511 else if (name.equals("valueSet")) { 4512 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.valueSet"); 4513 } 4514 else if (name.equals("hierarchyMeaning")) { 4515 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.hierarchyMeaning"); 4516 } 4517 else if (name.equals("compositional")) { 4518 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.compositional"); 4519 } 4520 else if (name.equals("versionNeeded")) { 4521 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.versionNeeded"); 4522 } 4523 else if (name.equals("content")) { 4524 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.content"); 4525 } 4526 else if (name.equals("supplements")) { 4527 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.supplements"); 4528 } 4529 else if (name.equals("count")) { 4530 throw new FHIRException("Cannot call addChild on a primitive type CodeSystem.count"); 4531 } 4532 else if (name.equals("filter")) { 4533 return addFilter(); 4534 } 4535 else if (name.equals("property")) { 4536 return addProperty(); 4537 } 4538 else if (name.equals("concept")) { 4539 return addConcept(); 4540 } 4541 else 4542 return super.addChild(name); 4543 } 4544 4545 public String fhirType() { 4546 return "CodeSystem"; 4547 4548 } 4549 4550 public CodeSystem copy() { 4551 CodeSystem dst = new CodeSystem(); 4552 copyValues(dst); 4553 return dst; 4554 } 4555 4556 public void copyValues(CodeSystem dst) { 4557 super.copyValues(dst); 4558 dst.url = url == null ? null : url.copy(); 4559 if (identifier != null) { 4560 dst.identifier = new ArrayList<Identifier>(); 4561 for (Identifier i : identifier) 4562 dst.identifier.add(i.copy()); 4563 }; 4564 dst.version = version == null ? null : version.copy(); 4565 dst.name = name == null ? null : name.copy(); 4566 dst.title = title == null ? null : title.copy(); 4567 dst.status = status == null ? null : status.copy(); 4568 dst.experimental = experimental == null ? null : experimental.copy(); 4569 dst.date = date == null ? null : date.copy(); 4570 dst.publisher = publisher == null ? null : publisher.copy(); 4571 if (contact != null) { 4572 dst.contact = new ArrayList<ContactDetail>(); 4573 for (ContactDetail i : contact) 4574 dst.contact.add(i.copy()); 4575 }; 4576 dst.description = description == null ? null : description.copy(); 4577 if (useContext != null) { 4578 dst.useContext = new ArrayList<UsageContext>(); 4579 for (UsageContext i : useContext) 4580 dst.useContext.add(i.copy()); 4581 }; 4582 if (jurisdiction != null) { 4583 dst.jurisdiction = new ArrayList<CodeableConcept>(); 4584 for (CodeableConcept i : jurisdiction) 4585 dst.jurisdiction.add(i.copy()); 4586 }; 4587 dst.purpose = purpose == null ? null : purpose.copy(); 4588 dst.copyright = copyright == null ? null : copyright.copy(); 4589 dst.caseSensitive = caseSensitive == null ? null : caseSensitive.copy(); 4590 dst.valueSet = valueSet == null ? null : valueSet.copy(); 4591 dst.hierarchyMeaning = hierarchyMeaning == null ? null : hierarchyMeaning.copy(); 4592 dst.compositional = compositional == null ? null : compositional.copy(); 4593 dst.versionNeeded = versionNeeded == null ? null : versionNeeded.copy(); 4594 dst.content = content == null ? null : content.copy(); 4595 dst.supplements = supplements == null ? null : supplements.copy(); 4596 dst.count = count == null ? null : count.copy(); 4597 if (filter != null) { 4598 dst.filter = new ArrayList<CodeSystemFilterComponent>(); 4599 for (CodeSystemFilterComponent i : filter) 4600 dst.filter.add(i.copy()); 4601 }; 4602 if (property != null) { 4603 dst.property = new ArrayList<PropertyComponent>(); 4604 for (PropertyComponent i : property) 4605 dst.property.add(i.copy()); 4606 }; 4607 if (concept != null) { 4608 dst.concept = new ArrayList<ConceptDefinitionComponent>(); 4609 for (ConceptDefinitionComponent i : concept) 4610 dst.concept.add(i.copy()); 4611 }; 4612 } 4613 4614 protected CodeSystem typedCopy() { 4615 return copy(); 4616 } 4617 4618 @Override 4619 public boolean equalsDeep(Base other_) { 4620 if (!super.equalsDeep(other_)) 4621 return false; 4622 if (!(other_ instanceof CodeSystem)) 4623 return false; 4624 CodeSystem o = (CodeSystem) other_; 4625 return compareDeep(identifier, o.identifier, true) && compareDeep(purpose, o.purpose, true) && compareDeep(copyright, o.copyright, true) 4626 && compareDeep(caseSensitive, o.caseSensitive, true) && compareDeep(valueSet, o.valueSet, true) 4627 && compareDeep(hierarchyMeaning, o.hierarchyMeaning, true) && compareDeep(compositional, o.compositional, true) 4628 && compareDeep(versionNeeded, o.versionNeeded, true) && compareDeep(content, o.content, true) && compareDeep(supplements, o.supplements, true) 4629 && compareDeep(count, o.count, true) && compareDeep(filter, o.filter, true) && compareDeep(property, o.property, true) 4630 && compareDeep(concept, o.concept, true); 4631 } 4632 4633 @Override 4634 public boolean equalsShallow(Base other_) { 4635 if (!super.equalsShallow(other_)) 4636 return false; 4637 if (!(other_ instanceof CodeSystem)) 4638 return false; 4639 CodeSystem o = (CodeSystem) other_; 4640 return compareValues(purpose, o.purpose, true) && compareValues(copyright, o.copyright, true) && compareValues(caseSensitive, o.caseSensitive, true) 4641 && compareValues(hierarchyMeaning, o.hierarchyMeaning, true) && compareValues(compositional, o.compositional, true) 4642 && compareValues(versionNeeded, o.versionNeeded, true) && compareValues(content, o.content, true) && compareValues(count, o.count, true) 4643 ; 4644 } 4645 4646 public boolean isEmpty() { 4647 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, purpose, copyright 4648 , caseSensitive, valueSet, hierarchyMeaning, compositional, versionNeeded, content 4649 , supplements, count, filter, property, concept); 4650 } 4651 4652 @Override 4653 public ResourceType getResourceType() { 4654 return ResourceType.CodeSystem; 4655 } 4656 4657 /** 4658 * Search parameter: <b>date</b> 4659 * <p> 4660 * Description: <b>The code system publication date</b><br> 4661 * Type: <b>date</b><br> 4662 * Path: <b>CodeSystem.date</b><br> 4663 * </p> 4664 */ 4665 @SearchParamDefinition(name="date", path="CodeSystem.date", description="The code system publication date", type="date" ) 4666 public static final String SP_DATE = "date"; 4667 /** 4668 * <b>Fluent Client</b> search parameter constant for <b>date</b> 4669 * <p> 4670 * Description: <b>The code system publication date</b><br> 4671 * Type: <b>date</b><br> 4672 * Path: <b>CodeSystem.date</b><br> 4673 * </p> 4674 */ 4675 public static final ca.uhn.fhir.rest.gclient.DateClientParam DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_DATE); 4676 4677 /** 4678 * Search parameter: <b>identifier</b> 4679 * <p> 4680 * Description: <b>External identifier for the code system</b><br> 4681 * Type: <b>token</b><br> 4682 * Path: <b>CodeSystem.identifier</b><br> 4683 * </p> 4684 */ 4685 @SearchParamDefinition(name="identifier", path="CodeSystem.identifier", description="External identifier for the code system", type="token" ) 4686 public static final String SP_IDENTIFIER = "identifier"; 4687 /** 4688 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 4689 * <p> 4690 * Description: <b>External identifier for the code system</b><br> 4691 * Type: <b>token</b><br> 4692 * Path: <b>CodeSystem.identifier</b><br> 4693 * </p> 4694 */ 4695 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 4696 4697 /** 4698 * Search parameter: <b>code</b> 4699 * <p> 4700 * Description: <b>A code defined in the code system</b><br> 4701 * Type: <b>token</b><br> 4702 * Path: <b>CodeSystem.concept.code</b><br> 4703 * </p> 4704 */ 4705 @SearchParamDefinition(name="code", path="CodeSystem.concept.code", description="A code defined in the code system", type="token" ) 4706 public static final String SP_CODE = "code"; 4707 /** 4708 * <b>Fluent Client</b> search parameter constant for <b>code</b> 4709 * <p> 4710 * Description: <b>A code defined in the code system</b><br> 4711 * Type: <b>token</b><br> 4712 * Path: <b>CodeSystem.concept.code</b><br> 4713 * </p> 4714 */ 4715 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CODE); 4716 4717 /** 4718 * Search parameter: <b>context-type-value</b> 4719 * <p> 4720 * Description: <b>A use context type and value assigned to the code system</b><br> 4721 * Type: <b>composite</b><br> 4722 * Path: <b></b><br> 4723 * </p> 4724 */ 4725 @SearchParamDefinition(name="context-type-value", path="CodeSystem.useContext", description="A use context type and value assigned to the code system", type="composite", compositeOf={"context-type", "context"} ) 4726 public static final String SP_CONTEXT_TYPE_VALUE = "context-type-value"; 4727 /** 4728 * <b>Fluent Client</b> search parameter constant for <b>context-type-value</b> 4729 * <p> 4730 * Description: <b>A use context type and value assigned to the code system</b><br> 4731 * Type: <b>composite</b><br> 4732 * Path: <b></b><br> 4733 * </p> 4734 */ 4735 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam> CONTEXT_TYPE_VALUE = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam>(SP_CONTEXT_TYPE_VALUE); 4736 4737 /** 4738 * Search parameter: <b>content-mode</b> 4739 * <p> 4740 * Description: <b>not-present | example | fragment | complete | supplement</b><br> 4741 * Type: <b>token</b><br> 4742 * Path: <b>CodeSystem.content</b><br> 4743 * </p> 4744 */ 4745 @SearchParamDefinition(name="content-mode", path="CodeSystem.content", description="not-present | example | fragment | complete | supplement", type="token" ) 4746 public static final String SP_CONTENT_MODE = "content-mode"; 4747 /** 4748 * <b>Fluent Client</b> search parameter constant for <b>content-mode</b> 4749 * <p> 4750 * Description: <b>not-present | example | fragment | complete | supplement</b><br> 4751 * Type: <b>token</b><br> 4752 * Path: <b>CodeSystem.content</b><br> 4753 * </p> 4754 */ 4755 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTENT_MODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CONTENT_MODE); 4756 4757 /** 4758 * Search parameter: <b>jurisdiction</b> 4759 * <p> 4760 * Description: <b>Intended jurisdiction for the code system</b><br> 4761 * Type: <b>token</b><br> 4762 * Path: <b>CodeSystem.jurisdiction</b><br> 4763 * </p> 4764 */ 4765 @SearchParamDefinition(name="jurisdiction", path="CodeSystem.jurisdiction", description="Intended jurisdiction for the code system", type="token" ) 4766 public static final String SP_JURISDICTION = "jurisdiction"; 4767 /** 4768 * <b>Fluent Client</b> search parameter constant for <b>jurisdiction</b> 4769 * <p> 4770 * Description: <b>Intended jurisdiction for the code system</b><br> 4771 * Type: <b>token</b><br> 4772 * Path: <b>CodeSystem.jurisdiction</b><br> 4773 * </p> 4774 */ 4775 public static final ca.uhn.fhir.rest.gclient.TokenClientParam JURISDICTION = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_JURISDICTION); 4776 4777 /** 4778 * Search parameter: <b>description</b> 4779 * <p> 4780 * Description: <b>The description of the code system</b><br> 4781 * Type: <b>string</b><br> 4782 * Path: <b>CodeSystem.description</b><br> 4783 * </p> 4784 */ 4785 @SearchParamDefinition(name="description", path="CodeSystem.description", description="The description of the code system", type="string" ) 4786 public static final String SP_DESCRIPTION = "description"; 4787 /** 4788 * <b>Fluent Client</b> search parameter constant for <b>description</b> 4789 * <p> 4790 * Description: <b>The description of the code system</b><br> 4791 * Type: <b>string</b><br> 4792 * Path: <b>CodeSystem.description</b><br> 4793 * </p> 4794 */ 4795 public static final ca.uhn.fhir.rest.gclient.StringClientParam DESCRIPTION = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_DESCRIPTION); 4796 4797 /** 4798 * Search parameter: <b>context-type</b> 4799 * <p> 4800 * Description: <b>A type of use context assigned to the code system</b><br> 4801 * Type: <b>token</b><br> 4802 * Path: <b>CodeSystem.useContext.code</b><br> 4803 * </p> 4804 */ 4805 @SearchParamDefinition(name="context-type", path="CodeSystem.useContext.code", description="A type of use context assigned to the code system", type="token" ) 4806 public static final String SP_CONTEXT_TYPE = "context-type"; 4807 /** 4808 * <b>Fluent Client</b> search parameter constant for <b>context-type</b> 4809 * <p> 4810 * Description: <b>A type of use context assigned to the code system</b><br> 4811 * Type: <b>token</b><br> 4812 * Path: <b>CodeSystem.useContext.code</b><br> 4813 * </p> 4814 */ 4815 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT_TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CONTEXT_TYPE); 4816 4817 /** 4818 * Search parameter: <b>language</b> 4819 * <p> 4820 * Description: <b>A language in which a designation is provided</b><br> 4821 * Type: <b>token</b><br> 4822 * Path: <b>CodeSystem.concept.designation.language</b><br> 4823 * </p> 4824 */ 4825 @SearchParamDefinition(name="language", path="CodeSystem.concept.designation.language", description="A language in which a designation is provided", type="token" ) 4826 public static final String SP_LANGUAGE = "language"; 4827 /** 4828 * <b>Fluent Client</b> search parameter constant for <b>language</b> 4829 * <p> 4830 * Description: <b>A language in which a designation is provided</b><br> 4831 * Type: <b>token</b><br> 4832 * Path: <b>CodeSystem.concept.designation.language</b><br> 4833 * </p> 4834 */ 4835 public static final ca.uhn.fhir.rest.gclient.TokenClientParam LANGUAGE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_LANGUAGE); 4836 4837 /** 4838 * Search parameter: <b>title</b> 4839 * <p> 4840 * Description: <b>The human-friendly name of the code system</b><br> 4841 * Type: <b>string</b><br> 4842 * Path: <b>CodeSystem.title</b><br> 4843 * </p> 4844 */ 4845 @SearchParamDefinition(name="title", path="CodeSystem.title", description="The human-friendly name of the code system", type="string" ) 4846 public static final String SP_TITLE = "title"; 4847 /** 4848 * <b>Fluent Client</b> search parameter constant for <b>title</b> 4849 * <p> 4850 * Description: <b>The human-friendly name of the code system</b><br> 4851 * Type: <b>string</b><br> 4852 * Path: <b>CodeSystem.title</b><br> 4853 * </p> 4854 */ 4855 public static final ca.uhn.fhir.rest.gclient.StringClientParam TITLE = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_TITLE); 4856 4857 /** 4858 * Search parameter: <b>version</b> 4859 * <p> 4860 * Description: <b>The business version of the code system</b><br> 4861 * Type: <b>token</b><br> 4862 * Path: <b>CodeSystem.version</b><br> 4863 * </p> 4864 */ 4865 @SearchParamDefinition(name="version", path="CodeSystem.version", description="The business version of the code system", type="token" ) 4866 public static final String SP_VERSION = "version"; 4867 /** 4868 * <b>Fluent Client</b> search parameter constant for <b>version</b> 4869 * <p> 4870 * Description: <b>The business version of the code system</b><br> 4871 * Type: <b>token</b><br> 4872 * Path: <b>CodeSystem.version</b><br> 4873 * </p> 4874 */ 4875 public static final ca.uhn.fhir.rest.gclient.TokenClientParam VERSION = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_VERSION); 4876 4877 /** 4878 * Search parameter: <b>url</b> 4879 * <p> 4880 * Description: <b>The uri that identifies the code system</b><br> 4881 * Type: <b>uri</b><br> 4882 * Path: <b>CodeSystem.url</b><br> 4883 * </p> 4884 */ 4885 @SearchParamDefinition(name="url", path="CodeSystem.url", description="The uri that identifies the code system", type="uri" ) 4886 public static final String SP_URL = "url"; 4887 /** 4888 * <b>Fluent Client</b> search parameter constant for <b>url</b> 4889 * <p> 4890 * Description: <b>The uri that identifies the code system</b><br> 4891 * Type: <b>uri</b><br> 4892 * Path: <b>CodeSystem.url</b><br> 4893 * </p> 4894 */ 4895 public static final ca.uhn.fhir.rest.gclient.UriClientParam URL = new ca.uhn.fhir.rest.gclient.UriClientParam(SP_URL); 4896 4897 /** 4898 * Search parameter: <b>context-quantity</b> 4899 * <p> 4900 * Description: <b>A quantity- or range-valued use context assigned to the code system</b><br> 4901 * Type: <b>quantity</b><br> 4902 * Path: <b>CodeSystem.useContext.valueQuantity, CodeSystem.useContext.valueRange</b><br> 4903 * </p> 4904 */ 4905 @SearchParamDefinition(name="context-quantity", path="(CodeSystem.useContext.value as Quantity) | (CodeSystem.useContext.value as Range)", description="A quantity- or range-valued use context assigned to the code system", type="quantity" ) 4906 public static final String SP_CONTEXT_QUANTITY = "context-quantity"; 4907 /** 4908 * <b>Fluent Client</b> search parameter constant for <b>context-quantity</b> 4909 * <p> 4910 * Description: <b>A quantity- or range-valued use context assigned to the code system</b><br> 4911 * Type: <b>quantity</b><br> 4912 * Path: <b>CodeSystem.useContext.valueQuantity, CodeSystem.useContext.valueRange</b><br> 4913 * </p> 4914 */ 4915 public static final ca.uhn.fhir.rest.gclient.QuantityClientParam CONTEXT_QUANTITY = new ca.uhn.fhir.rest.gclient.QuantityClientParam(SP_CONTEXT_QUANTITY); 4916 4917 /** 4918 * Search parameter: <b>supplements</b> 4919 * <p> 4920 * Description: <b>Find code system supplements for the referenced code system</b><br> 4921 * Type: <b>reference</b><br> 4922 * Path: <b>CodeSystem.supplements</b><br> 4923 * </p> 4924 */ 4925 @SearchParamDefinition(name="supplements", path="CodeSystem.supplements", description="Find code system supplements for the referenced code system", type="reference", target={CodeSystem.class } ) 4926 public static final String SP_SUPPLEMENTS = "supplements"; 4927 /** 4928 * <b>Fluent Client</b> search parameter constant for <b>supplements</b> 4929 * <p> 4930 * Description: <b>Find code system supplements for the referenced code system</b><br> 4931 * Type: <b>reference</b><br> 4932 * Path: <b>CodeSystem.supplements</b><br> 4933 * </p> 4934 */ 4935 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SUPPLEMENTS = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SUPPLEMENTS); 4936 4937/** 4938 * Constant for fluent queries to be used to add include statements. Specifies 4939 * the path value of "<b>CodeSystem:supplements</b>". 4940 */ 4941 public static final ca.uhn.fhir.model.api.Include INCLUDE_SUPPLEMENTS = new ca.uhn.fhir.model.api.Include("CodeSystem:supplements").toLocked(); 4942 4943 /** 4944 * Search parameter: <b>system</b> 4945 * <p> 4946 * Description: <b>The system for any codes defined by this code system (same as 'url')</b><br> 4947 * Type: <b>uri</b><br> 4948 * Path: <b>CodeSystem.url</b><br> 4949 * </p> 4950 */ 4951 @SearchParamDefinition(name="system", path="CodeSystem.url", description="The system for any codes defined by this code system (same as 'url')", type="uri" ) 4952 public static final String SP_SYSTEM = "system"; 4953 /** 4954 * <b>Fluent Client</b> search parameter constant for <b>system</b> 4955 * <p> 4956 * Description: <b>The system for any codes defined by this code system (same as 'url')</b><br> 4957 * Type: <b>uri</b><br> 4958 * Path: <b>CodeSystem.url</b><br> 4959 * </p> 4960 */ 4961 public static final ca.uhn.fhir.rest.gclient.UriClientParam SYSTEM = new ca.uhn.fhir.rest.gclient.UriClientParam(SP_SYSTEM); 4962 4963 /** 4964 * Search parameter: <b>name</b> 4965 * <p> 4966 * Description: <b>Computationally friendly name of the code system</b><br> 4967 * Type: <b>string</b><br> 4968 * Path: <b>CodeSystem.name</b><br> 4969 * </p> 4970 */ 4971 @SearchParamDefinition(name="name", path="CodeSystem.name", description="Computationally friendly name of the code system", type="string" ) 4972 public static final String SP_NAME = "name"; 4973 /** 4974 * <b>Fluent Client</b> search parameter constant for <b>name</b> 4975 * <p> 4976 * Description: <b>Computationally friendly name of the code system</b><br> 4977 * Type: <b>string</b><br> 4978 * Path: <b>CodeSystem.name</b><br> 4979 * </p> 4980 */ 4981 public static final ca.uhn.fhir.rest.gclient.StringClientParam NAME = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_NAME); 4982 4983 /** 4984 * Search parameter: <b>context</b> 4985 * <p> 4986 * Description: <b>A use context assigned to the code system</b><br> 4987 * Type: <b>token</b><br> 4988 * Path: <b>CodeSystem.useContext.valueCodeableConcept</b><br> 4989 * </p> 4990 */ 4991 @SearchParamDefinition(name="context", path="(CodeSystem.useContext.value as CodeableConcept)", description="A use context assigned to the code system", type="token" ) 4992 public static final String SP_CONTEXT = "context"; 4993 /** 4994 * <b>Fluent Client</b> search parameter constant for <b>context</b> 4995 * <p> 4996 * Description: <b>A use context assigned to the code system</b><br> 4997 * Type: <b>token</b><br> 4998 * Path: <b>CodeSystem.useContext.valueCodeableConcept</b><br> 4999 * </p> 5000 */ 5001 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CONTEXT); 5002 5003 /** 5004 * Search parameter: <b>publisher</b> 5005 * <p> 5006 * Description: <b>Name of the publisher of the code system</b><br> 5007 * Type: <b>string</b><br> 5008 * Path: <b>CodeSystem.publisher</b><br> 5009 * </p> 5010 */ 5011 @SearchParamDefinition(name="publisher", path="CodeSystem.publisher", description="Name of the publisher of the code system", type="string" ) 5012 public static final String SP_PUBLISHER = "publisher"; 5013 /** 5014 * <b>Fluent Client</b> search parameter constant for <b>publisher</b> 5015 * <p> 5016 * Description: <b>Name of the publisher of the code system</b><br> 5017 * Type: <b>string</b><br> 5018 * Path: <b>CodeSystem.publisher</b><br> 5019 * </p> 5020 */ 5021 public static final ca.uhn.fhir.rest.gclient.StringClientParam PUBLISHER = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_PUBLISHER); 5022 5023 /** 5024 * Search parameter: <b>context-type-quantity</b> 5025 * <p> 5026 * Description: <b>A use context type and quantity- or range-based value assigned to the code system</b><br> 5027 * Type: <b>composite</b><br> 5028 * Path: <b></b><br> 5029 * </p> 5030 */ 5031 @SearchParamDefinition(name="context-type-quantity", path="CodeSystem.useContext", description="A use context type and quantity- or range-based value assigned to the code system", type="composite", compositeOf={"context-type", "context-quantity"} ) 5032 public static final String SP_CONTEXT_TYPE_QUANTITY = "context-type-quantity"; 5033 /** 5034 * <b>Fluent Client</b> search parameter constant for <b>context-type-quantity</b> 5035 * <p> 5036 * Description: <b>A use context type and quantity- or range-based value assigned to the code system</b><br> 5037 * Type: <b>composite</b><br> 5038 * Path: <b></b><br> 5039 * </p> 5040 */ 5041 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam> CONTEXT_TYPE_QUANTITY = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam>(SP_CONTEXT_TYPE_QUANTITY); 5042 5043 /** 5044 * Search parameter: <b>status</b> 5045 * <p> 5046 * Description: <b>The current status of the code system</b><br> 5047 * Type: <b>token</b><br> 5048 * Path: <b>CodeSystem.status</b><br> 5049 * </p> 5050 */ 5051 @SearchParamDefinition(name="status", path="CodeSystem.status", description="The current status of the code system", type="token" ) 5052 public static final String SP_STATUS = "status"; 5053 /** 5054 * <b>Fluent Client</b> search parameter constant for <b>status</b> 5055 * <p> 5056 * Description: <b>The current status of the code system</b><br> 5057 * Type: <b>token</b><br> 5058 * Path: <b>CodeSystem.status</b><br> 5059 * </p> 5060 */ 5061 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 5062 5063// added from java-adornments.txt: 5064 public PropertyComponent getProperty(String code) { 5065 for (PropertyComponent pd : getProperty()) { 5066 if (pd.getCode().equalsIgnoreCase(code)) 5067 return pd; 5068 } 5069 return null; 5070 } 5071 5072// end addition 5073 5074} 5075