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 java.math.*; 060import org.hl7.fhir.instance.model.api.IBaseDatatypeElement; 061import org.hl7.fhir.utilities.Utilities; 062import org.hl7.fhir.r5.model.Enumerations.*; 063import ca.uhn.fhir.model.api.annotation.ResourceDef; 064import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 065import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 066import ca.uhn.fhir.model.api.annotation.Child; 067import ca.uhn.fhir.model.api.annotation.ChildOrder; 068import ca.uhn.fhir.model.api.annotation.Description; 069import ca.uhn.fhir.model.api.annotation.Block; 070/** 071 * Set of definitional characteristics for a kind of observation or measurement produced or consumed by an orderable health care service. 072 */ 073@ResourceDef(name="ObservationDefinition", profile="http://hl7.org/fhir/StructureDefinition/ObservationDefinition") 074public class ObservationDefinition extends DomainResource { 075 076 public enum PublicationStatus { 077 /** 078 * This resource is still under development and is not yet considered to be ready for normal use. 079 */ 080 DRAFT, 081 /** 082 * This resource is ready for normal use. 083 */ 084 ACTIVE, 085 /** 086 * This resource has been withdrawn or superseded and should no longer be used. 087 */ 088 RETIRED, 089 /** 090 * The authoring system does not know which of the status values currently applies for this resource. Note: This concept is not to be used for "other" - one of the listed statuses is presumed to apply, it's just not known which one. 091 */ 092 UNKNOWN, 093 /** 094 * added to help the parsers with the generic types 095 */ 096 NULL; 097 public static PublicationStatus fromCode(String codeString) throws FHIRException { 098 if (codeString == null || "".equals(codeString)) 099 return null; 100 if ("draft".equals(codeString)) 101 return DRAFT; 102 if ("active".equals(codeString)) 103 return ACTIVE; 104 if ("retired".equals(codeString)) 105 return RETIRED; 106 if ("unknown".equals(codeString)) 107 return UNKNOWN; 108 if (Configuration.isAcceptInvalidEnums()) 109 return null; 110 else 111 throw new FHIRException("Unknown PublicationStatus code '"+codeString+"'"); 112 } 113 public String toCode() { 114 switch (this) { 115 case DRAFT: return "draft"; 116 case ACTIVE: return "active"; 117 case RETIRED: return "retired"; 118 case UNKNOWN: return "unknown"; 119 default: return "?"; 120 } 121 } 122 public String getSystem() { 123 switch (this) { 124 case DRAFT: return "http://hl7.org/fhir/publication-status"; 125 case ACTIVE: return "http://hl7.org/fhir/publication-status"; 126 case RETIRED: return "http://hl7.org/fhir/publication-status"; 127 case UNKNOWN: return "http://hl7.org/fhir/publication-status"; 128 default: return "?"; 129 } 130 } 131 public String getDefinition() { 132 switch (this) { 133 case DRAFT: return "This resource is still under development and is not yet considered to be ready for normal use."; 134 case ACTIVE: return "This resource is ready for normal use."; 135 case RETIRED: return "This resource has been withdrawn or superseded and should no longer be used."; 136 case UNKNOWN: return "The authoring system does not know which of the status values currently applies for this resource. Note: This concept is not to be used for \"other\" - one of the listed statuses is presumed to apply, it's just not known which one."; 137 default: return "?"; 138 } 139 } 140 public String getDisplay() { 141 switch (this) { 142 case DRAFT: return "Draft"; 143 case ACTIVE: return "Active"; 144 case RETIRED: return "Retired"; 145 case UNKNOWN: return "Unknown"; 146 default: return "?"; 147 } 148 } 149 } 150 151 public static class PublicationStatusEnumFactory implements EnumFactory<PublicationStatus> { 152 public PublicationStatus fromCode(String codeString) throws IllegalArgumentException { 153 if (codeString == null || "".equals(codeString)) 154 if (codeString == null || "".equals(codeString)) 155 return null; 156 if ("draft".equals(codeString)) 157 return PublicationStatus.DRAFT; 158 if ("active".equals(codeString)) 159 return PublicationStatus.ACTIVE; 160 if ("retired".equals(codeString)) 161 return PublicationStatus.RETIRED; 162 if ("unknown".equals(codeString)) 163 return PublicationStatus.UNKNOWN; 164 throw new IllegalArgumentException("Unknown PublicationStatus code '"+codeString+"'"); 165 } 166 public Enumeration<PublicationStatus> fromType(Base code) throws FHIRException { 167 if (code == null) 168 return null; 169 if (code.isEmpty()) 170 return new Enumeration<PublicationStatus>(this); 171 String codeString = ((PrimitiveType) code).asStringValue(); 172 if (codeString == null || "".equals(codeString)) 173 return null; 174 if ("draft".equals(codeString)) 175 return new Enumeration<PublicationStatus>(this, PublicationStatus.DRAFT); 176 if ("active".equals(codeString)) 177 return new Enumeration<PublicationStatus>(this, PublicationStatus.ACTIVE); 178 if ("retired".equals(codeString)) 179 return new Enumeration<PublicationStatus>(this, PublicationStatus.RETIRED); 180 if ("unknown".equals(codeString)) 181 return new Enumeration<PublicationStatus>(this, PublicationStatus.UNKNOWN); 182 throw new FHIRException("Unknown PublicationStatus code '"+codeString+"'"); 183 } 184 public String toCode(PublicationStatus code) { 185 if (code == PublicationStatus.DRAFT) 186 return "draft"; 187 if (code == PublicationStatus.ACTIVE) 188 return "active"; 189 if (code == PublicationStatus.RETIRED) 190 return "retired"; 191 if (code == PublicationStatus.UNKNOWN) 192 return "unknown"; 193 return "?"; 194 } 195 public String toSystem(PublicationStatus code) { 196 return code.getSystem(); 197 } 198 } 199 200 public enum ObservationDataType { 201 /** 202 * A measured amount. 203 */ 204 QUANTITY, 205 /** 206 * A coded concept from a reference terminology and/or text. 207 */ 208 CODEABLECONCEPT, 209 /** 210 * A sequence of Unicode characters. 211 */ 212 STRING, 213 /** 214 * true or false. 215 */ 216 BOOLEAN, 217 /** 218 * A signed integer. 219 */ 220 INTEGER, 221 /** 222 * A set of values bounded by low and high. 223 */ 224 RANGE, 225 /** 226 * A ratio of two Quantity values - a numerator and a denominator. 227 */ 228 RATIO, 229 /** 230 * A series of measurements taken by a device. 231 */ 232 SAMPLEDDATA, 233 /** 234 * A time during the day, in the format hh:mm:ss. 235 */ 236 TIME, 237 /** 238 * A date, date-time or partial date (e.g. just year or year + month) as used in human communication. 239 */ 240 DATETIME, 241 /** 242 * A time range defined by start and end date/time. 243 */ 244 PERIOD, 245 /** 246 * added to help the parsers with the generic types 247 */ 248 NULL; 249 public static ObservationDataType fromCode(String codeString) throws FHIRException { 250 if (codeString == null || "".equals(codeString)) 251 return null; 252 if ("Quantity".equals(codeString)) 253 return QUANTITY; 254 if ("CodeableConcept".equals(codeString)) 255 return CODEABLECONCEPT; 256 if ("string".equals(codeString)) 257 return STRING; 258 if ("boolean".equals(codeString)) 259 return BOOLEAN; 260 if ("integer".equals(codeString)) 261 return INTEGER; 262 if ("Range".equals(codeString)) 263 return RANGE; 264 if ("Ratio".equals(codeString)) 265 return RATIO; 266 if ("SampledData".equals(codeString)) 267 return SAMPLEDDATA; 268 if ("time".equals(codeString)) 269 return TIME; 270 if ("dateTime".equals(codeString)) 271 return DATETIME; 272 if ("Period".equals(codeString)) 273 return PERIOD; 274 if (Configuration.isAcceptInvalidEnums()) 275 return null; 276 else 277 throw new FHIRException("Unknown ObservationDataType code '"+codeString+"'"); 278 } 279 public String toCode() { 280 switch (this) { 281 case QUANTITY: return "Quantity"; 282 case CODEABLECONCEPT: return "CodeableConcept"; 283 case STRING: return "string"; 284 case BOOLEAN: return "boolean"; 285 case INTEGER: return "integer"; 286 case RANGE: return "Range"; 287 case RATIO: return "Ratio"; 288 case SAMPLEDDATA: return "SampledData"; 289 case TIME: return "time"; 290 case DATETIME: return "dateTime"; 291 case PERIOD: return "Period"; 292 default: return "?"; 293 } 294 } 295 public String getSystem() { 296 switch (this) { 297 case QUANTITY: return "http://hl7.org/fhir/permitted-data-type"; 298 case CODEABLECONCEPT: return "http://hl7.org/fhir/permitted-data-type"; 299 case STRING: return "http://hl7.org/fhir/permitted-data-type"; 300 case BOOLEAN: return "http://hl7.org/fhir/permitted-data-type"; 301 case INTEGER: return "http://hl7.org/fhir/permitted-data-type"; 302 case RANGE: return "http://hl7.org/fhir/permitted-data-type"; 303 case RATIO: return "http://hl7.org/fhir/permitted-data-type"; 304 case SAMPLEDDATA: return "http://hl7.org/fhir/permitted-data-type"; 305 case TIME: return "http://hl7.org/fhir/permitted-data-type"; 306 case DATETIME: return "http://hl7.org/fhir/permitted-data-type"; 307 case PERIOD: return "http://hl7.org/fhir/permitted-data-type"; 308 default: return "?"; 309 } 310 } 311 public String getDefinition() { 312 switch (this) { 313 case QUANTITY: return "A measured amount."; 314 case CODEABLECONCEPT: return "A coded concept from a reference terminology and/or text."; 315 case STRING: return "A sequence of Unicode characters."; 316 case BOOLEAN: return "true or false."; 317 case INTEGER: return "A signed integer."; 318 case RANGE: return "A set of values bounded by low and high."; 319 case RATIO: return "A ratio of two Quantity values - a numerator and a denominator."; 320 case SAMPLEDDATA: return "A series of measurements taken by a device."; 321 case TIME: return "A time during the day, in the format hh:mm:ss."; 322 case DATETIME: return "A date, date-time or partial date (e.g. just year or year + month) as used in human communication."; 323 case PERIOD: return "A time range defined by start and end date/time."; 324 default: return "?"; 325 } 326 } 327 public String getDisplay() { 328 switch (this) { 329 case QUANTITY: return "Quantity"; 330 case CODEABLECONCEPT: return "CodeableConcept"; 331 case STRING: return "string"; 332 case BOOLEAN: return "boolean"; 333 case INTEGER: return "integer"; 334 case RANGE: return "Range"; 335 case RATIO: return "Ratio"; 336 case SAMPLEDDATA: return "SampledData"; 337 case TIME: return "time"; 338 case DATETIME: return "dateTime"; 339 case PERIOD: return "Period"; 340 default: return "?"; 341 } 342 } 343 } 344 345 public static class ObservationDataTypeEnumFactory implements EnumFactory<ObservationDataType> { 346 public ObservationDataType fromCode(String codeString) throws IllegalArgumentException { 347 if (codeString == null || "".equals(codeString)) 348 if (codeString == null || "".equals(codeString)) 349 return null; 350 if ("Quantity".equals(codeString)) 351 return ObservationDataType.QUANTITY; 352 if ("CodeableConcept".equals(codeString)) 353 return ObservationDataType.CODEABLECONCEPT; 354 if ("string".equals(codeString)) 355 return ObservationDataType.STRING; 356 if ("boolean".equals(codeString)) 357 return ObservationDataType.BOOLEAN; 358 if ("integer".equals(codeString)) 359 return ObservationDataType.INTEGER; 360 if ("Range".equals(codeString)) 361 return ObservationDataType.RANGE; 362 if ("Ratio".equals(codeString)) 363 return ObservationDataType.RATIO; 364 if ("SampledData".equals(codeString)) 365 return ObservationDataType.SAMPLEDDATA; 366 if ("time".equals(codeString)) 367 return ObservationDataType.TIME; 368 if ("dateTime".equals(codeString)) 369 return ObservationDataType.DATETIME; 370 if ("Period".equals(codeString)) 371 return ObservationDataType.PERIOD; 372 throw new IllegalArgumentException("Unknown ObservationDataType code '"+codeString+"'"); 373 } 374 public Enumeration<ObservationDataType> fromType(Base code) throws FHIRException { 375 if (code == null) 376 return null; 377 if (code.isEmpty()) 378 return new Enumeration<ObservationDataType>(this); 379 String codeString = ((PrimitiveType) code).asStringValue(); 380 if (codeString == null || "".equals(codeString)) 381 return null; 382 if ("Quantity".equals(codeString)) 383 return new Enumeration<ObservationDataType>(this, ObservationDataType.QUANTITY); 384 if ("CodeableConcept".equals(codeString)) 385 return new Enumeration<ObservationDataType>(this, ObservationDataType.CODEABLECONCEPT); 386 if ("string".equals(codeString)) 387 return new Enumeration<ObservationDataType>(this, ObservationDataType.STRING); 388 if ("boolean".equals(codeString)) 389 return new Enumeration<ObservationDataType>(this, ObservationDataType.BOOLEAN); 390 if ("integer".equals(codeString)) 391 return new Enumeration<ObservationDataType>(this, ObservationDataType.INTEGER); 392 if ("Range".equals(codeString)) 393 return new Enumeration<ObservationDataType>(this, ObservationDataType.RANGE); 394 if ("Ratio".equals(codeString)) 395 return new Enumeration<ObservationDataType>(this, ObservationDataType.RATIO); 396 if ("SampledData".equals(codeString)) 397 return new Enumeration<ObservationDataType>(this, ObservationDataType.SAMPLEDDATA); 398 if ("time".equals(codeString)) 399 return new Enumeration<ObservationDataType>(this, ObservationDataType.TIME); 400 if ("dateTime".equals(codeString)) 401 return new Enumeration<ObservationDataType>(this, ObservationDataType.DATETIME); 402 if ("Period".equals(codeString)) 403 return new Enumeration<ObservationDataType>(this, ObservationDataType.PERIOD); 404 throw new FHIRException("Unknown ObservationDataType code '"+codeString+"'"); 405 } 406 public String toCode(ObservationDataType code) { 407 if (code == ObservationDataType.QUANTITY) 408 return "Quantity"; 409 if (code == ObservationDataType.CODEABLECONCEPT) 410 return "CodeableConcept"; 411 if (code == ObservationDataType.STRING) 412 return "string"; 413 if (code == ObservationDataType.BOOLEAN) 414 return "boolean"; 415 if (code == ObservationDataType.INTEGER) 416 return "integer"; 417 if (code == ObservationDataType.RANGE) 418 return "Range"; 419 if (code == ObservationDataType.RATIO) 420 return "Ratio"; 421 if (code == ObservationDataType.SAMPLEDDATA) 422 return "SampledData"; 423 if (code == ObservationDataType.TIME) 424 return "time"; 425 if (code == ObservationDataType.DATETIME) 426 return "dateTime"; 427 if (code == ObservationDataType.PERIOD) 428 return "Period"; 429 return "?"; 430 } 431 public String toSystem(ObservationDataType code) { 432 return code.getSystem(); 433 } 434 } 435 436 public enum ObservationRangeCategory { 437 /** 438 * Reference (Normal) Range for Ordinal and Continuous Observations. 439 */ 440 REFERENCE, 441 /** 442 * Critical Range for Ordinal and Continuous Observations. Results outside this range are critical. 443 */ 444 CRITICAL, 445 /** 446 * Absolute Range for Ordinal and Continuous Observations. Results outside this range are not possible. 447 */ 448 ABSOLUTE, 449 /** 450 * added to help the parsers with the generic types 451 */ 452 NULL; 453 public static ObservationRangeCategory fromCode(String codeString) throws FHIRException { 454 if (codeString == null || "".equals(codeString)) 455 return null; 456 if ("reference".equals(codeString)) 457 return REFERENCE; 458 if ("critical".equals(codeString)) 459 return CRITICAL; 460 if ("absolute".equals(codeString)) 461 return ABSOLUTE; 462 if (Configuration.isAcceptInvalidEnums()) 463 return null; 464 else 465 throw new FHIRException("Unknown ObservationRangeCategory code '"+codeString+"'"); 466 } 467 public String toCode() { 468 switch (this) { 469 case REFERENCE: return "reference"; 470 case CRITICAL: return "critical"; 471 case ABSOLUTE: return "absolute"; 472 default: return "?"; 473 } 474 } 475 public String getSystem() { 476 switch (this) { 477 case REFERENCE: return "http://hl7.org/fhir/observation-range-category"; 478 case CRITICAL: return "http://hl7.org/fhir/observation-range-category"; 479 case ABSOLUTE: return "http://hl7.org/fhir/observation-range-category"; 480 default: return "?"; 481 } 482 } 483 public String getDefinition() { 484 switch (this) { 485 case REFERENCE: return "Reference (Normal) Range for Ordinal and Continuous Observations."; 486 case CRITICAL: return "Critical Range for Ordinal and Continuous Observations. Results outside this range are critical."; 487 case ABSOLUTE: return "Absolute Range for Ordinal and Continuous Observations. Results outside this range are not possible."; 488 default: return "?"; 489 } 490 } 491 public String getDisplay() { 492 switch (this) { 493 case REFERENCE: return "reference range"; 494 case CRITICAL: return "critical range"; 495 case ABSOLUTE: return "absolute range"; 496 default: return "?"; 497 } 498 } 499 } 500 501 public static class ObservationRangeCategoryEnumFactory implements EnumFactory<ObservationRangeCategory> { 502 public ObservationRangeCategory fromCode(String codeString) throws IllegalArgumentException { 503 if (codeString == null || "".equals(codeString)) 504 if (codeString == null || "".equals(codeString)) 505 return null; 506 if ("reference".equals(codeString)) 507 return ObservationRangeCategory.REFERENCE; 508 if ("critical".equals(codeString)) 509 return ObservationRangeCategory.CRITICAL; 510 if ("absolute".equals(codeString)) 511 return ObservationRangeCategory.ABSOLUTE; 512 throw new IllegalArgumentException("Unknown ObservationRangeCategory code '"+codeString+"'"); 513 } 514 public Enumeration<ObservationRangeCategory> fromType(Base code) throws FHIRException { 515 if (code == null) 516 return null; 517 if (code.isEmpty()) 518 return new Enumeration<ObservationRangeCategory>(this); 519 String codeString = ((PrimitiveType) code).asStringValue(); 520 if (codeString == null || "".equals(codeString)) 521 return null; 522 if ("reference".equals(codeString)) 523 return new Enumeration<ObservationRangeCategory>(this, ObservationRangeCategory.REFERENCE); 524 if ("critical".equals(codeString)) 525 return new Enumeration<ObservationRangeCategory>(this, ObservationRangeCategory.CRITICAL); 526 if ("absolute".equals(codeString)) 527 return new Enumeration<ObservationRangeCategory>(this, ObservationRangeCategory.ABSOLUTE); 528 throw new FHIRException("Unknown ObservationRangeCategory code '"+codeString+"'"); 529 } 530 public String toCode(ObservationRangeCategory code) { 531 if (code == ObservationRangeCategory.REFERENCE) 532 return "reference"; 533 if (code == ObservationRangeCategory.CRITICAL) 534 return "critical"; 535 if (code == ObservationRangeCategory.ABSOLUTE) 536 return "absolute"; 537 return "?"; 538 } 539 public String toSystem(ObservationRangeCategory code) { 540 return code.getSystem(); 541 } 542 } 543 544 @Block() 545 public static class ObservationDefinitionQuantitativeDetailsComponent extends BackboneElement implements IBaseBackboneElement { 546 /** 547 * Customary unit used to report quantitative results of observations conforming to this ObservationDefinition. 548 */ 549 @Child(name = "customaryUnit", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 550 @Description(shortDefinition="Customary unit for quantitative results", formalDefinition="Customary unit used to report quantitative results of observations conforming to this ObservationDefinition." ) 551 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/ucum-units") 552 protected CodeableConcept customaryUnit; 553 554 /** 555 * SI unit used to report quantitative results of observations conforming to this ObservationDefinition. 556 */ 557 @Child(name = "unit", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 558 @Description(shortDefinition="SI unit for quantitative results", formalDefinition="SI unit used to report quantitative results of observations conforming to this ObservationDefinition." ) 559 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/ucum-units") 560 protected CodeableConcept unit; 561 562 /** 563 * Factor for converting value expressed with SI unit to value expressed with customary unit. 564 */ 565 @Child(name = "conversionFactor", type = {DecimalType.class}, order=3, min=0, max=1, modifier=false, summary=false) 566 @Description(shortDefinition="SI to Customary unit conversion factor", formalDefinition="Factor for converting value expressed with SI unit to value expressed with customary unit." ) 567 protected DecimalType conversionFactor; 568 569 /** 570 * Number of digits after decimal separator when the results of such observations are of type Quantity. 571 */ 572 @Child(name = "decimalPrecision", type = {IntegerType.class}, order=4, min=0, max=1, modifier=false, summary=false) 573 @Description(shortDefinition="Decimal precision of observation quantitative results", formalDefinition="Number of digits after decimal separator when the results of such observations are of type Quantity." ) 574 protected IntegerType decimalPrecision; 575 576 private static final long serialVersionUID = 1790019610L; 577 578 /** 579 * Constructor 580 */ 581 public ObservationDefinitionQuantitativeDetailsComponent() { 582 super(); 583 } 584 585 /** 586 * @return {@link #customaryUnit} (Customary unit used to report quantitative results of observations conforming to this ObservationDefinition.) 587 */ 588 public CodeableConcept getCustomaryUnit() { 589 if (this.customaryUnit == null) 590 if (Configuration.errorOnAutoCreate()) 591 throw new Error("Attempt to auto-create ObservationDefinitionQuantitativeDetailsComponent.customaryUnit"); 592 else if (Configuration.doAutoCreate()) 593 this.customaryUnit = new CodeableConcept(); // cc 594 return this.customaryUnit; 595 } 596 597 public boolean hasCustomaryUnit() { 598 return this.customaryUnit != null && !this.customaryUnit.isEmpty(); 599 } 600 601 /** 602 * @param value {@link #customaryUnit} (Customary unit used to report quantitative results of observations conforming to this ObservationDefinition.) 603 */ 604 public ObservationDefinitionQuantitativeDetailsComponent setCustomaryUnit(CodeableConcept value) { 605 this.customaryUnit = value; 606 return this; 607 } 608 609 /** 610 * @return {@link #unit} (SI unit used to report quantitative results of observations conforming to this ObservationDefinition.) 611 */ 612 public CodeableConcept getUnit() { 613 if (this.unit == null) 614 if (Configuration.errorOnAutoCreate()) 615 throw new Error("Attempt to auto-create ObservationDefinitionQuantitativeDetailsComponent.unit"); 616 else if (Configuration.doAutoCreate()) 617 this.unit = new CodeableConcept(); // cc 618 return this.unit; 619 } 620 621 public boolean hasUnit() { 622 return this.unit != null && !this.unit.isEmpty(); 623 } 624 625 /** 626 * @param value {@link #unit} (SI unit used to report quantitative results of observations conforming to this ObservationDefinition.) 627 */ 628 public ObservationDefinitionQuantitativeDetailsComponent setUnit(CodeableConcept value) { 629 this.unit = value; 630 return this; 631 } 632 633 /** 634 * @return {@link #conversionFactor} (Factor for converting value expressed with SI unit to value expressed with customary unit.). This is the underlying object with id, value and extensions. The accessor "getConversionFactor" gives direct access to the value 635 */ 636 public DecimalType getConversionFactorElement() { 637 if (this.conversionFactor == null) 638 if (Configuration.errorOnAutoCreate()) 639 throw new Error("Attempt to auto-create ObservationDefinitionQuantitativeDetailsComponent.conversionFactor"); 640 else if (Configuration.doAutoCreate()) 641 this.conversionFactor = new DecimalType(); // bb 642 return this.conversionFactor; 643 } 644 645 public boolean hasConversionFactorElement() { 646 return this.conversionFactor != null && !this.conversionFactor.isEmpty(); 647 } 648 649 public boolean hasConversionFactor() { 650 return this.conversionFactor != null && !this.conversionFactor.isEmpty(); 651 } 652 653 /** 654 * @param value {@link #conversionFactor} (Factor for converting value expressed with SI unit to value expressed with customary unit.). This is the underlying object with id, value and extensions. The accessor "getConversionFactor" gives direct access to the value 655 */ 656 public ObservationDefinitionQuantitativeDetailsComponent setConversionFactorElement(DecimalType value) { 657 this.conversionFactor = value; 658 return this; 659 } 660 661 /** 662 * @return Factor for converting value expressed with SI unit to value expressed with customary unit. 663 */ 664 public BigDecimal getConversionFactor() { 665 return this.conversionFactor == null ? null : this.conversionFactor.getValue(); 666 } 667 668 /** 669 * @param value Factor for converting value expressed with SI unit to value expressed with customary unit. 670 */ 671 public ObservationDefinitionQuantitativeDetailsComponent setConversionFactor(BigDecimal value) { 672 if (value == null) 673 this.conversionFactor = null; 674 else { 675 if (this.conversionFactor == null) 676 this.conversionFactor = new DecimalType(); 677 this.conversionFactor.setValue(value); 678 } 679 return this; 680 } 681 682 /** 683 * @param value Factor for converting value expressed with SI unit to value expressed with customary unit. 684 */ 685 public ObservationDefinitionQuantitativeDetailsComponent setConversionFactor(long value) { 686 this.conversionFactor = new DecimalType(); 687 this.conversionFactor.setValue(value); 688 return this; 689 } 690 691 /** 692 * @param value Factor for converting value expressed with SI unit to value expressed with customary unit. 693 */ 694 public ObservationDefinitionQuantitativeDetailsComponent setConversionFactor(double value) { 695 this.conversionFactor = new DecimalType(); 696 this.conversionFactor.setValue(value); 697 return this; 698 } 699 700 /** 701 * @return {@link #decimalPrecision} (Number of digits after decimal separator when the results of such observations are of type Quantity.). This is the underlying object with id, value and extensions. The accessor "getDecimalPrecision" gives direct access to the value 702 */ 703 public IntegerType getDecimalPrecisionElement() { 704 if (this.decimalPrecision == null) 705 if (Configuration.errorOnAutoCreate()) 706 throw new Error("Attempt to auto-create ObservationDefinitionQuantitativeDetailsComponent.decimalPrecision"); 707 else if (Configuration.doAutoCreate()) 708 this.decimalPrecision = new IntegerType(); // bb 709 return this.decimalPrecision; 710 } 711 712 public boolean hasDecimalPrecisionElement() { 713 return this.decimalPrecision != null && !this.decimalPrecision.isEmpty(); 714 } 715 716 public boolean hasDecimalPrecision() { 717 return this.decimalPrecision != null && !this.decimalPrecision.isEmpty(); 718 } 719 720 /** 721 * @param value {@link #decimalPrecision} (Number of digits after decimal separator when the results of such observations are of type Quantity.). This is the underlying object with id, value and extensions. The accessor "getDecimalPrecision" gives direct access to the value 722 */ 723 public ObservationDefinitionQuantitativeDetailsComponent setDecimalPrecisionElement(IntegerType value) { 724 this.decimalPrecision = value; 725 return this; 726 } 727 728 /** 729 * @return Number of digits after decimal separator when the results of such observations are of type Quantity. 730 */ 731 public int getDecimalPrecision() { 732 return this.decimalPrecision == null || this.decimalPrecision.isEmpty() ? 0 : this.decimalPrecision.getValue(); 733 } 734 735 /** 736 * @param value Number of digits after decimal separator when the results of such observations are of type Quantity. 737 */ 738 public ObservationDefinitionQuantitativeDetailsComponent setDecimalPrecision(int value) { 739 if (this.decimalPrecision == null) 740 this.decimalPrecision = new IntegerType(); 741 this.decimalPrecision.setValue(value); 742 return this; 743 } 744 745 protected void listChildren(List<Property> children) { 746 super.listChildren(children); 747 children.add(new Property("customaryUnit", "CodeableConcept", "Customary unit used to report quantitative results of observations conforming to this ObservationDefinition.", 0, 1, customaryUnit)); 748 children.add(new Property("unit", "CodeableConcept", "SI unit used to report quantitative results of observations conforming to this ObservationDefinition.", 0, 1, unit)); 749 children.add(new Property("conversionFactor", "decimal", "Factor for converting value expressed with SI unit to value expressed with customary unit.", 0, 1, conversionFactor)); 750 children.add(new Property("decimalPrecision", "integer", "Number of digits after decimal separator when the results of such observations are of type Quantity.", 0, 1, decimalPrecision)); 751 } 752 753 @Override 754 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 755 switch (_hash) { 756 case -1375586437: /*customaryUnit*/ return new Property("customaryUnit", "CodeableConcept", "Customary unit used to report quantitative results of observations conforming to this ObservationDefinition.", 0, 1, customaryUnit); 757 case 3594628: /*unit*/ return new Property("unit", "CodeableConcept", "SI unit used to report quantitative results of observations conforming to this ObservationDefinition.", 0, 1, unit); 758 case 1438876165: /*conversionFactor*/ return new Property("conversionFactor", "decimal", "Factor for converting value expressed with SI unit to value expressed with customary unit.", 0, 1, conversionFactor); 759 case -1564447699: /*decimalPrecision*/ return new Property("decimalPrecision", "integer", "Number of digits after decimal separator when the results of such observations are of type Quantity.", 0, 1, decimalPrecision); 760 default: return super.getNamedProperty(_hash, _name, _checkValid); 761 } 762 763 } 764 765 @Override 766 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 767 switch (hash) { 768 case -1375586437: /*customaryUnit*/ return this.customaryUnit == null ? new Base[0] : new Base[] {this.customaryUnit}; // CodeableConcept 769 case 3594628: /*unit*/ return this.unit == null ? new Base[0] : new Base[] {this.unit}; // CodeableConcept 770 case 1438876165: /*conversionFactor*/ return this.conversionFactor == null ? new Base[0] : new Base[] {this.conversionFactor}; // DecimalType 771 case -1564447699: /*decimalPrecision*/ return this.decimalPrecision == null ? new Base[0] : new Base[] {this.decimalPrecision}; // IntegerType 772 default: return super.getProperty(hash, name, checkValid); 773 } 774 775 } 776 777 @Override 778 public Base setProperty(int hash, String name, Base value) throws FHIRException { 779 switch (hash) { 780 case -1375586437: // customaryUnit 781 this.customaryUnit = castToCodeableConcept(value); // CodeableConcept 782 return value; 783 case 3594628: // unit 784 this.unit = castToCodeableConcept(value); // CodeableConcept 785 return value; 786 case 1438876165: // conversionFactor 787 this.conversionFactor = castToDecimal(value); // DecimalType 788 return value; 789 case -1564447699: // decimalPrecision 790 this.decimalPrecision = castToInteger(value); // IntegerType 791 return value; 792 default: return super.setProperty(hash, name, value); 793 } 794 795 } 796 797 @Override 798 public Base setProperty(String name, Base value) throws FHIRException { 799 if (name.equals("customaryUnit")) { 800 this.customaryUnit = castToCodeableConcept(value); // CodeableConcept 801 } else if (name.equals("unit")) { 802 this.unit = castToCodeableConcept(value); // CodeableConcept 803 } else if (name.equals("conversionFactor")) { 804 this.conversionFactor = castToDecimal(value); // DecimalType 805 } else if (name.equals("decimalPrecision")) { 806 this.decimalPrecision = castToInteger(value); // IntegerType 807 } else 808 return super.setProperty(name, value); 809 return value; 810 } 811 812 @Override 813 public Base makeProperty(int hash, String name) throws FHIRException { 814 switch (hash) { 815 case -1375586437: return getCustomaryUnit(); 816 case 3594628: return getUnit(); 817 case 1438876165: return getConversionFactorElement(); 818 case -1564447699: return getDecimalPrecisionElement(); 819 default: return super.makeProperty(hash, name); 820 } 821 822 } 823 824 @Override 825 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 826 switch (hash) { 827 case -1375586437: /*customaryUnit*/ return new String[] {"CodeableConcept"}; 828 case 3594628: /*unit*/ return new String[] {"CodeableConcept"}; 829 case 1438876165: /*conversionFactor*/ return new String[] {"decimal"}; 830 case -1564447699: /*decimalPrecision*/ return new String[] {"integer"}; 831 default: return super.getTypesForProperty(hash, name); 832 } 833 834 } 835 836 @Override 837 public Base addChild(String name) throws FHIRException { 838 if (name.equals("customaryUnit")) { 839 this.customaryUnit = new CodeableConcept(); 840 return this.customaryUnit; 841 } 842 else if (name.equals("unit")) { 843 this.unit = new CodeableConcept(); 844 return this.unit; 845 } 846 else if (name.equals("conversionFactor")) { 847 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.conversionFactor"); 848 } 849 else if (name.equals("decimalPrecision")) { 850 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.decimalPrecision"); 851 } 852 else 853 return super.addChild(name); 854 } 855 856 public ObservationDefinitionQuantitativeDetailsComponent copy() { 857 ObservationDefinitionQuantitativeDetailsComponent dst = new ObservationDefinitionQuantitativeDetailsComponent(); 858 copyValues(dst); 859 return dst; 860 } 861 862 public void copyValues(ObservationDefinitionQuantitativeDetailsComponent dst) { 863 super.copyValues(dst); 864 dst.customaryUnit = customaryUnit == null ? null : customaryUnit.copy(); 865 dst.unit = unit == null ? null : unit.copy(); 866 dst.conversionFactor = conversionFactor == null ? null : conversionFactor.copy(); 867 dst.decimalPrecision = decimalPrecision == null ? null : decimalPrecision.copy(); 868 } 869 870 @Override 871 public boolean equalsDeep(Base other_) { 872 if (!super.equalsDeep(other_)) 873 return false; 874 if (!(other_ instanceof ObservationDefinitionQuantitativeDetailsComponent)) 875 return false; 876 ObservationDefinitionQuantitativeDetailsComponent o = (ObservationDefinitionQuantitativeDetailsComponent) other_; 877 return compareDeep(customaryUnit, o.customaryUnit, true) && compareDeep(unit, o.unit, true) && compareDeep(conversionFactor, o.conversionFactor, true) 878 && compareDeep(decimalPrecision, o.decimalPrecision, true); 879 } 880 881 @Override 882 public boolean equalsShallow(Base other_) { 883 if (!super.equalsShallow(other_)) 884 return false; 885 if (!(other_ instanceof ObservationDefinitionQuantitativeDetailsComponent)) 886 return false; 887 ObservationDefinitionQuantitativeDetailsComponent o = (ObservationDefinitionQuantitativeDetailsComponent) other_; 888 return compareValues(conversionFactor, o.conversionFactor, true) && compareValues(decimalPrecision, o.decimalPrecision, true) 889 ; 890 } 891 892 public boolean isEmpty() { 893 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(customaryUnit, unit, conversionFactor 894 , decimalPrecision); 895 } 896 897 public String fhirType() { 898 return "ObservationDefinition.quantitativeDetails"; 899 900 } 901 902 } 903 904 @Block() 905 public static class ObservationDefinitionQualifiedIntervalComponent extends BackboneElement implements IBaseBackboneElement { 906 /** 907 * The category of interval of values for continuous or ordinal observations conforming to this ObservationDefinition. 908 */ 909 @Child(name = "category", type = {CodeType.class}, order=1, min=0, max=1, modifier=false, summary=false) 910 @Description(shortDefinition="reference | critical | absolute", formalDefinition="The category of interval of values for continuous or ordinal observations conforming to this ObservationDefinition." ) 911 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-range-category") 912 protected Enumeration<ObservationRangeCategory> category; 913 914 /** 915 * The low and high values determining the interval. There may be only one of the two. 916 */ 917 @Child(name = "range", type = {Range.class}, order=2, min=0, max=1, modifier=false, summary=false) 918 @Description(shortDefinition="The interval itself, for continuous or ordinal observations", formalDefinition="The low and high values determining the interval. There may be only one of the two." ) 919 protected Range range; 920 921 /** 922 * Codes to indicate the health context the range applies to. For example, the normal or therapeutic range. 923 */ 924 @Child(name = "context", type = {CodeableConcept.class}, order=3, min=0, max=1, modifier=false, summary=false) 925 @Description(shortDefinition="Range context qualifier", formalDefinition="Codes to indicate the health context the range applies to. For example, the normal or therapeutic range." ) 926 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/referencerange-meaning") 927 protected CodeableConcept context; 928 929 /** 930 * Codes to indicate the target population this reference range applies to. 931 */ 932 @Child(name = "appliesTo", type = {CodeableConcept.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 933 @Description(shortDefinition="Targetted population of the range", formalDefinition="Codes to indicate the target population this reference range applies to." ) 934 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/referencerange-appliesto") 935 protected List<CodeableConcept> appliesTo; 936 937 /** 938 * Sex of the population the range applies to. 939 */ 940 @Child(name = "gender", type = {CodeType.class}, order=5, min=0, max=1, modifier=false, summary=false) 941 @Description(shortDefinition="male | female | other | unknown", formalDefinition="Sex of the population the range applies to." ) 942 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/administrative-gender") 943 protected Enumeration<AdministrativeGender> gender; 944 945 /** 946 * The age at which this reference range is applicable. This is a neonatal age (e.g. number of weeks at term) if the meaning says so. 947 */ 948 @Child(name = "age", type = {Range.class}, order=6, min=0, max=1, modifier=false, summary=false) 949 @Description(shortDefinition="Applicable age range, if relevant", formalDefinition="The age at which this reference range is applicable. This is a neonatal age (e.g. number of weeks at term) if the meaning says so." ) 950 protected Range age; 951 952 /** 953 * The gestational age to which this reference range is applicable, in the context of pregnancy. 954 */ 955 @Child(name = "gestationalAge", type = {Range.class}, order=7, min=0, max=1, modifier=false, summary=false) 956 @Description(shortDefinition="Applicable gestational age range, if relevant", formalDefinition="The gestational age to which this reference range is applicable, in the context of pregnancy." ) 957 protected Range gestationalAge; 958 959 /** 960 * Text based condition for which the reference range is valid. 961 */ 962 @Child(name = "condition", type = {StringType.class}, order=8, min=0, max=1, modifier=false, summary=false) 963 @Description(shortDefinition="Condition associated with the reference range", formalDefinition="Text based condition for which the reference range is valid." ) 964 protected StringType condition; 965 966 private static final long serialVersionUID = -416423468L; 967 968 /** 969 * Constructor 970 */ 971 public ObservationDefinitionQualifiedIntervalComponent() { 972 super(); 973 } 974 975 /** 976 * @return {@link #category} (The category of interval of values for continuous or ordinal observations conforming to this ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getCategory" gives direct access to the value 977 */ 978 public Enumeration<ObservationRangeCategory> getCategoryElement() { 979 if (this.category == null) 980 if (Configuration.errorOnAutoCreate()) 981 throw new Error("Attempt to auto-create ObservationDefinitionQualifiedIntervalComponent.category"); 982 else if (Configuration.doAutoCreate()) 983 this.category = new Enumeration<ObservationRangeCategory>(new ObservationRangeCategoryEnumFactory()); // bb 984 return this.category; 985 } 986 987 public boolean hasCategoryElement() { 988 return this.category != null && !this.category.isEmpty(); 989 } 990 991 public boolean hasCategory() { 992 return this.category != null && !this.category.isEmpty(); 993 } 994 995 /** 996 * @param value {@link #category} (The category of interval of values for continuous or ordinal observations conforming to this ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getCategory" gives direct access to the value 997 */ 998 public ObservationDefinitionQualifiedIntervalComponent setCategoryElement(Enumeration<ObservationRangeCategory> value) { 999 this.category = value; 1000 return this; 1001 } 1002 1003 /** 1004 * @return The category of interval of values for continuous or ordinal observations conforming to this ObservationDefinition. 1005 */ 1006 public ObservationRangeCategory getCategory() { 1007 return this.category == null ? null : this.category.getValue(); 1008 } 1009 1010 /** 1011 * @param value The category of interval of values for continuous or ordinal observations conforming to this ObservationDefinition. 1012 */ 1013 public ObservationDefinitionQualifiedIntervalComponent setCategory(ObservationRangeCategory value) { 1014 if (value == null) 1015 this.category = null; 1016 else { 1017 if (this.category == null) 1018 this.category = new Enumeration<ObservationRangeCategory>(new ObservationRangeCategoryEnumFactory()); 1019 this.category.setValue(value); 1020 } 1021 return this; 1022 } 1023 1024 /** 1025 * @return {@link #range} (The low and high values determining the interval. There may be only one of the two.) 1026 */ 1027 public Range getRange() { 1028 if (this.range == null) 1029 if (Configuration.errorOnAutoCreate()) 1030 throw new Error("Attempt to auto-create ObservationDefinitionQualifiedIntervalComponent.range"); 1031 else if (Configuration.doAutoCreate()) 1032 this.range = new Range(); // cc 1033 return this.range; 1034 } 1035 1036 public boolean hasRange() { 1037 return this.range != null && !this.range.isEmpty(); 1038 } 1039 1040 /** 1041 * @param value {@link #range} (The low and high values determining the interval. There may be only one of the two.) 1042 */ 1043 public ObservationDefinitionQualifiedIntervalComponent setRange(Range value) { 1044 this.range = value; 1045 return this; 1046 } 1047 1048 /** 1049 * @return {@link #context} (Codes to indicate the health context the range applies to. For example, the normal or therapeutic range.) 1050 */ 1051 public CodeableConcept getContext() { 1052 if (this.context == null) 1053 if (Configuration.errorOnAutoCreate()) 1054 throw new Error("Attempt to auto-create ObservationDefinitionQualifiedIntervalComponent.context"); 1055 else if (Configuration.doAutoCreate()) 1056 this.context = new CodeableConcept(); // cc 1057 return this.context; 1058 } 1059 1060 public boolean hasContext() { 1061 return this.context != null && !this.context.isEmpty(); 1062 } 1063 1064 /** 1065 * @param value {@link #context} (Codes to indicate the health context the range applies to. For example, the normal or therapeutic range.) 1066 */ 1067 public ObservationDefinitionQualifiedIntervalComponent setContext(CodeableConcept value) { 1068 this.context = value; 1069 return this; 1070 } 1071 1072 /** 1073 * @return {@link #appliesTo} (Codes to indicate the target population this reference range applies to.) 1074 */ 1075 public List<CodeableConcept> getAppliesTo() { 1076 if (this.appliesTo == null) 1077 this.appliesTo = new ArrayList<CodeableConcept>(); 1078 return this.appliesTo; 1079 } 1080 1081 /** 1082 * @return Returns a reference to <code>this</code> for easy method chaining 1083 */ 1084 public ObservationDefinitionQualifiedIntervalComponent setAppliesTo(List<CodeableConcept> theAppliesTo) { 1085 this.appliesTo = theAppliesTo; 1086 return this; 1087 } 1088 1089 public boolean hasAppliesTo() { 1090 if (this.appliesTo == null) 1091 return false; 1092 for (CodeableConcept item : this.appliesTo) 1093 if (!item.isEmpty()) 1094 return true; 1095 return false; 1096 } 1097 1098 public CodeableConcept addAppliesTo() { //3 1099 CodeableConcept t = new CodeableConcept(); 1100 if (this.appliesTo == null) 1101 this.appliesTo = new ArrayList<CodeableConcept>(); 1102 this.appliesTo.add(t); 1103 return t; 1104 } 1105 1106 public ObservationDefinitionQualifiedIntervalComponent addAppliesTo(CodeableConcept t) { //3 1107 if (t == null) 1108 return this; 1109 if (this.appliesTo == null) 1110 this.appliesTo = new ArrayList<CodeableConcept>(); 1111 this.appliesTo.add(t); 1112 return this; 1113 } 1114 1115 /** 1116 * @return The first repetition of repeating field {@link #appliesTo}, creating it if it does not already exist 1117 */ 1118 public CodeableConcept getAppliesToFirstRep() { 1119 if (getAppliesTo().isEmpty()) { 1120 addAppliesTo(); 1121 } 1122 return getAppliesTo().get(0); 1123 } 1124 1125 /** 1126 * @return {@link #gender} (Sex of the population the range applies to.). This is the underlying object with id, value and extensions. The accessor "getGender" gives direct access to the value 1127 */ 1128 public Enumeration<AdministrativeGender> getGenderElement() { 1129 if (this.gender == null) 1130 if (Configuration.errorOnAutoCreate()) 1131 throw new Error("Attempt to auto-create ObservationDefinitionQualifiedIntervalComponent.gender"); 1132 else if (Configuration.doAutoCreate()) 1133 this.gender = new Enumeration<AdministrativeGender>(new AdministrativeGenderEnumFactory()); // bb 1134 return this.gender; 1135 } 1136 1137 public boolean hasGenderElement() { 1138 return this.gender != null && !this.gender.isEmpty(); 1139 } 1140 1141 public boolean hasGender() { 1142 return this.gender != null && !this.gender.isEmpty(); 1143 } 1144 1145 /** 1146 * @param value {@link #gender} (Sex of the population the range applies to.). This is the underlying object with id, value and extensions. The accessor "getGender" gives direct access to the value 1147 */ 1148 public ObservationDefinitionQualifiedIntervalComponent setGenderElement(Enumeration<AdministrativeGender> value) { 1149 this.gender = value; 1150 return this; 1151 } 1152 1153 /** 1154 * @return Sex of the population the range applies to. 1155 */ 1156 public AdministrativeGender getGender() { 1157 return this.gender == null ? null : this.gender.getValue(); 1158 } 1159 1160 /** 1161 * @param value Sex of the population the range applies to. 1162 */ 1163 public ObservationDefinitionQualifiedIntervalComponent setGender(AdministrativeGender value) { 1164 if (value == null) 1165 this.gender = null; 1166 else { 1167 if (this.gender == null) 1168 this.gender = new Enumeration<AdministrativeGender>(new AdministrativeGenderEnumFactory()); 1169 this.gender.setValue(value); 1170 } 1171 return this; 1172 } 1173 1174 /** 1175 * @return {@link #age} (The age at which this reference range is applicable. This is a neonatal age (e.g. number of weeks at term) if the meaning says so.) 1176 */ 1177 public Range getAge() { 1178 if (this.age == null) 1179 if (Configuration.errorOnAutoCreate()) 1180 throw new Error("Attempt to auto-create ObservationDefinitionQualifiedIntervalComponent.age"); 1181 else if (Configuration.doAutoCreate()) 1182 this.age = new Range(); // cc 1183 return this.age; 1184 } 1185 1186 public boolean hasAge() { 1187 return this.age != null && !this.age.isEmpty(); 1188 } 1189 1190 /** 1191 * @param value {@link #age} (The age at which this reference range is applicable. This is a neonatal age (e.g. number of weeks at term) if the meaning says so.) 1192 */ 1193 public ObservationDefinitionQualifiedIntervalComponent setAge(Range value) { 1194 this.age = value; 1195 return this; 1196 } 1197 1198 /** 1199 * @return {@link #gestationalAge} (The gestational age to which this reference range is applicable, in the context of pregnancy.) 1200 */ 1201 public Range getGestationalAge() { 1202 if (this.gestationalAge == null) 1203 if (Configuration.errorOnAutoCreate()) 1204 throw new Error("Attempt to auto-create ObservationDefinitionQualifiedIntervalComponent.gestationalAge"); 1205 else if (Configuration.doAutoCreate()) 1206 this.gestationalAge = new Range(); // cc 1207 return this.gestationalAge; 1208 } 1209 1210 public boolean hasGestationalAge() { 1211 return this.gestationalAge != null && !this.gestationalAge.isEmpty(); 1212 } 1213 1214 /** 1215 * @param value {@link #gestationalAge} (The gestational age to which this reference range is applicable, in the context of pregnancy.) 1216 */ 1217 public ObservationDefinitionQualifiedIntervalComponent setGestationalAge(Range value) { 1218 this.gestationalAge = value; 1219 return this; 1220 } 1221 1222 /** 1223 * @return {@link #condition} (Text based condition for which the reference range is valid.). This is the underlying object with id, value and extensions. The accessor "getCondition" gives direct access to the value 1224 */ 1225 public StringType getConditionElement() { 1226 if (this.condition == null) 1227 if (Configuration.errorOnAutoCreate()) 1228 throw new Error("Attempt to auto-create ObservationDefinitionQualifiedIntervalComponent.condition"); 1229 else if (Configuration.doAutoCreate()) 1230 this.condition = new StringType(); // bb 1231 return this.condition; 1232 } 1233 1234 public boolean hasConditionElement() { 1235 return this.condition != null && !this.condition.isEmpty(); 1236 } 1237 1238 public boolean hasCondition() { 1239 return this.condition != null && !this.condition.isEmpty(); 1240 } 1241 1242 /** 1243 * @param value {@link #condition} (Text based condition for which the reference range is valid.). This is the underlying object with id, value and extensions. The accessor "getCondition" gives direct access to the value 1244 */ 1245 public ObservationDefinitionQualifiedIntervalComponent setConditionElement(StringType value) { 1246 this.condition = value; 1247 return this; 1248 } 1249 1250 /** 1251 * @return Text based condition for which the reference range is valid. 1252 */ 1253 public String getCondition() { 1254 return this.condition == null ? null : this.condition.getValue(); 1255 } 1256 1257 /** 1258 * @param value Text based condition for which the reference range is valid. 1259 */ 1260 public ObservationDefinitionQualifiedIntervalComponent setCondition(String value) { 1261 if (Utilities.noString(value)) 1262 this.condition = null; 1263 else { 1264 if (this.condition == null) 1265 this.condition = new StringType(); 1266 this.condition.setValue(value); 1267 } 1268 return this; 1269 } 1270 1271 protected void listChildren(List<Property> children) { 1272 super.listChildren(children); 1273 children.add(new Property("category", "code", "The category of interval of values for continuous or ordinal observations conforming to this ObservationDefinition.", 0, 1, category)); 1274 children.add(new Property("range", "Range", "The low and high values determining the interval. There may be only one of the two.", 0, 1, range)); 1275 children.add(new Property("context", "CodeableConcept", "Codes to indicate the health context the range applies to. For example, the normal or therapeutic range.", 0, 1, context)); 1276 children.add(new Property("appliesTo", "CodeableConcept", "Codes to indicate the target population this reference range applies to.", 0, java.lang.Integer.MAX_VALUE, appliesTo)); 1277 children.add(new Property("gender", "code", "Sex of the population the range applies to.", 0, 1, gender)); 1278 children.add(new Property("age", "Range", "The age at which this reference range is applicable. This is a neonatal age (e.g. number of weeks at term) if the meaning says so.", 0, 1, age)); 1279 children.add(new Property("gestationalAge", "Range", "The gestational age to which this reference range is applicable, in the context of pregnancy.", 0, 1, gestationalAge)); 1280 children.add(new Property("condition", "string", "Text based condition for which the reference range is valid.", 0, 1, condition)); 1281 } 1282 1283 @Override 1284 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1285 switch (_hash) { 1286 case 50511102: /*category*/ return new Property("category", "code", "The category of interval of values for continuous or ordinal observations conforming to this ObservationDefinition.", 0, 1, category); 1287 case 108280125: /*range*/ return new Property("range", "Range", "The low and high values determining the interval. There may be only one of the two.", 0, 1, range); 1288 case 951530927: /*context*/ return new Property("context", "CodeableConcept", "Codes to indicate the health context the range applies to. For example, the normal or therapeutic range.", 0, 1, context); 1289 case -2089924569: /*appliesTo*/ return new Property("appliesTo", "CodeableConcept", "Codes to indicate the target population this reference range applies to.", 0, java.lang.Integer.MAX_VALUE, appliesTo); 1290 case -1249512767: /*gender*/ return new Property("gender", "code", "Sex of the population the range applies to.", 0, 1, gender); 1291 case 96511: /*age*/ return new Property("age", "Range", "The age at which this reference range is applicable. This is a neonatal age (e.g. number of weeks at term) if the meaning says so.", 0, 1, age); 1292 case -241217538: /*gestationalAge*/ return new Property("gestationalAge", "Range", "The gestational age to which this reference range is applicable, in the context of pregnancy.", 0, 1, gestationalAge); 1293 case -861311717: /*condition*/ return new Property("condition", "string", "Text based condition for which the reference range is valid.", 0, 1, condition); 1294 default: return super.getNamedProperty(_hash, _name, _checkValid); 1295 } 1296 1297 } 1298 1299 @Override 1300 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1301 switch (hash) { 1302 case 50511102: /*category*/ return this.category == null ? new Base[0] : new Base[] {this.category}; // Enumeration<ObservationRangeCategory> 1303 case 108280125: /*range*/ return this.range == null ? new Base[0] : new Base[] {this.range}; // Range 1304 case 951530927: /*context*/ return this.context == null ? new Base[0] : new Base[] {this.context}; // CodeableConcept 1305 case -2089924569: /*appliesTo*/ return this.appliesTo == null ? new Base[0] : this.appliesTo.toArray(new Base[this.appliesTo.size()]); // CodeableConcept 1306 case -1249512767: /*gender*/ return this.gender == null ? new Base[0] : new Base[] {this.gender}; // Enumeration<AdministrativeGender> 1307 case 96511: /*age*/ return this.age == null ? new Base[0] : new Base[] {this.age}; // Range 1308 case -241217538: /*gestationalAge*/ return this.gestationalAge == null ? new Base[0] : new Base[] {this.gestationalAge}; // Range 1309 case -861311717: /*condition*/ return this.condition == null ? new Base[0] : new Base[] {this.condition}; // StringType 1310 default: return super.getProperty(hash, name, checkValid); 1311 } 1312 1313 } 1314 1315 @Override 1316 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1317 switch (hash) { 1318 case 50511102: // category 1319 value = new ObservationRangeCategoryEnumFactory().fromType(castToCode(value)); 1320 this.category = (Enumeration) value; // Enumeration<ObservationRangeCategory> 1321 return value; 1322 case 108280125: // range 1323 this.range = castToRange(value); // Range 1324 return value; 1325 case 951530927: // context 1326 this.context = castToCodeableConcept(value); // CodeableConcept 1327 return value; 1328 case -2089924569: // appliesTo 1329 this.getAppliesTo().add(castToCodeableConcept(value)); // CodeableConcept 1330 return value; 1331 case -1249512767: // gender 1332 value = new AdministrativeGenderEnumFactory().fromType(castToCode(value)); 1333 this.gender = (Enumeration) value; // Enumeration<AdministrativeGender> 1334 return value; 1335 case 96511: // age 1336 this.age = castToRange(value); // Range 1337 return value; 1338 case -241217538: // gestationalAge 1339 this.gestationalAge = castToRange(value); // Range 1340 return value; 1341 case -861311717: // condition 1342 this.condition = castToString(value); // StringType 1343 return value; 1344 default: return super.setProperty(hash, name, value); 1345 } 1346 1347 } 1348 1349 @Override 1350 public Base setProperty(String name, Base value) throws FHIRException { 1351 if (name.equals("category")) { 1352 value = new ObservationRangeCategoryEnumFactory().fromType(castToCode(value)); 1353 this.category = (Enumeration) value; // Enumeration<ObservationRangeCategory> 1354 } else if (name.equals("range")) { 1355 this.range = castToRange(value); // Range 1356 } else if (name.equals("context")) { 1357 this.context = castToCodeableConcept(value); // CodeableConcept 1358 } else if (name.equals("appliesTo")) { 1359 this.getAppliesTo().add(castToCodeableConcept(value)); 1360 } else if (name.equals("gender")) { 1361 value = new AdministrativeGenderEnumFactory().fromType(castToCode(value)); 1362 this.gender = (Enumeration) value; // Enumeration<AdministrativeGender> 1363 } else if (name.equals("age")) { 1364 this.age = castToRange(value); // Range 1365 } else if (name.equals("gestationalAge")) { 1366 this.gestationalAge = castToRange(value); // Range 1367 } else if (name.equals("condition")) { 1368 this.condition = castToString(value); // StringType 1369 } else 1370 return super.setProperty(name, value); 1371 return value; 1372 } 1373 1374 @Override 1375 public Base makeProperty(int hash, String name) throws FHIRException { 1376 switch (hash) { 1377 case 50511102: return getCategoryElement(); 1378 case 108280125: return getRange(); 1379 case 951530927: return getContext(); 1380 case -2089924569: return addAppliesTo(); 1381 case -1249512767: return getGenderElement(); 1382 case 96511: return getAge(); 1383 case -241217538: return getGestationalAge(); 1384 case -861311717: return getConditionElement(); 1385 default: return super.makeProperty(hash, name); 1386 } 1387 1388 } 1389 1390 @Override 1391 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1392 switch (hash) { 1393 case 50511102: /*category*/ return new String[] {"code"}; 1394 case 108280125: /*range*/ return new String[] {"Range"}; 1395 case 951530927: /*context*/ return new String[] {"CodeableConcept"}; 1396 case -2089924569: /*appliesTo*/ return new String[] {"CodeableConcept"}; 1397 case -1249512767: /*gender*/ return new String[] {"code"}; 1398 case 96511: /*age*/ return new String[] {"Range"}; 1399 case -241217538: /*gestationalAge*/ return new String[] {"Range"}; 1400 case -861311717: /*condition*/ return new String[] {"string"}; 1401 default: return super.getTypesForProperty(hash, name); 1402 } 1403 1404 } 1405 1406 @Override 1407 public Base addChild(String name) throws FHIRException { 1408 if (name.equals("category")) { 1409 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.category"); 1410 } 1411 else if (name.equals("range")) { 1412 this.range = new Range(); 1413 return this.range; 1414 } 1415 else if (name.equals("context")) { 1416 this.context = new CodeableConcept(); 1417 return this.context; 1418 } 1419 else if (name.equals("appliesTo")) { 1420 return addAppliesTo(); 1421 } 1422 else if (name.equals("gender")) { 1423 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.gender"); 1424 } 1425 else if (name.equals("age")) { 1426 this.age = new Range(); 1427 return this.age; 1428 } 1429 else if (name.equals("gestationalAge")) { 1430 this.gestationalAge = new Range(); 1431 return this.gestationalAge; 1432 } 1433 else if (name.equals("condition")) { 1434 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.condition"); 1435 } 1436 else 1437 return super.addChild(name); 1438 } 1439 1440 public ObservationDefinitionQualifiedIntervalComponent copy() { 1441 ObservationDefinitionQualifiedIntervalComponent dst = new ObservationDefinitionQualifiedIntervalComponent(); 1442 copyValues(dst); 1443 return dst; 1444 } 1445 1446 public void copyValues(ObservationDefinitionQualifiedIntervalComponent dst) { 1447 super.copyValues(dst); 1448 dst.category = category == null ? null : category.copy(); 1449 dst.range = range == null ? null : range.copy(); 1450 dst.context = context == null ? null : context.copy(); 1451 if (appliesTo != null) { 1452 dst.appliesTo = new ArrayList<CodeableConcept>(); 1453 for (CodeableConcept i : appliesTo) 1454 dst.appliesTo.add(i.copy()); 1455 }; 1456 dst.gender = gender == null ? null : gender.copy(); 1457 dst.age = age == null ? null : age.copy(); 1458 dst.gestationalAge = gestationalAge == null ? null : gestationalAge.copy(); 1459 dst.condition = condition == null ? null : condition.copy(); 1460 } 1461 1462 @Override 1463 public boolean equalsDeep(Base other_) { 1464 if (!super.equalsDeep(other_)) 1465 return false; 1466 if (!(other_ instanceof ObservationDefinitionQualifiedIntervalComponent)) 1467 return false; 1468 ObservationDefinitionQualifiedIntervalComponent o = (ObservationDefinitionQualifiedIntervalComponent) other_; 1469 return compareDeep(category, o.category, true) && compareDeep(range, o.range, true) && compareDeep(context, o.context, true) 1470 && compareDeep(appliesTo, o.appliesTo, true) && compareDeep(gender, o.gender, true) && compareDeep(age, o.age, true) 1471 && compareDeep(gestationalAge, o.gestationalAge, true) && compareDeep(condition, o.condition, true) 1472 ; 1473 } 1474 1475 @Override 1476 public boolean equalsShallow(Base other_) { 1477 if (!super.equalsShallow(other_)) 1478 return false; 1479 if (!(other_ instanceof ObservationDefinitionQualifiedIntervalComponent)) 1480 return false; 1481 ObservationDefinitionQualifiedIntervalComponent o = (ObservationDefinitionQualifiedIntervalComponent) other_; 1482 return compareValues(category, o.category, true) && compareValues(gender, o.gender, true) && compareValues(condition, o.condition, true) 1483 ; 1484 } 1485 1486 public boolean isEmpty() { 1487 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(category, range, context 1488 , appliesTo, gender, age, gestationalAge, condition); 1489 } 1490 1491 public String fhirType() { 1492 return "ObservationDefinition.qualifiedInterval"; 1493 1494 } 1495 1496 } 1497 1498 @Block() 1499 public static class ObservationDefinitionComponentComponent extends BackboneElement implements IBaseBackboneElement { 1500 /** 1501 * Describes what will be observed. 1502 */ 1503 @Child(name = "code", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 1504 @Description(shortDefinition="Type of observation", formalDefinition="Describes what will be observed." ) 1505 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-codes") 1506 protected CodeableConcept code; 1507 1508 /** 1509 * The data types allowed for the value element of the instance of this component observations. 1510 */ 1511 @Child(name = "permittedDataType", type = {CodeType.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1512 @Description(shortDefinition="Quantity | CodeableConcept | string | boolean | integer | Range | Ratio | SampledData | time | dateTime | Period", formalDefinition="The data types allowed for the value element of the instance of this component observations." ) 1513 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/permitted-data-type") 1514 protected List<Enumeration<ObservationDataType>> permittedDataType; 1515 1516 /** 1517 * The quantitative details specified. 1518 */ 1519 @Child(name = "quantitativeDetails", type = {ObservationDefinitionQuantitativeDetailsComponent.class}, order=3, min=0, max=1, modifier=false, summary=false) 1520 @Description(shortDefinition="Quantitative details", formalDefinition="The quantitative details specified." ) 1521 protected ObservationDefinitionQuantitativeDetailsComponent quantitativeDetails; 1522 1523 /** 1524 * The qualified interval specified. 1525 */ 1526 @Child(name = "qualifiedInterval", type = {ObservationDefinitionQualifiedIntervalComponent.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1527 @Description(shortDefinition="Qualified interval", formalDefinition="The qualified interval specified." ) 1528 protected List<ObservationDefinitionQualifiedIntervalComponent> qualifiedInterval; 1529 1530 private static final long serialVersionUID = 527664521L; 1531 1532 /** 1533 * Constructor 1534 */ 1535 public ObservationDefinitionComponentComponent() { 1536 super(); 1537 } 1538 1539 /** 1540 * Constructor 1541 */ 1542 public ObservationDefinitionComponentComponent(CodeableConcept code) { 1543 super(); 1544 this.code = code; 1545 } 1546 1547 /** 1548 * @return {@link #code} (Describes what will be observed.) 1549 */ 1550 public CodeableConcept getCode() { 1551 if (this.code == null) 1552 if (Configuration.errorOnAutoCreate()) 1553 throw new Error("Attempt to auto-create ObservationDefinitionComponentComponent.code"); 1554 else if (Configuration.doAutoCreate()) 1555 this.code = new CodeableConcept(); // cc 1556 return this.code; 1557 } 1558 1559 public boolean hasCode() { 1560 return this.code != null && !this.code.isEmpty(); 1561 } 1562 1563 /** 1564 * @param value {@link #code} (Describes what will be observed.) 1565 */ 1566 public ObservationDefinitionComponentComponent setCode(CodeableConcept value) { 1567 this.code = value; 1568 return this; 1569 } 1570 1571 /** 1572 * @return {@link #permittedDataType} (The data types allowed for the value element of the instance of this component observations.) 1573 */ 1574 public List<Enumeration<ObservationDataType>> getPermittedDataType() { 1575 if (this.permittedDataType == null) 1576 this.permittedDataType = new ArrayList<Enumeration<ObservationDataType>>(); 1577 return this.permittedDataType; 1578 } 1579 1580 /** 1581 * @return Returns a reference to <code>this</code> for easy method chaining 1582 */ 1583 public ObservationDefinitionComponentComponent setPermittedDataType(List<Enumeration<ObservationDataType>> thePermittedDataType) { 1584 this.permittedDataType = thePermittedDataType; 1585 return this; 1586 } 1587 1588 public boolean hasPermittedDataType() { 1589 if (this.permittedDataType == null) 1590 return false; 1591 for (Enumeration<ObservationDataType> item : this.permittedDataType) 1592 if (!item.isEmpty()) 1593 return true; 1594 return false; 1595 } 1596 1597 /** 1598 * @return {@link #permittedDataType} (The data types allowed for the value element of the instance of this component observations.) 1599 */ 1600 public Enumeration<ObservationDataType> addPermittedDataTypeElement() {//2 1601 Enumeration<ObservationDataType> t = new Enumeration<ObservationDataType>(new ObservationDataTypeEnumFactory()); 1602 if (this.permittedDataType == null) 1603 this.permittedDataType = new ArrayList<Enumeration<ObservationDataType>>(); 1604 this.permittedDataType.add(t); 1605 return t; 1606 } 1607 1608 /** 1609 * @param value {@link #permittedDataType} (The data types allowed for the value element of the instance of this component observations.) 1610 */ 1611 public ObservationDefinitionComponentComponent addPermittedDataType(ObservationDataType value) { //1 1612 Enumeration<ObservationDataType> t = new Enumeration<ObservationDataType>(new ObservationDataTypeEnumFactory()); 1613 t.setValue(value); 1614 if (this.permittedDataType == null) 1615 this.permittedDataType = new ArrayList<Enumeration<ObservationDataType>>(); 1616 this.permittedDataType.add(t); 1617 return this; 1618 } 1619 1620 /** 1621 * @param value {@link #permittedDataType} (The data types allowed for the value element of the instance of this component observations.) 1622 */ 1623 public boolean hasPermittedDataType(ObservationDataType value) { 1624 if (this.permittedDataType == null) 1625 return false; 1626 for (Enumeration<ObservationDataType> v : this.permittedDataType) 1627 if (v.getValue().equals(value)) // code 1628 return true; 1629 return false; 1630 } 1631 1632 /** 1633 * @return {@link #quantitativeDetails} (The quantitative details specified.) 1634 */ 1635 public ObservationDefinitionQuantitativeDetailsComponent getQuantitativeDetails() { 1636 if (this.quantitativeDetails == null) 1637 if (Configuration.errorOnAutoCreate()) 1638 throw new Error("Attempt to auto-create ObservationDefinitionComponentComponent.quantitativeDetails"); 1639 else if (Configuration.doAutoCreate()) 1640 this.quantitativeDetails = new ObservationDefinitionQuantitativeDetailsComponent(); // cc 1641 return this.quantitativeDetails; 1642 } 1643 1644 public boolean hasQuantitativeDetails() { 1645 return this.quantitativeDetails != null && !this.quantitativeDetails.isEmpty(); 1646 } 1647 1648 /** 1649 * @param value {@link #quantitativeDetails} (The quantitative details specified.) 1650 */ 1651 public ObservationDefinitionComponentComponent setQuantitativeDetails(ObservationDefinitionQuantitativeDetailsComponent value) { 1652 this.quantitativeDetails = value; 1653 return this; 1654 } 1655 1656 /** 1657 * @return {@link #qualifiedInterval} (The qualified interval specified.) 1658 */ 1659 public List<ObservationDefinitionQualifiedIntervalComponent> getQualifiedInterval() { 1660 if (this.qualifiedInterval == null) 1661 this.qualifiedInterval = new ArrayList<ObservationDefinitionQualifiedIntervalComponent>(); 1662 return this.qualifiedInterval; 1663 } 1664 1665 /** 1666 * @return Returns a reference to <code>this</code> for easy method chaining 1667 */ 1668 public ObservationDefinitionComponentComponent setQualifiedInterval(List<ObservationDefinitionQualifiedIntervalComponent> theQualifiedInterval) { 1669 this.qualifiedInterval = theQualifiedInterval; 1670 return this; 1671 } 1672 1673 public boolean hasQualifiedInterval() { 1674 if (this.qualifiedInterval == null) 1675 return false; 1676 for (ObservationDefinitionQualifiedIntervalComponent item : this.qualifiedInterval) 1677 if (!item.isEmpty()) 1678 return true; 1679 return false; 1680 } 1681 1682 public ObservationDefinitionQualifiedIntervalComponent addQualifiedInterval() { //3 1683 ObservationDefinitionQualifiedIntervalComponent t = new ObservationDefinitionQualifiedIntervalComponent(); 1684 if (this.qualifiedInterval == null) 1685 this.qualifiedInterval = new ArrayList<ObservationDefinitionQualifiedIntervalComponent>(); 1686 this.qualifiedInterval.add(t); 1687 return t; 1688 } 1689 1690 public ObservationDefinitionComponentComponent addQualifiedInterval(ObservationDefinitionQualifiedIntervalComponent t) { //3 1691 if (t == null) 1692 return this; 1693 if (this.qualifiedInterval == null) 1694 this.qualifiedInterval = new ArrayList<ObservationDefinitionQualifiedIntervalComponent>(); 1695 this.qualifiedInterval.add(t); 1696 return this; 1697 } 1698 1699 /** 1700 * @return The first repetition of repeating field {@link #qualifiedInterval}, creating it if it does not already exist 1701 */ 1702 public ObservationDefinitionQualifiedIntervalComponent getQualifiedIntervalFirstRep() { 1703 if (getQualifiedInterval().isEmpty()) { 1704 addQualifiedInterval(); 1705 } 1706 return getQualifiedInterval().get(0); 1707 } 1708 1709 protected void listChildren(List<Property> children) { 1710 super.listChildren(children); 1711 children.add(new Property("code", "CodeableConcept", "Describes what will be observed.", 0, 1, code)); 1712 children.add(new Property("permittedDataType", "code", "The data types allowed for the value element of the instance of this component observations.", 0, java.lang.Integer.MAX_VALUE, permittedDataType)); 1713 children.add(new Property("quantitativeDetails", "@ObservationDefinition.quantitativeDetails", "The quantitative details specified.", 0, 1, quantitativeDetails)); 1714 children.add(new Property("qualifiedInterval", "@ObservationDefinition.qualifiedInterval", "The qualified interval specified.", 0, java.lang.Integer.MAX_VALUE, qualifiedInterval)); 1715 } 1716 1717 @Override 1718 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1719 switch (_hash) { 1720 case 3059181: /*code*/ return new Property("code", "CodeableConcept", "Describes what will be observed.", 0, 1, code); 1721 case -99492804: /*permittedDataType*/ return new Property("permittedDataType", "code", "The data types allowed for the value element of the instance of this component observations.", 0, java.lang.Integer.MAX_VALUE, permittedDataType); 1722 case 842150763: /*quantitativeDetails*/ return new Property("quantitativeDetails", "@ObservationDefinition.quantitativeDetails", "The quantitative details specified.", 0, 1, quantitativeDetails); 1723 case 1882971521: /*qualifiedInterval*/ return new Property("qualifiedInterval", "@ObservationDefinition.qualifiedInterval", "The qualified interval specified.", 0, java.lang.Integer.MAX_VALUE, qualifiedInterval); 1724 default: return super.getNamedProperty(_hash, _name, _checkValid); 1725 } 1726 1727 } 1728 1729 @Override 1730 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1731 switch (hash) { 1732 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 1733 case -99492804: /*permittedDataType*/ return this.permittedDataType == null ? new Base[0] : this.permittedDataType.toArray(new Base[this.permittedDataType.size()]); // Enumeration<ObservationDataType> 1734 case 842150763: /*quantitativeDetails*/ return this.quantitativeDetails == null ? new Base[0] : new Base[] {this.quantitativeDetails}; // ObservationDefinitionQuantitativeDetailsComponent 1735 case 1882971521: /*qualifiedInterval*/ return this.qualifiedInterval == null ? new Base[0] : this.qualifiedInterval.toArray(new Base[this.qualifiedInterval.size()]); // ObservationDefinitionQualifiedIntervalComponent 1736 default: return super.getProperty(hash, name, checkValid); 1737 } 1738 1739 } 1740 1741 @Override 1742 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1743 switch (hash) { 1744 case 3059181: // code 1745 this.code = castToCodeableConcept(value); // CodeableConcept 1746 return value; 1747 case -99492804: // permittedDataType 1748 value = new ObservationDataTypeEnumFactory().fromType(castToCode(value)); 1749 this.getPermittedDataType().add((Enumeration) value); // Enumeration<ObservationDataType> 1750 return value; 1751 case 842150763: // quantitativeDetails 1752 this.quantitativeDetails = (ObservationDefinitionQuantitativeDetailsComponent) value; // ObservationDefinitionQuantitativeDetailsComponent 1753 return value; 1754 case 1882971521: // qualifiedInterval 1755 this.getQualifiedInterval().add((ObservationDefinitionQualifiedIntervalComponent) value); // ObservationDefinitionQualifiedIntervalComponent 1756 return value; 1757 default: return super.setProperty(hash, name, value); 1758 } 1759 1760 } 1761 1762 @Override 1763 public Base setProperty(String name, Base value) throws FHIRException { 1764 if (name.equals("code")) { 1765 this.code = castToCodeableConcept(value); // CodeableConcept 1766 } else if (name.equals("permittedDataType")) { 1767 value = new ObservationDataTypeEnumFactory().fromType(castToCode(value)); 1768 this.getPermittedDataType().add((Enumeration) value); 1769 } else if (name.equals("quantitativeDetails")) { 1770 this.quantitativeDetails = (ObservationDefinitionQuantitativeDetailsComponent) value; // ObservationDefinitionQuantitativeDetailsComponent 1771 } else if (name.equals("qualifiedInterval")) { 1772 this.getQualifiedInterval().add((ObservationDefinitionQualifiedIntervalComponent) value); 1773 } else 1774 return super.setProperty(name, value); 1775 return value; 1776 } 1777 1778 @Override 1779 public Base makeProperty(int hash, String name) throws FHIRException { 1780 switch (hash) { 1781 case 3059181: return getCode(); 1782 case -99492804: return addPermittedDataTypeElement(); 1783 case 842150763: return getQuantitativeDetails(); 1784 case 1882971521: return addQualifiedInterval(); 1785 default: return super.makeProperty(hash, name); 1786 } 1787 1788 } 1789 1790 @Override 1791 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1792 switch (hash) { 1793 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 1794 case -99492804: /*permittedDataType*/ return new String[] {"code"}; 1795 case 842150763: /*quantitativeDetails*/ return new String[] {"@ObservationDefinition.quantitativeDetails"}; 1796 case 1882971521: /*qualifiedInterval*/ return new String[] {"@ObservationDefinition.qualifiedInterval"}; 1797 default: return super.getTypesForProperty(hash, name); 1798 } 1799 1800 } 1801 1802 @Override 1803 public Base addChild(String name) throws FHIRException { 1804 if (name.equals("code")) { 1805 this.code = new CodeableConcept(); 1806 return this.code; 1807 } 1808 else if (name.equals("permittedDataType")) { 1809 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.permittedDataType"); 1810 } 1811 else if (name.equals("quantitativeDetails")) { 1812 this.quantitativeDetails = new ObservationDefinitionQuantitativeDetailsComponent(); 1813 return this.quantitativeDetails; 1814 } 1815 else if (name.equals("qualifiedInterval")) { 1816 return addQualifiedInterval(); 1817 } 1818 else 1819 return super.addChild(name); 1820 } 1821 1822 public ObservationDefinitionComponentComponent copy() { 1823 ObservationDefinitionComponentComponent dst = new ObservationDefinitionComponentComponent(); 1824 copyValues(dst); 1825 return dst; 1826 } 1827 1828 public void copyValues(ObservationDefinitionComponentComponent dst) { 1829 super.copyValues(dst); 1830 dst.code = code == null ? null : code.copy(); 1831 if (permittedDataType != null) { 1832 dst.permittedDataType = new ArrayList<Enumeration<ObservationDataType>>(); 1833 for (Enumeration<ObservationDataType> i : permittedDataType) 1834 dst.permittedDataType.add(i.copy()); 1835 }; 1836 dst.quantitativeDetails = quantitativeDetails == null ? null : quantitativeDetails.copy(); 1837 if (qualifiedInterval != null) { 1838 dst.qualifiedInterval = new ArrayList<ObservationDefinitionQualifiedIntervalComponent>(); 1839 for (ObservationDefinitionQualifiedIntervalComponent i : qualifiedInterval) 1840 dst.qualifiedInterval.add(i.copy()); 1841 }; 1842 } 1843 1844 @Override 1845 public boolean equalsDeep(Base other_) { 1846 if (!super.equalsDeep(other_)) 1847 return false; 1848 if (!(other_ instanceof ObservationDefinitionComponentComponent)) 1849 return false; 1850 ObservationDefinitionComponentComponent o = (ObservationDefinitionComponentComponent) other_; 1851 return compareDeep(code, o.code, true) && compareDeep(permittedDataType, o.permittedDataType, true) 1852 && compareDeep(quantitativeDetails, o.quantitativeDetails, true) && compareDeep(qualifiedInterval, o.qualifiedInterval, true) 1853 ; 1854 } 1855 1856 @Override 1857 public boolean equalsShallow(Base other_) { 1858 if (!super.equalsShallow(other_)) 1859 return false; 1860 if (!(other_ instanceof ObservationDefinitionComponentComponent)) 1861 return false; 1862 ObservationDefinitionComponentComponent o = (ObservationDefinitionComponentComponent) other_; 1863 return compareValues(permittedDataType, o.permittedDataType, true); 1864 } 1865 1866 public boolean isEmpty() { 1867 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, permittedDataType, quantitativeDetails 1868 , qualifiedInterval); 1869 } 1870 1871 public String fhirType() { 1872 return "ObservationDefinition.component"; 1873 1874 } 1875 1876 } 1877 1878 /** 1879 * An absolute URL that is used to identify this ObservationDefinition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this ObservationDefinition is (or will be) published. The URL SHOULD include the major version of the ObservationDefinition. For more information see Technical and Business Versions. 1880 */ 1881 @Child(name = "url", type = {UriType.class}, order=0, min=0, max=1, modifier=false, summary=true) 1882 @Description(shortDefinition="Logical canonical URL to reference this ObservationDefinition (globally unique)", formalDefinition="An absolute URL that is used to identify this ObservationDefinition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this ObservationDefinition is (or will be) published. The URL SHOULD include the major version of the ObservationDefinition. For more information see Technical and Business Versions." ) 1883 protected UriType url; 1884 1885 /** 1886 * Business identifiers assigned to this ObservationDefinition. by the performer and/or other systems. These identifiers remain constant as the resource is updated and propagates from server to server. 1887 */ 1888 @Child(name = "identifier", type = {Identifier.class}, order=1, min=0, max=1, modifier=false, summary=true) 1889 @Description(shortDefinition="Business identifier of the ObservationDefinition", formalDefinition="Business identifiers assigned to this ObservationDefinition. by the performer and/or other systems. These identifiers remain constant as the resource is updated and propagates from server to server." ) 1890 protected Identifier identifier; 1891 1892 /** 1893 * The identifier that is used to identify this version of the ObservationDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the ObservationDefinition 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 are orderable. 1894 */ 1895 @Child(name = "version", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=true) 1896 @Description(shortDefinition="Business version of the ObservationDefinition", formalDefinition="The identifier that is used to identify this version of the ObservationDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the ObservationDefinition 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 are orderable." ) 1897 protected StringType version; 1898 1899 /** 1900 * A short, descriptive, user-friendly title for the ObservationDefinition. 1901 */ 1902 @Child(name = "title", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=true) 1903 @Description(shortDefinition="Name for this ObservationDefinition (Human friendly)", formalDefinition="A short, descriptive, user-friendly title for the ObservationDefinition." ) 1904 protected StringType title; 1905 1906 /** 1907 * The canonical URL pointing to another FHIR-defined ObservationDefinition that is adhered to in whole or in part by this definition. 1908 */ 1909 @Child(name = "derivedFromCanonical", type = {CanonicalType.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1910 @Description(shortDefinition="Based on FHIR definition of another observation", formalDefinition="The canonical URL pointing to another FHIR-defined ObservationDefinition that is adhered to in whole or in part by this definition." ) 1911 protected List<CanonicalType> derivedFromCanonical; 1912 1913 /** 1914 * The URL pointing to an externally-defined observation definition, guideline or other definition that is adhered to in whole or in part by this definition. 1915 */ 1916 @Child(name = "derivedFromUri", type = {UriType.class}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1917 @Description(shortDefinition="Based on external definition", formalDefinition="The URL pointing to an externally-defined observation definition, guideline or other definition that is adhered to in whole or in part by this definition." ) 1918 protected List<UriType> derivedFromUri; 1919 1920 /** 1921 * The current state of the ObservationDefinition. 1922 */ 1923 @Child(name = "status", type = {CodeType.class}, order=6, min=1, max=1, modifier=true, summary=true) 1924 @Description(shortDefinition="draft | active | retired | unknown", formalDefinition="The current state of the ObservationDefinition." ) 1925 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/publication-status") 1926 protected Enumeration<PublicationStatus> status; 1927 1928 /** 1929 * A flag to indicate that this ObservationDefinition is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage. 1930 */ 1931 @Child(name = "experimental", type = {BooleanType.class}, order=7, min=0, max=1, modifier=true, summary=true) 1932 @Description(shortDefinition="If for testing purposes, not real usage", formalDefinition="A flag to indicate that this ObservationDefinition is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage." ) 1933 protected BooleanType experimental; 1934 1935 /** 1936 * A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition. 1937 */ 1938 @Child(name = "subject", type = {CodeableConcept.class, Group.class}, order=8, min=0, max=1, modifier=false, summary=true) 1939 @Description(shortDefinition="Type of subject for the defined observation", formalDefinition="A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition." ) 1940 protected Type subject; 1941 1942 /** 1943 * For draft definitions, indicates the date of initial creation. For active definitions, represents the date of activation. For withdrawn definitions, indicates the date of withdrawal. 1944 */ 1945 @Child(name = "date", type = {DateTimeType.class}, order=9, min=0, max=1, modifier=false, summary=true) 1946 @Description(shortDefinition="Date status first applied", formalDefinition="For draft definitions, indicates the date of initial creation. For active definitions, represents the date of activation. For withdrawn definitions, indicates the date of withdrawal." ) 1947 protected DateTimeType date; 1948 1949 /** 1950 * Helps establish the "authority/credibility" of the ObservationDefinition. May also allow for contact. 1951 */ 1952 @Child(name = "publisher", type = {Practitioner.class, PractitionerRole.class, Organization.class}, order=10, min=0, max=1, modifier=false, summary=true) 1953 @Description(shortDefinition="The name of the individual or organization that published the ObservationDefinition", formalDefinition="Helps establish the \"authority/credibility\" of the ObservationDefinition. May also allow for contact." ) 1954 protected Reference publisher; 1955 1956 /** 1957 * Contact details to assist a user in finding and communicating with the publisher. 1958 */ 1959 @Child(name = "contact", type = {ContactDetail.class}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1960 @Description(shortDefinition="Contact details for the publisher", formalDefinition="Contact details to assist a user in finding and communicating with the publisher." ) 1961 protected List<ContactDetail> contact; 1962 1963 /** 1964 * A free text natural language description of the ObservationDefinition from the consumer's perspective. 1965 */ 1966 @Child(name = "description", type = {MarkdownType.class}, order=12, min=0, max=1, modifier=false, summary=false) 1967 @Description(shortDefinition="Natural language description of the ObservationDefinition", formalDefinition="A free text natural language description of the ObservationDefinition from the consumer's perspective." ) 1968 protected MarkdownType description; 1969 1970 /** 1971 * The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of observation definitions. 1972 */ 1973 @Child(name = "useContext", type = {UsageContext.class}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1974 @Description(shortDefinition="Content intends to support these contexts", formalDefinition="The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of observation definitions." ) 1975 protected List<UsageContext> useContext; 1976 1977 /** 1978 * A jurisdiction in which the ObservationDefinition is intended to be used. 1979 */ 1980 @Child(name = "jurisdiction", type = {CodeableConcept.class}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1981 @Description(shortDefinition="Intended jurisdiction for this ObservationDefinition (if applicable)", formalDefinition="A jurisdiction in which the ObservationDefinition is intended to be used." ) 1982 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/jurisdiction") 1983 protected List<CodeableConcept> jurisdiction; 1984 1985 /** 1986 * Explains why this ObservationDefinition is needed and why it has been designed as it has. 1987 */ 1988 @Child(name = "purpose", type = {MarkdownType.class}, order=15, min=0, max=1, modifier=false, summary=false) 1989 @Description(shortDefinition="Why this ObservationDefinition is defined", formalDefinition="Explains why this ObservationDefinition is needed and why it has been designed as it has." ) 1990 protected MarkdownType purpose; 1991 1992 /** 1993 * Copyright statement relating to the ObservationDefinition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the ObservationDefinition. 1994 */ 1995 @Child(name = "copyright", type = {MarkdownType.class}, order=16, min=0, max=1, modifier=false, summary=false) 1996 @Description(shortDefinition="Use and/or publishing restrictions", formalDefinition="Copyright statement relating to the ObservationDefinition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the ObservationDefinition." ) 1997 protected MarkdownType copyright; 1998 1999 /** 2000 * The date on which the asset content was approved by the publisher. Approval happens once when the content is officially approved for usage. 2001 */ 2002 @Child(name = "approvalDate", type = {DateType.class}, order=17, min=0, max=1, modifier=false, summary=false) 2003 @Description(shortDefinition="When ObservationDefinition was approved by publisher", formalDefinition="The date on which the asset content was approved by the publisher. Approval happens once when the content is officially approved for usage." ) 2004 protected DateType approvalDate; 2005 2006 /** 2007 * The date on which the asset content was last reviewed. Review happens periodically after that, but doesn't change the original approval date. 2008 */ 2009 @Child(name = "lastReviewDate", type = {DateType.class}, order=18, min=0, max=1, modifier=false, summary=false) 2010 @Description(shortDefinition="Last review date for the ObservationDefinition", formalDefinition="The date on which the asset content was last reviewed. Review happens periodically after that, but doesn't change the original approval date." ) 2011 protected DateType lastReviewDate; 2012 2013 /** 2014 * The period during which the ObservationDefinition content was or is planned to be effective. 2015 */ 2016 @Child(name = "effectivePeriod", type = {Period.class}, order=19, min=0, max=1, modifier=false, summary=true) 2017 @Description(shortDefinition="The effective date range for the ObservationDefinition", formalDefinition="The period during which the ObservationDefinition content was or is planned to be effective." ) 2018 protected Period effectivePeriod; 2019 2020 /** 2021 * The type of individual/organization/device that is expected to act upon instances of this definition. 2022 */ 2023 @Child(name = "performerType", type = {CodeableConcept.class}, order=20, min=0, max=1, modifier=false, summary=true) 2024 @Description(shortDefinition="Desired kind of performer for such kind of observation", formalDefinition="The type of individual/organization/device that is expected to act upon instances of this definition." ) 2025 protected CodeableConcept performerType; 2026 2027 /** 2028 * A code that classifies the general type of observation. 2029 */ 2030 @Child(name = "category", type = {CodeableConcept.class}, order=21, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 2031 @Description(shortDefinition="Category of observation", formalDefinition="A code that classifies the general type of observation." ) 2032 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-category") 2033 protected List<CodeableConcept> category; 2034 2035 /** 2036 * Describes what will be observed. Sometimes this is called the observation "name". 2037 */ 2038 @Child(name = "code", type = {CodeableConcept.class}, order=22, min=1, max=1, modifier=false, summary=true) 2039 @Description(shortDefinition="Type of observation", formalDefinition="Describes what will be observed. Sometimes this is called the observation \"name\"." ) 2040 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-codes") 2041 protected CodeableConcept code; 2042 2043 /** 2044 * The data types allowed for the value element of the instance observations conforming to this ObservationDefinition. 2045 */ 2046 @Child(name = "permittedDataType", type = {CodeType.class}, order=23, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2047 @Description(shortDefinition="Quantity | CodeableConcept | string | boolean | integer | Range | Ratio | SampledData | time | dateTime | Period", formalDefinition="The data types allowed for the value element of the instance observations conforming to this ObservationDefinition." ) 2048 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/permitted-data-type") 2049 protected List<Enumeration<ObservationDataType>> permittedDataType; 2050 2051 /** 2052 * Multiple results allowed for observations conforming to this ObservationDefinition. 2053 */ 2054 @Child(name = "multipleResultsAllowed", type = {BooleanType.class}, order=24, min=0, max=1, modifier=false, summary=false) 2055 @Description(shortDefinition="Multiple results allowed", formalDefinition="Multiple results allowed for observations conforming to this ObservationDefinition." ) 2056 protected BooleanType multipleResultsAllowed; 2057 2058 /** 2059 * The site on the subject's body where the observation is to be made. 2060 */ 2061 @Child(name = "bodySite", type = {CodeableConcept.class}, order=25, min=0, max=1, modifier=false, summary=false) 2062 @Description(shortDefinition="Body part to be observed", formalDefinition="The site on the subject's body where the observation is to be made." ) 2063 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/body-site") 2064 protected CodeableConcept bodySite; 2065 2066 /** 2067 * The method or technique used to perform the observation. 2068 */ 2069 @Child(name = "method", type = {CodeableConcept.class}, order=26, min=0, max=1, modifier=false, summary=false) 2070 @Description(shortDefinition="Method used to produce the observation", formalDefinition="The method or technique used to perform the observation." ) 2071 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-methods") 2072 protected CodeableConcept method; 2073 2074 /** 2075 * The kind of specimen that this type of observation is produced on. 2076 */ 2077 @Child(name = "specimen", type = {SpecimenDefinition.class}, order=27, min=0, max=1, modifier=false, summary=false) 2078 @Description(shortDefinition="Kind of specimen used by this type of observation", formalDefinition="The kind of specimen that this type of observation is produced on." ) 2079 protected Reference specimen; 2080 2081 /** 2082 * The measurement device used to produce observations of this type. 2083 */ 2084 @Child(name = "device", type = {Device.class}, order=28, min=0, max=1, modifier=false, summary=false) 2085 @Description(shortDefinition="Measurement device", formalDefinition="The measurement device used to produce observations of this type." ) 2086 protected Reference device; 2087 2088 /** 2089 * The preferred name to be used when reporting the results of observations conforming to this ObservationDefinition. 2090 */ 2091 @Child(name = "preferredReportName", type = {StringType.class}, order=29, min=0, max=1, modifier=false, summary=false) 2092 @Description(shortDefinition="Preferred report name", formalDefinition="The preferred name to be used when reporting the results of observations conforming to this ObservationDefinition." ) 2093 protected StringType preferredReportName; 2094 2095 /** 2096 * Characteristics for quantitative results of this observation. 2097 */ 2098 @Child(name = "quantitativeDetails", type = {}, order=30, min=0, max=1, modifier=false, summary=false) 2099 @Description(shortDefinition="Characteristics of quantitative results", formalDefinition="Characteristics for quantitative results of this observation." ) 2100 protected ObservationDefinitionQuantitativeDetailsComponent quantitativeDetails; 2101 2102 /** 2103 * Multiple ranges of results qualified by different contexts for ordinal or continuous observations conforming to this ObservationDefinition. 2104 */ 2105 @Child(name = "qualifiedInterval", type = {}, order=31, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2106 @Description(shortDefinition="Qualified range for continuous and ordinal observation results", formalDefinition="Multiple ranges of results qualified by different contexts for ordinal or continuous observations conforming to this ObservationDefinition." ) 2107 protected List<ObservationDefinitionQualifiedIntervalComponent> qualifiedInterval; 2108 2109 /** 2110 * The set of valid coded results for the observations conforming to this ObservationDefinition. 2111 */ 2112 @Child(name = "validCodedValueSet", type = {ValueSet.class}, order=32, min=0, max=1, modifier=false, summary=false) 2113 @Description(shortDefinition="Value set of valid coded values for the observations conforming to this ObservationDefinition", formalDefinition="The set of valid coded results for the observations conforming to this ObservationDefinition." ) 2114 protected Reference validCodedValueSet; 2115 2116 /** 2117 * The set of normal coded results for the observations conforming to this ObservationDefinition. 2118 */ 2119 @Child(name = "normalCodedValueSet", type = {ValueSet.class}, order=33, min=0, max=1, modifier=false, summary=false) 2120 @Description(shortDefinition="Value set of normal coded values for the observations conforming to this ObservationDefinition", formalDefinition="The set of normal coded results for the observations conforming to this ObservationDefinition." ) 2121 protected Reference normalCodedValueSet; 2122 2123 /** 2124 * The set of abnormal coded results for the observation conforming to this ObservationDefinition. 2125 */ 2126 @Child(name = "abnormalCodedValueSet", type = {ValueSet.class}, order=34, min=0, max=1, modifier=false, summary=false) 2127 @Description(shortDefinition="Value set of abnormal coded values for the observations conforming to this ObservationDefinition", formalDefinition="The set of abnormal coded results for the observation conforming to this ObservationDefinition." ) 2128 protected Reference abnormalCodedValueSet; 2129 2130 /** 2131 * The set of critical coded results for the observation conforming to this ObservationDefinition. 2132 */ 2133 @Child(name = "criticalCodedValueSet", type = {ValueSet.class}, order=35, min=0, max=1, modifier=false, summary=false) 2134 @Description(shortDefinition="Value set of critical coded values for the observations conforming to this ObservationDefinition", formalDefinition="The set of critical coded results for the observation conforming to this ObservationDefinition." ) 2135 protected Reference criticalCodedValueSet; 2136 2137 /** 2138 * This ObservationDefinition defines a group observation (e.g. a battery, a panel of tests, a set of vital sign measurements) that includes the target as a member of the group. 2139 */ 2140 @Child(name = "hasMember", type = {ObservationDefinition.class, Questionnaire.class}, order=36, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2141 @Description(shortDefinition="Definitions of related resources belonging to this kind of observation group", formalDefinition="This ObservationDefinition defines a group observation (e.g. a battery, a panel of tests, a set of vital sign measurements) that includes the target as a member of the group." ) 2142 protected List<Reference> hasMember; 2143 2144 /** 2145 * Some observations have multiple component observations, expressed as separate code value pairs. 2146 */ 2147 @Child(name = "component", type = {}, order=37, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2148 @Description(shortDefinition="Component results", formalDefinition="Some observations have multiple component observations, expressed as separate code value pairs." ) 2149 protected List<ObservationDefinitionComponentComponent> component; 2150 2151 private static final long serialVersionUID = 1657059612L; 2152 2153 /** 2154 * Constructor 2155 */ 2156 public ObservationDefinition() { 2157 super(); 2158 } 2159 2160 /** 2161 * Constructor 2162 */ 2163 public ObservationDefinition(Enumeration<PublicationStatus> status, CodeableConcept code) { 2164 super(); 2165 this.status = status; 2166 this.code = code; 2167 } 2168 2169 /** 2170 * @return {@link #url} (An absolute URL that is used to identify this ObservationDefinition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this ObservationDefinition is (or will be) published. The URL SHOULD include the major version of the ObservationDefinition. For more information see Technical and Business Versions.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 2171 */ 2172 public UriType getUrlElement() { 2173 if (this.url == null) 2174 if (Configuration.errorOnAutoCreate()) 2175 throw new Error("Attempt to auto-create ObservationDefinition.url"); 2176 else if (Configuration.doAutoCreate()) 2177 this.url = new UriType(); // bb 2178 return this.url; 2179 } 2180 2181 public boolean hasUrlElement() { 2182 return this.url != null && !this.url.isEmpty(); 2183 } 2184 2185 public boolean hasUrl() { 2186 return this.url != null && !this.url.isEmpty(); 2187 } 2188 2189 /** 2190 * @param value {@link #url} (An absolute URL that is used to identify this ObservationDefinition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this ObservationDefinition is (or will be) published. The URL SHOULD include the major version of the ObservationDefinition. For more information see Technical and Business Versions.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 2191 */ 2192 public ObservationDefinition setUrlElement(UriType value) { 2193 this.url = value; 2194 return this; 2195 } 2196 2197 /** 2198 * @return An absolute URL that is used to identify this ObservationDefinition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this ObservationDefinition is (or will be) published. The URL SHOULD include the major version of the ObservationDefinition. For more information see Technical and Business Versions. 2199 */ 2200 public String getUrl() { 2201 return this.url == null ? null : this.url.getValue(); 2202 } 2203 2204 /** 2205 * @param value An absolute URL that is used to identify this ObservationDefinition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this ObservationDefinition is (or will be) published. The URL SHOULD include the major version of the ObservationDefinition. For more information see Technical and Business Versions. 2206 */ 2207 public ObservationDefinition setUrl(String value) { 2208 if (Utilities.noString(value)) 2209 this.url = null; 2210 else { 2211 if (this.url == null) 2212 this.url = new UriType(); 2213 this.url.setValue(value); 2214 } 2215 return this; 2216 } 2217 2218 /** 2219 * @return {@link #identifier} (Business identifiers assigned to this ObservationDefinition. by the performer and/or other systems. These identifiers remain constant as the resource is updated and propagates from server to server.) 2220 */ 2221 public Identifier getIdentifier() { 2222 if (this.identifier == null) 2223 if (Configuration.errorOnAutoCreate()) 2224 throw new Error("Attempt to auto-create ObservationDefinition.identifier"); 2225 else if (Configuration.doAutoCreate()) 2226 this.identifier = new Identifier(); // cc 2227 return this.identifier; 2228 } 2229 2230 public boolean hasIdentifier() { 2231 return this.identifier != null && !this.identifier.isEmpty(); 2232 } 2233 2234 /** 2235 * @param value {@link #identifier} (Business identifiers assigned to this ObservationDefinition. by the performer and/or other systems. These identifiers remain constant as the resource is updated and propagates from server to server.) 2236 */ 2237 public ObservationDefinition setIdentifier(Identifier value) { 2238 this.identifier = value; 2239 return this; 2240 } 2241 2242 /** 2243 * @return {@link #version} (The identifier that is used to identify this version of the ObservationDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the ObservationDefinition 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 are orderable.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value 2244 */ 2245 public StringType getVersionElement() { 2246 if (this.version == null) 2247 if (Configuration.errorOnAutoCreate()) 2248 throw new Error("Attempt to auto-create ObservationDefinition.version"); 2249 else if (Configuration.doAutoCreate()) 2250 this.version = new StringType(); // bb 2251 return this.version; 2252 } 2253 2254 public boolean hasVersionElement() { 2255 return this.version != null && !this.version.isEmpty(); 2256 } 2257 2258 public boolean hasVersion() { 2259 return this.version != null && !this.version.isEmpty(); 2260 } 2261 2262 /** 2263 * @param value {@link #version} (The identifier that is used to identify this version of the ObservationDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the ObservationDefinition 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 are orderable.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value 2264 */ 2265 public ObservationDefinition setVersionElement(StringType value) { 2266 this.version = value; 2267 return this; 2268 } 2269 2270 /** 2271 * @return The identifier that is used to identify this version of the ObservationDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the ObservationDefinition 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 are orderable. 2272 */ 2273 public String getVersion() { 2274 return this.version == null ? null : this.version.getValue(); 2275 } 2276 2277 /** 2278 * @param value The identifier that is used to identify this version of the ObservationDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the ObservationDefinition 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 are orderable. 2279 */ 2280 public ObservationDefinition setVersion(String value) { 2281 if (Utilities.noString(value)) 2282 this.version = null; 2283 else { 2284 if (this.version == null) 2285 this.version = new StringType(); 2286 this.version.setValue(value); 2287 } 2288 return this; 2289 } 2290 2291 /** 2292 * @return {@link #title} (A short, descriptive, user-friendly title for the ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 2293 */ 2294 public StringType getTitleElement() { 2295 if (this.title == null) 2296 if (Configuration.errorOnAutoCreate()) 2297 throw new Error("Attempt to auto-create ObservationDefinition.title"); 2298 else if (Configuration.doAutoCreate()) 2299 this.title = new StringType(); // bb 2300 return this.title; 2301 } 2302 2303 public boolean hasTitleElement() { 2304 return this.title != null && !this.title.isEmpty(); 2305 } 2306 2307 public boolean hasTitle() { 2308 return this.title != null && !this.title.isEmpty(); 2309 } 2310 2311 /** 2312 * @param value {@link #title} (A short, descriptive, user-friendly title for the ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 2313 */ 2314 public ObservationDefinition setTitleElement(StringType value) { 2315 this.title = value; 2316 return this; 2317 } 2318 2319 /** 2320 * @return A short, descriptive, user-friendly title for the ObservationDefinition. 2321 */ 2322 public String getTitle() { 2323 return this.title == null ? null : this.title.getValue(); 2324 } 2325 2326 /** 2327 * @param value A short, descriptive, user-friendly title for the ObservationDefinition. 2328 */ 2329 public ObservationDefinition setTitle(String value) { 2330 if (Utilities.noString(value)) 2331 this.title = null; 2332 else { 2333 if (this.title == null) 2334 this.title = new StringType(); 2335 this.title.setValue(value); 2336 } 2337 return this; 2338 } 2339 2340 /** 2341 * @return {@link #derivedFromCanonical} (The canonical URL pointing to another FHIR-defined ObservationDefinition that is adhered to in whole or in part by this definition.) 2342 */ 2343 public List<CanonicalType> getDerivedFromCanonical() { 2344 if (this.derivedFromCanonical == null) 2345 this.derivedFromCanonical = new ArrayList<CanonicalType>(); 2346 return this.derivedFromCanonical; 2347 } 2348 2349 /** 2350 * @return Returns a reference to <code>this</code> for easy method chaining 2351 */ 2352 public ObservationDefinition setDerivedFromCanonical(List<CanonicalType> theDerivedFromCanonical) { 2353 this.derivedFromCanonical = theDerivedFromCanonical; 2354 return this; 2355 } 2356 2357 public boolean hasDerivedFromCanonical() { 2358 if (this.derivedFromCanonical == null) 2359 return false; 2360 for (CanonicalType item : this.derivedFromCanonical) 2361 if (!item.isEmpty()) 2362 return true; 2363 return false; 2364 } 2365 2366 /** 2367 * @return {@link #derivedFromCanonical} (The canonical URL pointing to another FHIR-defined ObservationDefinition that is adhered to in whole or in part by this definition.) 2368 */ 2369 public CanonicalType addDerivedFromCanonicalElement() {//2 2370 CanonicalType t = new CanonicalType(); 2371 if (this.derivedFromCanonical == null) 2372 this.derivedFromCanonical = new ArrayList<CanonicalType>(); 2373 this.derivedFromCanonical.add(t); 2374 return t; 2375 } 2376 2377 /** 2378 * @param value {@link #derivedFromCanonical} (The canonical URL pointing to another FHIR-defined ObservationDefinition that is adhered to in whole or in part by this definition.) 2379 */ 2380 public ObservationDefinition addDerivedFromCanonical(String value) { //1 2381 CanonicalType t = new CanonicalType(); 2382 t.setValue(value); 2383 if (this.derivedFromCanonical == null) 2384 this.derivedFromCanonical = new ArrayList<CanonicalType>(); 2385 this.derivedFromCanonical.add(t); 2386 return this; 2387 } 2388 2389 /** 2390 * @param value {@link #derivedFromCanonical} (The canonical URL pointing to another FHIR-defined ObservationDefinition that is adhered to in whole or in part by this definition.) 2391 */ 2392 public boolean hasDerivedFromCanonical(String value) { 2393 if (this.derivedFromCanonical == null) 2394 return false; 2395 for (CanonicalType v : this.derivedFromCanonical) 2396 if (v.getValue().equals(value)) // canonical(ObservationDefinition) 2397 return true; 2398 return false; 2399 } 2400 2401 /** 2402 * @return {@link #derivedFromUri} (The URL pointing to an externally-defined observation definition, guideline or other definition that is adhered to in whole or in part by this definition.) 2403 */ 2404 public List<UriType> getDerivedFromUri() { 2405 if (this.derivedFromUri == null) 2406 this.derivedFromUri = new ArrayList<UriType>(); 2407 return this.derivedFromUri; 2408 } 2409 2410 /** 2411 * @return Returns a reference to <code>this</code> for easy method chaining 2412 */ 2413 public ObservationDefinition setDerivedFromUri(List<UriType> theDerivedFromUri) { 2414 this.derivedFromUri = theDerivedFromUri; 2415 return this; 2416 } 2417 2418 public boolean hasDerivedFromUri() { 2419 if (this.derivedFromUri == null) 2420 return false; 2421 for (UriType item : this.derivedFromUri) 2422 if (!item.isEmpty()) 2423 return true; 2424 return false; 2425 } 2426 2427 /** 2428 * @return {@link #derivedFromUri} (The URL pointing to an externally-defined observation definition, guideline or other definition that is adhered to in whole or in part by this definition.) 2429 */ 2430 public UriType addDerivedFromUriElement() {//2 2431 UriType t = new UriType(); 2432 if (this.derivedFromUri == null) 2433 this.derivedFromUri = new ArrayList<UriType>(); 2434 this.derivedFromUri.add(t); 2435 return t; 2436 } 2437 2438 /** 2439 * @param value {@link #derivedFromUri} (The URL pointing to an externally-defined observation definition, guideline or other definition that is adhered to in whole or in part by this definition.) 2440 */ 2441 public ObservationDefinition addDerivedFromUri(String value) { //1 2442 UriType t = new UriType(); 2443 t.setValue(value); 2444 if (this.derivedFromUri == null) 2445 this.derivedFromUri = new ArrayList<UriType>(); 2446 this.derivedFromUri.add(t); 2447 return this; 2448 } 2449 2450 /** 2451 * @param value {@link #derivedFromUri} (The URL pointing to an externally-defined observation definition, guideline or other definition that is adhered to in whole or in part by this definition.) 2452 */ 2453 public boolean hasDerivedFromUri(String value) { 2454 if (this.derivedFromUri == null) 2455 return false; 2456 for (UriType v : this.derivedFromUri) 2457 if (v.getValue().equals(value)) // uri 2458 return true; 2459 return false; 2460 } 2461 2462 /** 2463 * @return {@link #status} (The current state of the ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 2464 */ 2465 public Enumeration<PublicationStatus> getStatusElement() { 2466 if (this.status == null) 2467 if (Configuration.errorOnAutoCreate()) 2468 throw new Error("Attempt to auto-create ObservationDefinition.status"); 2469 else if (Configuration.doAutoCreate()) 2470 this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); // bb 2471 return this.status; 2472 } 2473 2474 public boolean hasStatusElement() { 2475 return this.status != null && !this.status.isEmpty(); 2476 } 2477 2478 public boolean hasStatus() { 2479 return this.status != null && !this.status.isEmpty(); 2480 } 2481 2482 /** 2483 * @param value {@link #status} (The current state of the ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 2484 */ 2485 public ObservationDefinition setStatusElement(Enumeration<PublicationStatus> value) { 2486 this.status = value; 2487 return this; 2488 } 2489 2490 /** 2491 * @return The current state of the ObservationDefinition. 2492 */ 2493 public PublicationStatus getStatus() { 2494 return this.status == null ? null : this.status.getValue(); 2495 } 2496 2497 /** 2498 * @param value The current state of the ObservationDefinition. 2499 */ 2500 public ObservationDefinition setStatus(PublicationStatus value) { 2501 if (this.status == null) 2502 this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); 2503 this.status.setValue(value); 2504 return this; 2505 } 2506 2507 /** 2508 * @return {@link #experimental} (A flag to indicate that this ObservationDefinition 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 2509 */ 2510 public BooleanType getExperimentalElement() { 2511 if (this.experimental == null) 2512 if (Configuration.errorOnAutoCreate()) 2513 throw new Error("Attempt to auto-create ObservationDefinition.experimental"); 2514 else if (Configuration.doAutoCreate()) 2515 this.experimental = new BooleanType(); // bb 2516 return this.experimental; 2517 } 2518 2519 public boolean hasExperimentalElement() { 2520 return this.experimental != null && !this.experimental.isEmpty(); 2521 } 2522 2523 public boolean hasExperimental() { 2524 return this.experimental != null && !this.experimental.isEmpty(); 2525 } 2526 2527 /** 2528 * @param value {@link #experimental} (A flag to indicate that this ObservationDefinition 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 2529 */ 2530 public ObservationDefinition setExperimentalElement(BooleanType value) { 2531 this.experimental = value; 2532 return this; 2533 } 2534 2535 /** 2536 * @return A flag to indicate that this ObservationDefinition is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage. 2537 */ 2538 public boolean getExperimental() { 2539 return this.experimental == null || this.experimental.isEmpty() ? false : this.experimental.getValue(); 2540 } 2541 2542 /** 2543 * @param value A flag to indicate that this ObservationDefinition is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage. 2544 */ 2545 public ObservationDefinition setExperimental(boolean value) { 2546 if (this.experimental == null) 2547 this.experimental = new BooleanType(); 2548 this.experimental.setValue(value); 2549 return this; 2550 } 2551 2552 /** 2553 * @return {@link #subject} (A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition.) 2554 */ 2555 public Type getSubject() { 2556 return this.subject; 2557 } 2558 2559 /** 2560 * @return {@link #subject} (A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition.) 2561 */ 2562 public CodeableConcept getSubjectCodeableConcept() throws FHIRException { 2563 if (this.subject == null) 2564 this.subject = new CodeableConcept(); 2565 if (!(this.subject instanceof CodeableConcept)) 2566 throw new FHIRException("Type mismatch: the type CodeableConcept was expected, but "+this.subject.getClass().getName()+" was encountered"); 2567 return (CodeableConcept) this.subject; 2568 } 2569 2570 public boolean hasSubjectCodeableConcept() { 2571 return this != null && this.subject instanceof CodeableConcept; 2572 } 2573 2574 /** 2575 * @return {@link #subject} (A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition.) 2576 */ 2577 public Reference getSubjectReference() throws FHIRException { 2578 if (this.subject == null) 2579 this.subject = new Reference(); 2580 if (!(this.subject instanceof Reference)) 2581 throw new FHIRException("Type mismatch: the type Reference was expected, but "+this.subject.getClass().getName()+" was encountered"); 2582 return (Reference) this.subject; 2583 } 2584 2585 public boolean hasSubjectReference() { 2586 return this != null && this.subject instanceof Reference; 2587 } 2588 2589 public boolean hasSubject() { 2590 return this.subject != null && !this.subject.isEmpty(); 2591 } 2592 2593 /** 2594 * @param value {@link #subject} (A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition.) 2595 */ 2596 public ObservationDefinition setSubject(Type value) { 2597 if (value != null && !(value instanceof CodeableConcept || value instanceof Reference)) 2598 throw new Error("Not the right type for ObservationDefinition.subject[x]: "+value.fhirType()); 2599 this.subject = value; 2600 return this; 2601 } 2602 2603 /** 2604 * @return {@link #date} (For draft definitions, indicates the date of initial creation. For active definitions, represents the date of activation. For withdrawn definitions, indicates the date of withdrawal.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value 2605 */ 2606 public DateTimeType getDateElement() { 2607 if (this.date == null) 2608 if (Configuration.errorOnAutoCreate()) 2609 throw new Error("Attempt to auto-create ObservationDefinition.date"); 2610 else if (Configuration.doAutoCreate()) 2611 this.date = new DateTimeType(); // bb 2612 return this.date; 2613 } 2614 2615 public boolean hasDateElement() { 2616 return this.date != null && !this.date.isEmpty(); 2617 } 2618 2619 public boolean hasDate() { 2620 return this.date != null && !this.date.isEmpty(); 2621 } 2622 2623 /** 2624 * @param value {@link #date} (For draft definitions, indicates the date of initial creation. For active definitions, represents the date of activation. For withdrawn definitions, indicates the date of withdrawal.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value 2625 */ 2626 public ObservationDefinition setDateElement(DateTimeType value) { 2627 this.date = value; 2628 return this; 2629 } 2630 2631 /** 2632 * @return For draft definitions, indicates the date of initial creation. For active definitions, represents the date of activation. For withdrawn definitions, indicates the date of withdrawal. 2633 */ 2634 public Date getDate() { 2635 return this.date == null ? null : this.date.getValue(); 2636 } 2637 2638 /** 2639 * @param value For draft definitions, indicates the date of initial creation. For active definitions, represents the date of activation. For withdrawn definitions, indicates the date of withdrawal. 2640 */ 2641 public ObservationDefinition setDate(Date value) { 2642 if (value == null) 2643 this.date = null; 2644 else { 2645 if (this.date == null) 2646 this.date = new DateTimeType(); 2647 this.date.setValue(value); 2648 } 2649 return this; 2650 } 2651 2652 /** 2653 * @return {@link #publisher} (Helps establish the "authority/credibility" of the ObservationDefinition. May also allow for contact.) 2654 */ 2655 public Reference getPublisher() { 2656 if (this.publisher == null) 2657 if (Configuration.errorOnAutoCreate()) 2658 throw new Error("Attempt to auto-create ObservationDefinition.publisher"); 2659 else if (Configuration.doAutoCreate()) 2660 this.publisher = new Reference(); // cc 2661 return this.publisher; 2662 } 2663 2664 public boolean hasPublisher() { 2665 return this.publisher != null && !this.publisher.isEmpty(); 2666 } 2667 2668 /** 2669 * @param value {@link #publisher} (Helps establish the "authority/credibility" of the ObservationDefinition. May also allow for contact.) 2670 */ 2671 public ObservationDefinition setPublisher(Reference value) { 2672 this.publisher = value; 2673 return this; 2674 } 2675 2676 /** 2677 * @return {@link #contact} (Contact details to assist a user in finding and communicating with the publisher.) 2678 */ 2679 public List<ContactDetail> getContact() { 2680 if (this.contact == null) 2681 this.contact = new ArrayList<ContactDetail>(); 2682 return this.contact; 2683 } 2684 2685 /** 2686 * @return Returns a reference to <code>this</code> for easy method chaining 2687 */ 2688 public ObservationDefinition setContact(List<ContactDetail> theContact) { 2689 this.contact = theContact; 2690 return this; 2691 } 2692 2693 public boolean hasContact() { 2694 if (this.contact == null) 2695 return false; 2696 for (ContactDetail item : this.contact) 2697 if (!item.isEmpty()) 2698 return true; 2699 return false; 2700 } 2701 2702 public ContactDetail addContact() { //3 2703 ContactDetail t = new ContactDetail(); 2704 if (this.contact == null) 2705 this.contact = new ArrayList<ContactDetail>(); 2706 this.contact.add(t); 2707 return t; 2708 } 2709 2710 public ObservationDefinition addContact(ContactDetail t) { //3 2711 if (t == null) 2712 return this; 2713 if (this.contact == null) 2714 this.contact = new ArrayList<ContactDetail>(); 2715 this.contact.add(t); 2716 return this; 2717 } 2718 2719 /** 2720 * @return The first repetition of repeating field {@link #contact}, creating it if it does not already exist 2721 */ 2722 public ContactDetail getContactFirstRep() { 2723 if (getContact().isEmpty()) { 2724 addContact(); 2725 } 2726 return getContact().get(0); 2727 } 2728 2729 /** 2730 * @return {@link #description} (A free text natural language description of the ObservationDefinition from the consumer's perspective.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 2731 */ 2732 public MarkdownType getDescriptionElement() { 2733 if (this.description == null) 2734 if (Configuration.errorOnAutoCreate()) 2735 throw new Error("Attempt to auto-create ObservationDefinition.description"); 2736 else if (Configuration.doAutoCreate()) 2737 this.description = new MarkdownType(); // bb 2738 return this.description; 2739 } 2740 2741 public boolean hasDescriptionElement() { 2742 return this.description != null && !this.description.isEmpty(); 2743 } 2744 2745 public boolean hasDescription() { 2746 return this.description != null && !this.description.isEmpty(); 2747 } 2748 2749 /** 2750 * @param value {@link #description} (A free text natural language description of the ObservationDefinition from the consumer's perspective.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 2751 */ 2752 public ObservationDefinition setDescriptionElement(MarkdownType value) { 2753 this.description = value; 2754 return this; 2755 } 2756 2757 /** 2758 * @return A free text natural language description of the ObservationDefinition from the consumer's perspective. 2759 */ 2760 public String getDescription() { 2761 return this.description == null ? null : this.description.getValue(); 2762 } 2763 2764 /** 2765 * @param value A free text natural language description of the ObservationDefinition from the consumer's perspective. 2766 */ 2767 public ObservationDefinition setDescription(String value) { 2768 if (value == null) 2769 this.description = null; 2770 else { 2771 if (this.description == null) 2772 this.description = new MarkdownType(); 2773 this.description.setValue(value); 2774 } 2775 return this; 2776 } 2777 2778 /** 2779 * @return {@link #useContext} (The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of observation definitions.) 2780 */ 2781 public List<UsageContext> getUseContext() { 2782 if (this.useContext == null) 2783 this.useContext = new ArrayList<UsageContext>(); 2784 return this.useContext; 2785 } 2786 2787 /** 2788 * @return Returns a reference to <code>this</code> for easy method chaining 2789 */ 2790 public ObservationDefinition setUseContext(List<UsageContext> theUseContext) { 2791 this.useContext = theUseContext; 2792 return this; 2793 } 2794 2795 public boolean hasUseContext() { 2796 if (this.useContext == null) 2797 return false; 2798 for (UsageContext item : this.useContext) 2799 if (!item.isEmpty()) 2800 return true; 2801 return false; 2802 } 2803 2804 public UsageContext addUseContext() { //3 2805 UsageContext t = new UsageContext(); 2806 if (this.useContext == null) 2807 this.useContext = new ArrayList<UsageContext>(); 2808 this.useContext.add(t); 2809 return t; 2810 } 2811 2812 public ObservationDefinition addUseContext(UsageContext t) { //3 2813 if (t == null) 2814 return this; 2815 if (this.useContext == null) 2816 this.useContext = new ArrayList<UsageContext>(); 2817 this.useContext.add(t); 2818 return this; 2819 } 2820 2821 /** 2822 * @return The first repetition of repeating field {@link #useContext}, creating it if it does not already exist 2823 */ 2824 public UsageContext getUseContextFirstRep() { 2825 if (getUseContext().isEmpty()) { 2826 addUseContext(); 2827 } 2828 return getUseContext().get(0); 2829 } 2830 2831 /** 2832 * @return {@link #jurisdiction} (A jurisdiction in which the ObservationDefinition is intended to be used.) 2833 */ 2834 public List<CodeableConcept> getJurisdiction() { 2835 if (this.jurisdiction == null) 2836 this.jurisdiction = new ArrayList<CodeableConcept>(); 2837 return this.jurisdiction; 2838 } 2839 2840 /** 2841 * @return Returns a reference to <code>this</code> for easy method chaining 2842 */ 2843 public ObservationDefinition setJurisdiction(List<CodeableConcept> theJurisdiction) { 2844 this.jurisdiction = theJurisdiction; 2845 return this; 2846 } 2847 2848 public boolean hasJurisdiction() { 2849 if (this.jurisdiction == null) 2850 return false; 2851 for (CodeableConcept item : this.jurisdiction) 2852 if (!item.isEmpty()) 2853 return true; 2854 return false; 2855 } 2856 2857 public CodeableConcept addJurisdiction() { //3 2858 CodeableConcept t = new CodeableConcept(); 2859 if (this.jurisdiction == null) 2860 this.jurisdiction = new ArrayList<CodeableConcept>(); 2861 this.jurisdiction.add(t); 2862 return t; 2863 } 2864 2865 public ObservationDefinition addJurisdiction(CodeableConcept t) { //3 2866 if (t == null) 2867 return this; 2868 if (this.jurisdiction == null) 2869 this.jurisdiction = new ArrayList<CodeableConcept>(); 2870 this.jurisdiction.add(t); 2871 return this; 2872 } 2873 2874 /** 2875 * @return The first repetition of repeating field {@link #jurisdiction}, creating it if it does not already exist 2876 */ 2877 public CodeableConcept getJurisdictionFirstRep() { 2878 if (getJurisdiction().isEmpty()) { 2879 addJurisdiction(); 2880 } 2881 return getJurisdiction().get(0); 2882 } 2883 2884 /** 2885 * @return {@link #purpose} (Explains why this ObservationDefinition 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 2886 */ 2887 public MarkdownType getPurposeElement() { 2888 if (this.purpose == null) 2889 if (Configuration.errorOnAutoCreate()) 2890 throw new Error("Attempt to auto-create ObservationDefinition.purpose"); 2891 else if (Configuration.doAutoCreate()) 2892 this.purpose = new MarkdownType(); // bb 2893 return this.purpose; 2894 } 2895 2896 public boolean hasPurposeElement() { 2897 return this.purpose != null && !this.purpose.isEmpty(); 2898 } 2899 2900 public boolean hasPurpose() { 2901 return this.purpose != null && !this.purpose.isEmpty(); 2902 } 2903 2904 /** 2905 * @param value {@link #purpose} (Explains why this ObservationDefinition 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 2906 */ 2907 public ObservationDefinition setPurposeElement(MarkdownType value) { 2908 this.purpose = value; 2909 return this; 2910 } 2911 2912 /** 2913 * @return Explains why this ObservationDefinition is needed and why it has been designed as it has. 2914 */ 2915 public String getPurpose() { 2916 return this.purpose == null ? null : this.purpose.getValue(); 2917 } 2918 2919 /** 2920 * @param value Explains why this ObservationDefinition is needed and why it has been designed as it has. 2921 */ 2922 public ObservationDefinition setPurpose(String value) { 2923 if (value == null) 2924 this.purpose = null; 2925 else { 2926 if (this.purpose == null) 2927 this.purpose = new MarkdownType(); 2928 this.purpose.setValue(value); 2929 } 2930 return this; 2931 } 2932 2933 /** 2934 * @return {@link #copyright} (Copyright statement relating to the ObservationDefinition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value 2935 */ 2936 public MarkdownType getCopyrightElement() { 2937 if (this.copyright == null) 2938 if (Configuration.errorOnAutoCreate()) 2939 throw new Error("Attempt to auto-create ObservationDefinition.copyright"); 2940 else if (Configuration.doAutoCreate()) 2941 this.copyright = new MarkdownType(); // bb 2942 return this.copyright; 2943 } 2944 2945 public boolean hasCopyrightElement() { 2946 return this.copyright != null && !this.copyright.isEmpty(); 2947 } 2948 2949 public boolean hasCopyright() { 2950 return this.copyright != null && !this.copyright.isEmpty(); 2951 } 2952 2953 /** 2954 * @param value {@link #copyright} (Copyright statement relating to the ObservationDefinition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value 2955 */ 2956 public ObservationDefinition setCopyrightElement(MarkdownType value) { 2957 this.copyright = value; 2958 return this; 2959 } 2960 2961 /** 2962 * @return Copyright statement relating to the ObservationDefinition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the ObservationDefinition. 2963 */ 2964 public String getCopyright() { 2965 return this.copyright == null ? null : this.copyright.getValue(); 2966 } 2967 2968 /** 2969 * @param value Copyright statement relating to the ObservationDefinition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the ObservationDefinition. 2970 */ 2971 public ObservationDefinition setCopyright(String value) { 2972 if (value == null) 2973 this.copyright = null; 2974 else { 2975 if (this.copyright == null) 2976 this.copyright = new MarkdownType(); 2977 this.copyright.setValue(value); 2978 } 2979 return this; 2980 } 2981 2982 /** 2983 * @return {@link #approvalDate} (The date on which the asset content was approved by the publisher. Approval happens once when the content is officially approved for usage.). This is the underlying object with id, value and extensions. The accessor "getApprovalDate" gives direct access to the value 2984 */ 2985 public DateType getApprovalDateElement() { 2986 if (this.approvalDate == null) 2987 if (Configuration.errorOnAutoCreate()) 2988 throw new Error("Attempt to auto-create ObservationDefinition.approvalDate"); 2989 else if (Configuration.doAutoCreate()) 2990 this.approvalDate = new DateType(); // bb 2991 return this.approvalDate; 2992 } 2993 2994 public boolean hasApprovalDateElement() { 2995 return this.approvalDate != null && !this.approvalDate.isEmpty(); 2996 } 2997 2998 public boolean hasApprovalDate() { 2999 return this.approvalDate != null && !this.approvalDate.isEmpty(); 3000 } 3001 3002 /** 3003 * @param value {@link #approvalDate} (The date on which the asset content was approved by the publisher. Approval happens once when the content is officially approved for usage.). This is the underlying object with id, value and extensions. The accessor "getApprovalDate" gives direct access to the value 3004 */ 3005 public ObservationDefinition setApprovalDateElement(DateType value) { 3006 this.approvalDate = value; 3007 return this; 3008 } 3009 3010 /** 3011 * @return The date on which the asset content was approved by the publisher. Approval happens once when the content is officially approved for usage. 3012 */ 3013 public Date getApprovalDate() { 3014 return this.approvalDate == null ? null : this.approvalDate.getValue(); 3015 } 3016 3017 /** 3018 * @param value The date on which the asset content was approved by the publisher. Approval happens once when the content is officially approved for usage. 3019 */ 3020 public ObservationDefinition setApprovalDate(Date value) { 3021 if (value == null) 3022 this.approvalDate = null; 3023 else { 3024 if (this.approvalDate == null) 3025 this.approvalDate = new DateType(); 3026 this.approvalDate.setValue(value); 3027 } 3028 return this; 3029 } 3030 3031 /** 3032 * @return {@link #lastReviewDate} (The date on which the asset content was last reviewed. Review happens periodically after that, but doesn't change the original approval date.). This is the underlying object with id, value and extensions. The accessor "getLastReviewDate" gives direct access to the value 3033 */ 3034 public DateType getLastReviewDateElement() { 3035 if (this.lastReviewDate == null) 3036 if (Configuration.errorOnAutoCreate()) 3037 throw new Error("Attempt to auto-create ObservationDefinition.lastReviewDate"); 3038 else if (Configuration.doAutoCreate()) 3039 this.lastReviewDate = new DateType(); // bb 3040 return this.lastReviewDate; 3041 } 3042 3043 public boolean hasLastReviewDateElement() { 3044 return this.lastReviewDate != null && !this.lastReviewDate.isEmpty(); 3045 } 3046 3047 public boolean hasLastReviewDate() { 3048 return this.lastReviewDate != null && !this.lastReviewDate.isEmpty(); 3049 } 3050 3051 /** 3052 * @param value {@link #lastReviewDate} (The date on which the asset content was last reviewed. Review happens periodically after that, but doesn't change the original approval date.). This is the underlying object with id, value and extensions. The accessor "getLastReviewDate" gives direct access to the value 3053 */ 3054 public ObservationDefinition setLastReviewDateElement(DateType value) { 3055 this.lastReviewDate = value; 3056 return this; 3057 } 3058 3059 /** 3060 * @return The date on which the asset content was last reviewed. Review happens periodically after that, but doesn't change the original approval date. 3061 */ 3062 public Date getLastReviewDate() { 3063 return this.lastReviewDate == null ? null : this.lastReviewDate.getValue(); 3064 } 3065 3066 /** 3067 * @param value The date on which the asset content was last reviewed. Review happens periodically after that, but doesn't change the original approval date. 3068 */ 3069 public ObservationDefinition setLastReviewDate(Date value) { 3070 if (value == null) 3071 this.lastReviewDate = null; 3072 else { 3073 if (this.lastReviewDate == null) 3074 this.lastReviewDate = new DateType(); 3075 this.lastReviewDate.setValue(value); 3076 } 3077 return this; 3078 } 3079 3080 /** 3081 * @return {@link #effectivePeriod} (The period during which the ObservationDefinition content was or is planned to be effective.) 3082 */ 3083 public Period getEffectivePeriod() { 3084 if (this.effectivePeriod == null) 3085 if (Configuration.errorOnAutoCreate()) 3086 throw new Error("Attempt to auto-create ObservationDefinition.effectivePeriod"); 3087 else if (Configuration.doAutoCreate()) 3088 this.effectivePeriod = new Period(); // cc 3089 return this.effectivePeriod; 3090 } 3091 3092 public boolean hasEffectivePeriod() { 3093 return this.effectivePeriod != null && !this.effectivePeriod.isEmpty(); 3094 } 3095 3096 /** 3097 * @param value {@link #effectivePeriod} (The period during which the ObservationDefinition content was or is planned to be effective.) 3098 */ 3099 public ObservationDefinition setEffectivePeriod(Period value) { 3100 this.effectivePeriod = value; 3101 return this; 3102 } 3103 3104 /** 3105 * @return {@link #performerType} (The type of individual/organization/device that is expected to act upon instances of this definition.) 3106 */ 3107 public CodeableConcept getPerformerType() { 3108 if (this.performerType == null) 3109 if (Configuration.errorOnAutoCreate()) 3110 throw new Error("Attempt to auto-create ObservationDefinition.performerType"); 3111 else if (Configuration.doAutoCreate()) 3112 this.performerType = new CodeableConcept(); // cc 3113 return this.performerType; 3114 } 3115 3116 public boolean hasPerformerType() { 3117 return this.performerType != null && !this.performerType.isEmpty(); 3118 } 3119 3120 /** 3121 * @param value {@link #performerType} (The type of individual/organization/device that is expected to act upon instances of this definition.) 3122 */ 3123 public ObservationDefinition setPerformerType(CodeableConcept value) { 3124 this.performerType = value; 3125 return this; 3126 } 3127 3128 /** 3129 * @return {@link #category} (A code that classifies the general type of observation.) 3130 */ 3131 public List<CodeableConcept> getCategory() { 3132 if (this.category == null) 3133 this.category = new ArrayList<CodeableConcept>(); 3134 return this.category; 3135 } 3136 3137 /** 3138 * @return Returns a reference to <code>this</code> for easy method chaining 3139 */ 3140 public ObservationDefinition setCategory(List<CodeableConcept> theCategory) { 3141 this.category = theCategory; 3142 return this; 3143 } 3144 3145 public boolean hasCategory() { 3146 if (this.category == null) 3147 return false; 3148 for (CodeableConcept item : this.category) 3149 if (!item.isEmpty()) 3150 return true; 3151 return false; 3152 } 3153 3154 public CodeableConcept addCategory() { //3 3155 CodeableConcept t = new CodeableConcept(); 3156 if (this.category == null) 3157 this.category = new ArrayList<CodeableConcept>(); 3158 this.category.add(t); 3159 return t; 3160 } 3161 3162 public ObservationDefinition addCategory(CodeableConcept t) { //3 3163 if (t == null) 3164 return this; 3165 if (this.category == null) 3166 this.category = new ArrayList<CodeableConcept>(); 3167 this.category.add(t); 3168 return this; 3169 } 3170 3171 /** 3172 * @return The first repetition of repeating field {@link #category}, creating it if it does not already exist 3173 */ 3174 public CodeableConcept getCategoryFirstRep() { 3175 if (getCategory().isEmpty()) { 3176 addCategory(); 3177 } 3178 return getCategory().get(0); 3179 } 3180 3181 /** 3182 * @return {@link #code} (Describes what will be observed. Sometimes this is called the observation "name".) 3183 */ 3184 public CodeableConcept getCode() { 3185 if (this.code == null) 3186 if (Configuration.errorOnAutoCreate()) 3187 throw new Error("Attempt to auto-create ObservationDefinition.code"); 3188 else if (Configuration.doAutoCreate()) 3189 this.code = new CodeableConcept(); // cc 3190 return this.code; 3191 } 3192 3193 public boolean hasCode() { 3194 return this.code != null && !this.code.isEmpty(); 3195 } 3196 3197 /** 3198 * @param value {@link #code} (Describes what will be observed. Sometimes this is called the observation "name".) 3199 */ 3200 public ObservationDefinition setCode(CodeableConcept value) { 3201 this.code = value; 3202 return this; 3203 } 3204 3205 /** 3206 * @return {@link #permittedDataType} (The data types allowed for the value element of the instance observations conforming to this ObservationDefinition.) 3207 */ 3208 public List<Enumeration<ObservationDataType>> getPermittedDataType() { 3209 if (this.permittedDataType == null) 3210 this.permittedDataType = new ArrayList<Enumeration<ObservationDataType>>(); 3211 return this.permittedDataType; 3212 } 3213 3214 /** 3215 * @return Returns a reference to <code>this</code> for easy method chaining 3216 */ 3217 public ObservationDefinition setPermittedDataType(List<Enumeration<ObservationDataType>> thePermittedDataType) { 3218 this.permittedDataType = thePermittedDataType; 3219 return this; 3220 } 3221 3222 public boolean hasPermittedDataType() { 3223 if (this.permittedDataType == null) 3224 return false; 3225 for (Enumeration<ObservationDataType> item : this.permittedDataType) 3226 if (!item.isEmpty()) 3227 return true; 3228 return false; 3229 } 3230 3231 /** 3232 * @return {@link #permittedDataType} (The data types allowed for the value element of the instance observations conforming to this ObservationDefinition.) 3233 */ 3234 public Enumeration<ObservationDataType> addPermittedDataTypeElement() {//2 3235 Enumeration<ObservationDataType> t = new Enumeration<ObservationDataType>(new ObservationDataTypeEnumFactory()); 3236 if (this.permittedDataType == null) 3237 this.permittedDataType = new ArrayList<Enumeration<ObservationDataType>>(); 3238 this.permittedDataType.add(t); 3239 return t; 3240 } 3241 3242 /** 3243 * @param value {@link #permittedDataType} (The data types allowed for the value element of the instance observations conforming to this ObservationDefinition.) 3244 */ 3245 public ObservationDefinition addPermittedDataType(ObservationDataType value) { //1 3246 Enumeration<ObservationDataType> t = new Enumeration<ObservationDataType>(new ObservationDataTypeEnumFactory()); 3247 t.setValue(value); 3248 if (this.permittedDataType == null) 3249 this.permittedDataType = new ArrayList<Enumeration<ObservationDataType>>(); 3250 this.permittedDataType.add(t); 3251 return this; 3252 } 3253 3254 /** 3255 * @param value {@link #permittedDataType} (The data types allowed for the value element of the instance observations conforming to this ObservationDefinition.) 3256 */ 3257 public boolean hasPermittedDataType(ObservationDataType value) { 3258 if (this.permittedDataType == null) 3259 return false; 3260 for (Enumeration<ObservationDataType> v : this.permittedDataType) 3261 if (v.getValue().equals(value)) // code 3262 return true; 3263 return false; 3264 } 3265 3266 /** 3267 * @return {@link #multipleResultsAllowed} (Multiple results allowed for observations conforming to this ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getMultipleResultsAllowed" gives direct access to the value 3268 */ 3269 public BooleanType getMultipleResultsAllowedElement() { 3270 if (this.multipleResultsAllowed == null) 3271 if (Configuration.errorOnAutoCreate()) 3272 throw new Error("Attempt to auto-create ObservationDefinition.multipleResultsAllowed"); 3273 else if (Configuration.doAutoCreate()) 3274 this.multipleResultsAllowed = new BooleanType(); // bb 3275 return this.multipleResultsAllowed; 3276 } 3277 3278 public boolean hasMultipleResultsAllowedElement() { 3279 return this.multipleResultsAllowed != null && !this.multipleResultsAllowed.isEmpty(); 3280 } 3281 3282 public boolean hasMultipleResultsAllowed() { 3283 return this.multipleResultsAllowed != null && !this.multipleResultsAllowed.isEmpty(); 3284 } 3285 3286 /** 3287 * @param value {@link #multipleResultsAllowed} (Multiple results allowed for observations conforming to this ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getMultipleResultsAllowed" gives direct access to the value 3288 */ 3289 public ObservationDefinition setMultipleResultsAllowedElement(BooleanType value) { 3290 this.multipleResultsAllowed = value; 3291 return this; 3292 } 3293 3294 /** 3295 * @return Multiple results allowed for observations conforming to this ObservationDefinition. 3296 */ 3297 public boolean getMultipleResultsAllowed() { 3298 return this.multipleResultsAllowed == null || this.multipleResultsAllowed.isEmpty() ? false : this.multipleResultsAllowed.getValue(); 3299 } 3300 3301 /** 3302 * @param value Multiple results allowed for observations conforming to this ObservationDefinition. 3303 */ 3304 public ObservationDefinition setMultipleResultsAllowed(boolean value) { 3305 if (this.multipleResultsAllowed == null) 3306 this.multipleResultsAllowed = new BooleanType(); 3307 this.multipleResultsAllowed.setValue(value); 3308 return this; 3309 } 3310 3311 /** 3312 * @return {@link #bodySite} (The site on the subject's body where the observation is to be made.) 3313 */ 3314 public CodeableConcept getBodySite() { 3315 if (this.bodySite == null) 3316 if (Configuration.errorOnAutoCreate()) 3317 throw new Error("Attempt to auto-create ObservationDefinition.bodySite"); 3318 else if (Configuration.doAutoCreate()) 3319 this.bodySite = new CodeableConcept(); // cc 3320 return this.bodySite; 3321 } 3322 3323 public boolean hasBodySite() { 3324 return this.bodySite != null && !this.bodySite.isEmpty(); 3325 } 3326 3327 /** 3328 * @param value {@link #bodySite} (The site on the subject's body where the observation is to be made.) 3329 */ 3330 public ObservationDefinition setBodySite(CodeableConcept value) { 3331 this.bodySite = value; 3332 return this; 3333 } 3334 3335 /** 3336 * @return {@link #method} (The method or technique used to perform the observation.) 3337 */ 3338 public CodeableConcept getMethod() { 3339 if (this.method == null) 3340 if (Configuration.errorOnAutoCreate()) 3341 throw new Error("Attempt to auto-create ObservationDefinition.method"); 3342 else if (Configuration.doAutoCreate()) 3343 this.method = new CodeableConcept(); // cc 3344 return this.method; 3345 } 3346 3347 public boolean hasMethod() { 3348 return this.method != null && !this.method.isEmpty(); 3349 } 3350 3351 /** 3352 * @param value {@link #method} (The method or technique used to perform the observation.) 3353 */ 3354 public ObservationDefinition setMethod(CodeableConcept value) { 3355 this.method = value; 3356 return this; 3357 } 3358 3359 /** 3360 * @return {@link #specimen} (The kind of specimen that this type of observation is produced on.) 3361 */ 3362 public Reference getSpecimen() { 3363 if (this.specimen == null) 3364 if (Configuration.errorOnAutoCreate()) 3365 throw new Error("Attempt to auto-create ObservationDefinition.specimen"); 3366 else if (Configuration.doAutoCreate()) 3367 this.specimen = new Reference(); // cc 3368 return this.specimen; 3369 } 3370 3371 public boolean hasSpecimen() { 3372 return this.specimen != null && !this.specimen.isEmpty(); 3373 } 3374 3375 /** 3376 * @param value {@link #specimen} (The kind of specimen that this type of observation is produced on.) 3377 */ 3378 public ObservationDefinition setSpecimen(Reference value) { 3379 this.specimen = value; 3380 return this; 3381 } 3382 3383 /** 3384 * @return {@link #device} (The measurement device used to produce observations of this type.) 3385 */ 3386 public Reference getDevice() { 3387 if (this.device == null) 3388 if (Configuration.errorOnAutoCreate()) 3389 throw new Error("Attempt to auto-create ObservationDefinition.device"); 3390 else if (Configuration.doAutoCreate()) 3391 this.device = new Reference(); // cc 3392 return this.device; 3393 } 3394 3395 public boolean hasDevice() { 3396 return this.device != null && !this.device.isEmpty(); 3397 } 3398 3399 /** 3400 * @param value {@link #device} (The measurement device used to produce observations of this type.) 3401 */ 3402 public ObservationDefinition setDevice(Reference value) { 3403 this.device = value; 3404 return this; 3405 } 3406 3407 /** 3408 * @return {@link #preferredReportName} (The preferred name to be used when reporting the results of observations conforming to this ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getPreferredReportName" gives direct access to the value 3409 */ 3410 public StringType getPreferredReportNameElement() { 3411 if (this.preferredReportName == null) 3412 if (Configuration.errorOnAutoCreate()) 3413 throw new Error("Attempt to auto-create ObservationDefinition.preferredReportName"); 3414 else if (Configuration.doAutoCreate()) 3415 this.preferredReportName = new StringType(); // bb 3416 return this.preferredReportName; 3417 } 3418 3419 public boolean hasPreferredReportNameElement() { 3420 return this.preferredReportName != null && !this.preferredReportName.isEmpty(); 3421 } 3422 3423 public boolean hasPreferredReportName() { 3424 return this.preferredReportName != null && !this.preferredReportName.isEmpty(); 3425 } 3426 3427 /** 3428 * @param value {@link #preferredReportName} (The preferred name to be used when reporting the results of observations conforming to this ObservationDefinition.). This is the underlying object with id, value and extensions. The accessor "getPreferredReportName" gives direct access to the value 3429 */ 3430 public ObservationDefinition setPreferredReportNameElement(StringType value) { 3431 this.preferredReportName = value; 3432 return this; 3433 } 3434 3435 /** 3436 * @return The preferred name to be used when reporting the results of observations conforming to this ObservationDefinition. 3437 */ 3438 public String getPreferredReportName() { 3439 return this.preferredReportName == null ? null : this.preferredReportName.getValue(); 3440 } 3441 3442 /** 3443 * @param value The preferred name to be used when reporting the results of observations conforming to this ObservationDefinition. 3444 */ 3445 public ObservationDefinition setPreferredReportName(String value) { 3446 if (Utilities.noString(value)) 3447 this.preferredReportName = null; 3448 else { 3449 if (this.preferredReportName == null) 3450 this.preferredReportName = new StringType(); 3451 this.preferredReportName.setValue(value); 3452 } 3453 return this; 3454 } 3455 3456 /** 3457 * @return {@link #quantitativeDetails} (Characteristics for quantitative results of this observation.) 3458 */ 3459 public ObservationDefinitionQuantitativeDetailsComponent getQuantitativeDetails() { 3460 if (this.quantitativeDetails == null) 3461 if (Configuration.errorOnAutoCreate()) 3462 throw new Error("Attempt to auto-create ObservationDefinition.quantitativeDetails"); 3463 else if (Configuration.doAutoCreate()) 3464 this.quantitativeDetails = new ObservationDefinitionQuantitativeDetailsComponent(); // cc 3465 return this.quantitativeDetails; 3466 } 3467 3468 public boolean hasQuantitativeDetails() { 3469 return this.quantitativeDetails != null && !this.quantitativeDetails.isEmpty(); 3470 } 3471 3472 /** 3473 * @param value {@link #quantitativeDetails} (Characteristics for quantitative results of this observation.) 3474 */ 3475 public ObservationDefinition setQuantitativeDetails(ObservationDefinitionQuantitativeDetailsComponent value) { 3476 this.quantitativeDetails = value; 3477 return this; 3478 } 3479 3480 /** 3481 * @return {@link #qualifiedInterval} (Multiple ranges of results qualified by different contexts for ordinal or continuous observations conforming to this ObservationDefinition.) 3482 */ 3483 public List<ObservationDefinitionQualifiedIntervalComponent> getQualifiedInterval() { 3484 if (this.qualifiedInterval == null) 3485 this.qualifiedInterval = new ArrayList<ObservationDefinitionQualifiedIntervalComponent>(); 3486 return this.qualifiedInterval; 3487 } 3488 3489 /** 3490 * @return Returns a reference to <code>this</code> for easy method chaining 3491 */ 3492 public ObservationDefinition setQualifiedInterval(List<ObservationDefinitionQualifiedIntervalComponent> theQualifiedInterval) { 3493 this.qualifiedInterval = theQualifiedInterval; 3494 return this; 3495 } 3496 3497 public boolean hasQualifiedInterval() { 3498 if (this.qualifiedInterval == null) 3499 return false; 3500 for (ObservationDefinitionQualifiedIntervalComponent item : this.qualifiedInterval) 3501 if (!item.isEmpty()) 3502 return true; 3503 return false; 3504 } 3505 3506 public ObservationDefinitionQualifiedIntervalComponent addQualifiedInterval() { //3 3507 ObservationDefinitionQualifiedIntervalComponent t = new ObservationDefinitionQualifiedIntervalComponent(); 3508 if (this.qualifiedInterval == null) 3509 this.qualifiedInterval = new ArrayList<ObservationDefinitionQualifiedIntervalComponent>(); 3510 this.qualifiedInterval.add(t); 3511 return t; 3512 } 3513 3514 public ObservationDefinition addQualifiedInterval(ObservationDefinitionQualifiedIntervalComponent t) { //3 3515 if (t == null) 3516 return this; 3517 if (this.qualifiedInterval == null) 3518 this.qualifiedInterval = new ArrayList<ObservationDefinitionQualifiedIntervalComponent>(); 3519 this.qualifiedInterval.add(t); 3520 return this; 3521 } 3522 3523 /** 3524 * @return The first repetition of repeating field {@link #qualifiedInterval}, creating it if it does not already exist 3525 */ 3526 public ObservationDefinitionQualifiedIntervalComponent getQualifiedIntervalFirstRep() { 3527 if (getQualifiedInterval().isEmpty()) { 3528 addQualifiedInterval(); 3529 } 3530 return getQualifiedInterval().get(0); 3531 } 3532 3533 /** 3534 * @return {@link #validCodedValueSet} (The set of valid coded results for the observations conforming to this ObservationDefinition.) 3535 */ 3536 public Reference getValidCodedValueSet() { 3537 if (this.validCodedValueSet == null) 3538 if (Configuration.errorOnAutoCreate()) 3539 throw new Error("Attempt to auto-create ObservationDefinition.validCodedValueSet"); 3540 else if (Configuration.doAutoCreate()) 3541 this.validCodedValueSet = new Reference(); // cc 3542 return this.validCodedValueSet; 3543 } 3544 3545 public boolean hasValidCodedValueSet() { 3546 return this.validCodedValueSet != null && !this.validCodedValueSet.isEmpty(); 3547 } 3548 3549 /** 3550 * @param value {@link #validCodedValueSet} (The set of valid coded results for the observations conforming to this ObservationDefinition.) 3551 */ 3552 public ObservationDefinition setValidCodedValueSet(Reference value) { 3553 this.validCodedValueSet = value; 3554 return this; 3555 } 3556 3557 /** 3558 * @return {@link #normalCodedValueSet} (The set of normal coded results for the observations conforming to this ObservationDefinition.) 3559 */ 3560 public Reference getNormalCodedValueSet() { 3561 if (this.normalCodedValueSet == null) 3562 if (Configuration.errorOnAutoCreate()) 3563 throw new Error("Attempt to auto-create ObservationDefinition.normalCodedValueSet"); 3564 else if (Configuration.doAutoCreate()) 3565 this.normalCodedValueSet = new Reference(); // cc 3566 return this.normalCodedValueSet; 3567 } 3568 3569 public boolean hasNormalCodedValueSet() { 3570 return this.normalCodedValueSet != null && !this.normalCodedValueSet.isEmpty(); 3571 } 3572 3573 /** 3574 * @param value {@link #normalCodedValueSet} (The set of normal coded results for the observations conforming to this ObservationDefinition.) 3575 */ 3576 public ObservationDefinition setNormalCodedValueSet(Reference value) { 3577 this.normalCodedValueSet = value; 3578 return this; 3579 } 3580 3581 /** 3582 * @return {@link #abnormalCodedValueSet} (The set of abnormal coded results for the observation conforming to this ObservationDefinition.) 3583 */ 3584 public Reference getAbnormalCodedValueSet() { 3585 if (this.abnormalCodedValueSet == null) 3586 if (Configuration.errorOnAutoCreate()) 3587 throw new Error("Attempt to auto-create ObservationDefinition.abnormalCodedValueSet"); 3588 else if (Configuration.doAutoCreate()) 3589 this.abnormalCodedValueSet = new Reference(); // cc 3590 return this.abnormalCodedValueSet; 3591 } 3592 3593 public boolean hasAbnormalCodedValueSet() { 3594 return this.abnormalCodedValueSet != null && !this.abnormalCodedValueSet.isEmpty(); 3595 } 3596 3597 /** 3598 * @param value {@link #abnormalCodedValueSet} (The set of abnormal coded results for the observation conforming to this ObservationDefinition.) 3599 */ 3600 public ObservationDefinition setAbnormalCodedValueSet(Reference value) { 3601 this.abnormalCodedValueSet = value; 3602 return this; 3603 } 3604 3605 /** 3606 * @return {@link #criticalCodedValueSet} (The set of critical coded results for the observation conforming to this ObservationDefinition.) 3607 */ 3608 public Reference getCriticalCodedValueSet() { 3609 if (this.criticalCodedValueSet == null) 3610 if (Configuration.errorOnAutoCreate()) 3611 throw new Error("Attempt to auto-create ObservationDefinition.criticalCodedValueSet"); 3612 else if (Configuration.doAutoCreate()) 3613 this.criticalCodedValueSet = new Reference(); // cc 3614 return this.criticalCodedValueSet; 3615 } 3616 3617 public boolean hasCriticalCodedValueSet() { 3618 return this.criticalCodedValueSet != null && !this.criticalCodedValueSet.isEmpty(); 3619 } 3620 3621 /** 3622 * @param value {@link #criticalCodedValueSet} (The set of critical coded results for the observation conforming to this ObservationDefinition.) 3623 */ 3624 public ObservationDefinition setCriticalCodedValueSet(Reference value) { 3625 this.criticalCodedValueSet = value; 3626 return this; 3627 } 3628 3629 /** 3630 * @return {@link #hasMember} (This ObservationDefinition defines a group observation (e.g. a battery, a panel of tests, a set of vital sign measurements) that includes the target as a member of the group.) 3631 */ 3632 public List<Reference> getHasMember() { 3633 if (this.hasMember == null) 3634 this.hasMember = new ArrayList<Reference>(); 3635 return this.hasMember; 3636 } 3637 3638 /** 3639 * @return Returns a reference to <code>this</code> for easy method chaining 3640 */ 3641 public ObservationDefinition setHasMember(List<Reference> theHasMember) { 3642 this.hasMember = theHasMember; 3643 return this; 3644 } 3645 3646 public boolean hasHasMember() { 3647 if (this.hasMember == null) 3648 return false; 3649 for (Reference item : this.hasMember) 3650 if (!item.isEmpty()) 3651 return true; 3652 return false; 3653 } 3654 3655 public Reference addHasMember() { //3 3656 Reference t = new Reference(); 3657 if (this.hasMember == null) 3658 this.hasMember = new ArrayList<Reference>(); 3659 this.hasMember.add(t); 3660 return t; 3661 } 3662 3663 public ObservationDefinition addHasMember(Reference t) { //3 3664 if (t == null) 3665 return this; 3666 if (this.hasMember == null) 3667 this.hasMember = new ArrayList<Reference>(); 3668 this.hasMember.add(t); 3669 return this; 3670 } 3671 3672 /** 3673 * @return The first repetition of repeating field {@link #hasMember}, creating it if it does not already exist 3674 */ 3675 public Reference getHasMemberFirstRep() { 3676 if (getHasMember().isEmpty()) { 3677 addHasMember(); 3678 } 3679 return getHasMember().get(0); 3680 } 3681 3682 /** 3683 * @return {@link #component} (Some observations have multiple component observations, expressed as separate code value pairs.) 3684 */ 3685 public List<ObservationDefinitionComponentComponent> getComponent() { 3686 if (this.component == null) 3687 this.component = new ArrayList<ObservationDefinitionComponentComponent>(); 3688 return this.component; 3689 } 3690 3691 /** 3692 * @return Returns a reference to <code>this</code> for easy method chaining 3693 */ 3694 public ObservationDefinition setComponent(List<ObservationDefinitionComponentComponent> theComponent) { 3695 this.component = theComponent; 3696 return this; 3697 } 3698 3699 public boolean hasComponent() { 3700 if (this.component == null) 3701 return false; 3702 for (ObservationDefinitionComponentComponent item : this.component) 3703 if (!item.isEmpty()) 3704 return true; 3705 return false; 3706 } 3707 3708 public ObservationDefinitionComponentComponent addComponent() { //3 3709 ObservationDefinitionComponentComponent t = new ObservationDefinitionComponentComponent(); 3710 if (this.component == null) 3711 this.component = new ArrayList<ObservationDefinitionComponentComponent>(); 3712 this.component.add(t); 3713 return t; 3714 } 3715 3716 public ObservationDefinition addComponent(ObservationDefinitionComponentComponent t) { //3 3717 if (t == null) 3718 return this; 3719 if (this.component == null) 3720 this.component = new ArrayList<ObservationDefinitionComponentComponent>(); 3721 this.component.add(t); 3722 return this; 3723 } 3724 3725 /** 3726 * @return The first repetition of repeating field {@link #component}, creating it if it does not already exist 3727 */ 3728 public ObservationDefinitionComponentComponent getComponentFirstRep() { 3729 if (getComponent().isEmpty()) { 3730 addComponent(); 3731 } 3732 return getComponent().get(0); 3733 } 3734 3735 protected void listChildren(List<Property> children) { 3736 super.listChildren(children); 3737 children.add(new Property("url", "uri", "An absolute URL that is used to identify this ObservationDefinition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this ObservationDefinition is (or will be) published. The URL SHOULD include the major version of the ObservationDefinition. For more information see Technical and Business Versions.", 0, 1, url)); 3738 children.add(new Property("identifier", "Identifier", "Business identifiers assigned to this ObservationDefinition. by the performer and/or other systems. These identifiers remain constant as the resource is updated and propagates from server to server.", 0, 1, identifier)); 3739 children.add(new Property("version", "string", "The identifier that is used to identify this version of the ObservationDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the ObservationDefinition 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 are orderable.", 0, 1, version)); 3740 children.add(new Property("title", "string", "A short, descriptive, user-friendly title for the ObservationDefinition.", 0, 1, title)); 3741 children.add(new Property("derivedFromCanonical", "canonical(ObservationDefinition)", "The canonical URL pointing to another FHIR-defined ObservationDefinition that is adhered to in whole or in part by this definition.", 0, java.lang.Integer.MAX_VALUE, derivedFromCanonical)); 3742 children.add(new Property("derivedFromUri", "uri", "The URL pointing to an externally-defined observation definition, guideline or other definition that is adhered to in whole or in part by this definition.", 0, java.lang.Integer.MAX_VALUE, derivedFromUri)); 3743 children.add(new Property("status", "code", "The current state of the ObservationDefinition.", 0, 1, status)); 3744 children.add(new Property("experimental", "boolean", "A flag to indicate that this ObservationDefinition is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage.", 0, 1, experimental)); 3745 children.add(new Property("subject[x]", "CodeableConcept|Reference(Group)", "A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition.", 0, 1, subject)); 3746 children.add(new Property("date", "dateTime", "For draft definitions, indicates the date of initial creation. For active definitions, represents the date of activation. For withdrawn definitions, indicates the date of withdrawal.", 0, 1, date)); 3747 children.add(new Property("publisher", "Reference(Practitioner|PractitionerRole|Organization)", "Helps establish the \"authority/credibility\" of the ObservationDefinition. May also allow for contact.", 0, 1, publisher)); 3748 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)); 3749 children.add(new Property("description", "markdown", "A free text natural language description of the ObservationDefinition from the consumer's perspective.", 0, 1, description)); 3750 children.add(new Property("useContext", "UsageContext", "The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of observation definitions.", 0, java.lang.Integer.MAX_VALUE, useContext)); 3751 children.add(new Property("jurisdiction", "CodeableConcept", "A jurisdiction in which the ObservationDefinition is intended to be used.", 0, java.lang.Integer.MAX_VALUE, jurisdiction)); 3752 children.add(new Property("purpose", "markdown", "Explains why this ObservationDefinition is needed and why it has been designed as it has.", 0, 1, purpose)); 3753 children.add(new Property("copyright", "markdown", "Copyright statement relating to the ObservationDefinition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the ObservationDefinition.", 0, 1, copyright)); 3754 children.add(new Property("approvalDate", "date", "The date on which the asset content was approved by the publisher. Approval happens once when the content is officially approved for usage.", 0, 1, approvalDate)); 3755 children.add(new Property("lastReviewDate", "date", "The date on which the asset content was last reviewed. Review happens periodically after that, but doesn't change the original approval date.", 0, 1, lastReviewDate)); 3756 children.add(new Property("effectivePeriod", "Period", "The period during which the ObservationDefinition content was or is planned to be effective.", 0, 1, effectivePeriod)); 3757 children.add(new Property("performerType", "CodeableConcept", "The type of individual/organization/device that is expected to act upon instances of this definition.", 0, 1, performerType)); 3758 children.add(new Property("category", "CodeableConcept", "A code that classifies the general type of observation.", 0, java.lang.Integer.MAX_VALUE, category)); 3759 children.add(new Property("code", "CodeableConcept", "Describes what will be observed. Sometimes this is called the observation \"name\".", 0, 1, code)); 3760 children.add(new Property("permittedDataType", "code", "The data types allowed for the value element of the instance observations conforming to this ObservationDefinition.", 0, java.lang.Integer.MAX_VALUE, permittedDataType)); 3761 children.add(new Property("multipleResultsAllowed", "boolean", "Multiple results allowed for observations conforming to this ObservationDefinition.", 0, 1, multipleResultsAllowed)); 3762 children.add(new Property("bodySite", "CodeableConcept", "The site on the subject's body where the observation is to be made.", 0, 1, bodySite)); 3763 children.add(new Property("method", "CodeableConcept", "The method or technique used to perform the observation.", 0, 1, method)); 3764 children.add(new Property("specimen", "Reference(SpecimenDefinition)", "The kind of specimen that this type of observation is produced on.", 0, 1, specimen)); 3765 children.add(new Property("device", "Reference(Device)", "The measurement device used to produce observations of this type.", 0, 1, device)); 3766 children.add(new Property("preferredReportName", "string", "The preferred name to be used when reporting the results of observations conforming to this ObservationDefinition.", 0, 1, preferredReportName)); 3767 children.add(new Property("quantitativeDetails", "", "Characteristics for quantitative results of this observation.", 0, 1, quantitativeDetails)); 3768 children.add(new Property("qualifiedInterval", "", "Multiple ranges of results qualified by different contexts for ordinal or continuous observations conforming to this ObservationDefinition.", 0, java.lang.Integer.MAX_VALUE, qualifiedInterval)); 3769 children.add(new Property("validCodedValueSet", "Reference(ValueSet)", "The set of valid coded results for the observations conforming to this ObservationDefinition.", 0, 1, validCodedValueSet)); 3770 children.add(new Property("normalCodedValueSet", "Reference(ValueSet)", "The set of normal coded results for the observations conforming to this ObservationDefinition.", 0, 1, normalCodedValueSet)); 3771 children.add(new Property("abnormalCodedValueSet", "Reference(ValueSet)", "The set of abnormal coded results for the observation conforming to this ObservationDefinition.", 0, 1, abnormalCodedValueSet)); 3772 children.add(new Property("criticalCodedValueSet", "Reference(ValueSet)", "The set of critical coded results for the observation conforming to this ObservationDefinition.", 0, 1, criticalCodedValueSet)); 3773 children.add(new Property("hasMember", "Reference(ObservationDefinition|Questionnaire)", "This ObservationDefinition defines a group observation (e.g. a battery, a panel of tests, a set of vital sign measurements) that includes the target as a member of the group.", 0, java.lang.Integer.MAX_VALUE, hasMember)); 3774 children.add(new Property("component", "", "Some observations have multiple component observations, expressed as separate code value pairs.", 0, java.lang.Integer.MAX_VALUE, component)); 3775 } 3776 3777 @Override 3778 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 3779 switch (_hash) { 3780 case 116079: /*url*/ return new Property("url", "uri", "An absolute URL that is used to identify this ObservationDefinition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this ObservationDefinition is (or will be) published. The URL SHOULD include the major version of the ObservationDefinition. For more information see Technical and Business Versions.", 0, 1, url); 3781 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "Business identifiers assigned to this ObservationDefinition. by the performer and/or other systems. These identifiers remain constant as the resource is updated and propagates from server to server.", 0, 1, identifier); 3782 case 351608024: /*version*/ return new Property("version", "string", "The identifier that is used to identify this version of the ObservationDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the ObservationDefinition 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 are orderable.", 0, 1, version); 3783 case 110371416: /*title*/ return new Property("title", "string", "A short, descriptive, user-friendly title for the ObservationDefinition.", 0, 1, title); 3784 case -978133683: /*derivedFromCanonical*/ return new Property("derivedFromCanonical", "canonical(ObservationDefinition)", "The canonical URL pointing to another FHIR-defined ObservationDefinition that is adhered to in whole or in part by this definition.", 0, java.lang.Integer.MAX_VALUE, derivedFromCanonical); 3785 case -1076333435: /*derivedFromUri*/ return new Property("derivedFromUri", "uri", "The URL pointing to an externally-defined observation definition, guideline or other definition that is adhered to in whole or in part by this definition.", 0, java.lang.Integer.MAX_VALUE, derivedFromUri); 3786 case -892481550: /*status*/ return new Property("status", "code", "The current state of the ObservationDefinition.", 0, 1, status); 3787 case -404562712: /*experimental*/ return new Property("experimental", "boolean", "A flag to indicate that this ObservationDefinition is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage.", 0, 1, experimental); 3788 case -573640748: /*subject[x]*/ return new Property("subject[x]", "CodeableConcept|Reference(Group)", "A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition.", 0, 1, subject); 3789 case -1867885268: /*subject*/ return new Property("subject[x]", "CodeableConcept|Reference(Group)", "A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition.", 0, 1, subject); 3790 case -1257122603: /*subjectCodeableConcept*/ return new Property("subject[x]", "CodeableConcept|Reference(Group)", "A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition.", 0, 1, subject); 3791 case 772938623: /*subjectReference*/ return new Property("subject[x]", "CodeableConcept|Reference(Group)", "A code or group definition that describes the intended subject of Observation instances conforming to this ObservationDefinition.", 0, 1, subject); 3792 case 3076014: /*date*/ return new Property("date", "dateTime", "For draft definitions, indicates the date of initial creation. For active definitions, represents the date of activation. For withdrawn definitions, indicates the date of withdrawal.", 0, 1, date); 3793 case 1447404028: /*publisher*/ return new Property("publisher", "Reference(Practitioner|PractitionerRole|Organization)", "Helps establish the \"authority/credibility\" of the ObservationDefinition. May also allow for contact.", 0, 1, publisher); 3794 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); 3795 case -1724546052: /*description*/ return new Property("description", "markdown", "A free text natural language description of the ObservationDefinition from the consumer's perspective.", 0, 1, description); 3796 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 terms may be used to assist with indexing and searching of observation definitions.", 0, java.lang.Integer.MAX_VALUE, useContext); 3797 case -507075711: /*jurisdiction*/ return new Property("jurisdiction", "CodeableConcept", "A jurisdiction in which the ObservationDefinition is intended to be used.", 0, java.lang.Integer.MAX_VALUE, jurisdiction); 3798 case -220463842: /*purpose*/ return new Property("purpose", "markdown", "Explains why this ObservationDefinition is needed and why it has been designed as it has.", 0, 1, purpose); 3799 case 1522889671: /*copyright*/ return new Property("copyright", "markdown", "Copyright statement relating to the ObservationDefinition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the ObservationDefinition.", 0, 1, copyright); 3800 case 223539345: /*approvalDate*/ return new Property("approvalDate", "date", "The date on which the asset content was approved by the publisher. Approval happens once when the content is officially approved for usage.", 0, 1, approvalDate); 3801 case -1687512484: /*lastReviewDate*/ return new Property("lastReviewDate", "date", "The date on which the asset content was last reviewed. Review happens periodically after that, but doesn't change the original approval date.", 0, 1, lastReviewDate); 3802 case -403934648: /*effectivePeriod*/ return new Property("effectivePeriod", "Period", "The period during which the ObservationDefinition content was or is planned to be effective.", 0, 1, effectivePeriod); 3803 case -901444568: /*performerType*/ return new Property("performerType", "CodeableConcept", "The type of individual/organization/device that is expected to act upon instances of this definition.", 0, 1, performerType); 3804 case 50511102: /*category*/ return new Property("category", "CodeableConcept", "A code that classifies the general type of observation.", 0, java.lang.Integer.MAX_VALUE, category); 3805 case 3059181: /*code*/ return new Property("code", "CodeableConcept", "Describes what will be observed. Sometimes this is called the observation \"name\".", 0, 1, code); 3806 case -99492804: /*permittedDataType*/ return new Property("permittedDataType", "code", "The data types allowed for the value element of the instance observations conforming to this ObservationDefinition.", 0, java.lang.Integer.MAX_VALUE, permittedDataType); 3807 case -2102414590: /*multipleResultsAllowed*/ return new Property("multipleResultsAllowed", "boolean", "Multiple results allowed for observations conforming to this ObservationDefinition.", 0, 1, multipleResultsAllowed); 3808 case 1702620169: /*bodySite*/ return new Property("bodySite", "CodeableConcept", "The site on the subject's body where the observation is to be made.", 0, 1, bodySite); 3809 case -1077554975: /*method*/ return new Property("method", "CodeableConcept", "The method or technique used to perform the observation.", 0, 1, method); 3810 case -2132868344: /*specimen*/ return new Property("specimen", "Reference(SpecimenDefinition)", "The kind of specimen that this type of observation is produced on.", 0, 1, specimen); 3811 case -1335157162: /*device*/ return new Property("device", "Reference(Device)", "The measurement device used to produce observations of this type.", 0, 1, device); 3812 case -1851030208: /*preferredReportName*/ return new Property("preferredReportName", "string", "The preferred name to be used when reporting the results of observations conforming to this ObservationDefinition.", 0, 1, preferredReportName); 3813 case 842150763: /*quantitativeDetails*/ return new Property("quantitativeDetails", "", "Characteristics for quantitative results of this observation.", 0, 1, quantitativeDetails); 3814 case 1882971521: /*qualifiedInterval*/ return new Property("qualifiedInterval", "", "Multiple ranges of results qualified by different contexts for ordinal or continuous observations conforming to this ObservationDefinition.", 0, java.lang.Integer.MAX_VALUE, qualifiedInterval); 3815 case 1374640076: /*validCodedValueSet*/ return new Property("validCodedValueSet", "Reference(ValueSet)", "The set of valid coded results for the observations conforming to this ObservationDefinition.", 0, 1, validCodedValueSet); 3816 case -837500735: /*normalCodedValueSet*/ return new Property("normalCodedValueSet", "Reference(ValueSet)", "The set of normal coded results for the observations conforming to this ObservationDefinition.", 0, 1, normalCodedValueSet); 3817 case 1073600256: /*abnormalCodedValueSet*/ return new Property("abnormalCodedValueSet", "Reference(ValueSet)", "The set of abnormal coded results for the observation conforming to this ObservationDefinition.", 0, 1, abnormalCodedValueSet); 3818 case 2568457: /*criticalCodedValueSet*/ return new Property("criticalCodedValueSet", "Reference(ValueSet)", "The set of critical coded results for the observation conforming to this ObservationDefinition.", 0, 1, criticalCodedValueSet); 3819 case -458019372: /*hasMember*/ return new Property("hasMember", "Reference(ObservationDefinition|Questionnaire)", "This ObservationDefinition defines a group observation (e.g. a battery, a panel of tests, a set of vital sign measurements) that includes the target as a member of the group.", 0, java.lang.Integer.MAX_VALUE, hasMember); 3820 case -1399907075: /*component*/ return new Property("component", "", "Some observations have multiple component observations, expressed as separate code value pairs.", 0, java.lang.Integer.MAX_VALUE, component); 3821 default: return super.getNamedProperty(_hash, _name, _checkValid); 3822 } 3823 3824 } 3825 3826 @Override 3827 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 3828 switch (hash) { 3829 case 116079: /*url*/ return this.url == null ? new Base[0] : new Base[] {this.url}; // UriType 3830 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : new Base[] {this.identifier}; // Identifier 3831 case 351608024: /*version*/ return this.version == null ? new Base[0] : new Base[] {this.version}; // StringType 3832 case 110371416: /*title*/ return this.title == null ? new Base[0] : new Base[] {this.title}; // StringType 3833 case -978133683: /*derivedFromCanonical*/ return this.derivedFromCanonical == null ? new Base[0] : this.derivedFromCanonical.toArray(new Base[this.derivedFromCanonical.size()]); // CanonicalType 3834 case -1076333435: /*derivedFromUri*/ return this.derivedFromUri == null ? new Base[0] : this.derivedFromUri.toArray(new Base[this.derivedFromUri.size()]); // UriType 3835 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<PublicationStatus> 3836 case -404562712: /*experimental*/ return this.experimental == null ? new Base[0] : new Base[] {this.experimental}; // BooleanType 3837 case -1867885268: /*subject*/ return this.subject == null ? new Base[0] : new Base[] {this.subject}; // Type 3838 case 3076014: /*date*/ return this.date == null ? new Base[0] : new Base[] {this.date}; // DateTimeType 3839 case 1447404028: /*publisher*/ return this.publisher == null ? new Base[0] : new Base[] {this.publisher}; // Reference 3840 case 951526432: /*contact*/ return this.contact == null ? new Base[0] : this.contact.toArray(new Base[this.contact.size()]); // ContactDetail 3841 case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // MarkdownType 3842 case -669707736: /*useContext*/ return this.useContext == null ? new Base[0] : this.useContext.toArray(new Base[this.useContext.size()]); // UsageContext 3843 case -507075711: /*jurisdiction*/ return this.jurisdiction == null ? new Base[0] : this.jurisdiction.toArray(new Base[this.jurisdiction.size()]); // CodeableConcept 3844 case -220463842: /*purpose*/ return this.purpose == null ? new Base[0] : new Base[] {this.purpose}; // MarkdownType 3845 case 1522889671: /*copyright*/ return this.copyright == null ? new Base[0] : new Base[] {this.copyright}; // MarkdownType 3846 case 223539345: /*approvalDate*/ return this.approvalDate == null ? new Base[0] : new Base[] {this.approvalDate}; // DateType 3847 case -1687512484: /*lastReviewDate*/ return this.lastReviewDate == null ? new Base[0] : new Base[] {this.lastReviewDate}; // DateType 3848 case -403934648: /*effectivePeriod*/ return this.effectivePeriod == null ? new Base[0] : new Base[] {this.effectivePeriod}; // Period 3849 case -901444568: /*performerType*/ return this.performerType == null ? new Base[0] : new Base[] {this.performerType}; // CodeableConcept 3850 case 50511102: /*category*/ return this.category == null ? new Base[0] : this.category.toArray(new Base[this.category.size()]); // CodeableConcept 3851 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 3852 case -99492804: /*permittedDataType*/ return this.permittedDataType == null ? new Base[0] : this.permittedDataType.toArray(new Base[this.permittedDataType.size()]); // Enumeration<ObservationDataType> 3853 case -2102414590: /*multipleResultsAllowed*/ return this.multipleResultsAllowed == null ? new Base[0] : new Base[] {this.multipleResultsAllowed}; // BooleanType 3854 case 1702620169: /*bodySite*/ return this.bodySite == null ? new Base[0] : new Base[] {this.bodySite}; // CodeableConcept 3855 case -1077554975: /*method*/ return this.method == null ? new Base[0] : new Base[] {this.method}; // CodeableConcept 3856 case -2132868344: /*specimen*/ return this.specimen == null ? new Base[0] : new Base[] {this.specimen}; // Reference 3857 case -1335157162: /*device*/ return this.device == null ? new Base[0] : new Base[] {this.device}; // Reference 3858 case -1851030208: /*preferredReportName*/ return this.preferredReportName == null ? new Base[0] : new Base[] {this.preferredReportName}; // StringType 3859 case 842150763: /*quantitativeDetails*/ return this.quantitativeDetails == null ? new Base[0] : new Base[] {this.quantitativeDetails}; // ObservationDefinitionQuantitativeDetailsComponent 3860 case 1882971521: /*qualifiedInterval*/ return this.qualifiedInterval == null ? new Base[0] : this.qualifiedInterval.toArray(new Base[this.qualifiedInterval.size()]); // ObservationDefinitionQualifiedIntervalComponent 3861 case 1374640076: /*validCodedValueSet*/ return this.validCodedValueSet == null ? new Base[0] : new Base[] {this.validCodedValueSet}; // Reference 3862 case -837500735: /*normalCodedValueSet*/ return this.normalCodedValueSet == null ? new Base[0] : new Base[] {this.normalCodedValueSet}; // Reference 3863 case 1073600256: /*abnormalCodedValueSet*/ return this.abnormalCodedValueSet == null ? new Base[0] : new Base[] {this.abnormalCodedValueSet}; // Reference 3864 case 2568457: /*criticalCodedValueSet*/ return this.criticalCodedValueSet == null ? new Base[0] : new Base[] {this.criticalCodedValueSet}; // Reference 3865 case -458019372: /*hasMember*/ return this.hasMember == null ? new Base[0] : this.hasMember.toArray(new Base[this.hasMember.size()]); // Reference 3866 case -1399907075: /*component*/ return this.component == null ? new Base[0] : this.component.toArray(new Base[this.component.size()]); // ObservationDefinitionComponentComponent 3867 default: return super.getProperty(hash, name, checkValid); 3868 } 3869 3870 } 3871 3872 @Override 3873 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3874 switch (hash) { 3875 case 116079: // url 3876 this.url = castToUri(value); // UriType 3877 return value; 3878 case -1618432855: // identifier 3879 this.identifier = castToIdentifier(value); // Identifier 3880 return value; 3881 case 351608024: // version 3882 this.version = castToString(value); // StringType 3883 return value; 3884 case 110371416: // title 3885 this.title = castToString(value); // StringType 3886 return value; 3887 case -978133683: // derivedFromCanonical 3888 this.getDerivedFromCanonical().add(castToCanonical(value)); // CanonicalType 3889 return value; 3890 case -1076333435: // derivedFromUri 3891 this.getDerivedFromUri().add(castToUri(value)); // UriType 3892 return value; 3893 case -892481550: // status 3894 value = new PublicationStatusEnumFactory().fromType(castToCode(value)); 3895 this.status = (Enumeration) value; // Enumeration<PublicationStatus> 3896 return value; 3897 case -404562712: // experimental 3898 this.experimental = castToBoolean(value); // BooleanType 3899 return value; 3900 case -1867885268: // subject 3901 this.subject = castToType(value); // Type 3902 return value; 3903 case 3076014: // date 3904 this.date = castToDateTime(value); // DateTimeType 3905 return value; 3906 case 1447404028: // publisher 3907 this.publisher = castToReference(value); // Reference 3908 return value; 3909 case 951526432: // contact 3910 this.getContact().add(castToContactDetail(value)); // ContactDetail 3911 return value; 3912 case -1724546052: // description 3913 this.description = castToMarkdown(value); // MarkdownType 3914 return value; 3915 case -669707736: // useContext 3916 this.getUseContext().add(castToUsageContext(value)); // UsageContext 3917 return value; 3918 case -507075711: // jurisdiction 3919 this.getJurisdiction().add(castToCodeableConcept(value)); // CodeableConcept 3920 return value; 3921 case -220463842: // purpose 3922 this.purpose = castToMarkdown(value); // MarkdownType 3923 return value; 3924 case 1522889671: // copyright 3925 this.copyright = castToMarkdown(value); // MarkdownType 3926 return value; 3927 case 223539345: // approvalDate 3928 this.approvalDate = castToDate(value); // DateType 3929 return value; 3930 case -1687512484: // lastReviewDate 3931 this.lastReviewDate = castToDate(value); // DateType 3932 return value; 3933 case -403934648: // effectivePeriod 3934 this.effectivePeriod = castToPeriod(value); // Period 3935 return value; 3936 case -901444568: // performerType 3937 this.performerType = castToCodeableConcept(value); // CodeableConcept 3938 return value; 3939 case 50511102: // category 3940 this.getCategory().add(castToCodeableConcept(value)); // CodeableConcept 3941 return value; 3942 case 3059181: // code 3943 this.code = castToCodeableConcept(value); // CodeableConcept 3944 return value; 3945 case -99492804: // permittedDataType 3946 value = new ObservationDataTypeEnumFactory().fromType(castToCode(value)); 3947 this.getPermittedDataType().add((Enumeration) value); // Enumeration<ObservationDataType> 3948 return value; 3949 case -2102414590: // multipleResultsAllowed 3950 this.multipleResultsAllowed = castToBoolean(value); // BooleanType 3951 return value; 3952 case 1702620169: // bodySite 3953 this.bodySite = castToCodeableConcept(value); // CodeableConcept 3954 return value; 3955 case -1077554975: // method 3956 this.method = castToCodeableConcept(value); // CodeableConcept 3957 return value; 3958 case -2132868344: // specimen 3959 this.specimen = castToReference(value); // Reference 3960 return value; 3961 case -1335157162: // device 3962 this.device = castToReference(value); // Reference 3963 return value; 3964 case -1851030208: // preferredReportName 3965 this.preferredReportName = castToString(value); // StringType 3966 return value; 3967 case 842150763: // quantitativeDetails 3968 this.quantitativeDetails = (ObservationDefinitionQuantitativeDetailsComponent) value; // ObservationDefinitionQuantitativeDetailsComponent 3969 return value; 3970 case 1882971521: // qualifiedInterval 3971 this.getQualifiedInterval().add((ObservationDefinitionQualifiedIntervalComponent) value); // ObservationDefinitionQualifiedIntervalComponent 3972 return value; 3973 case 1374640076: // validCodedValueSet 3974 this.validCodedValueSet = castToReference(value); // Reference 3975 return value; 3976 case -837500735: // normalCodedValueSet 3977 this.normalCodedValueSet = castToReference(value); // Reference 3978 return value; 3979 case 1073600256: // abnormalCodedValueSet 3980 this.abnormalCodedValueSet = castToReference(value); // Reference 3981 return value; 3982 case 2568457: // criticalCodedValueSet 3983 this.criticalCodedValueSet = castToReference(value); // Reference 3984 return value; 3985 case -458019372: // hasMember 3986 this.getHasMember().add(castToReference(value)); // Reference 3987 return value; 3988 case -1399907075: // component 3989 this.getComponent().add((ObservationDefinitionComponentComponent) value); // ObservationDefinitionComponentComponent 3990 return value; 3991 default: return super.setProperty(hash, name, value); 3992 } 3993 3994 } 3995 3996 @Override 3997 public Base setProperty(String name, Base value) throws FHIRException { 3998 if (name.equals("url")) { 3999 this.url = castToUri(value); // UriType 4000 } else if (name.equals("identifier")) { 4001 this.identifier = castToIdentifier(value); // Identifier 4002 } else if (name.equals("version")) { 4003 this.version = castToString(value); // StringType 4004 } else if (name.equals("title")) { 4005 this.title = castToString(value); // StringType 4006 } else if (name.equals("derivedFromCanonical")) { 4007 this.getDerivedFromCanonical().add(castToCanonical(value)); 4008 } else if (name.equals("derivedFromUri")) { 4009 this.getDerivedFromUri().add(castToUri(value)); 4010 } else if (name.equals("status")) { 4011 value = new PublicationStatusEnumFactory().fromType(castToCode(value)); 4012 this.status = (Enumeration) value; // Enumeration<PublicationStatus> 4013 } else if (name.equals("experimental")) { 4014 this.experimental = castToBoolean(value); // BooleanType 4015 } else if (name.equals("subject[x]")) { 4016 this.subject = castToType(value); // Type 4017 } else if (name.equals("date")) { 4018 this.date = castToDateTime(value); // DateTimeType 4019 } else if (name.equals("publisher")) { 4020 this.publisher = castToReference(value); // Reference 4021 } else if (name.equals("contact")) { 4022 this.getContact().add(castToContactDetail(value)); 4023 } else if (name.equals("description")) { 4024 this.description = castToMarkdown(value); // MarkdownType 4025 } else if (name.equals("useContext")) { 4026 this.getUseContext().add(castToUsageContext(value)); 4027 } else if (name.equals("jurisdiction")) { 4028 this.getJurisdiction().add(castToCodeableConcept(value)); 4029 } else if (name.equals("purpose")) { 4030 this.purpose = castToMarkdown(value); // MarkdownType 4031 } else if (name.equals("copyright")) { 4032 this.copyright = castToMarkdown(value); // MarkdownType 4033 } else if (name.equals("approvalDate")) { 4034 this.approvalDate = castToDate(value); // DateType 4035 } else if (name.equals("lastReviewDate")) { 4036 this.lastReviewDate = castToDate(value); // DateType 4037 } else if (name.equals("effectivePeriod")) { 4038 this.effectivePeriod = castToPeriod(value); // Period 4039 } else if (name.equals("performerType")) { 4040 this.performerType = castToCodeableConcept(value); // CodeableConcept 4041 } else if (name.equals("category")) { 4042 this.getCategory().add(castToCodeableConcept(value)); 4043 } else if (name.equals("code")) { 4044 this.code = castToCodeableConcept(value); // CodeableConcept 4045 } else if (name.equals("permittedDataType")) { 4046 value = new ObservationDataTypeEnumFactory().fromType(castToCode(value)); 4047 this.getPermittedDataType().add((Enumeration) value); 4048 } else if (name.equals("multipleResultsAllowed")) { 4049 this.multipleResultsAllowed = castToBoolean(value); // BooleanType 4050 } else if (name.equals("bodySite")) { 4051 this.bodySite = castToCodeableConcept(value); // CodeableConcept 4052 } else if (name.equals("method")) { 4053 this.method = castToCodeableConcept(value); // CodeableConcept 4054 } else if (name.equals("specimen")) { 4055 this.specimen = castToReference(value); // Reference 4056 } else if (name.equals("device")) { 4057 this.device = castToReference(value); // Reference 4058 } else if (name.equals("preferredReportName")) { 4059 this.preferredReportName = castToString(value); // StringType 4060 } else if (name.equals("quantitativeDetails")) { 4061 this.quantitativeDetails = (ObservationDefinitionQuantitativeDetailsComponent) value; // ObservationDefinitionQuantitativeDetailsComponent 4062 } else if (name.equals("qualifiedInterval")) { 4063 this.getQualifiedInterval().add((ObservationDefinitionQualifiedIntervalComponent) value); 4064 } else if (name.equals("validCodedValueSet")) { 4065 this.validCodedValueSet = castToReference(value); // Reference 4066 } else if (name.equals("normalCodedValueSet")) { 4067 this.normalCodedValueSet = castToReference(value); // Reference 4068 } else if (name.equals("abnormalCodedValueSet")) { 4069 this.abnormalCodedValueSet = castToReference(value); // Reference 4070 } else if (name.equals("criticalCodedValueSet")) { 4071 this.criticalCodedValueSet = castToReference(value); // Reference 4072 } else if (name.equals("hasMember")) { 4073 this.getHasMember().add(castToReference(value)); 4074 } else if (name.equals("component")) { 4075 this.getComponent().add((ObservationDefinitionComponentComponent) value); 4076 } else 4077 return super.setProperty(name, value); 4078 return value; 4079 } 4080 4081 @Override 4082 public Base makeProperty(int hash, String name) throws FHIRException { 4083 switch (hash) { 4084 case 116079: return getUrlElement(); 4085 case -1618432855: return getIdentifier(); 4086 case 351608024: return getVersionElement(); 4087 case 110371416: return getTitleElement(); 4088 case -978133683: return addDerivedFromCanonicalElement(); 4089 case -1076333435: return addDerivedFromUriElement(); 4090 case -892481550: return getStatusElement(); 4091 case -404562712: return getExperimentalElement(); 4092 case -573640748: return getSubject(); 4093 case -1867885268: return getSubject(); 4094 case 3076014: return getDateElement(); 4095 case 1447404028: return getPublisher(); 4096 case 951526432: return addContact(); 4097 case -1724546052: return getDescriptionElement(); 4098 case -669707736: return addUseContext(); 4099 case -507075711: return addJurisdiction(); 4100 case -220463842: return getPurposeElement(); 4101 case 1522889671: return getCopyrightElement(); 4102 case 223539345: return getApprovalDateElement(); 4103 case -1687512484: return getLastReviewDateElement(); 4104 case -403934648: return getEffectivePeriod(); 4105 case -901444568: return getPerformerType(); 4106 case 50511102: return addCategory(); 4107 case 3059181: return getCode(); 4108 case -99492804: return addPermittedDataTypeElement(); 4109 case -2102414590: return getMultipleResultsAllowedElement(); 4110 case 1702620169: return getBodySite(); 4111 case -1077554975: return getMethod(); 4112 case -2132868344: return getSpecimen(); 4113 case -1335157162: return getDevice(); 4114 case -1851030208: return getPreferredReportNameElement(); 4115 case 842150763: return getQuantitativeDetails(); 4116 case 1882971521: return addQualifiedInterval(); 4117 case 1374640076: return getValidCodedValueSet(); 4118 case -837500735: return getNormalCodedValueSet(); 4119 case 1073600256: return getAbnormalCodedValueSet(); 4120 case 2568457: return getCriticalCodedValueSet(); 4121 case -458019372: return addHasMember(); 4122 case -1399907075: return addComponent(); 4123 default: return super.makeProperty(hash, name); 4124 } 4125 4126 } 4127 4128 @Override 4129 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 4130 switch (hash) { 4131 case 116079: /*url*/ return new String[] {"uri"}; 4132 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 4133 case 351608024: /*version*/ return new String[] {"string"}; 4134 case 110371416: /*title*/ return new String[] {"string"}; 4135 case -978133683: /*derivedFromCanonical*/ return new String[] {"canonical"}; 4136 case -1076333435: /*derivedFromUri*/ return new String[] {"uri"}; 4137 case -892481550: /*status*/ return new String[] {"code"}; 4138 case -404562712: /*experimental*/ return new String[] {"boolean"}; 4139 case -1867885268: /*subject*/ return new String[] {"CodeableConcept", "Reference"}; 4140 case 3076014: /*date*/ return new String[] {"dateTime"}; 4141 case 1447404028: /*publisher*/ return new String[] {"Reference"}; 4142 case 951526432: /*contact*/ return new String[] {"ContactDetail"}; 4143 case -1724546052: /*description*/ return new String[] {"markdown"}; 4144 case -669707736: /*useContext*/ return new String[] {"UsageContext"}; 4145 case -507075711: /*jurisdiction*/ return new String[] {"CodeableConcept"}; 4146 case -220463842: /*purpose*/ return new String[] {"markdown"}; 4147 case 1522889671: /*copyright*/ return new String[] {"markdown"}; 4148 case 223539345: /*approvalDate*/ return new String[] {"date"}; 4149 case -1687512484: /*lastReviewDate*/ return new String[] {"date"}; 4150 case -403934648: /*effectivePeriod*/ return new String[] {"Period"}; 4151 case -901444568: /*performerType*/ return new String[] {"CodeableConcept"}; 4152 case 50511102: /*category*/ return new String[] {"CodeableConcept"}; 4153 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 4154 case -99492804: /*permittedDataType*/ return new String[] {"code"}; 4155 case -2102414590: /*multipleResultsAllowed*/ return new String[] {"boolean"}; 4156 case 1702620169: /*bodySite*/ return new String[] {"CodeableConcept"}; 4157 case -1077554975: /*method*/ return new String[] {"CodeableConcept"}; 4158 case -2132868344: /*specimen*/ return new String[] {"Reference"}; 4159 case -1335157162: /*device*/ return new String[] {"Reference"}; 4160 case -1851030208: /*preferredReportName*/ return new String[] {"string"}; 4161 case 842150763: /*quantitativeDetails*/ return new String[] {}; 4162 case 1882971521: /*qualifiedInterval*/ return new String[] {}; 4163 case 1374640076: /*validCodedValueSet*/ return new String[] {"Reference"}; 4164 case -837500735: /*normalCodedValueSet*/ return new String[] {"Reference"}; 4165 case 1073600256: /*abnormalCodedValueSet*/ return new String[] {"Reference"}; 4166 case 2568457: /*criticalCodedValueSet*/ return new String[] {"Reference"}; 4167 case -458019372: /*hasMember*/ return new String[] {"Reference"}; 4168 case -1399907075: /*component*/ return new String[] {}; 4169 default: return super.getTypesForProperty(hash, name); 4170 } 4171 4172 } 4173 4174 @Override 4175 public Base addChild(String name) throws FHIRException { 4176 if (name.equals("url")) { 4177 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.url"); 4178 } 4179 else if (name.equals("identifier")) { 4180 this.identifier = new Identifier(); 4181 return this.identifier; 4182 } 4183 else if (name.equals("version")) { 4184 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.version"); 4185 } 4186 else if (name.equals("title")) { 4187 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.title"); 4188 } 4189 else if (name.equals("derivedFromCanonical")) { 4190 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.derivedFromCanonical"); 4191 } 4192 else if (name.equals("derivedFromUri")) { 4193 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.derivedFromUri"); 4194 } 4195 else if (name.equals("status")) { 4196 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.status"); 4197 } 4198 else if (name.equals("experimental")) { 4199 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.experimental"); 4200 } 4201 else if (name.equals("subjectCodeableConcept")) { 4202 this.subject = new CodeableConcept(); 4203 return this.subject; 4204 } 4205 else if (name.equals("subjectReference")) { 4206 this.subject = new Reference(); 4207 return this.subject; 4208 } 4209 else if (name.equals("date")) { 4210 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.date"); 4211 } 4212 else if (name.equals("publisher")) { 4213 this.publisher = new Reference(); 4214 return this.publisher; 4215 } 4216 else if (name.equals("contact")) { 4217 return addContact(); 4218 } 4219 else if (name.equals("description")) { 4220 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.description"); 4221 } 4222 else if (name.equals("useContext")) { 4223 return addUseContext(); 4224 } 4225 else if (name.equals("jurisdiction")) { 4226 return addJurisdiction(); 4227 } 4228 else if (name.equals("purpose")) { 4229 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.purpose"); 4230 } 4231 else if (name.equals("copyright")) { 4232 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.copyright"); 4233 } 4234 else if (name.equals("approvalDate")) { 4235 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.approvalDate"); 4236 } 4237 else if (name.equals("lastReviewDate")) { 4238 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.lastReviewDate"); 4239 } 4240 else if (name.equals("effectivePeriod")) { 4241 this.effectivePeriod = new Period(); 4242 return this.effectivePeriod; 4243 } 4244 else if (name.equals("performerType")) { 4245 this.performerType = new CodeableConcept(); 4246 return this.performerType; 4247 } 4248 else if (name.equals("category")) { 4249 return addCategory(); 4250 } 4251 else if (name.equals("code")) { 4252 this.code = new CodeableConcept(); 4253 return this.code; 4254 } 4255 else if (name.equals("permittedDataType")) { 4256 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.permittedDataType"); 4257 } 4258 else if (name.equals("multipleResultsAllowed")) { 4259 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.multipleResultsAllowed"); 4260 } 4261 else if (name.equals("bodySite")) { 4262 this.bodySite = new CodeableConcept(); 4263 return this.bodySite; 4264 } 4265 else if (name.equals("method")) { 4266 this.method = new CodeableConcept(); 4267 return this.method; 4268 } 4269 else if (name.equals("specimen")) { 4270 this.specimen = new Reference(); 4271 return this.specimen; 4272 } 4273 else if (name.equals("device")) { 4274 this.device = new Reference(); 4275 return this.device; 4276 } 4277 else if (name.equals("preferredReportName")) { 4278 throw new FHIRException("Cannot call addChild on a primitive type ObservationDefinition.preferredReportName"); 4279 } 4280 else if (name.equals("quantitativeDetails")) { 4281 this.quantitativeDetails = new ObservationDefinitionQuantitativeDetailsComponent(); 4282 return this.quantitativeDetails; 4283 } 4284 else if (name.equals("qualifiedInterval")) { 4285 return addQualifiedInterval(); 4286 } 4287 else if (name.equals("validCodedValueSet")) { 4288 this.validCodedValueSet = new Reference(); 4289 return this.validCodedValueSet; 4290 } 4291 else if (name.equals("normalCodedValueSet")) { 4292 this.normalCodedValueSet = new Reference(); 4293 return this.normalCodedValueSet; 4294 } 4295 else if (name.equals("abnormalCodedValueSet")) { 4296 this.abnormalCodedValueSet = new Reference(); 4297 return this.abnormalCodedValueSet; 4298 } 4299 else if (name.equals("criticalCodedValueSet")) { 4300 this.criticalCodedValueSet = new Reference(); 4301 return this.criticalCodedValueSet; 4302 } 4303 else if (name.equals("hasMember")) { 4304 return addHasMember(); 4305 } 4306 else if (name.equals("component")) { 4307 return addComponent(); 4308 } 4309 else 4310 return super.addChild(name); 4311 } 4312 4313 public String fhirType() { 4314 return "ObservationDefinition"; 4315 4316 } 4317 4318 public ObservationDefinition copy() { 4319 ObservationDefinition dst = new ObservationDefinition(); 4320 copyValues(dst); 4321 return dst; 4322 } 4323 4324 public void copyValues(ObservationDefinition dst) { 4325 super.copyValues(dst); 4326 dst.url = url == null ? null : url.copy(); 4327 dst.identifier = identifier == null ? null : identifier.copy(); 4328 dst.version = version == null ? null : version.copy(); 4329 dst.title = title == null ? null : title.copy(); 4330 if (derivedFromCanonical != null) { 4331 dst.derivedFromCanonical = new ArrayList<CanonicalType>(); 4332 for (CanonicalType i : derivedFromCanonical) 4333 dst.derivedFromCanonical.add(i.copy()); 4334 }; 4335 if (derivedFromUri != null) { 4336 dst.derivedFromUri = new ArrayList<UriType>(); 4337 for (UriType i : derivedFromUri) 4338 dst.derivedFromUri.add(i.copy()); 4339 }; 4340 dst.status = status == null ? null : status.copy(); 4341 dst.experimental = experimental == null ? null : experimental.copy(); 4342 dst.subject = subject == null ? null : subject.copy(); 4343 dst.date = date == null ? null : date.copy(); 4344 dst.publisher = publisher == null ? null : publisher.copy(); 4345 if (contact != null) { 4346 dst.contact = new ArrayList<ContactDetail>(); 4347 for (ContactDetail i : contact) 4348 dst.contact.add(i.copy()); 4349 }; 4350 dst.description = description == null ? null : description.copy(); 4351 if (useContext != null) { 4352 dst.useContext = new ArrayList<UsageContext>(); 4353 for (UsageContext i : useContext) 4354 dst.useContext.add(i.copy()); 4355 }; 4356 if (jurisdiction != null) { 4357 dst.jurisdiction = new ArrayList<CodeableConcept>(); 4358 for (CodeableConcept i : jurisdiction) 4359 dst.jurisdiction.add(i.copy()); 4360 }; 4361 dst.purpose = purpose == null ? null : purpose.copy(); 4362 dst.copyright = copyright == null ? null : copyright.copy(); 4363 dst.approvalDate = approvalDate == null ? null : approvalDate.copy(); 4364 dst.lastReviewDate = lastReviewDate == null ? null : lastReviewDate.copy(); 4365 dst.effectivePeriod = effectivePeriod == null ? null : effectivePeriod.copy(); 4366 dst.performerType = performerType == null ? null : performerType.copy(); 4367 if (category != null) { 4368 dst.category = new ArrayList<CodeableConcept>(); 4369 for (CodeableConcept i : category) 4370 dst.category.add(i.copy()); 4371 }; 4372 dst.code = code == null ? null : code.copy(); 4373 if (permittedDataType != null) { 4374 dst.permittedDataType = new ArrayList<Enumeration<ObservationDataType>>(); 4375 for (Enumeration<ObservationDataType> i : permittedDataType) 4376 dst.permittedDataType.add(i.copy()); 4377 }; 4378 dst.multipleResultsAllowed = multipleResultsAllowed == null ? null : multipleResultsAllowed.copy(); 4379 dst.bodySite = bodySite == null ? null : bodySite.copy(); 4380 dst.method = method == null ? null : method.copy(); 4381 dst.specimen = specimen == null ? null : specimen.copy(); 4382 dst.device = device == null ? null : device.copy(); 4383 dst.preferredReportName = preferredReportName == null ? null : preferredReportName.copy(); 4384 dst.quantitativeDetails = quantitativeDetails == null ? null : quantitativeDetails.copy(); 4385 if (qualifiedInterval != null) { 4386 dst.qualifiedInterval = new ArrayList<ObservationDefinitionQualifiedIntervalComponent>(); 4387 for (ObservationDefinitionQualifiedIntervalComponent i : qualifiedInterval) 4388 dst.qualifiedInterval.add(i.copy()); 4389 }; 4390 dst.validCodedValueSet = validCodedValueSet == null ? null : validCodedValueSet.copy(); 4391 dst.normalCodedValueSet = normalCodedValueSet == null ? null : normalCodedValueSet.copy(); 4392 dst.abnormalCodedValueSet = abnormalCodedValueSet == null ? null : abnormalCodedValueSet.copy(); 4393 dst.criticalCodedValueSet = criticalCodedValueSet == null ? null : criticalCodedValueSet.copy(); 4394 if (hasMember != null) { 4395 dst.hasMember = new ArrayList<Reference>(); 4396 for (Reference i : hasMember) 4397 dst.hasMember.add(i.copy()); 4398 }; 4399 if (component != null) { 4400 dst.component = new ArrayList<ObservationDefinitionComponentComponent>(); 4401 for (ObservationDefinitionComponentComponent i : component) 4402 dst.component.add(i.copy()); 4403 }; 4404 } 4405 4406 protected ObservationDefinition typedCopy() { 4407 return copy(); 4408 } 4409 4410 @Override 4411 public boolean equalsDeep(Base other_) { 4412 if (!super.equalsDeep(other_)) 4413 return false; 4414 if (!(other_ instanceof ObservationDefinition)) 4415 return false; 4416 ObservationDefinition o = (ObservationDefinition) other_; 4417 return compareDeep(url, o.url, true) && compareDeep(identifier, o.identifier, true) && compareDeep(version, o.version, true) 4418 && compareDeep(title, o.title, true) && compareDeep(derivedFromCanonical, o.derivedFromCanonical, true) 4419 && compareDeep(derivedFromUri, o.derivedFromUri, true) && compareDeep(status, o.status, true) && compareDeep(experimental, o.experimental, true) 4420 && compareDeep(subject, o.subject, true) && compareDeep(date, o.date, true) && compareDeep(publisher, o.publisher, true) 4421 && compareDeep(contact, o.contact, true) && compareDeep(description, o.description, true) && compareDeep(useContext, o.useContext, true) 4422 && compareDeep(jurisdiction, o.jurisdiction, true) && compareDeep(purpose, o.purpose, true) && compareDeep(copyright, o.copyright, true) 4423 && compareDeep(approvalDate, o.approvalDate, true) && compareDeep(lastReviewDate, o.lastReviewDate, true) 4424 && compareDeep(effectivePeriod, o.effectivePeriod, true) && compareDeep(performerType, o.performerType, true) 4425 && compareDeep(category, o.category, true) && compareDeep(code, o.code, true) && compareDeep(permittedDataType, o.permittedDataType, true) 4426 && compareDeep(multipleResultsAllowed, o.multipleResultsAllowed, true) && compareDeep(bodySite, o.bodySite, true) 4427 && compareDeep(method, o.method, true) && compareDeep(specimen, o.specimen, true) && compareDeep(device, o.device, true) 4428 && compareDeep(preferredReportName, o.preferredReportName, true) && compareDeep(quantitativeDetails, o.quantitativeDetails, true) 4429 && compareDeep(qualifiedInterval, o.qualifiedInterval, true) && compareDeep(validCodedValueSet, o.validCodedValueSet, true) 4430 && compareDeep(normalCodedValueSet, o.normalCodedValueSet, true) && compareDeep(abnormalCodedValueSet, o.abnormalCodedValueSet, true) 4431 && compareDeep(criticalCodedValueSet, o.criticalCodedValueSet, true) && compareDeep(hasMember, o.hasMember, true) 4432 && compareDeep(component, o.component, true); 4433 } 4434 4435 @Override 4436 public boolean equalsShallow(Base other_) { 4437 if (!super.equalsShallow(other_)) 4438 return false; 4439 if (!(other_ instanceof ObservationDefinition)) 4440 return false; 4441 ObservationDefinition o = (ObservationDefinition) other_; 4442 return compareValues(url, o.url, true) && compareValues(version, o.version, true) && compareValues(title, o.title, true) 4443 && compareValues(derivedFromUri, o.derivedFromUri, true) && compareValues(status, o.status, true) && compareValues(experimental, o.experimental, true) 4444 && compareValues(date, o.date, true) && compareValues(description, o.description, true) && compareValues(purpose, o.purpose, true) 4445 && compareValues(copyright, o.copyright, true) && compareValues(approvalDate, o.approvalDate, true) 4446 && compareValues(lastReviewDate, o.lastReviewDate, true) && compareValues(permittedDataType, o.permittedDataType, true) 4447 && compareValues(multipleResultsAllowed, o.multipleResultsAllowed, true) && compareValues(preferredReportName, o.preferredReportName, true) 4448 ; 4449 } 4450 4451 public boolean isEmpty() { 4452 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(url, identifier, version 4453 , title, derivedFromCanonical, derivedFromUri, status, experimental, subject, date 4454 , publisher, contact, description, useContext, jurisdiction, purpose, copyright 4455 , approvalDate, lastReviewDate, effectivePeriod, performerType, category, code, permittedDataType 4456 , multipleResultsAllowed, bodySite, method, specimen, device, preferredReportName 4457 , quantitativeDetails, qualifiedInterval, validCodedValueSet, normalCodedValueSet, abnormalCodedValueSet 4458 , criticalCodedValueSet, hasMember, component); 4459 } 4460 4461 @Override 4462 public ResourceType getResourceType() { 4463 return ResourceType.ObservationDefinition; 4464 } 4465 4466 /** 4467 * Search parameter: <b>identifier</b> 4468 * <p> 4469 * Description: <b>The unique identifier associated with the specimen definition</b><br> 4470 * Type: <b>token</b><br> 4471 * Path: <b>ObservationDefinition.identifier</b><br> 4472 * </p> 4473 */ 4474 @SearchParamDefinition(name="identifier", path="ObservationDefinition.identifier", description="The unique identifier associated with the specimen definition", type="token" ) 4475 public static final String SP_IDENTIFIER = "identifier"; 4476 /** 4477 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 4478 * <p> 4479 * Description: <b>The unique identifier associated with the specimen definition</b><br> 4480 * Type: <b>token</b><br> 4481 * Path: <b>ObservationDefinition.identifier</b><br> 4482 * </p> 4483 */ 4484 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 4485 4486 /** 4487 * Search parameter: <b>code</b> 4488 * <p> 4489 * Description: <b>Observation code</b><br> 4490 * Type: <b>token</b><br> 4491 * Path: <b>ObservationDefinition.code</b><br> 4492 * </p> 4493 */ 4494 @SearchParamDefinition(name="code", path="ObservationDefinition.code", description="Observation code", type="token" ) 4495 public static final String SP_CODE = "code"; 4496 /** 4497 * <b>Fluent Client</b> search parameter constant for <b>code</b> 4498 * <p> 4499 * Description: <b>Observation code</b><br> 4500 * Type: <b>token</b><br> 4501 * Path: <b>ObservationDefinition.code</b><br> 4502 * </p> 4503 */ 4504 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CODE); 4505 4506 /** 4507 * Search parameter: <b>method</b> 4508 * <p> 4509 * Description: <b>Method of observation</b><br> 4510 * Type: <b>token</b><br> 4511 * Path: <b>ObservationDefinition.method</b><br> 4512 * </p> 4513 */ 4514 @SearchParamDefinition(name="method", path="ObservationDefinition.method", description="Method of observation", type="token" ) 4515 public static final String SP_METHOD = "method"; 4516 /** 4517 * <b>Fluent Client</b> search parameter constant for <b>method</b> 4518 * <p> 4519 * Description: <b>Method of observation</b><br> 4520 * Type: <b>token</b><br> 4521 * Path: <b>ObservationDefinition.method</b><br> 4522 * </p> 4523 */ 4524 public static final ca.uhn.fhir.rest.gclient.TokenClientParam METHOD = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_METHOD); 4525 4526 /** 4527 * Search parameter: <b>experimental</b> 4528 * <p> 4529 * Description: <b>Not for genuine usage (true)</b><br> 4530 * Type: <b>token</b><br> 4531 * Path: <b>ObservationDefinition.experimental</b><br> 4532 * </p> 4533 */ 4534 @SearchParamDefinition(name="experimental", path="ObservationDefinition.experimental", description="Not for genuine usage (true)", type="token" ) 4535 public static final String SP_EXPERIMENTAL = "experimental"; 4536 /** 4537 * <b>Fluent Client</b> search parameter constant for <b>experimental</b> 4538 * <p> 4539 * Description: <b>Not for genuine usage (true)</b><br> 4540 * Type: <b>token</b><br> 4541 * Path: <b>ObservationDefinition.experimental</b><br> 4542 * </p> 4543 */ 4544 public static final ca.uhn.fhir.rest.gclient.TokenClientParam EXPERIMENTAL = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_EXPERIMENTAL); 4545 4546 /** 4547 * Search parameter: <b>category</b> 4548 * <p> 4549 * Description: <b>Category (class) of observation</b><br> 4550 * Type: <b>token</b><br> 4551 * Path: <b>ObservationDefinition.category</b><br> 4552 * </p> 4553 */ 4554 @SearchParamDefinition(name="category", path="ObservationDefinition.category", description="Category (class) of observation", type="token" ) 4555 public static final String SP_CATEGORY = "category"; 4556 /** 4557 * <b>Fluent Client</b> search parameter constant for <b>category</b> 4558 * <p> 4559 * Description: <b>Category (class) of observation</b><br> 4560 * Type: <b>token</b><br> 4561 * Path: <b>ObservationDefinition.category</b><br> 4562 * </p> 4563 */ 4564 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CATEGORY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CATEGORY); 4565 4566 /** 4567 * Search parameter: <b>title</b> 4568 * <p> 4569 * Description: <b>Human-friendly name of the ObservationDefinition</b><br> 4570 * Type: <b>string</b><br> 4571 * Path: <b>ObservationDefinition.title</b><br> 4572 * </p> 4573 */ 4574 @SearchParamDefinition(name="title", path="ObservationDefinition.title", description="Human-friendly name of the ObservationDefinition", type="string" ) 4575 public static final String SP_TITLE = "title"; 4576 /** 4577 * <b>Fluent Client</b> search parameter constant for <b>title</b> 4578 * <p> 4579 * Description: <b>Human-friendly name of the ObservationDefinition</b><br> 4580 * Type: <b>string</b><br> 4581 * Path: <b>ObservationDefinition.title</b><br> 4582 * </p> 4583 */ 4584 public static final ca.uhn.fhir.rest.gclient.StringClientParam TITLE = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_TITLE); 4585 4586 /** 4587 * Search parameter: <b>status</b> 4588 * <p> 4589 * Description: <b>Publication status of the ObservationDefinition: draft, active, retired, unknown</b><br> 4590 * Type: <b>token</b><br> 4591 * Path: <b>ObservationDefinition.status</b><br> 4592 * </p> 4593 */ 4594 @SearchParamDefinition(name="status", path="ObservationDefinition.status", description="Publication status of the ObservationDefinition: draft, active, retired, unknown", type="token" ) 4595 public static final String SP_STATUS = "status"; 4596 /** 4597 * <b>Fluent Client</b> search parameter constant for <b>status</b> 4598 * <p> 4599 * Description: <b>Publication status of the ObservationDefinition: draft, active, retired, unknown</b><br> 4600 * Type: <b>token</b><br> 4601 * Path: <b>ObservationDefinition.status</b><br> 4602 * </p> 4603 */ 4604 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 4605 4606 4607} 4608