
001package org.hl7.fhir.r5.model; 002 003 004/* 005 Copyright (c) 2011+, HL7, Inc. 006 All rights reserved. 007 008 Redistribution and use in source and binary forms, with or without modification, \ 009 are permitted provided that the following conditions are met: 010 011 * Redistributions of source code must retain the above copyright notice, this \ 012 list of conditions and the following disclaimer. 013 * Redistributions in binary form must reproduce the above copyright notice, \ 014 this list of conditions and the following disclaimer in the documentation \ 015 and/or other materials provided with the distribution. 016 * Neither the name of HL7 nor the names of its contributors may be used to 017 endorse or promote products derived from this software without specific 018 prior written permission. 019 020 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND \ 021 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \ 022 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \ 023 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \ 024 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT \ 025 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR \ 026 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \ 027 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) \ 028 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE \ 029 POSSIBILITY OF SUCH DAMAGE. 030 */ 031 032// Generated on Sat, Nov 5, 2022 10:47+1100 for FHIR v5.0.0-ballot 033 034import java.util.ArrayList; 035import java.util.Date; 036import java.util.List; 037import org.hl7.fhir.utilities.Utilities; 038import org.hl7.fhir.r5.model.Enumerations.*; 039import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 040import org.hl7.fhir.exceptions.FHIRException; 041import org.hl7.fhir.instance.model.api.ICompositeType; 042import ca.uhn.fhir.model.api.annotation.ResourceDef; 043import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 044import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 045import ca.uhn.fhir.model.api.annotation.Child; 046import ca.uhn.fhir.model.api.annotation.ChildOrder; 047import ca.uhn.fhir.model.api.annotation.Description; 048import ca.uhn.fhir.model.api.annotation.Block; 049 050/** 051 * Measurements and simple assertions made about a patient, device or other subject. 052 */ 053@ResourceDef(name="Observation", profile="http://hl7.org/fhir/StructureDefinition/Observation") 054public class Observation extends DomainResource { 055 056 public enum TriggeredBytype { 057 /** 058 * Performance of one or more other tests depending on the results of the initial test. This may include collection of additional specimen. While a new ServiceRequest is not required to perform the additional test, where it is still needed (e.g., requesting another laboratory to perform the reflex test), the Observation.basedOn would reference the new ServiceRequest that requested the additional test to be performed as well as the original ServiceRequest to reflect the one that provided the authorization. 059 */ 060 REFLEX, 061 /** 062 * Performance of the same test again with the same parameters/settings/solution. 063 */ 064 REPEAT, 065 /** 066 * Performance of the same test but with different parameters/settings/solution. 067 */ 068 RERUN, 069 /** 070 * added to help the parsers with the generic types 071 */ 072 NULL; 073 public static TriggeredBytype fromCode(String codeString) throws FHIRException { 074 if (codeString == null || "".equals(codeString)) 075 return null; 076 if ("reflex".equals(codeString)) 077 return REFLEX; 078 if ("repeat".equals(codeString)) 079 return REPEAT; 080 if ("re-run".equals(codeString)) 081 return RERUN; 082 if (Configuration.isAcceptInvalidEnums()) 083 return null; 084 else 085 throw new FHIRException("Unknown TriggeredBytype code '"+codeString+"'"); 086 } 087 public String toCode() { 088 switch (this) { 089 case REFLEX: return "reflex"; 090 case REPEAT: return "repeat"; 091 case RERUN: return "re-run"; 092 case NULL: return null; 093 default: return "?"; 094 } 095 } 096 public String getSystem() { 097 switch (this) { 098 case REFLEX: return "http://hl7.org/fhir/observation-triggeredbytype"; 099 case REPEAT: return "http://hl7.org/fhir/observation-triggeredbytype"; 100 case RERUN: return "http://hl7.org/fhir/observation-triggeredbytype"; 101 case NULL: return null; 102 default: return "?"; 103 } 104 } 105 public String getDefinition() { 106 switch (this) { 107 case REFLEX: return "Performance of one or more other tests depending on the results of the initial test. This may include collection of additional specimen. While a new ServiceRequest is not required to perform the additional test, where it is still needed (e.g., requesting another laboratory to perform the reflex test), the Observation.basedOn would reference the new ServiceRequest that requested the additional test to be performed as well as the original ServiceRequest to reflect the one that provided the authorization."; 108 case REPEAT: return "Performance of the same test again with the same parameters/settings/solution."; 109 case RERUN: return "Performance of the same test but with different parameters/settings/solution."; 110 case NULL: return null; 111 default: return "?"; 112 } 113 } 114 public String getDisplay() { 115 switch (this) { 116 case REFLEX: return "Reflex"; 117 case REPEAT: return "Repeat (per policy)"; 118 case RERUN: return "Re-run (per policy)"; 119 case NULL: return null; 120 default: return "?"; 121 } 122 } 123 } 124 125 public static class TriggeredBytypeEnumFactory implements EnumFactory<TriggeredBytype> { 126 public TriggeredBytype fromCode(String codeString) throws IllegalArgumentException { 127 if (codeString == null || "".equals(codeString)) 128 if (codeString == null || "".equals(codeString)) 129 return null; 130 if ("reflex".equals(codeString)) 131 return TriggeredBytype.REFLEX; 132 if ("repeat".equals(codeString)) 133 return TriggeredBytype.REPEAT; 134 if ("re-run".equals(codeString)) 135 return TriggeredBytype.RERUN; 136 throw new IllegalArgumentException("Unknown TriggeredBytype code '"+codeString+"'"); 137 } 138 public Enumeration<TriggeredBytype> fromType(Base code) throws FHIRException { 139 if (code == null) 140 return null; 141 if (code.isEmpty()) 142 return new Enumeration<TriggeredBytype>(this); 143 String codeString = ((PrimitiveType) code).asStringValue(); 144 if (codeString == null || "".equals(codeString)) 145 return null; 146 if ("reflex".equals(codeString)) 147 return new Enumeration<TriggeredBytype>(this, TriggeredBytype.REFLEX); 148 if ("repeat".equals(codeString)) 149 return new Enumeration<TriggeredBytype>(this, TriggeredBytype.REPEAT); 150 if ("re-run".equals(codeString)) 151 return new Enumeration<TriggeredBytype>(this, TriggeredBytype.RERUN); 152 throw new FHIRException("Unknown TriggeredBytype code '"+codeString+"'"); 153 } 154 public String toCode(TriggeredBytype code) { 155 if (code == TriggeredBytype.REFLEX) 156 return "reflex"; 157 if (code == TriggeredBytype.REPEAT) 158 return "repeat"; 159 if (code == TriggeredBytype.RERUN) 160 return "re-run"; 161 return "?"; 162 } 163 public String toSystem(TriggeredBytype code) { 164 return code.getSystem(); 165 } 166 } 167 168 @Block() 169 public static class ObservationTriggeredByComponent extends BackboneElement implements IBaseBackboneElement { 170 /** 171 * Reference to the triggering observation. 172 */ 173 @Child(name = "observation", type = {Observation.class}, order=1, min=1, max=1, modifier=false, summary=true) 174 @Description(shortDefinition="Triggering observation", formalDefinition="Reference to the triggering observation." ) 175 protected Reference observation; 176 177 /** 178 * The type of trigger. 179Reflex | Repeat | Re-run. 180 */ 181 @Child(name = "type", type = {CodeType.class}, order=2, min=1, max=1, modifier=false, summary=true) 182 @Description(shortDefinition="reflex | repeat | re-run", formalDefinition="The type of trigger.\nReflex | Repeat | Re-run." ) 183 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-triggeredbytype") 184 protected Enumeration<TriggeredBytype> type; 185 186 /** 187 * Provides the reason why this observation was performed as a result of the observation(s) referenced. 188 */ 189 @Child(name = "reason", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false) 190 @Description(shortDefinition="Reason that the observation was triggered", formalDefinition="Provides the reason why this observation was performed as a result of the observation(s) referenced." ) 191 protected StringType reason; 192 193 private static final long serialVersionUID = -737822241L; 194 195 /** 196 * Constructor 197 */ 198 public ObservationTriggeredByComponent() { 199 super(); 200 } 201 202 /** 203 * Constructor 204 */ 205 public ObservationTriggeredByComponent(Reference observation, TriggeredBytype type) { 206 super(); 207 this.setObservation(observation); 208 this.setType(type); 209 } 210 211 /** 212 * @return {@link #observation} (Reference to the triggering observation.) 213 */ 214 public Reference getObservation() { 215 if (this.observation == null) 216 if (Configuration.errorOnAutoCreate()) 217 throw new Error("Attempt to auto-create ObservationTriggeredByComponent.observation"); 218 else if (Configuration.doAutoCreate()) 219 this.observation = new Reference(); // cc 220 return this.observation; 221 } 222 223 public boolean hasObservation() { 224 return this.observation != null && !this.observation.isEmpty(); 225 } 226 227 /** 228 * @param value {@link #observation} (Reference to the triggering observation.) 229 */ 230 public ObservationTriggeredByComponent setObservation(Reference value) { 231 this.observation = value; 232 return this; 233 } 234 235 /** 236 * @return {@link #type} (The type of trigger. 237Reflex | Repeat | Re-run.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value 238 */ 239 public Enumeration<TriggeredBytype> getTypeElement() { 240 if (this.type == null) 241 if (Configuration.errorOnAutoCreate()) 242 throw new Error("Attempt to auto-create ObservationTriggeredByComponent.type"); 243 else if (Configuration.doAutoCreate()) 244 this.type = new Enumeration<TriggeredBytype>(new TriggeredBytypeEnumFactory()); // bb 245 return this.type; 246 } 247 248 public boolean hasTypeElement() { 249 return this.type != null && !this.type.isEmpty(); 250 } 251 252 public boolean hasType() { 253 return this.type != null && !this.type.isEmpty(); 254 } 255 256 /** 257 * @param value {@link #type} (The type of trigger. 258Reflex | Repeat | Re-run.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value 259 */ 260 public ObservationTriggeredByComponent setTypeElement(Enumeration<TriggeredBytype> value) { 261 this.type = value; 262 return this; 263 } 264 265 /** 266 * @return The type of trigger. 267Reflex | Repeat | Re-run. 268 */ 269 public TriggeredBytype getType() { 270 return this.type == null ? null : this.type.getValue(); 271 } 272 273 /** 274 * @param value The type of trigger. 275Reflex | Repeat | Re-run. 276 */ 277 public ObservationTriggeredByComponent setType(TriggeredBytype value) { 278 if (this.type == null) 279 this.type = new Enumeration<TriggeredBytype>(new TriggeredBytypeEnumFactory()); 280 this.type.setValue(value); 281 return this; 282 } 283 284 /** 285 * @return {@link #reason} (Provides the reason why this observation was performed as a result of the observation(s) referenced.). This is the underlying object with id, value and extensions. The accessor "getReason" gives direct access to the value 286 */ 287 public StringType getReasonElement() { 288 if (this.reason == null) 289 if (Configuration.errorOnAutoCreate()) 290 throw new Error("Attempt to auto-create ObservationTriggeredByComponent.reason"); 291 else if (Configuration.doAutoCreate()) 292 this.reason = new StringType(); // bb 293 return this.reason; 294 } 295 296 public boolean hasReasonElement() { 297 return this.reason != null && !this.reason.isEmpty(); 298 } 299 300 public boolean hasReason() { 301 return this.reason != null && !this.reason.isEmpty(); 302 } 303 304 /** 305 * @param value {@link #reason} (Provides the reason why this observation was performed as a result of the observation(s) referenced.). This is the underlying object with id, value and extensions. The accessor "getReason" gives direct access to the value 306 */ 307 public ObservationTriggeredByComponent setReasonElement(StringType value) { 308 this.reason = value; 309 return this; 310 } 311 312 /** 313 * @return Provides the reason why this observation was performed as a result of the observation(s) referenced. 314 */ 315 public String getReason() { 316 return this.reason == null ? null : this.reason.getValue(); 317 } 318 319 /** 320 * @param value Provides the reason why this observation was performed as a result of the observation(s) referenced. 321 */ 322 public ObservationTriggeredByComponent setReason(String value) { 323 if (Utilities.noString(value)) 324 this.reason = null; 325 else { 326 if (this.reason == null) 327 this.reason = new StringType(); 328 this.reason.setValue(value); 329 } 330 return this; 331 } 332 333 protected void listChildren(List<Property> children) { 334 super.listChildren(children); 335 children.add(new Property("observation", "Reference(Observation)", "Reference to the triggering observation.", 0, 1, observation)); 336 children.add(new Property("type", "code", "The type of trigger.\nReflex | Repeat | Re-run.", 0, 1, type)); 337 children.add(new Property("reason", "string", "Provides the reason why this observation was performed as a result of the observation(s) referenced.", 0, 1, reason)); 338 } 339 340 @Override 341 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 342 switch (_hash) { 343 case 122345516: /*observation*/ return new Property("observation", "Reference(Observation)", "Reference to the triggering observation.", 0, 1, observation); 344 case 3575610: /*type*/ return new Property("type", "code", "The type of trigger.\nReflex | Repeat | Re-run.", 0, 1, type); 345 case -934964668: /*reason*/ return new Property("reason", "string", "Provides the reason why this observation was performed as a result of the observation(s) referenced.", 0, 1, reason); 346 default: return super.getNamedProperty(_hash, _name, _checkValid); 347 } 348 349 } 350 351 @Override 352 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 353 switch (hash) { 354 case 122345516: /*observation*/ return this.observation == null ? new Base[0] : new Base[] {this.observation}; // Reference 355 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // Enumeration<TriggeredBytype> 356 case -934964668: /*reason*/ return this.reason == null ? new Base[0] : new Base[] {this.reason}; // StringType 357 default: return super.getProperty(hash, name, checkValid); 358 } 359 360 } 361 362 @Override 363 public Base setProperty(int hash, String name, Base value) throws FHIRException { 364 switch (hash) { 365 case 122345516: // observation 366 this.observation = TypeConvertor.castToReference(value); // Reference 367 return value; 368 case 3575610: // type 369 value = new TriggeredBytypeEnumFactory().fromType(TypeConvertor.castToCode(value)); 370 this.type = (Enumeration) value; // Enumeration<TriggeredBytype> 371 return value; 372 case -934964668: // reason 373 this.reason = TypeConvertor.castToString(value); // StringType 374 return value; 375 default: return super.setProperty(hash, name, value); 376 } 377 378 } 379 380 @Override 381 public Base setProperty(String name, Base value) throws FHIRException { 382 if (name.equals("observation")) { 383 this.observation = TypeConvertor.castToReference(value); // Reference 384 } else if (name.equals("type")) { 385 value = new TriggeredBytypeEnumFactory().fromType(TypeConvertor.castToCode(value)); 386 this.type = (Enumeration) value; // Enumeration<TriggeredBytype> 387 } else if (name.equals("reason")) { 388 this.reason = TypeConvertor.castToString(value); // StringType 389 } else 390 return super.setProperty(name, value); 391 return value; 392 } 393 394 @Override 395 public Base makeProperty(int hash, String name) throws FHIRException { 396 switch (hash) { 397 case 122345516: return getObservation(); 398 case 3575610: return getTypeElement(); 399 case -934964668: return getReasonElement(); 400 default: return super.makeProperty(hash, name); 401 } 402 403 } 404 405 @Override 406 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 407 switch (hash) { 408 case 122345516: /*observation*/ return new String[] {"Reference"}; 409 case 3575610: /*type*/ return new String[] {"code"}; 410 case -934964668: /*reason*/ return new String[] {"string"}; 411 default: return super.getTypesForProperty(hash, name); 412 } 413 414 } 415 416 @Override 417 public Base addChild(String name) throws FHIRException { 418 if (name.equals("observation")) { 419 this.observation = new Reference(); 420 return this.observation; 421 } 422 else if (name.equals("type")) { 423 throw new FHIRException("Cannot call addChild on a primitive type Observation.triggeredBy.type"); 424 } 425 else if (name.equals("reason")) { 426 throw new FHIRException("Cannot call addChild on a primitive type Observation.triggeredBy.reason"); 427 } 428 else 429 return super.addChild(name); 430 } 431 432 public ObservationTriggeredByComponent copy() { 433 ObservationTriggeredByComponent dst = new ObservationTriggeredByComponent(); 434 copyValues(dst); 435 return dst; 436 } 437 438 public void copyValues(ObservationTriggeredByComponent dst) { 439 super.copyValues(dst); 440 dst.observation = observation == null ? null : observation.copy(); 441 dst.type = type == null ? null : type.copy(); 442 dst.reason = reason == null ? null : reason.copy(); 443 } 444 445 @Override 446 public boolean equalsDeep(Base other_) { 447 if (!super.equalsDeep(other_)) 448 return false; 449 if (!(other_ instanceof ObservationTriggeredByComponent)) 450 return false; 451 ObservationTriggeredByComponent o = (ObservationTriggeredByComponent) other_; 452 return compareDeep(observation, o.observation, true) && compareDeep(type, o.type, true) && compareDeep(reason, o.reason, true) 453 ; 454 } 455 456 @Override 457 public boolean equalsShallow(Base other_) { 458 if (!super.equalsShallow(other_)) 459 return false; 460 if (!(other_ instanceof ObservationTriggeredByComponent)) 461 return false; 462 ObservationTriggeredByComponent o = (ObservationTriggeredByComponent) other_; 463 return compareValues(type, o.type, true) && compareValues(reason, o.reason, true); 464 } 465 466 public boolean isEmpty() { 467 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(observation, type, reason 468 ); 469 } 470 471 public String fhirType() { 472 return "Observation.triggeredBy"; 473 474 } 475 476 } 477 478 @Block() 479 public static class ObservationReferenceRangeComponent extends BackboneElement implements IBaseBackboneElement { 480 /** 481 * The value of the low bound of the reference range. The low bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the low bound is omitted, it is assumed to be meaningless (e.g. reference range is <=2.3). 482 */ 483 @Child(name = "low", type = {Quantity.class}, order=1, min=0, max=1, modifier=false, summary=false) 484 @Description(shortDefinition="Low Range, if relevant", formalDefinition="The value of the low bound of the reference range. The low bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the low bound is omitted, it is assumed to be meaningless (e.g. reference range is <=2.3)." ) 485 protected Quantity low; 486 487 /** 488 * The value of the high bound of the reference range. The high bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the high bound is omitted, it is assumed to be meaningless (e.g. reference range is >= 2.3). 489 */ 490 @Child(name = "high", type = {Quantity.class}, order=2, min=0, max=1, modifier=false, summary=false) 491 @Description(shortDefinition="High Range, if relevant", formalDefinition="The value of the high bound of the reference range. The high bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the high bound is omitted, it is assumed to be meaningless (e.g. reference range is >= 2.3)." ) 492 protected Quantity high; 493 494 /** 495 * The value of the normal value of the reference range. 496 */ 497 @Child(name = "normalValue", type = {CodeableConcept.class}, order=3, min=0, max=1, modifier=false, summary=false) 498 @Description(shortDefinition="Normal value, if relevant", formalDefinition="The value of the normal value of the reference range." ) 499 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-referencerange-normalvalue") 500 protected CodeableConcept normalValue; 501 502 /** 503 * Codes to indicate the what part of the targeted reference population it applies to. For example, the normal or therapeutic range. 504 */ 505 @Child(name = "type", type = {CodeableConcept.class}, order=4, min=0, max=1, modifier=false, summary=false) 506 @Description(shortDefinition="Reference range qualifier", formalDefinition="Codes to indicate the what part of the targeted reference population it applies to. For example, the normal or therapeutic range." ) 507 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/referencerange-meaning") 508 protected CodeableConcept type; 509 510 /** 511 * Codes to indicate the target population this reference range applies to. For example, a reference range may be based on the normal population or a particular sex or race. Multiple `appliesTo` are interpreted as an "AND" of the target populations. For example, to represent a target population of African American females, both a code of female and a code for African American would be used. 512 */ 513 @Child(name = "appliesTo", type = {CodeableConcept.class}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 514 @Description(shortDefinition="Reference range population", formalDefinition="Codes to indicate the target population this reference range applies to. For example, a reference range may be based on the normal population or a particular sex or race. Multiple `appliesTo` are interpreted as an \"AND\" of the target populations. For example, to represent a target population of African American females, both a code of female and a code for African American would be used." ) 515 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/referencerange-appliesto") 516 protected List<CodeableConcept> appliesTo; 517 518 /** 519 * 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. 520 */ 521 @Child(name = "age", type = {Range.class}, order=6, min=0, max=1, modifier=false, summary=false) 522 @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." ) 523 protected Range age; 524 525 /** 526 * Text based reference range in an observation which may be used when a quantitative range is not appropriate for an observation. An example would be a reference value of "Negative" or a list or table of "normals". 527 */ 528 @Child(name = "text", type = {StringType.class}, order=7, min=0, max=1, modifier=false, summary=false) 529 @Description(shortDefinition="Text based reference range in an observation", formalDefinition="Text based reference range in an observation which may be used when a quantitative range is not appropriate for an observation. An example would be a reference value of \"Negative\" or a list or table of \"normals\"." ) 530 protected StringType text; 531 532 private static final long serialVersionUID = -2015583438L; 533 534 /** 535 * Constructor 536 */ 537 public ObservationReferenceRangeComponent() { 538 super(); 539 } 540 541 /** 542 * @return {@link #low} (The value of the low bound of the reference range. The low bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the low bound is omitted, it is assumed to be meaningless (e.g. reference range is <=2.3).) 543 */ 544 public Quantity getLow() { 545 if (this.low == null) 546 if (Configuration.errorOnAutoCreate()) 547 throw new Error("Attempt to auto-create ObservationReferenceRangeComponent.low"); 548 else if (Configuration.doAutoCreate()) 549 this.low = new Quantity(); // cc 550 return this.low; 551 } 552 553 public boolean hasLow() { 554 return this.low != null && !this.low.isEmpty(); 555 } 556 557 /** 558 * @param value {@link #low} (The value of the low bound of the reference range. The low bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the low bound is omitted, it is assumed to be meaningless (e.g. reference range is <=2.3).) 559 */ 560 public ObservationReferenceRangeComponent setLow(Quantity value) { 561 this.low = value; 562 return this; 563 } 564 565 /** 566 * @return {@link #high} (The value of the high bound of the reference range. The high bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the high bound is omitted, it is assumed to be meaningless (e.g. reference range is >= 2.3).) 567 */ 568 public Quantity getHigh() { 569 if (this.high == null) 570 if (Configuration.errorOnAutoCreate()) 571 throw new Error("Attempt to auto-create ObservationReferenceRangeComponent.high"); 572 else if (Configuration.doAutoCreate()) 573 this.high = new Quantity(); // cc 574 return this.high; 575 } 576 577 public boolean hasHigh() { 578 return this.high != null && !this.high.isEmpty(); 579 } 580 581 /** 582 * @param value {@link #high} (The value of the high bound of the reference range. The high bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the high bound is omitted, it is assumed to be meaningless (e.g. reference range is >= 2.3).) 583 */ 584 public ObservationReferenceRangeComponent setHigh(Quantity value) { 585 this.high = value; 586 return this; 587 } 588 589 /** 590 * @return {@link #normalValue} (The value of the normal value of the reference range.) 591 */ 592 public CodeableConcept getNormalValue() { 593 if (this.normalValue == null) 594 if (Configuration.errorOnAutoCreate()) 595 throw new Error("Attempt to auto-create ObservationReferenceRangeComponent.normalValue"); 596 else if (Configuration.doAutoCreate()) 597 this.normalValue = new CodeableConcept(); // cc 598 return this.normalValue; 599 } 600 601 public boolean hasNormalValue() { 602 return this.normalValue != null && !this.normalValue.isEmpty(); 603 } 604 605 /** 606 * @param value {@link #normalValue} (The value of the normal value of the reference range.) 607 */ 608 public ObservationReferenceRangeComponent setNormalValue(CodeableConcept value) { 609 this.normalValue = value; 610 return this; 611 } 612 613 /** 614 * @return {@link #type} (Codes to indicate the what part of the targeted reference population it applies to. For example, the normal or therapeutic range.) 615 */ 616 public CodeableConcept getType() { 617 if (this.type == null) 618 if (Configuration.errorOnAutoCreate()) 619 throw new Error("Attempt to auto-create ObservationReferenceRangeComponent.type"); 620 else if (Configuration.doAutoCreate()) 621 this.type = new CodeableConcept(); // cc 622 return this.type; 623 } 624 625 public boolean hasType() { 626 return this.type != null && !this.type.isEmpty(); 627 } 628 629 /** 630 * @param value {@link #type} (Codes to indicate the what part of the targeted reference population it applies to. For example, the normal or therapeutic range.) 631 */ 632 public ObservationReferenceRangeComponent setType(CodeableConcept value) { 633 this.type = value; 634 return this; 635 } 636 637 /** 638 * @return {@link #appliesTo} (Codes to indicate the target population this reference range applies to. For example, a reference range may be based on the normal population or a particular sex or race. Multiple `appliesTo` are interpreted as an "AND" of the target populations. For example, to represent a target population of African American females, both a code of female and a code for African American would be used.) 639 */ 640 public List<CodeableConcept> getAppliesTo() { 641 if (this.appliesTo == null) 642 this.appliesTo = new ArrayList<CodeableConcept>(); 643 return this.appliesTo; 644 } 645 646 /** 647 * @return Returns a reference to <code>this</code> for easy method chaining 648 */ 649 public ObservationReferenceRangeComponent setAppliesTo(List<CodeableConcept> theAppliesTo) { 650 this.appliesTo = theAppliesTo; 651 return this; 652 } 653 654 public boolean hasAppliesTo() { 655 if (this.appliesTo == null) 656 return false; 657 for (CodeableConcept item : this.appliesTo) 658 if (!item.isEmpty()) 659 return true; 660 return false; 661 } 662 663 public CodeableConcept addAppliesTo() { //3 664 CodeableConcept t = new CodeableConcept(); 665 if (this.appliesTo == null) 666 this.appliesTo = new ArrayList<CodeableConcept>(); 667 this.appliesTo.add(t); 668 return t; 669 } 670 671 public ObservationReferenceRangeComponent addAppliesTo(CodeableConcept t) { //3 672 if (t == null) 673 return this; 674 if (this.appliesTo == null) 675 this.appliesTo = new ArrayList<CodeableConcept>(); 676 this.appliesTo.add(t); 677 return this; 678 } 679 680 /** 681 * @return The first repetition of repeating field {@link #appliesTo}, creating it if it does not already exist {3} 682 */ 683 public CodeableConcept getAppliesToFirstRep() { 684 if (getAppliesTo().isEmpty()) { 685 addAppliesTo(); 686 } 687 return getAppliesTo().get(0); 688 } 689 690 /** 691 * @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.) 692 */ 693 public Range getAge() { 694 if (this.age == null) 695 if (Configuration.errorOnAutoCreate()) 696 throw new Error("Attempt to auto-create ObservationReferenceRangeComponent.age"); 697 else if (Configuration.doAutoCreate()) 698 this.age = new Range(); // cc 699 return this.age; 700 } 701 702 public boolean hasAge() { 703 return this.age != null && !this.age.isEmpty(); 704 } 705 706 /** 707 * @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.) 708 */ 709 public ObservationReferenceRangeComponent setAge(Range value) { 710 this.age = value; 711 return this; 712 } 713 714 /** 715 * @return {@link #text} (Text based reference range in an observation which may be used when a quantitative range is not appropriate for an observation. An example would be a reference value of "Negative" or a list or table of "normals".). This is the underlying object with id, value and extensions. The accessor "getText" gives direct access to the value 716 */ 717 public StringType getTextElement() { 718 if (this.text == null) 719 if (Configuration.errorOnAutoCreate()) 720 throw new Error("Attempt to auto-create ObservationReferenceRangeComponent.text"); 721 else if (Configuration.doAutoCreate()) 722 this.text = new StringType(); // bb 723 return this.text; 724 } 725 726 public boolean hasTextElement() { 727 return this.text != null && !this.text.isEmpty(); 728 } 729 730 public boolean hasText() { 731 return this.text != null && !this.text.isEmpty(); 732 } 733 734 /** 735 * @param value {@link #text} (Text based reference range in an observation which may be used when a quantitative range is not appropriate for an observation. An example would be a reference value of "Negative" or a list or table of "normals".). This is the underlying object with id, value and extensions. The accessor "getText" gives direct access to the value 736 */ 737 public ObservationReferenceRangeComponent setTextElement(StringType value) { 738 this.text = value; 739 return this; 740 } 741 742 /** 743 * @return Text based reference range in an observation which may be used when a quantitative range is not appropriate for an observation. An example would be a reference value of "Negative" or a list or table of "normals". 744 */ 745 public String getText() { 746 return this.text == null ? null : this.text.getValue(); 747 } 748 749 /** 750 * @param value Text based reference range in an observation which may be used when a quantitative range is not appropriate for an observation. An example would be a reference value of "Negative" or a list or table of "normals". 751 */ 752 public ObservationReferenceRangeComponent setText(String value) { 753 if (Utilities.noString(value)) 754 this.text = null; 755 else { 756 if (this.text == null) 757 this.text = new StringType(); 758 this.text.setValue(value); 759 } 760 return this; 761 } 762 763 protected void listChildren(List<Property> children) { 764 super.listChildren(children); 765 children.add(new Property("low", "Quantity", "The value of the low bound of the reference range. The low bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the low bound is omitted, it is assumed to be meaningless (e.g. reference range is <=2.3).", 0, 1, low)); 766 children.add(new Property("high", "Quantity", "The value of the high bound of the reference range. The high bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the high bound is omitted, it is assumed to be meaningless (e.g. reference range is >= 2.3).", 0, 1, high)); 767 children.add(new Property("normalValue", "CodeableConcept", "The value of the normal value of the reference range.", 0, 1, normalValue)); 768 children.add(new Property("type", "CodeableConcept", "Codes to indicate the what part of the targeted reference population it applies to. For example, the normal or therapeutic range.", 0, 1, type)); 769 children.add(new Property("appliesTo", "CodeableConcept", "Codes to indicate the target population this reference range applies to. For example, a reference range may be based on the normal population or a particular sex or race. Multiple `appliesTo` are interpreted as an \"AND\" of the target populations. For example, to represent a target population of African American females, both a code of female and a code for African American would be used.", 0, java.lang.Integer.MAX_VALUE, appliesTo)); 770 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)); 771 children.add(new Property("text", "string", "Text based reference range in an observation which may be used when a quantitative range is not appropriate for an observation. An example would be a reference value of \"Negative\" or a list or table of \"normals\".", 0, 1, text)); 772 } 773 774 @Override 775 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 776 switch (_hash) { 777 case 107348: /*low*/ return new Property("low", "Quantity", "The value of the low bound of the reference range. The low bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the low bound is omitted, it is assumed to be meaningless (e.g. reference range is <=2.3).", 0, 1, low); 778 case 3202466: /*high*/ return new Property("high", "Quantity", "The value of the high bound of the reference range. The high bound of the reference range endpoint is inclusive of the value (e.g. reference range is >=5 - <=9). If the high bound is omitted, it is assumed to be meaningless (e.g. reference range is >= 2.3).", 0, 1, high); 779 case -270017334: /*normalValue*/ return new Property("normalValue", "CodeableConcept", "The value of the normal value of the reference range.", 0, 1, normalValue); 780 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Codes to indicate the what part of the targeted reference population it applies to. For example, the normal or therapeutic range.", 0, 1, type); 781 case -2089924569: /*appliesTo*/ return new Property("appliesTo", "CodeableConcept", "Codes to indicate the target population this reference range applies to. For example, a reference range may be based on the normal population or a particular sex or race. Multiple `appliesTo` are interpreted as an \"AND\" of the target populations. For example, to represent a target population of African American females, both a code of female and a code for African American would be used.", 0, java.lang.Integer.MAX_VALUE, appliesTo); 782 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); 783 case 3556653: /*text*/ return new Property("text", "string", "Text based reference range in an observation which may be used when a quantitative range is not appropriate for an observation. An example would be a reference value of \"Negative\" or a list or table of \"normals\".", 0, 1, text); 784 default: return super.getNamedProperty(_hash, _name, _checkValid); 785 } 786 787 } 788 789 @Override 790 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 791 switch (hash) { 792 case 107348: /*low*/ return this.low == null ? new Base[0] : new Base[] {this.low}; // Quantity 793 case 3202466: /*high*/ return this.high == null ? new Base[0] : new Base[] {this.high}; // Quantity 794 case -270017334: /*normalValue*/ return this.normalValue == null ? new Base[0] : new Base[] {this.normalValue}; // CodeableConcept 795 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 796 case -2089924569: /*appliesTo*/ return this.appliesTo == null ? new Base[0] : this.appliesTo.toArray(new Base[this.appliesTo.size()]); // CodeableConcept 797 case 96511: /*age*/ return this.age == null ? new Base[0] : new Base[] {this.age}; // Range 798 case 3556653: /*text*/ return this.text == null ? new Base[0] : new Base[] {this.text}; // StringType 799 default: return super.getProperty(hash, name, checkValid); 800 } 801 802 } 803 804 @Override 805 public Base setProperty(int hash, String name, Base value) throws FHIRException { 806 switch (hash) { 807 case 107348: // low 808 this.low = TypeConvertor.castToQuantity(value); // Quantity 809 return value; 810 case 3202466: // high 811 this.high = TypeConvertor.castToQuantity(value); // Quantity 812 return value; 813 case -270017334: // normalValue 814 this.normalValue = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 815 return value; 816 case 3575610: // type 817 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 818 return value; 819 case -2089924569: // appliesTo 820 this.getAppliesTo().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 821 return value; 822 case 96511: // age 823 this.age = TypeConvertor.castToRange(value); // Range 824 return value; 825 case 3556653: // text 826 this.text = TypeConvertor.castToString(value); // StringType 827 return value; 828 default: return super.setProperty(hash, name, value); 829 } 830 831 } 832 833 @Override 834 public Base setProperty(String name, Base value) throws FHIRException { 835 if (name.equals("low")) { 836 this.low = TypeConvertor.castToQuantity(value); // Quantity 837 } else if (name.equals("high")) { 838 this.high = TypeConvertor.castToQuantity(value); // Quantity 839 } else if (name.equals("normalValue")) { 840 this.normalValue = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 841 } else if (name.equals("type")) { 842 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 843 } else if (name.equals("appliesTo")) { 844 this.getAppliesTo().add(TypeConvertor.castToCodeableConcept(value)); 845 } else if (name.equals("age")) { 846 this.age = TypeConvertor.castToRange(value); // Range 847 } else if (name.equals("text")) { 848 this.text = TypeConvertor.castToString(value); // StringType 849 } else 850 return super.setProperty(name, value); 851 return value; 852 } 853 854 @Override 855 public Base makeProperty(int hash, String name) throws FHIRException { 856 switch (hash) { 857 case 107348: return getLow(); 858 case 3202466: return getHigh(); 859 case -270017334: return getNormalValue(); 860 case 3575610: return getType(); 861 case -2089924569: return addAppliesTo(); 862 case 96511: return getAge(); 863 case 3556653: return getTextElement(); 864 default: return super.makeProperty(hash, name); 865 } 866 867 } 868 869 @Override 870 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 871 switch (hash) { 872 case 107348: /*low*/ return new String[] {"Quantity"}; 873 case 3202466: /*high*/ return new String[] {"Quantity"}; 874 case -270017334: /*normalValue*/ return new String[] {"CodeableConcept"}; 875 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 876 case -2089924569: /*appliesTo*/ return new String[] {"CodeableConcept"}; 877 case 96511: /*age*/ return new String[] {"Range"}; 878 case 3556653: /*text*/ return new String[] {"string"}; 879 default: return super.getTypesForProperty(hash, name); 880 } 881 882 } 883 884 @Override 885 public Base addChild(String name) throws FHIRException { 886 if (name.equals("low")) { 887 this.low = new Quantity(); 888 return this.low; 889 } 890 else if (name.equals("high")) { 891 this.high = new Quantity(); 892 return this.high; 893 } 894 else if (name.equals("normalValue")) { 895 this.normalValue = new CodeableConcept(); 896 return this.normalValue; 897 } 898 else if (name.equals("type")) { 899 this.type = new CodeableConcept(); 900 return this.type; 901 } 902 else if (name.equals("appliesTo")) { 903 return addAppliesTo(); 904 } 905 else if (name.equals("age")) { 906 this.age = new Range(); 907 return this.age; 908 } 909 else if (name.equals("text")) { 910 throw new FHIRException("Cannot call addChild on a primitive type Observation.referenceRange.text"); 911 } 912 else 913 return super.addChild(name); 914 } 915 916 public ObservationReferenceRangeComponent copy() { 917 ObservationReferenceRangeComponent dst = new ObservationReferenceRangeComponent(); 918 copyValues(dst); 919 return dst; 920 } 921 922 public void copyValues(ObservationReferenceRangeComponent dst) { 923 super.copyValues(dst); 924 dst.low = low == null ? null : low.copy(); 925 dst.high = high == null ? null : high.copy(); 926 dst.normalValue = normalValue == null ? null : normalValue.copy(); 927 dst.type = type == null ? null : type.copy(); 928 if (appliesTo != null) { 929 dst.appliesTo = new ArrayList<CodeableConcept>(); 930 for (CodeableConcept i : appliesTo) 931 dst.appliesTo.add(i.copy()); 932 }; 933 dst.age = age == null ? null : age.copy(); 934 dst.text = text == null ? null : text.copy(); 935 } 936 937 @Override 938 public boolean equalsDeep(Base other_) { 939 if (!super.equalsDeep(other_)) 940 return false; 941 if (!(other_ instanceof ObservationReferenceRangeComponent)) 942 return false; 943 ObservationReferenceRangeComponent o = (ObservationReferenceRangeComponent) other_; 944 return compareDeep(low, o.low, true) && compareDeep(high, o.high, true) && compareDeep(normalValue, o.normalValue, true) 945 && compareDeep(type, o.type, true) && compareDeep(appliesTo, o.appliesTo, true) && compareDeep(age, o.age, true) 946 && compareDeep(text, o.text, true); 947 } 948 949 @Override 950 public boolean equalsShallow(Base other_) { 951 if (!super.equalsShallow(other_)) 952 return false; 953 if (!(other_ instanceof ObservationReferenceRangeComponent)) 954 return false; 955 ObservationReferenceRangeComponent o = (ObservationReferenceRangeComponent) other_; 956 return compareValues(text, o.text, true); 957 } 958 959 public boolean isEmpty() { 960 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(low, high, normalValue, type 961 , appliesTo, age, text); 962 } 963 964 public String fhirType() { 965 return "Observation.referenceRange"; 966 967 } 968 969 } 970 971 @Block() 972 public static class ObservationComponentComponent extends BackboneElement implements IBaseBackboneElement { 973 /** 974 * Describes what was observed. Sometimes this is called the observation "code". 975 */ 976 @Child(name = "code", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=true) 977 @Description(shortDefinition="Type of component observation (code / type)", formalDefinition="Describes what was observed. Sometimes this is called the observation \"code\"." ) 978 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-codes") 979 protected CodeableConcept code; 980 981 /** 982 * The information determined as a result of making the observation, if the information has a simple value. 983 */ 984 @Child(name = "value", type = {Quantity.class, CodeableConcept.class, StringType.class, BooleanType.class, IntegerType.class, Range.class, Ratio.class, SampledData.class, TimeType.class, DateTimeType.class, Period.class, Attachment.class}, order=2, min=0, max=1, modifier=false, summary=true) 985 @Description(shortDefinition="Actual component result", formalDefinition="The information determined as a result of making the observation, if the information has a simple value." ) 986 protected DataType value; 987 988 /** 989 * Provides a reason why the expected value in the element Observation.component.value[x] is missing. 990 */ 991 @Child(name = "dataAbsentReason", type = {CodeableConcept.class}, order=3, min=0, max=1, modifier=false, summary=false) 992 @Description(shortDefinition="Why the component result is missing", formalDefinition="Provides a reason why the expected value in the element Observation.component.value[x] is missing." ) 993 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/data-absent-reason") 994 protected CodeableConcept dataAbsentReason; 995 996 /** 997 * A categorical assessment of an observation value. For example, high, low, normal. 998 */ 999 @Child(name = "interpretation", type = {CodeableConcept.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1000 @Description(shortDefinition="High, low, normal, etc.", formalDefinition="A categorical assessment of an observation value. For example, high, low, normal." ) 1001 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-interpretation") 1002 protected List<CodeableConcept> interpretation; 1003 1004 /** 1005 * Guidance on how to interpret the value by comparison to a normal or recommended range. 1006 */ 1007 @Child(name = "referenceRange", type = {ObservationReferenceRangeComponent.class}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1008 @Description(shortDefinition="Provides guide for interpretation of component result", formalDefinition="Guidance on how to interpret the value by comparison to a normal or recommended range." ) 1009 protected List<ObservationReferenceRangeComponent> referenceRange; 1010 1011 private static final long serialVersionUID = -1771757751L; 1012 1013 /** 1014 * Constructor 1015 */ 1016 public ObservationComponentComponent() { 1017 super(); 1018 } 1019 1020 /** 1021 * Constructor 1022 */ 1023 public ObservationComponentComponent(CodeableConcept code) { 1024 super(); 1025 this.setCode(code); 1026 } 1027 1028 /** 1029 * @return {@link #code} (Describes what was observed. Sometimes this is called the observation "code".) 1030 */ 1031 public CodeableConcept getCode() { 1032 if (this.code == null) 1033 if (Configuration.errorOnAutoCreate()) 1034 throw new Error("Attempt to auto-create ObservationComponentComponent.code"); 1035 else if (Configuration.doAutoCreate()) 1036 this.code = new CodeableConcept(); // cc 1037 return this.code; 1038 } 1039 1040 public boolean hasCode() { 1041 return this.code != null && !this.code.isEmpty(); 1042 } 1043 1044 /** 1045 * @param value {@link #code} (Describes what was observed. Sometimes this is called the observation "code".) 1046 */ 1047 public ObservationComponentComponent setCode(CodeableConcept value) { 1048 this.code = value; 1049 return this; 1050 } 1051 1052 /** 1053 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1054 */ 1055 public DataType getValue() { 1056 return this.value; 1057 } 1058 1059 /** 1060 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1061 */ 1062 public Quantity getValueQuantity() throws FHIRException { 1063 if (this.value == null) 1064 this.value = new Quantity(); 1065 if (!(this.value instanceof Quantity)) 1066 throw new FHIRException("Type mismatch: the type Quantity was expected, but "+this.value.getClass().getName()+" was encountered"); 1067 return (Quantity) this.value; 1068 } 1069 1070 public boolean hasValueQuantity() { 1071 return this != null && this.value instanceof Quantity; 1072 } 1073 1074 /** 1075 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1076 */ 1077 public CodeableConcept getValueCodeableConcept() throws FHIRException { 1078 if (this.value == null) 1079 this.value = new CodeableConcept(); 1080 if (!(this.value instanceof CodeableConcept)) 1081 throw new FHIRException("Type mismatch: the type CodeableConcept was expected, but "+this.value.getClass().getName()+" was encountered"); 1082 return (CodeableConcept) this.value; 1083 } 1084 1085 public boolean hasValueCodeableConcept() { 1086 return this != null && this.value instanceof CodeableConcept; 1087 } 1088 1089 /** 1090 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1091 */ 1092 public StringType getValueStringType() throws FHIRException { 1093 if (this.value == null) 1094 this.value = new StringType(); 1095 if (!(this.value instanceof StringType)) 1096 throw new FHIRException("Type mismatch: the type StringType was expected, but "+this.value.getClass().getName()+" was encountered"); 1097 return (StringType) this.value; 1098 } 1099 1100 public boolean hasValueStringType() { 1101 return this != null && this.value instanceof StringType; 1102 } 1103 1104 /** 1105 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1106 */ 1107 public BooleanType getValueBooleanType() throws FHIRException { 1108 if (this.value == null) 1109 this.value = new BooleanType(); 1110 if (!(this.value instanceof BooleanType)) 1111 throw new FHIRException("Type mismatch: the type BooleanType was expected, but "+this.value.getClass().getName()+" was encountered"); 1112 return (BooleanType) this.value; 1113 } 1114 1115 public boolean hasValueBooleanType() { 1116 return this != null && this.value instanceof BooleanType; 1117 } 1118 1119 /** 1120 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1121 */ 1122 public IntegerType getValueIntegerType() throws FHIRException { 1123 if (this.value == null) 1124 this.value = new IntegerType(); 1125 if (!(this.value instanceof IntegerType)) 1126 throw new FHIRException("Type mismatch: the type IntegerType was expected, but "+this.value.getClass().getName()+" was encountered"); 1127 return (IntegerType) this.value; 1128 } 1129 1130 public boolean hasValueIntegerType() { 1131 return this != null && this.value instanceof IntegerType; 1132 } 1133 1134 /** 1135 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1136 */ 1137 public Range getValueRange() throws FHIRException { 1138 if (this.value == null) 1139 this.value = new Range(); 1140 if (!(this.value instanceof Range)) 1141 throw new FHIRException("Type mismatch: the type Range was expected, but "+this.value.getClass().getName()+" was encountered"); 1142 return (Range) this.value; 1143 } 1144 1145 public boolean hasValueRange() { 1146 return this != null && this.value instanceof Range; 1147 } 1148 1149 /** 1150 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1151 */ 1152 public Ratio getValueRatio() throws FHIRException { 1153 if (this.value == null) 1154 this.value = new Ratio(); 1155 if (!(this.value instanceof Ratio)) 1156 throw new FHIRException("Type mismatch: the type Ratio was expected, but "+this.value.getClass().getName()+" was encountered"); 1157 return (Ratio) this.value; 1158 } 1159 1160 public boolean hasValueRatio() { 1161 return this != null && this.value instanceof Ratio; 1162 } 1163 1164 /** 1165 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1166 */ 1167 public SampledData getValueSampledData() throws FHIRException { 1168 if (this.value == null) 1169 this.value = new SampledData(); 1170 if (!(this.value instanceof SampledData)) 1171 throw new FHIRException("Type mismatch: the type SampledData was expected, but "+this.value.getClass().getName()+" was encountered"); 1172 return (SampledData) this.value; 1173 } 1174 1175 public boolean hasValueSampledData() { 1176 return this != null && this.value instanceof SampledData; 1177 } 1178 1179 /** 1180 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1181 */ 1182 public TimeType getValueTimeType() throws FHIRException { 1183 if (this.value == null) 1184 this.value = new TimeType(); 1185 if (!(this.value instanceof TimeType)) 1186 throw new FHIRException("Type mismatch: the type TimeType was expected, but "+this.value.getClass().getName()+" was encountered"); 1187 return (TimeType) this.value; 1188 } 1189 1190 public boolean hasValueTimeType() { 1191 return this != null && this.value instanceof TimeType; 1192 } 1193 1194 /** 1195 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1196 */ 1197 public DateTimeType getValueDateTimeType() throws FHIRException { 1198 if (this.value == null) 1199 this.value = new DateTimeType(); 1200 if (!(this.value instanceof DateTimeType)) 1201 throw new FHIRException("Type mismatch: the type DateTimeType was expected, but "+this.value.getClass().getName()+" was encountered"); 1202 return (DateTimeType) this.value; 1203 } 1204 1205 public boolean hasValueDateTimeType() { 1206 return this != null && this.value instanceof DateTimeType; 1207 } 1208 1209 /** 1210 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1211 */ 1212 public Period getValuePeriod() throws FHIRException { 1213 if (this.value == null) 1214 this.value = new Period(); 1215 if (!(this.value instanceof Period)) 1216 throw new FHIRException("Type mismatch: the type Period was expected, but "+this.value.getClass().getName()+" was encountered"); 1217 return (Period) this.value; 1218 } 1219 1220 public boolean hasValuePeriod() { 1221 return this != null && this.value instanceof Period; 1222 } 1223 1224 /** 1225 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1226 */ 1227 public Attachment getValueAttachment() throws FHIRException { 1228 if (this.value == null) 1229 this.value = new Attachment(); 1230 if (!(this.value instanceof Attachment)) 1231 throw new FHIRException("Type mismatch: the type Attachment was expected, but "+this.value.getClass().getName()+" was encountered"); 1232 return (Attachment) this.value; 1233 } 1234 1235 public boolean hasValueAttachment() { 1236 return this != null && this.value instanceof Attachment; 1237 } 1238 1239 public boolean hasValue() { 1240 return this.value != null && !this.value.isEmpty(); 1241 } 1242 1243 /** 1244 * @param value {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 1245 */ 1246 public ObservationComponentComponent setValue(DataType value) { 1247 if (value != null && !(value instanceof Quantity || value instanceof CodeableConcept || value instanceof StringType || value instanceof BooleanType || value instanceof IntegerType || value instanceof Range || value instanceof Ratio || value instanceof SampledData || value instanceof TimeType || value instanceof DateTimeType || value instanceof Period || value instanceof Attachment)) 1248 throw new Error("Not the right type for Observation.component.value[x]: "+value.fhirType()); 1249 this.value = value; 1250 return this; 1251 } 1252 1253 /** 1254 * @return {@link #dataAbsentReason} (Provides a reason why the expected value in the element Observation.component.value[x] is missing.) 1255 */ 1256 public CodeableConcept getDataAbsentReason() { 1257 if (this.dataAbsentReason == null) 1258 if (Configuration.errorOnAutoCreate()) 1259 throw new Error("Attempt to auto-create ObservationComponentComponent.dataAbsentReason"); 1260 else if (Configuration.doAutoCreate()) 1261 this.dataAbsentReason = new CodeableConcept(); // cc 1262 return this.dataAbsentReason; 1263 } 1264 1265 public boolean hasDataAbsentReason() { 1266 return this.dataAbsentReason != null && !this.dataAbsentReason.isEmpty(); 1267 } 1268 1269 /** 1270 * @param value {@link #dataAbsentReason} (Provides a reason why the expected value in the element Observation.component.value[x] is missing.) 1271 */ 1272 public ObservationComponentComponent setDataAbsentReason(CodeableConcept value) { 1273 this.dataAbsentReason = value; 1274 return this; 1275 } 1276 1277 /** 1278 * @return {@link #interpretation} (A categorical assessment of an observation value. For example, high, low, normal.) 1279 */ 1280 public List<CodeableConcept> getInterpretation() { 1281 if (this.interpretation == null) 1282 this.interpretation = new ArrayList<CodeableConcept>(); 1283 return this.interpretation; 1284 } 1285 1286 /** 1287 * @return Returns a reference to <code>this</code> for easy method chaining 1288 */ 1289 public ObservationComponentComponent setInterpretation(List<CodeableConcept> theInterpretation) { 1290 this.interpretation = theInterpretation; 1291 return this; 1292 } 1293 1294 public boolean hasInterpretation() { 1295 if (this.interpretation == null) 1296 return false; 1297 for (CodeableConcept item : this.interpretation) 1298 if (!item.isEmpty()) 1299 return true; 1300 return false; 1301 } 1302 1303 public CodeableConcept addInterpretation() { //3 1304 CodeableConcept t = new CodeableConcept(); 1305 if (this.interpretation == null) 1306 this.interpretation = new ArrayList<CodeableConcept>(); 1307 this.interpretation.add(t); 1308 return t; 1309 } 1310 1311 public ObservationComponentComponent addInterpretation(CodeableConcept t) { //3 1312 if (t == null) 1313 return this; 1314 if (this.interpretation == null) 1315 this.interpretation = new ArrayList<CodeableConcept>(); 1316 this.interpretation.add(t); 1317 return this; 1318 } 1319 1320 /** 1321 * @return The first repetition of repeating field {@link #interpretation}, creating it if it does not already exist {3} 1322 */ 1323 public CodeableConcept getInterpretationFirstRep() { 1324 if (getInterpretation().isEmpty()) { 1325 addInterpretation(); 1326 } 1327 return getInterpretation().get(0); 1328 } 1329 1330 /** 1331 * @return {@link #referenceRange} (Guidance on how to interpret the value by comparison to a normal or recommended range.) 1332 */ 1333 public List<ObservationReferenceRangeComponent> getReferenceRange() { 1334 if (this.referenceRange == null) 1335 this.referenceRange = new ArrayList<ObservationReferenceRangeComponent>(); 1336 return this.referenceRange; 1337 } 1338 1339 /** 1340 * @return Returns a reference to <code>this</code> for easy method chaining 1341 */ 1342 public ObservationComponentComponent setReferenceRange(List<ObservationReferenceRangeComponent> theReferenceRange) { 1343 this.referenceRange = theReferenceRange; 1344 return this; 1345 } 1346 1347 public boolean hasReferenceRange() { 1348 if (this.referenceRange == null) 1349 return false; 1350 for (ObservationReferenceRangeComponent item : this.referenceRange) 1351 if (!item.isEmpty()) 1352 return true; 1353 return false; 1354 } 1355 1356 public ObservationReferenceRangeComponent addReferenceRange() { //3 1357 ObservationReferenceRangeComponent t = new ObservationReferenceRangeComponent(); 1358 if (this.referenceRange == null) 1359 this.referenceRange = new ArrayList<ObservationReferenceRangeComponent>(); 1360 this.referenceRange.add(t); 1361 return t; 1362 } 1363 1364 public ObservationComponentComponent addReferenceRange(ObservationReferenceRangeComponent t) { //3 1365 if (t == null) 1366 return this; 1367 if (this.referenceRange == null) 1368 this.referenceRange = new ArrayList<ObservationReferenceRangeComponent>(); 1369 this.referenceRange.add(t); 1370 return this; 1371 } 1372 1373 /** 1374 * @return The first repetition of repeating field {@link #referenceRange}, creating it if it does not already exist {3} 1375 */ 1376 public ObservationReferenceRangeComponent getReferenceRangeFirstRep() { 1377 if (getReferenceRange().isEmpty()) { 1378 addReferenceRange(); 1379 } 1380 return getReferenceRange().get(0); 1381 } 1382 1383 protected void listChildren(List<Property> children) { 1384 super.listChildren(children); 1385 children.add(new Property("code", "CodeableConcept", "Describes what was observed. Sometimes this is called the observation \"code\".", 0, 1, code)); 1386 children.add(new Property("value[x]", "Quantity|CodeableConcept|string|boolean|integer|Range|Ratio|SampledData|time|dateTime|Period|Attachment", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value)); 1387 children.add(new Property("dataAbsentReason", "CodeableConcept", "Provides a reason why the expected value in the element Observation.component.value[x] is missing.", 0, 1, dataAbsentReason)); 1388 children.add(new Property("interpretation", "CodeableConcept", "A categorical assessment of an observation value. For example, high, low, normal.", 0, java.lang.Integer.MAX_VALUE, interpretation)); 1389 children.add(new Property("referenceRange", "@Observation.referenceRange", "Guidance on how to interpret the value by comparison to a normal or recommended range.", 0, java.lang.Integer.MAX_VALUE, referenceRange)); 1390 } 1391 1392 @Override 1393 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1394 switch (_hash) { 1395 case 3059181: /*code*/ return new Property("code", "CodeableConcept", "Describes what was observed. Sometimes this is called the observation \"code\".", 0, 1, code); 1396 case -1410166417: /*value[x]*/ return new Property("value[x]", "Quantity|CodeableConcept|string|boolean|integer|Range|Ratio|SampledData|time|dateTime|Period|Attachment", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1397 case 111972721: /*value*/ return new Property("value[x]", "Quantity|CodeableConcept|string|boolean|integer|Range|Ratio|SampledData|time|dateTime|Period|Attachment", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1398 case -2029823716: /*valueQuantity*/ return new Property("value[x]", "Quantity", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1399 case 924902896: /*valueCodeableConcept*/ return new Property("value[x]", "CodeableConcept", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1400 case -1424603934: /*valueString*/ return new Property("value[x]", "string", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1401 case 733421943: /*valueBoolean*/ return new Property("value[x]", "boolean", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1402 case -1668204915: /*valueInteger*/ return new Property("value[x]", "integer", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1403 case 2030761548: /*valueRange*/ return new Property("value[x]", "Range", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1404 case 2030767386: /*valueRatio*/ return new Property("value[x]", "Ratio", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1405 case -962229101: /*valueSampledData*/ return new Property("value[x]", "SampledData", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1406 case -765708322: /*valueTime*/ return new Property("value[x]", "time", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1407 case 1047929900: /*valueDateTime*/ return new Property("value[x]", "dateTime", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1408 case -1524344174: /*valuePeriod*/ return new Property("value[x]", "Period", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1409 case -475566732: /*valueAttachment*/ return new Property("value[x]", "Attachment", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 1410 case 1034315687: /*dataAbsentReason*/ return new Property("dataAbsentReason", "CodeableConcept", "Provides a reason why the expected value in the element Observation.component.value[x] is missing.", 0, 1, dataAbsentReason); 1411 case -297950712: /*interpretation*/ return new Property("interpretation", "CodeableConcept", "A categorical assessment of an observation value. For example, high, low, normal.", 0, java.lang.Integer.MAX_VALUE, interpretation); 1412 case -1912545102: /*referenceRange*/ return new Property("referenceRange", "@Observation.referenceRange", "Guidance on how to interpret the value by comparison to a normal or recommended range.", 0, java.lang.Integer.MAX_VALUE, referenceRange); 1413 default: return super.getNamedProperty(_hash, _name, _checkValid); 1414 } 1415 1416 } 1417 1418 @Override 1419 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1420 switch (hash) { 1421 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 1422 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // DataType 1423 case 1034315687: /*dataAbsentReason*/ return this.dataAbsentReason == null ? new Base[0] : new Base[] {this.dataAbsentReason}; // CodeableConcept 1424 case -297950712: /*interpretation*/ return this.interpretation == null ? new Base[0] : this.interpretation.toArray(new Base[this.interpretation.size()]); // CodeableConcept 1425 case -1912545102: /*referenceRange*/ return this.referenceRange == null ? new Base[0] : this.referenceRange.toArray(new Base[this.referenceRange.size()]); // ObservationReferenceRangeComponent 1426 default: return super.getProperty(hash, name, checkValid); 1427 } 1428 1429 } 1430 1431 @Override 1432 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1433 switch (hash) { 1434 case 3059181: // code 1435 this.code = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1436 return value; 1437 case 111972721: // value 1438 this.value = TypeConvertor.castToType(value); // DataType 1439 return value; 1440 case 1034315687: // dataAbsentReason 1441 this.dataAbsentReason = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1442 return value; 1443 case -297950712: // interpretation 1444 this.getInterpretation().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 1445 return value; 1446 case -1912545102: // referenceRange 1447 this.getReferenceRange().add((ObservationReferenceRangeComponent) value); // ObservationReferenceRangeComponent 1448 return value; 1449 default: return super.setProperty(hash, name, value); 1450 } 1451 1452 } 1453 1454 @Override 1455 public Base setProperty(String name, Base value) throws FHIRException { 1456 if (name.equals("code")) { 1457 this.code = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1458 } else if (name.equals("value[x]")) { 1459 this.value = TypeConvertor.castToType(value); // DataType 1460 } else if (name.equals("dataAbsentReason")) { 1461 this.dataAbsentReason = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1462 } else if (name.equals("interpretation")) { 1463 this.getInterpretation().add(TypeConvertor.castToCodeableConcept(value)); 1464 } else if (name.equals("referenceRange")) { 1465 this.getReferenceRange().add((ObservationReferenceRangeComponent) value); 1466 } else 1467 return super.setProperty(name, value); 1468 return value; 1469 } 1470 1471 @Override 1472 public Base makeProperty(int hash, String name) throws FHIRException { 1473 switch (hash) { 1474 case 3059181: return getCode(); 1475 case -1410166417: return getValue(); 1476 case 111972721: return getValue(); 1477 case 1034315687: return getDataAbsentReason(); 1478 case -297950712: return addInterpretation(); 1479 case -1912545102: return addReferenceRange(); 1480 default: return super.makeProperty(hash, name); 1481 } 1482 1483 } 1484 1485 @Override 1486 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1487 switch (hash) { 1488 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 1489 case 111972721: /*value*/ return new String[] {"Quantity", "CodeableConcept", "string", "boolean", "integer", "Range", "Ratio", "SampledData", "time", "dateTime", "Period", "Attachment"}; 1490 case 1034315687: /*dataAbsentReason*/ return new String[] {"CodeableConcept"}; 1491 case -297950712: /*interpretation*/ return new String[] {"CodeableConcept"}; 1492 case -1912545102: /*referenceRange*/ return new String[] {"@Observation.referenceRange"}; 1493 default: return super.getTypesForProperty(hash, name); 1494 } 1495 1496 } 1497 1498 @Override 1499 public Base addChild(String name) throws FHIRException { 1500 if (name.equals("code")) { 1501 this.code = new CodeableConcept(); 1502 return this.code; 1503 } 1504 else if (name.equals("valueQuantity")) { 1505 this.value = new Quantity(); 1506 return this.value; 1507 } 1508 else if (name.equals("valueCodeableConcept")) { 1509 this.value = new CodeableConcept(); 1510 return this.value; 1511 } 1512 else if (name.equals("valueString")) { 1513 this.value = new StringType(); 1514 return this.value; 1515 } 1516 else if (name.equals("valueBoolean")) { 1517 this.value = new BooleanType(); 1518 return this.value; 1519 } 1520 else if (name.equals("valueInteger")) { 1521 this.value = new IntegerType(); 1522 return this.value; 1523 } 1524 else if (name.equals("valueRange")) { 1525 this.value = new Range(); 1526 return this.value; 1527 } 1528 else if (name.equals("valueRatio")) { 1529 this.value = new Ratio(); 1530 return this.value; 1531 } 1532 else if (name.equals("valueSampledData")) { 1533 this.value = new SampledData(); 1534 return this.value; 1535 } 1536 else if (name.equals("valueTime")) { 1537 this.value = new TimeType(); 1538 return this.value; 1539 } 1540 else if (name.equals("valueDateTime")) { 1541 this.value = new DateTimeType(); 1542 return this.value; 1543 } 1544 else if (name.equals("valuePeriod")) { 1545 this.value = new Period(); 1546 return this.value; 1547 } 1548 else if (name.equals("valueAttachment")) { 1549 this.value = new Attachment(); 1550 return this.value; 1551 } 1552 else if (name.equals("dataAbsentReason")) { 1553 this.dataAbsentReason = new CodeableConcept(); 1554 return this.dataAbsentReason; 1555 } 1556 else if (name.equals("interpretation")) { 1557 return addInterpretation(); 1558 } 1559 else if (name.equals("referenceRange")) { 1560 return addReferenceRange(); 1561 } 1562 else 1563 return super.addChild(name); 1564 } 1565 1566 public ObservationComponentComponent copy() { 1567 ObservationComponentComponent dst = new ObservationComponentComponent(); 1568 copyValues(dst); 1569 return dst; 1570 } 1571 1572 public void copyValues(ObservationComponentComponent dst) { 1573 super.copyValues(dst); 1574 dst.code = code == null ? null : code.copy(); 1575 dst.value = value == null ? null : value.copy(); 1576 dst.dataAbsentReason = dataAbsentReason == null ? null : dataAbsentReason.copy(); 1577 if (interpretation != null) { 1578 dst.interpretation = new ArrayList<CodeableConcept>(); 1579 for (CodeableConcept i : interpretation) 1580 dst.interpretation.add(i.copy()); 1581 }; 1582 if (referenceRange != null) { 1583 dst.referenceRange = new ArrayList<ObservationReferenceRangeComponent>(); 1584 for (ObservationReferenceRangeComponent i : referenceRange) 1585 dst.referenceRange.add(i.copy()); 1586 }; 1587 } 1588 1589 @Override 1590 public boolean equalsDeep(Base other_) { 1591 if (!super.equalsDeep(other_)) 1592 return false; 1593 if (!(other_ instanceof ObservationComponentComponent)) 1594 return false; 1595 ObservationComponentComponent o = (ObservationComponentComponent) other_; 1596 return compareDeep(code, o.code, true) && compareDeep(value, o.value, true) && compareDeep(dataAbsentReason, o.dataAbsentReason, true) 1597 && compareDeep(interpretation, o.interpretation, true) && compareDeep(referenceRange, o.referenceRange, true) 1598 ; 1599 } 1600 1601 @Override 1602 public boolean equalsShallow(Base other_) { 1603 if (!super.equalsShallow(other_)) 1604 return false; 1605 if (!(other_ instanceof ObservationComponentComponent)) 1606 return false; 1607 ObservationComponentComponent o = (ObservationComponentComponent) other_; 1608 return true; 1609 } 1610 1611 public boolean isEmpty() { 1612 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, value, dataAbsentReason 1613 , interpretation, referenceRange); 1614 } 1615 1616 public String fhirType() { 1617 return "Observation.component"; 1618 1619 } 1620 1621 } 1622 1623 /** 1624 * A unique identifier assigned to this observation. 1625 */ 1626 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1627 @Description(shortDefinition="Business Identifier for observation", formalDefinition="A unique identifier assigned to this observation." ) 1628 protected List<Identifier> identifier; 1629 1630 /** 1631 * The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance. 1632 */ 1633 @Child(name = "instantiates", type = {CanonicalType.class, ObservationDefinition.class}, order=1, min=0, max=1, modifier=false, summary=true) 1634 @Description(shortDefinition="Instantiates FHIR ObservationDefinition", formalDefinition="The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance." ) 1635 protected DataType instantiates; 1636 1637 /** 1638 * A plan, proposal or order that is fulfilled in whole or in part by this event. For example, a MedicationRequest may require a patient to have laboratory test performed before it is dispensed. 1639 */ 1640 @Child(name = "basedOn", type = {CarePlan.class, DeviceRequest.class, ImmunizationRecommendation.class, MedicationRequest.class, NutritionOrder.class, ServiceRequest.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1641 @Description(shortDefinition="Fulfills plan, proposal or order", formalDefinition="A plan, proposal or order that is fulfilled in whole or in part by this event. For example, a MedicationRequest may require a patient to have laboratory test performed before it is dispensed." ) 1642 protected List<Reference> basedOn; 1643 1644 /** 1645 * Identifies the observation(s) that triggered the performance of this observation. 1646 */ 1647 @Child(name = "triggeredBy", type = {}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1648 @Description(shortDefinition="Triggering observation(s)", formalDefinition="Identifies the observation(s) that triggered the performance of this observation." ) 1649 protected List<ObservationTriggeredByComponent> triggeredBy; 1650 1651 /** 1652 * A larger event of which this particular Observation is a component or step. For example, an observation as part of a procedure. 1653 */ 1654 @Child(name = "partOf", type = {MedicationAdministration.class, MedicationDispense.class, MedicationUsage.class, Procedure.class, Immunization.class, ImagingStudy.class, GenomicStudy.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1655 @Description(shortDefinition="Part of referenced event", formalDefinition="A larger event of which this particular Observation is a component or step. For example, an observation as part of a procedure." ) 1656 protected List<Reference> partOf; 1657 1658 /** 1659 * The status of the result value. 1660 */ 1661 @Child(name = "status", type = {CodeType.class}, order=5, min=1, max=1, modifier=true, summary=true) 1662 @Description(shortDefinition="registered | preliminary | final | amended +", formalDefinition="The status of the result value." ) 1663 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-status") 1664 protected Enumeration<ObservationStatus> status; 1665 1666 /** 1667 * A code that classifies the general type of observation being made. 1668 */ 1669 @Child(name = "category", type = {CodeableConcept.class}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1670 @Description(shortDefinition="Classification of type of observation", formalDefinition="A code that classifies the general type of observation being made." ) 1671 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-category") 1672 protected List<CodeableConcept> category; 1673 1674 /** 1675 * Describes what was observed. Sometimes this is called the observation "name". 1676 */ 1677 @Child(name = "code", type = {CodeableConcept.class}, order=7, min=1, max=1, modifier=false, summary=true) 1678 @Description(shortDefinition="Type of observation (code / type)", formalDefinition="Describes what was observed. Sometimes this is called the observation \"name\"." ) 1679 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-codes") 1680 protected CodeableConcept code; 1681 1682 /** 1683 * The patient, or group of patients, location, device, organization, procedure or practitioner this observation is about and into whose or what record the observation is placed. If the actual focus of the observation is different from the subject (or a sample of, part, or region of the subject), the `focus` element or the `code` itself specifies the actual focus of the observation. 1684 */ 1685 @Child(name = "subject", type = {Patient.class, Group.class, Device.class, Location.class, Organization.class, Procedure.class, Practitioner.class, Medication.class, Substance.class, BiologicallyDerivedProduct.class, NutritionProduct.class}, order=8, min=0, max=1, modifier=false, summary=true) 1686 @Description(shortDefinition="Who and/or what the observation is about", formalDefinition="The patient, or group of patients, location, device, organization, procedure or practitioner this observation is about and into whose or what record the observation is placed. If the actual focus of the observation is different from the subject (or a sample of, part, or region of the subject), the `focus` element or the `code` itself specifies the actual focus of the observation." ) 1687 protected Reference subject; 1688 1689 /** 1690 * The actual focus of an observation when it is not the patient of record representing something or someone associated with the patient such as a spouse, parent, fetus, or donor. For example, fetus observations in a mother's record. The focus of an observation could also be an existing condition, an intervention, the subject's diet, another observation of the subject, or a body structure such as tumor or implanted device. An example use case would be using the Observation resource to capture whether the mother is trained to change her child's tracheostomy tube. In this example, the child is the patient of record and the mother is the focus. 1691 */ 1692 @Child(name = "focus", type = {Reference.class}, order=9, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1693 @Description(shortDefinition="What the observation is about, when it is not about the subject of record", formalDefinition="The actual focus of an observation when it is not the patient of record representing something or someone associated with the patient such as a spouse, parent, fetus, or donor. For example, fetus observations in a mother's record. The focus of an observation could also be an existing condition, an intervention, the subject's diet, another observation of the subject, or a body structure such as tumor or implanted device. An example use case would be using the Observation resource to capture whether the mother is trained to change her child's tracheostomy tube. In this example, the child is the patient of record and the mother is the focus." ) 1694 protected List<Reference> focus; 1695 1696 /** 1697 * The healthcare event (e.g. a patient and healthcare provider interaction) during which this observation is made. 1698 */ 1699 @Child(name = "encounter", type = {Encounter.class}, order=10, min=0, max=1, modifier=false, summary=true) 1700 @Description(shortDefinition="Healthcare event during which this observation is made", formalDefinition="The healthcare event (e.g. a patient and healthcare provider interaction) during which this observation is made." ) 1701 protected Reference encounter; 1702 1703 /** 1704 * The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the "physiologically relevant time". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself. 1705 */ 1706 @Child(name = "effective", type = {DateTimeType.class, Period.class, Timing.class, InstantType.class}, order=11, min=0, max=1, modifier=false, summary=true) 1707 @Description(shortDefinition="Clinically relevant time/time-period for observation", formalDefinition="The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the \"physiologically relevant time\". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself." ) 1708 protected DataType effective; 1709 1710 /** 1711 * The date and time this version of the observation was made available to providers, typically after the results have been reviewed and verified. 1712 */ 1713 @Child(name = "issued", type = {InstantType.class}, order=12, min=0, max=1, modifier=false, summary=true) 1714 @Description(shortDefinition="Date/Time this version was made available", formalDefinition="The date and time this version of the observation was made available to providers, typically after the results have been reviewed and verified." ) 1715 protected InstantType issued; 1716 1717 /** 1718 * Who was responsible for asserting the observed value as "true". 1719 */ 1720 @Child(name = "performer", type = {Practitioner.class, PractitionerRole.class, Organization.class, CareTeam.class, Patient.class, RelatedPerson.class}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1721 @Description(shortDefinition="Who is responsible for the observation", formalDefinition="Who was responsible for asserting the observed value as \"true\"." ) 1722 protected List<Reference> performer; 1723 1724 /** 1725 * The information determined as a result of making the observation, if the information has a simple value. 1726 */ 1727 @Child(name = "value", type = {Quantity.class, CodeableConcept.class, StringType.class, BooleanType.class, IntegerType.class, Range.class, Ratio.class, SampledData.class, TimeType.class, DateTimeType.class, Period.class, Attachment.class}, order=14, min=0, max=1, modifier=false, summary=true) 1728 @Description(shortDefinition="Actual result", formalDefinition="The information determined as a result of making the observation, if the information has a simple value." ) 1729 protected DataType value; 1730 1731 /** 1732 * Provides a reason why the expected value in the element Observation.value[x] is missing. 1733 */ 1734 @Child(name = "dataAbsentReason", type = {CodeableConcept.class}, order=15, min=0, max=1, modifier=false, summary=false) 1735 @Description(shortDefinition="Why the result is missing", formalDefinition="Provides a reason why the expected value in the element Observation.value[x] is missing." ) 1736 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/data-absent-reason") 1737 protected CodeableConcept dataAbsentReason; 1738 1739 /** 1740 * A categorical assessment of an observation value. For example, high, low, normal. 1741 */ 1742 @Child(name = "interpretation", type = {CodeableConcept.class}, order=16, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1743 @Description(shortDefinition="High, low, normal, etc.", formalDefinition="A categorical assessment of an observation value. For example, high, low, normal." ) 1744 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-interpretation") 1745 protected List<CodeableConcept> interpretation; 1746 1747 /** 1748 * Comments about the observation or the results. 1749 */ 1750 @Child(name = "note", type = {Annotation.class}, order=17, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1751 @Description(shortDefinition="Comments about the observation", formalDefinition="Comments about the observation or the results." ) 1752 protected List<Annotation> note; 1753 1754 /** 1755 * Indicates the site on the subject's body where the observation was made (i.e. the target site). 1756 */ 1757 @Child(name = "bodySite", type = {CodeableConcept.class}, order=18, min=0, max=1, modifier=false, summary=false) 1758 @Description(shortDefinition="Observed body part", formalDefinition="Indicates the site on the subject's body where the observation was made (i.e. the target site)." ) 1759 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/body-site") 1760 protected CodeableConcept bodySite; 1761 1762 /** 1763 * Indicates the body structure on the subject's body where the observation was made (i.e. the target site). 1764 */ 1765 @Child(name = "bodyStructure", type = {BodyStructure.class}, order=19, min=0, max=1, modifier=false, summary=false) 1766 @Description(shortDefinition="Observed body structure", formalDefinition="Indicates the body structure on the subject's body where the observation was made (i.e. the target site)." ) 1767 protected Reference bodyStructure; 1768 1769 /** 1770 * Indicates the mechanism used to perform the observation. 1771 */ 1772 @Child(name = "method", type = {CodeableConcept.class}, order=20, min=0, max=1, modifier=false, summary=false) 1773 @Description(shortDefinition="How it was done", formalDefinition="Indicates the mechanism used to perform the observation." ) 1774 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/observation-methods") 1775 protected CodeableConcept method; 1776 1777 /** 1778 * The specimen that was used when this observation was made. 1779 */ 1780 @Child(name = "specimen", type = {Specimen.class, Group.class}, order=21, min=0, max=1, modifier=false, summary=false) 1781 @Description(shortDefinition="Specimen used for this observation", formalDefinition="The specimen that was used when this observation was made." ) 1782 protected Reference specimen; 1783 1784 /** 1785 * The device used to generate the observation data. 1786 */ 1787 @Child(name = "device", type = {Device.class, DeviceMetric.class}, order=22, min=0, max=1, modifier=false, summary=false) 1788 @Description(shortDefinition="(Measurement) Device", formalDefinition="The device used to generate the observation data." ) 1789 protected Reference device; 1790 1791 /** 1792 * Guidance on how to interpret the value by comparison to a normal or recommended range. Multiple reference ranges are interpreted as an "OR". In other words, to represent two distinct target populations, two `referenceRange` elements would be used. 1793 */ 1794 @Child(name = "referenceRange", type = {}, order=23, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1795 @Description(shortDefinition="Provides guide for interpretation", formalDefinition="Guidance on how to interpret the value by comparison to a normal or recommended range. Multiple reference ranges are interpreted as an \"OR\". In other words, to represent two distinct target populations, two `referenceRange` elements would be used." ) 1796 protected List<ObservationReferenceRangeComponent> referenceRange; 1797 1798 /** 1799 * This observation is 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. 1800 */ 1801 @Child(name = "hasMember", type = {Observation.class, QuestionnaireResponse.class, MolecularSequence.class}, order=24, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1802 @Description(shortDefinition="Related resource that belongs to the Observation group", formalDefinition="This observation is 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." ) 1803 protected List<Reference> hasMember; 1804 1805 /** 1806 * The target resource that represents a measurement from which this observation value is derived. For example, a calculated anion gap or a fetal measurement based on an ultrasound image. 1807 */ 1808 @Child(name = "derivedFrom", type = {DocumentReference.class, ImagingStudy.class, ImagingSelection.class, QuestionnaireResponse.class, Observation.class, MolecularSequence.class, GenomicStudy.class}, order=25, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1809 @Description(shortDefinition="Related resource from which the observation is made", formalDefinition="The target resource that represents a measurement from which this observation value is derived. For example, a calculated anion gap or a fetal measurement based on an ultrasound image." ) 1810 protected List<Reference> derivedFrom; 1811 1812 /** 1813 * Some observations have multiple component observations. These component observations are expressed as separate code value pairs that share the same attributes. Examples include systolic and diastolic component observations for blood pressure measurement and multiple component observations for genetics observations. 1814 */ 1815 @Child(name = "component", type = {}, order=26, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1816 @Description(shortDefinition="Component results", formalDefinition="Some observations have multiple component observations. These component observations are expressed as separate code value pairs that share the same attributes. Examples include systolic and diastolic component observations for blood pressure measurement and multiple component observations for genetics observations." ) 1817 protected List<ObservationComponentComponent> component; 1818 1819 private static final long serialVersionUID = -44103660L; 1820 1821 /** 1822 * Constructor 1823 */ 1824 public Observation() { 1825 super(); 1826 } 1827 1828 /** 1829 * Constructor 1830 */ 1831 public Observation(ObservationStatus status, CodeableConcept code) { 1832 super(); 1833 this.setStatus(status); 1834 this.setCode(code); 1835 } 1836 1837 /** 1838 * @return {@link #identifier} (A unique identifier assigned to this observation.) 1839 */ 1840 public List<Identifier> getIdentifier() { 1841 if (this.identifier == null) 1842 this.identifier = new ArrayList<Identifier>(); 1843 return this.identifier; 1844 } 1845 1846 /** 1847 * @return Returns a reference to <code>this</code> for easy method chaining 1848 */ 1849 public Observation setIdentifier(List<Identifier> theIdentifier) { 1850 this.identifier = theIdentifier; 1851 return this; 1852 } 1853 1854 public boolean hasIdentifier() { 1855 if (this.identifier == null) 1856 return false; 1857 for (Identifier item : this.identifier) 1858 if (!item.isEmpty()) 1859 return true; 1860 return false; 1861 } 1862 1863 public Identifier addIdentifier() { //3 1864 Identifier t = new Identifier(); 1865 if (this.identifier == null) 1866 this.identifier = new ArrayList<Identifier>(); 1867 this.identifier.add(t); 1868 return t; 1869 } 1870 1871 public Observation addIdentifier(Identifier t) { //3 1872 if (t == null) 1873 return this; 1874 if (this.identifier == null) 1875 this.identifier = new ArrayList<Identifier>(); 1876 this.identifier.add(t); 1877 return this; 1878 } 1879 1880 /** 1881 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist {3} 1882 */ 1883 public Identifier getIdentifierFirstRep() { 1884 if (getIdentifier().isEmpty()) { 1885 addIdentifier(); 1886 } 1887 return getIdentifier().get(0); 1888 } 1889 1890 /** 1891 * @return {@link #instantiates} (The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance.) 1892 */ 1893 public DataType getInstantiates() { 1894 return this.instantiates; 1895 } 1896 1897 /** 1898 * @return {@link #instantiates} (The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance.) 1899 */ 1900 public CanonicalType getInstantiatesCanonicalType() throws FHIRException { 1901 if (this.instantiates == null) 1902 this.instantiates = new CanonicalType(); 1903 if (!(this.instantiates instanceof CanonicalType)) 1904 throw new FHIRException("Type mismatch: the type CanonicalType was expected, but "+this.instantiates.getClass().getName()+" was encountered"); 1905 return (CanonicalType) this.instantiates; 1906 } 1907 1908 public boolean hasInstantiatesCanonicalType() { 1909 return this != null && this.instantiates instanceof CanonicalType; 1910 } 1911 1912 /** 1913 * @return {@link #instantiates} (The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance.) 1914 */ 1915 public Reference getInstantiatesReference() throws FHIRException { 1916 if (this.instantiates == null) 1917 this.instantiates = new Reference(); 1918 if (!(this.instantiates instanceof Reference)) 1919 throw new FHIRException("Type mismatch: the type Reference was expected, but "+this.instantiates.getClass().getName()+" was encountered"); 1920 return (Reference) this.instantiates; 1921 } 1922 1923 public boolean hasInstantiatesReference() { 1924 return this != null && this.instantiates instanceof Reference; 1925 } 1926 1927 public boolean hasInstantiates() { 1928 return this.instantiates != null && !this.instantiates.isEmpty(); 1929 } 1930 1931 /** 1932 * @param value {@link #instantiates} (The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance.) 1933 */ 1934 public Observation setInstantiates(DataType value) { 1935 if (value != null && !(value instanceof CanonicalType || value instanceof Reference)) 1936 throw new Error("Not the right type for Observation.instantiates[x]: "+value.fhirType()); 1937 this.instantiates = value; 1938 return this; 1939 } 1940 1941 /** 1942 * @return {@link #basedOn} (A plan, proposal or order that is fulfilled in whole or in part by this event. For example, a MedicationRequest may require a patient to have laboratory test performed before it is dispensed.) 1943 */ 1944 public List<Reference> getBasedOn() { 1945 if (this.basedOn == null) 1946 this.basedOn = new ArrayList<Reference>(); 1947 return this.basedOn; 1948 } 1949 1950 /** 1951 * @return Returns a reference to <code>this</code> for easy method chaining 1952 */ 1953 public Observation setBasedOn(List<Reference> theBasedOn) { 1954 this.basedOn = theBasedOn; 1955 return this; 1956 } 1957 1958 public boolean hasBasedOn() { 1959 if (this.basedOn == null) 1960 return false; 1961 for (Reference item : this.basedOn) 1962 if (!item.isEmpty()) 1963 return true; 1964 return false; 1965 } 1966 1967 public Reference addBasedOn() { //3 1968 Reference t = new Reference(); 1969 if (this.basedOn == null) 1970 this.basedOn = new ArrayList<Reference>(); 1971 this.basedOn.add(t); 1972 return t; 1973 } 1974 1975 public Observation addBasedOn(Reference t) { //3 1976 if (t == null) 1977 return this; 1978 if (this.basedOn == null) 1979 this.basedOn = new ArrayList<Reference>(); 1980 this.basedOn.add(t); 1981 return this; 1982 } 1983 1984 /** 1985 * @return The first repetition of repeating field {@link #basedOn}, creating it if it does not already exist {3} 1986 */ 1987 public Reference getBasedOnFirstRep() { 1988 if (getBasedOn().isEmpty()) { 1989 addBasedOn(); 1990 } 1991 return getBasedOn().get(0); 1992 } 1993 1994 /** 1995 * @return {@link #triggeredBy} (Identifies the observation(s) that triggered the performance of this observation.) 1996 */ 1997 public List<ObservationTriggeredByComponent> getTriggeredBy() { 1998 if (this.triggeredBy == null) 1999 this.triggeredBy = new ArrayList<ObservationTriggeredByComponent>(); 2000 return this.triggeredBy; 2001 } 2002 2003 /** 2004 * @return Returns a reference to <code>this</code> for easy method chaining 2005 */ 2006 public Observation setTriggeredBy(List<ObservationTriggeredByComponent> theTriggeredBy) { 2007 this.triggeredBy = theTriggeredBy; 2008 return this; 2009 } 2010 2011 public boolean hasTriggeredBy() { 2012 if (this.triggeredBy == null) 2013 return false; 2014 for (ObservationTriggeredByComponent item : this.triggeredBy) 2015 if (!item.isEmpty()) 2016 return true; 2017 return false; 2018 } 2019 2020 public ObservationTriggeredByComponent addTriggeredBy() { //3 2021 ObservationTriggeredByComponent t = new ObservationTriggeredByComponent(); 2022 if (this.triggeredBy == null) 2023 this.triggeredBy = new ArrayList<ObservationTriggeredByComponent>(); 2024 this.triggeredBy.add(t); 2025 return t; 2026 } 2027 2028 public Observation addTriggeredBy(ObservationTriggeredByComponent t) { //3 2029 if (t == null) 2030 return this; 2031 if (this.triggeredBy == null) 2032 this.triggeredBy = new ArrayList<ObservationTriggeredByComponent>(); 2033 this.triggeredBy.add(t); 2034 return this; 2035 } 2036 2037 /** 2038 * @return The first repetition of repeating field {@link #triggeredBy}, creating it if it does not already exist {3} 2039 */ 2040 public ObservationTriggeredByComponent getTriggeredByFirstRep() { 2041 if (getTriggeredBy().isEmpty()) { 2042 addTriggeredBy(); 2043 } 2044 return getTriggeredBy().get(0); 2045 } 2046 2047 /** 2048 * @return {@link #partOf} (A larger event of which this particular Observation is a component or step. For example, an observation as part of a procedure.) 2049 */ 2050 public List<Reference> getPartOf() { 2051 if (this.partOf == null) 2052 this.partOf = new ArrayList<Reference>(); 2053 return this.partOf; 2054 } 2055 2056 /** 2057 * @return Returns a reference to <code>this</code> for easy method chaining 2058 */ 2059 public Observation setPartOf(List<Reference> thePartOf) { 2060 this.partOf = thePartOf; 2061 return this; 2062 } 2063 2064 public boolean hasPartOf() { 2065 if (this.partOf == null) 2066 return false; 2067 for (Reference item : this.partOf) 2068 if (!item.isEmpty()) 2069 return true; 2070 return false; 2071 } 2072 2073 public Reference addPartOf() { //3 2074 Reference t = new Reference(); 2075 if (this.partOf == null) 2076 this.partOf = new ArrayList<Reference>(); 2077 this.partOf.add(t); 2078 return t; 2079 } 2080 2081 public Observation addPartOf(Reference t) { //3 2082 if (t == null) 2083 return this; 2084 if (this.partOf == null) 2085 this.partOf = new ArrayList<Reference>(); 2086 this.partOf.add(t); 2087 return this; 2088 } 2089 2090 /** 2091 * @return The first repetition of repeating field {@link #partOf}, creating it if it does not already exist {3} 2092 */ 2093 public Reference getPartOfFirstRep() { 2094 if (getPartOf().isEmpty()) { 2095 addPartOf(); 2096 } 2097 return getPartOf().get(0); 2098 } 2099 2100 /** 2101 * @return {@link #status} (The status of the result value.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 2102 */ 2103 public Enumeration<ObservationStatus> getStatusElement() { 2104 if (this.status == null) 2105 if (Configuration.errorOnAutoCreate()) 2106 throw new Error("Attempt to auto-create Observation.status"); 2107 else if (Configuration.doAutoCreate()) 2108 this.status = new Enumeration<ObservationStatus>(new ObservationStatusEnumFactory()); // bb 2109 return this.status; 2110 } 2111 2112 public boolean hasStatusElement() { 2113 return this.status != null && !this.status.isEmpty(); 2114 } 2115 2116 public boolean hasStatus() { 2117 return this.status != null && !this.status.isEmpty(); 2118 } 2119 2120 /** 2121 * @param value {@link #status} (The status of the result value.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 2122 */ 2123 public Observation setStatusElement(Enumeration<ObservationStatus> value) { 2124 this.status = value; 2125 return this; 2126 } 2127 2128 /** 2129 * @return The status of the result value. 2130 */ 2131 public ObservationStatus getStatus() { 2132 return this.status == null ? null : this.status.getValue(); 2133 } 2134 2135 /** 2136 * @param value The status of the result value. 2137 */ 2138 public Observation setStatus(ObservationStatus value) { 2139 if (this.status == null) 2140 this.status = new Enumeration<ObservationStatus>(new ObservationStatusEnumFactory()); 2141 this.status.setValue(value); 2142 return this; 2143 } 2144 2145 /** 2146 * @return {@link #category} (A code that classifies the general type of observation being made.) 2147 */ 2148 public List<CodeableConcept> getCategory() { 2149 if (this.category == null) 2150 this.category = new ArrayList<CodeableConcept>(); 2151 return this.category; 2152 } 2153 2154 /** 2155 * @return Returns a reference to <code>this</code> for easy method chaining 2156 */ 2157 public Observation setCategory(List<CodeableConcept> theCategory) { 2158 this.category = theCategory; 2159 return this; 2160 } 2161 2162 public boolean hasCategory() { 2163 if (this.category == null) 2164 return false; 2165 for (CodeableConcept item : this.category) 2166 if (!item.isEmpty()) 2167 return true; 2168 return false; 2169 } 2170 2171 public CodeableConcept addCategory() { //3 2172 CodeableConcept t = new CodeableConcept(); 2173 if (this.category == null) 2174 this.category = new ArrayList<CodeableConcept>(); 2175 this.category.add(t); 2176 return t; 2177 } 2178 2179 public Observation addCategory(CodeableConcept t) { //3 2180 if (t == null) 2181 return this; 2182 if (this.category == null) 2183 this.category = new ArrayList<CodeableConcept>(); 2184 this.category.add(t); 2185 return this; 2186 } 2187 2188 /** 2189 * @return The first repetition of repeating field {@link #category}, creating it if it does not already exist {3} 2190 */ 2191 public CodeableConcept getCategoryFirstRep() { 2192 if (getCategory().isEmpty()) { 2193 addCategory(); 2194 } 2195 return getCategory().get(0); 2196 } 2197 2198 /** 2199 * @return {@link #code} (Describes what was observed. Sometimes this is called the observation "name".) 2200 */ 2201 public CodeableConcept getCode() { 2202 if (this.code == null) 2203 if (Configuration.errorOnAutoCreate()) 2204 throw new Error("Attempt to auto-create Observation.code"); 2205 else if (Configuration.doAutoCreate()) 2206 this.code = new CodeableConcept(); // cc 2207 return this.code; 2208 } 2209 2210 public boolean hasCode() { 2211 return this.code != null && !this.code.isEmpty(); 2212 } 2213 2214 /** 2215 * @param value {@link #code} (Describes what was observed. Sometimes this is called the observation "name".) 2216 */ 2217 public Observation setCode(CodeableConcept value) { 2218 this.code = value; 2219 return this; 2220 } 2221 2222 /** 2223 * @return {@link #subject} (The patient, or group of patients, location, device, organization, procedure or practitioner this observation is about and into whose or what record the observation is placed. If the actual focus of the observation is different from the subject (or a sample of, part, or region of the subject), the `focus` element or the `code` itself specifies the actual focus of the observation.) 2224 */ 2225 public Reference getSubject() { 2226 if (this.subject == null) 2227 if (Configuration.errorOnAutoCreate()) 2228 throw new Error("Attempt to auto-create Observation.subject"); 2229 else if (Configuration.doAutoCreate()) 2230 this.subject = new Reference(); // cc 2231 return this.subject; 2232 } 2233 2234 public boolean hasSubject() { 2235 return this.subject != null && !this.subject.isEmpty(); 2236 } 2237 2238 /** 2239 * @param value {@link #subject} (The patient, or group of patients, location, device, organization, procedure or practitioner this observation is about and into whose or what record the observation is placed. If the actual focus of the observation is different from the subject (or a sample of, part, or region of the subject), the `focus` element or the `code` itself specifies the actual focus of the observation.) 2240 */ 2241 public Observation setSubject(Reference value) { 2242 this.subject = value; 2243 return this; 2244 } 2245 2246 /** 2247 * @return {@link #focus} (The actual focus of an observation when it is not the patient of record representing something or someone associated with the patient such as a spouse, parent, fetus, or donor. For example, fetus observations in a mother's record. The focus of an observation could also be an existing condition, an intervention, the subject's diet, another observation of the subject, or a body structure such as tumor or implanted device. An example use case would be using the Observation resource to capture whether the mother is trained to change her child's tracheostomy tube. In this example, the child is the patient of record and the mother is the focus.) 2248 */ 2249 public List<Reference> getFocus() { 2250 if (this.focus == null) 2251 this.focus = new ArrayList<Reference>(); 2252 return this.focus; 2253 } 2254 2255 /** 2256 * @return Returns a reference to <code>this</code> for easy method chaining 2257 */ 2258 public Observation setFocus(List<Reference> theFocus) { 2259 this.focus = theFocus; 2260 return this; 2261 } 2262 2263 public boolean hasFocus() { 2264 if (this.focus == null) 2265 return false; 2266 for (Reference item : this.focus) 2267 if (!item.isEmpty()) 2268 return true; 2269 return false; 2270 } 2271 2272 public Reference addFocus() { //3 2273 Reference t = new Reference(); 2274 if (this.focus == null) 2275 this.focus = new ArrayList<Reference>(); 2276 this.focus.add(t); 2277 return t; 2278 } 2279 2280 public Observation addFocus(Reference t) { //3 2281 if (t == null) 2282 return this; 2283 if (this.focus == null) 2284 this.focus = new ArrayList<Reference>(); 2285 this.focus.add(t); 2286 return this; 2287 } 2288 2289 /** 2290 * @return The first repetition of repeating field {@link #focus}, creating it if it does not already exist {3} 2291 */ 2292 public Reference getFocusFirstRep() { 2293 if (getFocus().isEmpty()) { 2294 addFocus(); 2295 } 2296 return getFocus().get(0); 2297 } 2298 2299 /** 2300 * @return {@link #encounter} (The healthcare event (e.g. a patient and healthcare provider interaction) during which this observation is made.) 2301 */ 2302 public Reference getEncounter() { 2303 if (this.encounter == null) 2304 if (Configuration.errorOnAutoCreate()) 2305 throw new Error("Attempt to auto-create Observation.encounter"); 2306 else if (Configuration.doAutoCreate()) 2307 this.encounter = new Reference(); // cc 2308 return this.encounter; 2309 } 2310 2311 public boolean hasEncounter() { 2312 return this.encounter != null && !this.encounter.isEmpty(); 2313 } 2314 2315 /** 2316 * @param value {@link #encounter} (The healthcare event (e.g. a patient and healthcare provider interaction) during which this observation is made.) 2317 */ 2318 public Observation setEncounter(Reference value) { 2319 this.encounter = value; 2320 return this; 2321 } 2322 2323 /** 2324 * @return {@link #effective} (The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the "physiologically relevant time". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.) 2325 */ 2326 public DataType getEffective() { 2327 return this.effective; 2328 } 2329 2330 /** 2331 * @return {@link #effective} (The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the "physiologically relevant time". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.) 2332 */ 2333 public DateTimeType getEffectiveDateTimeType() throws FHIRException { 2334 if (this.effective == null) 2335 this.effective = new DateTimeType(); 2336 if (!(this.effective instanceof DateTimeType)) 2337 throw new FHIRException("Type mismatch: the type DateTimeType was expected, but "+this.effective.getClass().getName()+" was encountered"); 2338 return (DateTimeType) this.effective; 2339 } 2340 2341 public boolean hasEffectiveDateTimeType() { 2342 return this != null && this.effective instanceof DateTimeType; 2343 } 2344 2345 /** 2346 * @return {@link #effective} (The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the "physiologically relevant time". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.) 2347 */ 2348 public Period getEffectivePeriod() throws FHIRException { 2349 if (this.effective == null) 2350 this.effective = new Period(); 2351 if (!(this.effective instanceof Period)) 2352 throw new FHIRException("Type mismatch: the type Period was expected, but "+this.effective.getClass().getName()+" was encountered"); 2353 return (Period) this.effective; 2354 } 2355 2356 public boolean hasEffectivePeriod() { 2357 return this != null && this.effective instanceof Period; 2358 } 2359 2360 /** 2361 * @return {@link #effective} (The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the "physiologically relevant time". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.) 2362 */ 2363 public Timing getEffectiveTiming() throws FHIRException { 2364 if (this.effective == null) 2365 this.effective = new Timing(); 2366 if (!(this.effective instanceof Timing)) 2367 throw new FHIRException("Type mismatch: the type Timing was expected, but "+this.effective.getClass().getName()+" was encountered"); 2368 return (Timing) this.effective; 2369 } 2370 2371 public boolean hasEffectiveTiming() { 2372 return this != null && this.effective instanceof Timing; 2373 } 2374 2375 /** 2376 * @return {@link #effective} (The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the "physiologically relevant time". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.) 2377 */ 2378 public InstantType getEffectiveInstantType() throws FHIRException { 2379 if (this.effective == null) 2380 this.effective = new InstantType(); 2381 if (!(this.effective instanceof InstantType)) 2382 throw new FHIRException("Type mismatch: the type InstantType was expected, but "+this.effective.getClass().getName()+" was encountered"); 2383 return (InstantType) this.effective; 2384 } 2385 2386 public boolean hasEffectiveInstantType() { 2387 return this != null && this.effective instanceof InstantType; 2388 } 2389 2390 public boolean hasEffective() { 2391 return this.effective != null && !this.effective.isEmpty(); 2392 } 2393 2394 /** 2395 * @param value {@link #effective} (The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the "physiologically relevant time". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.) 2396 */ 2397 public Observation setEffective(DataType value) { 2398 if (value != null && !(value instanceof DateTimeType || value instanceof Period || value instanceof Timing || value instanceof InstantType)) 2399 throw new Error("Not the right type for Observation.effective[x]: "+value.fhirType()); 2400 this.effective = value; 2401 return this; 2402 } 2403 2404 /** 2405 * @return {@link #issued} (The date and time this version of the observation was made available to providers, typically after the results have been reviewed and verified.). This is the underlying object with id, value and extensions. The accessor "getIssued" gives direct access to the value 2406 */ 2407 public InstantType getIssuedElement() { 2408 if (this.issued == null) 2409 if (Configuration.errorOnAutoCreate()) 2410 throw new Error("Attempt to auto-create Observation.issued"); 2411 else if (Configuration.doAutoCreate()) 2412 this.issued = new InstantType(); // bb 2413 return this.issued; 2414 } 2415 2416 public boolean hasIssuedElement() { 2417 return this.issued != null && !this.issued.isEmpty(); 2418 } 2419 2420 public boolean hasIssued() { 2421 return this.issued != null && !this.issued.isEmpty(); 2422 } 2423 2424 /** 2425 * @param value {@link #issued} (The date and time this version of the observation was made available to providers, typically after the results have been reviewed and verified.). This is the underlying object with id, value and extensions. The accessor "getIssued" gives direct access to the value 2426 */ 2427 public Observation setIssuedElement(InstantType value) { 2428 this.issued = value; 2429 return this; 2430 } 2431 2432 /** 2433 * @return The date and time this version of the observation was made available to providers, typically after the results have been reviewed and verified. 2434 */ 2435 public Date getIssued() { 2436 return this.issued == null ? null : this.issued.getValue(); 2437 } 2438 2439 /** 2440 * @param value The date and time this version of the observation was made available to providers, typically after the results have been reviewed and verified. 2441 */ 2442 public Observation setIssued(Date value) { 2443 if (value == null) 2444 this.issued = null; 2445 else { 2446 if (this.issued == null) 2447 this.issued = new InstantType(); 2448 this.issued.setValue(value); 2449 } 2450 return this; 2451 } 2452 2453 /** 2454 * @return {@link #performer} (Who was responsible for asserting the observed value as "true".) 2455 */ 2456 public List<Reference> getPerformer() { 2457 if (this.performer == null) 2458 this.performer = new ArrayList<Reference>(); 2459 return this.performer; 2460 } 2461 2462 /** 2463 * @return Returns a reference to <code>this</code> for easy method chaining 2464 */ 2465 public Observation setPerformer(List<Reference> thePerformer) { 2466 this.performer = thePerformer; 2467 return this; 2468 } 2469 2470 public boolean hasPerformer() { 2471 if (this.performer == null) 2472 return false; 2473 for (Reference item : this.performer) 2474 if (!item.isEmpty()) 2475 return true; 2476 return false; 2477 } 2478 2479 public Reference addPerformer() { //3 2480 Reference t = new Reference(); 2481 if (this.performer == null) 2482 this.performer = new ArrayList<Reference>(); 2483 this.performer.add(t); 2484 return t; 2485 } 2486 2487 public Observation addPerformer(Reference t) { //3 2488 if (t == null) 2489 return this; 2490 if (this.performer == null) 2491 this.performer = new ArrayList<Reference>(); 2492 this.performer.add(t); 2493 return this; 2494 } 2495 2496 /** 2497 * @return The first repetition of repeating field {@link #performer}, creating it if it does not already exist {3} 2498 */ 2499 public Reference getPerformerFirstRep() { 2500 if (getPerformer().isEmpty()) { 2501 addPerformer(); 2502 } 2503 return getPerformer().get(0); 2504 } 2505 2506 /** 2507 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2508 */ 2509 public DataType getValue() { 2510 return this.value; 2511 } 2512 2513 /** 2514 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2515 */ 2516 public Quantity getValueQuantity() throws FHIRException { 2517 if (this.value == null) 2518 this.value = new Quantity(); 2519 if (!(this.value instanceof Quantity)) 2520 throw new FHIRException("Type mismatch: the type Quantity was expected, but "+this.value.getClass().getName()+" was encountered"); 2521 return (Quantity) this.value; 2522 } 2523 2524 public boolean hasValueQuantity() { 2525 return this != null && this.value instanceof Quantity; 2526 } 2527 2528 /** 2529 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2530 */ 2531 public CodeableConcept getValueCodeableConcept() throws FHIRException { 2532 if (this.value == null) 2533 this.value = new CodeableConcept(); 2534 if (!(this.value instanceof CodeableConcept)) 2535 throw new FHIRException("Type mismatch: the type CodeableConcept was expected, but "+this.value.getClass().getName()+" was encountered"); 2536 return (CodeableConcept) this.value; 2537 } 2538 2539 public boolean hasValueCodeableConcept() { 2540 return this != null && this.value instanceof CodeableConcept; 2541 } 2542 2543 /** 2544 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2545 */ 2546 public StringType getValueStringType() throws FHIRException { 2547 if (this.value == null) 2548 this.value = new StringType(); 2549 if (!(this.value instanceof StringType)) 2550 throw new FHIRException("Type mismatch: the type StringType was expected, but "+this.value.getClass().getName()+" was encountered"); 2551 return (StringType) this.value; 2552 } 2553 2554 public boolean hasValueStringType() { 2555 return this != null && this.value instanceof StringType; 2556 } 2557 2558 /** 2559 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2560 */ 2561 public BooleanType getValueBooleanType() throws FHIRException { 2562 if (this.value == null) 2563 this.value = new BooleanType(); 2564 if (!(this.value instanceof BooleanType)) 2565 throw new FHIRException("Type mismatch: the type BooleanType was expected, but "+this.value.getClass().getName()+" was encountered"); 2566 return (BooleanType) this.value; 2567 } 2568 2569 public boolean hasValueBooleanType() { 2570 return this != null && this.value instanceof BooleanType; 2571 } 2572 2573 /** 2574 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2575 */ 2576 public IntegerType getValueIntegerType() throws FHIRException { 2577 if (this.value == null) 2578 this.value = new IntegerType(); 2579 if (!(this.value instanceof IntegerType)) 2580 throw new FHIRException("Type mismatch: the type IntegerType was expected, but "+this.value.getClass().getName()+" was encountered"); 2581 return (IntegerType) this.value; 2582 } 2583 2584 public boolean hasValueIntegerType() { 2585 return this != null && this.value instanceof IntegerType; 2586 } 2587 2588 /** 2589 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2590 */ 2591 public Range getValueRange() throws FHIRException { 2592 if (this.value == null) 2593 this.value = new Range(); 2594 if (!(this.value instanceof Range)) 2595 throw new FHIRException("Type mismatch: the type Range was expected, but "+this.value.getClass().getName()+" was encountered"); 2596 return (Range) this.value; 2597 } 2598 2599 public boolean hasValueRange() { 2600 return this != null && this.value instanceof Range; 2601 } 2602 2603 /** 2604 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2605 */ 2606 public Ratio getValueRatio() throws FHIRException { 2607 if (this.value == null) 2608 this.value = new Ratio(); 2609 if (!(this.value instanceof Ratio)) 2610 throw new FHIRException("Type mismatch: the type Ratio was expected, but "+this.value.getClass().getName()+" was encountered"); 2611 return (Ratio) this.value; 2612 } 2613 2614 public boolean hasValueRatio() { 2615 return this != null && this.value instanceof Ratio; 2616 } 2617 2618 /** 2619 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2620 */ 2621 public SampledData getValueSampledData() throws FHIRException { 2622 if (this.value == null) 2623 this.value = new SampledData(); 2624 if (!(this.value instanceof SampledData)) 2625 throw new FHIRException("Type mismatch: the type SampledData was expected, but "+this.value.getClass().getName()+" was encountered"); 2626 return (SampledData) this.value; 2627 } 2628 2629 public boolean hasValueSampledData() { 2630 return this != null && this.value instanceof SampledData; 2631 } 2632 2633 /** 2634 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2635 */ 2636 public TimeType getValueTimeType() throws FHIRException { 2637 if (this.value == null) 2638 this.value = new TimeType(); 2639 if (!(this.value instanceof TimeType)) 2640 throw new FHIRException("Type mismatch: the type TimeType was expected, but "+this.value.getClass().getName()+" was encountered"); 2641 return (TimeType) this.value; 2642 } 2643 2644 public boolean hasValueTimeType() { 2645 return this != null && this.value instanceof TimeType; 2646 } 2647 2648 /** 2649 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2650 */ 2651 public DateTimeType getValueDateTimeType() throws FHIRException { 2652 if (this.value == null) 2653 this.value = new DateTimeType(); 2654 if (!(this.value instanceof DateTimeType)) 2655 throw new FHIRException("Type mismatch: the type DateTimeType was expected, but "+this.value.getClass().getName()+" was encountered"); 2656 return (DateTimeType) this.value; 2657 } 2658 2659 public boolean hasValueDateTimeType() { 2660 return this != null && this.value instanceof DateTimeType; 2661 } 2662 2663 /** 2664 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2665 */ 2666 public Period getValuePeriod() throws FHIRException { 2667 if (this.value == null) 2668 this.value = new Period(); 2669 if (!(this.value instanceof Period)) 2670 throw new FHIRException("Type mismatch: the type Period was expected, but "+this.value.getClass().getName()+" was encountered"); 2671 return (Period) this.value; 2672 } 2673 2674 public boolean hasValuePeriod() { 2675 return this != null && this.value instanceof Period; 2676 } 2677 2678 /** 2679 * @return {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2680 */ 2681 public Attachment getValueAttachment() throws FHIRException { 2682 if (this.value == null) 2683 this.value = new Attachment(); 2684 if (!(this.value instanceof Attachment)) 2685 throw new FHIRException("Type mismatch: the type Attachment was expected, but "+this.value.getClass().getName()+" was encountered"); 2686 return (Attachment) this.value; 2687 } 2688 2689 public boolean hasValueAttachment() { 2690 return this != null && this.value instanceof Attachment; 2691 } 2692 2693 public boolean hasValue() { 2694 return this.value != null && !this.value.isEmpty(); 2695 } 2696 2697 /** 2698 * @param value {@link #value} (The information determined as a result of making the observation, if the information has a simple value.) 2699 */ 2700 public Observation setValue(DataType value) { 2701 if (value != null && !(value instanceof Quantity || value instanceof CodeableConcept || value instanceof StringType || value instanceof BooleanType || value instanceof IntegerType || value instanceof Range || value instanceof Ratio || value instanceof SampledData || value instanceof TimeType || value instanceof DateTimeType || value instanceof Period || value instanceof Attachment)) 2702 throw new Error("Not the right type for Observation.value[x]: "+value.fhirType()); 2703 this.value = value; 2704 return this; 2705 } 2706 2707 /** 2708 * @return {@link #dataAbsentReason} (Provides a reason why the expected value in the element Observation.value[x] is missing.) 2709 */ 2710 public CodeableConcept getDataAbsentReason() { 2711 if (this.dataAbsentReason == null) 2712 if (Configuration.errorOnAutoCreate()) 2713 throw new Error("Attempt to auto-create Observation.dataAbsentReason"); 2714 else if (Configuration.doAutoCreate()) 2715 this.dataAbsentReason = new CodeableConcept(); // cc 2716 return this.dataAbsentReason; 2717 } 2718 2719 public boolean hasDataAbsentReason() { 2720 return this.dataAbsentReason != null && !this.dataAbsentReason.isEmpty(); 2721 } 2722 2723 /** 2724 * @param value {@link #dataAbsentReason} (Provides a reason why the expected value in the element Observation.value[x] is missing.) 2725 */ 2726 public Observation setDataAbsentReason(CodeableConcept value) { 2727 this.dataAbsentReason = value; 2728 return this; 2729 } 2730 2731 /** 2732 * @return {@link #interpretation} (A categorical assessment of an observation value. For example, high, low, normal.) 2733 */ 2734 public List<CodeableConcept> getInterpretation() { 2735 if (this.interpretation == null) 2736 this.interpretation = new ArrayList<CodeableConcept>(); 2737 return this.interpretation; 2738 } 2739 2740 /** 2741 * @return Returns a reference to <code>this</code> for easy method chaining 2742 */ 2743 public Observation setInterpretation(List<CodeableConcept> theInterpretation) { 2744 this.interpretation = theInterpretation; 2745 return this; 2746 } 2747 2748 public boolean hasInterpretation() { 2749 if (this.interpretation == null) 2750 return false; 2751 for (CodeableConcept item : this.interpretation) 2752 if (!item.isEmpty()) 2753 return true; 2754 return false; 2755 } 2756 2757 public CodeableConcept addInterpretation() { //3 2758 CodeableConcept t = new CodeableConcept(); 2759 if (this.interpretation == null) 2760 this.interpretation = new ArrayList<CodeableConcept>(); 2761 this.interpretation.add(t); 2762 return t; 2763 } 2764 2765 public Observation addInterpretation(CodeableConcept t) { //3 2766 if (t == null) 2767 return this; 2768 if (this.interpretation == null) 2769 this.interpretation = new ArrayList<CodeableConcept>(); 2770 this.interpretation.add(t); 2771 return this; 2772 } 2773 2774 /** 2775 * @return The first repetition of repeating field {@link #interpretation}, creating it if it does not already exist {3} 2776 */ 2777 public CodeableConcept getInterpretationFirstRep() { 2778 if (getInterpretation().isEmpty()) { 2779 addInterpretation(); 2780 } 2781 return getInterpretation().get(0); 2782 } 2783 2784 /** 2785 * @return {@link #note} (Comments about the observation or the results.) 2786 */ 2787 public List<Annotation> getNote() { 2788 if (this.note == null) 2789 this.note = new ArrayList<Annotation>(); 2790 return this.note; 2791 } 2792 2793 /** 2794 * @return Returns a reference to <code>this</code> for easy method chaining 2795 */ 2796 public Observation setNote(List<Annotation> theNote) { 2797 this.note = theNote; 2798 return this; 2799 } 2800 2801 public boolean hasNote() { 2802 if (this.note == null) 2803 return false; 2804 for (Annotation item : this.note) 2805 if (!item.isEmpty()) 2806 return true; 2807 return false; 2808 } 2809 2810 public Annotation addNote() { //3 2811 Annotation t = new Annotation(); 2812 if (this.note == null) 2813 this.note = new ArrayList<Annotation>(); 2814 this.note.add(t); 2815 return t; 2816 } 2817 2818 public Observation addNote(Annotation t) { //3 2819 if (t == null) 2820 return this; 2821 if (this.note == null) 2822 this.note = new ArrayList<Annotation>(); 2823 this.note.add(t); 2824 return this; 2825 } 2826 2827 /** 2828 * @return The first repetition of repeating field {@link #note}, creating it if it does not already exist {3} 2829 */ 2830 public Annotation getNoteFirstRep() { 2831 if (getNote().isEmpty()) { 2832 addNote(); 2833 } 2834 return getNote().get(0); 2835 } 2836 2837 /** 2838 * @return {@link #bodySite} (Indicates the site on the subject's body where the observation was made (i.e. the target site).) 2839 */ 2840 public CodeableConcept getBodySite() { 2841 if (this.bodySite == null) 2842 if (Configuration.errorOnAutoCreate()) 2843 throw new Error("Attempt to auto-create Observation.bodySite"); 2844 else if (Configuration.doAutoCreate()) 2845 this.bodySite = new CodeableConcept(); // cc 2846 return this.bodySite; 2847 } 2848 2849 public boolean hasBodySite() { 2850 return this.bodySite != null && !this.bodySite.isEmpty(); 2851 } 2852 2853 /** 2854 * @param value {@link #bodySite} (Indicates the site on the subject's body where the observation was made (i.e. the target site).) 2855 */ 2856 public Observation setBodySite(CodeableConcept value) { 2857 this.bodySite = value; 2858 return this; 2859 } 2860 2861 /** 2862 * @return {@link #bodyStructure} (Indicates the body structure on the subject's body where the observation was made (i.e. the target site).) 2863 */ 2864 public Reference getBodyStructure() { 2865 if (this.bodyStructure == null) 2866 if (Configuration.errorOnAutoCreate()) 2867 throw new Error("Attempt to auto-create Observation.bodyStructure"); 2868 else if (Configuration.doAutoCreate()) 2869 this.bodyStructure = new Reference(); // cc 2870 return this.bodyStructure; 2871 } 2872 2873 public boolean hasBodyStructure() { 2874 return this.bodyStructure != null && !this.bodyStructure.isEmpty(); 2875 } 2876 2877 /** 2878 * @param value {@link #bodyStructure} (Indicates the body structure on the subject's body where the observation was made (i.e. the target site).) 2879 */ 2880 public Observation setBodyStructure(Reference value) { 2881 this.bodyStructure = value; 2882 return this; 2883 } 2884 2885 /** 2886 * @return {@link #method} (Indicates the mechanism used to perform the observation.) 2887 */ 2888 public CodeableConcept getMethod() { 2889 if (this.method == null) 2890 if (Configuration.errorOnAutoCreate()) 2891 throw new Error("Attempt to auto-create Observation.method"); 2892 else if (Configuration.doAutoCreate()) 2893 this.method = new CodeableConcept(); // cc 2894 return this.method; 2895 } 2896 2897 public boolean hasMethod() { 2898 return this.method != null && !this.method.isEmpty(); 2899 } 2900 2901 /** 2902 * @param value {@link #method} (Indicates the mechanism used to perform the observation.) 2903 */ 2904 public Observation setMethod(CodeableConcept value) { 2905 this.method = value; 2906 return this; 2907 } 2908 2909 /** 2910 * @return {@link #specimen} (The specimen that was used when this observation was made.) 2911 */ 2912 public Reference getSpecimen() { 2913 if (this.specimen == null) 2914 if (Configuration.errorOnAutoCreate()) 2915 throw new Error("Attempt to auto-create Observation.specimen"); 2916 else if (Configuration.doAutoCreate()) 2917 this.specimen = new Reference(); // cc 2918 return this.specimen; 2919 } 2920 2921 public boolean hasSpecimen() { 2922 return this.specimen != null && !this.specimen.isEmpty(); 2923 } 2924 2925 /** 2926 * @param value {@link #specimen} (The specimen that was used when this observation was made.) 2927 */ 2928 public Observation setSpecimen(Reference value) { 2929 this.specimen = value; 2930 return this; 2931 } 2932 2933 /** 2934 * @return {@link #device} (The device used to generate the observation data.) 2935 */ 2936 public Reference getDevice() { 2937 if (this.device == null) 2938 if (Configuration.errorOnAutoCreate()) 2939 throw new Error("Attempt to auto-create Observation.device"); 2940 else if (Configuration.doAutoCreate()) 2941 this.device = new Reference(); // cc 2942 return this.device; 2943 } 2944 2945 public boolean hasDevice() { 2946 return this.device != null && !this.device.isEmpty(); 2947 } 2948 2949 /** 2950 * @param value {@link #device} (The device used to generate the observation data.) 2951 */ 2952 public Observation setDevice(Reference value) { 2953 this.device = value; 2954 return this; 2955 } 2956 2957 /** 2958 * @return {@link #referenceRange} (Guidance on how to interpret the value by comparison to a normal or recommended range. Multiple reference ranges are interpreted as an "OR". In other words, to represent two distinct target populations, two `referenceRange` elements would be used.) 2959 */ 2960 public List<ObservationReferenceRangeComponent> getReferenceRange() { 2961 if (this.referenceRange == null) 2962 this.referenceRange = new ArrayList<ObservationReferenceRangeComponent>(); 2963 return this.referenceRange; 2964 } 2965 2966 /** 2967 * @return Returns a reference to <code>this</code> for easy method chaining 2968 */ 2969 public Observation setReferenceRange(List<ObservationReferenceRangeComponent> theReferenceRange) { 2970 this.referenceRange = theReferenceRange; 2971 return this; 2972 } 2973 2974 public boolean hasReferenceRange() { 2975 if (this.referenceRange == null) 2976 return false; 2977 for (ObservationReferenceRangeComponent item : this.referenceRange) 2978 if (!item.isEmpty()) 2979 return true; 2980 return false; 2981 } 2982 2983 public ObservationReferenceRangeComponent addReferenceRange() { //3 2984 ObservationReferenceRangeComponent t = new ObservationReferenceRangeComponent(); 2985 if (this.referenceRange == null) 2986 this.referenceRange = new ArrayList<ObservationReferenceRangeComponent>(); 2987 this.referenceRange.add(t); 2988 return t; 2989 } 2990 2991 public Observation addReferenceRange(ObservationReferenceRangeComponent t) { //3 2992 if (t == null) 2993 return this; 2994 if (this.referenceRange == null) 2995 this.referenceRange = new ArrayList<ObservationReferenceRangeComponent>(); 2996 this.referenceRange.add(t); 2997 return this; 2998 } 2999 3000 /** 3001 * @return The first repetition of repeating field {@link #referenceRange}, creating it if it does not already exist {3} 3002 */ 3003 public ObservationReferenceRangeComponent getReferenceRangeFirstRep() { 3004 if (getReferenceRange().isEmpty()) { 3005 addReferenceRange(); 3006 } 3007 return getReferenceRange().get(0); 3008 } 3009 3010 /** 3011 * @return {@link #hasMember} (This observation is 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.) 3012 */ 3013 public List<Reference> getHasMember() { 3014 if (this.hasMember == null) 3015 this.hasMember = new ArrayList<Reference>(); 3016 return this.hasMember; 3017 } 3018 3019 /** 3020 * @return Returns a reference to <code>this</code> for easy method chaining 3021 */ 3022 public Observation setHasMember(List<Reference> theHasMember) { 3023 this.hasMember = theHasMember; 3024 return this; 3025 } 3026 3027 public boolean hasHasMember() { 3028 if (this.hasMember == null) 3029 return false; 3030 for (Reference item : this.hasMember) 3031 if (!item.isEmpty()) 3032 return true; 3033 return false; 3034 } 3035 3036 public Reference addHasMember() { //3 3037 Reference t = new Reference(); 3038 if (this.hasMember == null) 3039 this.hasMember = new ArrayList<Reference>(); 3040 this.hasMember.add(t); 3041 return t; 3042 } 3043 3044 public Observation addHasMember(Reference t) { //3 3045 if (t == null) 3046 return this; 3047 if (this.hasMember == null) 3048 this.hasMember = new ArrayList<Reference>(); 3049 this.hasMember.add(t); 3050 return this; 3051 } 3052 3053 /** 3054 * @return The first repetition of repeating field {@link #hasMember}, creating it if it does not already exist {3} 3055 */ 3056 public Reference getHasMemberFirstRep() { 3057 if (getHasMember().isEmpty()) { 3058 addHasMember(); 3059 } 3060 return getHasMember().get(0); 3061 } 3062 3063 /** 3064 * @return {@link #derivedFrom} (The target resource that represents a measurement from which this observation value is derived. For example, a calculated anion gap or a fetal measurement based on an ultrasound image.) 3065 */ 3066 public List<Reference> getDerivedFrom() { 3067 if (this.derivedFrom == null) 3068 this.derivedFrom = new ArrayList<Reference>(); 3069 return this.derivedFrom; 3070 } 3071 3072 /** 3073 * @return Returns a reference to <code>this</code> for easy method chaining 3074 */ 3075 public Observation setDerivedFrom(List<Reference> theDerivedFrom) { 3076 this.derivedFrom = theDerivedFrom; 3077 return this; 3078 } 3079 3080 public boolean hasDerivedFrom() { 3081 if (this.derivedFrom == null) 3082 return false; 3083 for (Reference item : this.derivedFrom) 3084 if (!item.isEmpty()) 3085 return true; 3086 return false; 3087 } 3088 3089 public Reference addDerivedFrom() { //3 3090 Reference t = new Reference(); 3091 if (this.derivedFrom == null) 3092 this.derivedFrom = new ArrayList<Reference>(); 3093 this.derivedFrom.add(t); 3094 return t; 3095 } 3096 3097 public Observation addDerivedFrom(Reference t) { //3 3098 if (t == null) 3099 return this; 3100 if (this.derivedFrom == null) 3101 this.derivedFrom = new ArrayList<Reference>(); 3102 this.derivedFrom.add(t); 3103 return this; 3104 } 3105 3106 /** 3107 * @return The first repetition of repeating field {@link #derivedFrom}, creating it if it does not already exist {3} 3108 */ 3109 public Reference getDerivedFromFirstRep() { 3110 if (getDerivedFrom().isEmpty()) { 3111 addDerivedFrom(); 3112 } 3113 return getDerivedFrom().get(0); 3114 } 3115 3116 /** 3117 * @return {@link #component} (Some observations have multiple component observations. These component observations are expressed as separate code value pairs that share the same attributes. Examples include systolic and diastolic component observations for blood pressure measurement and multiple component observations for genetics observations.) 3118 */ 3119 public List<ObservationComponentComponent> getComponent() { 3120 if (this.component == null) 3121 this.component = new ArrayList<ObservationComponentComponent>(); 3122 return this.component; 3123 } 3124 3125 /** 3126 * @return Returns a reference to <code>this</code> for easy method chaining 3127 */ 3128 public Observation setComponent(List<ObservationComponentComponent> theComponent) { 3129 this.component = theComponent; 3130 return this; 3131 } 3132 3133 public boolean hasComponent() { 3134 if (this.component == null) 3135 return false; 3136 for (ObservationComponentComponent item : this.component) 3137 if (!item.isEmpty()) 3138 return true; 3139 return false; 3140 } 3141 3142 public ObservationComponentComponent addComponent() { //3 3143 ObservationComponentComponent t = new ObservationComponentComponent(); 3144 if (this.component == null) 3145 this.component = new ArrayList<ObservationComponentComponent>(); 3146 this.component.add(t); 3147 return t; 3148 } 3149 3150 public Observation addComponent(ObservationComponentComponent t) { //3 3151 if (t == null) 3152 return this; 3153 if (this.component == null) 3154 this.component = new ArrayList<ObservationComponentComponent>(); 3155 this.component.add(t); 3156 return this; 3157 } 3158 3159 /** 3160 * @return The first repetition of repeating field {@link #component}, creating it if it does not already exist {3} 3161 */ 3162 public ObservationComponentComponent getComponentFirstRep() { 3163 if (getComponent().isEmpty()) { 3164 addComponent(); 3165 } 3166 return getComponent().get(0); 3167 } 3168 3169 protected void listChildren(List<Property> children) { 3170 super.listChildren(children); 3171 children.add(new Property("identifier", "Identifier", "A unique identifier assigned to this observation.", 0, java.lang.Integer.MAX_VALUE, identifier)); 3172 children.add(new Property("instantiates[x]", "canonical(ObservationDefinition)|Reference(ObservationDefinition)", "The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance.", 0, 1, instantiates)); 3173 children.add(new Property("basedOn", "Reference(CarePlan|DeviceRequest|ImmunizationRecommendation|MedicationRequest|NutritionOrder|ServiceRequest)", "A plan, proposal or order that is fulfilled in whole or in part by this event. For example, a MedicationRequest may require a patient to have laboratory test performed before it is dispensed.", 0, java.lang.Integer.MAX_VALUE, basedOn)); 3174 children.add(new Property("triggeredBy", "", "Identifies the observation(s) that triggered the performance of this observation.", 0, java.lang.Integer.MAX_VALUE, triggeredBy)); 3175 children.add(new Property("partOf", "Reference(MedicationAdministration|MedicationDispense|MedicationUsage|Procedure|Immunization|ImagingStudy|GenomicStudy)", "A larger event of which this particular Observation is a component or step. For example, an observation as part of a procedure.", 0, java.lang.Integer.MAX_VALUE, partOf)); 3176 children.add(new Property("status", "code", "The status of the result value.", 0, 1, status)); 3177 children.add(new Property("category", "CodeableConcept", "A code that classifies the general type of observation being made.", 0, java.lang.Integer.MAX_VALUE, category)); 3178 children.add(new Property("code", "CodeableConcept", "Describes what was observed. Sometimes this is called the observation \"name\".", 0, 1, code)); 3179 children.add(new Property("subject", "Reference(Patient|Group|Device|Location|Organization|Procedure|Practitioner|Medication|Substance|BiologicallyDerivedProduct|NutritionProduct)", "The patient, or group of patients, location, device, organization, procedure or practitioner this observation is about and into whose or what record the observation is placed. If the actual focus of the observation is different from the subject (or a sample of, part, or region of the subject), the `focus` element or the `code` itself specifies the actual focus of the observation.", 0, 1, subject)); 3180 children.add(new Property("focus", "Reference(Any)", "The actual focus of an observation when it is not the patient of record representing something or someone associated with the patient such as a spouse, parent, fetus, or donor. For example, fetus observations in a mother's record. The focus of an observation could also be an existing condition, an intervention, the subject's diet, another observation of the subject, or a body structure such as tumor or implanted device. An example use case would be using the Observation resource to capture whether the mother is trained to change her child's tracheostomy tube. In this example, the child is the patient of record and the mother is the focus.", 0, java.lang.Integer.MAX_VALUE, focus)); 3181 children.add(new Property("encounter", "Reference(Encounter)", "The healthcare event (e.g. a patient and healthcare provider interaction) during which this observation is made.", 0, 1, encounter)); 3182 children.add(new Property("effective[x]", "dateTime|Period|Timing|instant", "The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the \"physiologically relevant time\". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective)); 3183 children.add(new Property("issued", "instant", "The date and time this version of the observation was made available to providers, typically after the results have been reviewed and verified.", 0, 1, issued)); 3184 children.add(new Property("performer", "Reference(Practitioner|PractitionerRole|Organization|CareTeam|Patient|RelatedPerson)", "Who was responsible for asserting the observed value as \"true\".", 0, java.lang.Integer.MAX_VALUE, performer)); 3185 children.add(new Property("value[x]", "Quantity|CodeableConcept|string|boolean|integer|Range|Ratio|SampledData|time|dateTime|Period|Attachment", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value)); 3186 children.add(new Property("dataAbsentReason", "CodeableConcept", "Provides a reason why the expected value in the element Observation.value[x] is missing.", 0, 1, dataAbsentReason)); 3187 children.add(new Property("interpretation", "CodeableConcept", "A categorical assessment of an observation value. For example, high, low, normal.", 0, java.lang.Integer.MAX_VALUE, interpretation)); 3188 children.add(new Property("note", "Annotation", "Comments about the observation or the results.", 0, java.lang.Integer.MAX_VALUE, note)); 3189 children.add(new Property("bodySite", "CodeableConcept", "Indicates the site on the subject's body where the observation was made (i.e. the target site).", 0, 1, bodySite)); 3190 children.add(new Property("bodyStructure", "Reference(BodyStructure)", "Indicates the body structure on the subject's body where the observation was made (i.e. the target site).", 0, 1, bodyStructure)); 3191 children.add(new Property("method", "CodeableConcept", "Indicates the mechanism used to perform the observation.", 0, 1, method)); 3192 children.add(new Property("specimen", "Reference(Specimen|Group)", "The specimen that was used when this observation was made.", 0, 1, specimen)); 3193 children.add(new Property("device", "Reference(Device|DeviceMetric)", "The device used to generate the observation data.", 0, 1, device)); 3194 children.add(new Property("referenceRange", "", "Guidance on how to interpret the value by comparison to a normal or recommended range. Multiple reference ranges are interpreted as an \"OR\". In other words, to represent two distinct target populations, two `referenceRange` elements would be used.", 0, java.lang.Integer.MAX_VALUE, referenceRange)); 3195 children.add(new Property("hasMember", "Reference(Observation|QuestionnaireResponse|MolecularSequence)", "This observation is 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)); 3196 children.add(new Property("derivedFrom", "Reference(DocumentReference|ImagingStudy|ImagingSelection|QuestionnaireResponse|Observation|MolecularSequence|GenomicStudy)", "The target resource that represents a measurement from which this observation value is derived. For example, a calculated anion gap or a fetal measurement based on an ultrasound image.", 0, java.lang.Integer.MAX_VALUE, derivedFrom)); 3197 children.add(new Property("component", "", "Some observations have multiple component observations. These component observations are expressed as separate code value pairs that share the same attributes. Examples include systolic and diastolic component observations for blood pressure measurement and multiple component observations for genetics observations.", 0, java.lang.Integer.MAX_VALUE, component)); 3198 } 3199 3200 @Override 3201 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 3202 switch (_hash) { 3203 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "A unique identifier assigned to this observation.", 0, java.lang.Integer.MAX_VALUE, identifier); 3204 case -1926387433: /*instantiates[x]*/ return new Property("instantiates[x]", "canonical(ObservationDefinition)|Reference(ObservationDefinition)", "The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance.", 0, 1, instantiates); 3205 case -246883639: /*instantiates*/ return new Property("instantiates[x]", "canonical(ObservationDefinition)|Reference(ObservationDefinition)", "The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance.", 0, 1, instantiates); 3206 case 8911915: /*instantiatesCanonical*/ return new Property("instantiates[x]", "canonical(ObservationDefinition)", "The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance.", 0, 1, instantiates); 3207 case -1744595326: /*instantiatesReference*/ return new Property("instantiates[x]", "Reference(ObservationDefinition)", "The reference to a FHIR ObservationDefinition resource that provides the definition that is adhered to in whole or in part by this Observation instance.", 0, 1, instantiates); 3208 case -332612366: /*basedOn*/ return new Property("basedOn", "Reference(CarePlan|DeviceRequest|ImmunizationRecommendation|MedicationRequest|NutritionOrder|ServiceRequest)", "A plan, proposal or order that is fulfilled in whole or in part by this event. For example, a MedicationRequest may require a patient to have laboratory test performed before it is dispensed.", 0, java.lang.Integer.MAX_VALUE, basedOn); 3209 case -680451314: /*triggeredBy*/ return new Property("triggeredBy", "", "Identifies the observation(s) that triggered the performance of this observation.", 0, java.lang.Integer.MAX_VALUE, triggeredBy); 3210 case -995410646: /*partOf*/ return new Property("partOf", "Reference(MedicationAdministration|MedicationDispense|MedicationUsage|Procedure|Immunization|ImagingStudy|GenomicStudy)", "A larger event of which this particular Observation is a component or step. For example, an observation as part of a procedure.", 0, java.lang.Integer.MAX_VALUE, partOf); 3211 case -892481550: /*status*/ return new Property("status", "code", "The status of the result value.", 0, 1, status); 3212 case 50511102: /*category*/ return new Property("category", "CodeableConcept", "A code that classifies the general type of observation being made.", 0, java.lang.Integer.MAX_VALUE, category); 3213 case 3059181: /*code*/ return new Property("code", "CodeableConcept", "Describes what was observed. Sometimes this is called the observation \"name\".", 0, 1, code); 3214 case -1867885268: /*subject*/ return new Property("subject", "Reference(Patient|Group|Device|Location|Organization|Procedure|Practitioner|Medication|Substance|BiologicallyDerivedProduct|NutritionProduct)", "The patient, or group of patients, location, device, organization, procedure or practitioner this observation is about and into whose or what record the observation is placed. If the actual focus of the observation is different from the subject (or a sample of, part, or region of the subject), the `focus` element or the `code` itself specifies the actual focus of the observation.", 0, 1, subject); 3215 case 97604824: /*focus*/ return new Property("focus", "Reference(Any)", "The actual focus of an observation when it is not the patient of record representing something or someone associated with the patient such as a spouse, parent, fetus, or donor. For example, fetus observations in a mother's record. The focus of an observation could also be an existing condition, an intervention, the subject's diet, another observation of the subject, or a body structure such as tumor or implanted device. An example use case would be using the Observation resource to capture whether the mother is trained to change her child's tracheostomy tube. In this example, the child is the patient of record and the mother is the focus.", 0, java.lang.Integer.MAX_VALUE, focus); 3216 case 1524132147: /*encounter*/ return new Property("encounter", "Reference(Encounter)", "The healthcare event (e.g. a patient and healthcare provider interaction) during which this observation is made.", 0, 1, encounter); 3217 case 247104889: /*effective[x]*/ return new Property("effective[x]", "dateTime|Period|Timing|instant", "The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the \"physiologically relevant time\". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective); 3218 case -1468651097: /*effective*/ return new Property("effective[x]", "dateTime|Period|Timing|instant", "The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the \"physiologically relevant time\". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective); 3219 case -275306910: /*effectiveDateTime*/ return new Property("effective[x]", "dateTime", "The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the \"physiologically relevant time\". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective); 3220 case -403934648: /*effectivePeriod*/ return new Property("effective[x]", "Period", "The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the \"physiologically relevant time\". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective); 3221 case -285872943: /*effectiveTiming*/ return new Property("effective[x]", "Timing", "The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the \"physiologically relevant time\". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective); 3222 case -1295730118: /*effectiveInstant*/ return new Property("effective[x]", "instant", "The time or time-period the observed value is asserted as being true. For biological subjects - e.g. human patients - this is usually called the \"physiologically relevant time\". This is usually either the time of the procedure or of specimen collection, but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective); 3223 case -1179159893: /*issued*/ return new Property("issued", "instant", "The date and time this version of the observation was made available to providers, typically after the results have been reviewed and verified.", 0, 1, issued); 3224 case 481140686: /*performer*/ return new Property("performer", "Reference(Practitioner|PractitionerRole|Organization|CareTeam|Patient|RelatedPerson)", "Who was responsible for asserting the observed value as \"true\".", 0, java.lang.Integer.MAX_VALUE, performer); 3225 case -1410166417: /*value[x]*/ return new Property("value[x]", "Quantity|CodeableConcept|string|boolean|integer|Range|Ratio|SampledData|time|dateTime|Period|Attachment", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3226 case 111972721: /*value*/ return new Property("value[x]", "Quantity|CodeableConcept|string|boolean|integer|Range|Ratio|SampledData|time|dateTime|Period|Attachment", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3227 case -2029823716: /*valueQuantity*/ return new Property("value[x]", "Quantity", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3228 case 924902896: /*valueCodeableConcept*/ return new Property("value[x]", "CodeableConcept", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3229 case -1424603934: /*valueString*/ return new Property("value[x]", "string", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3230 case 733421943: /*valueBoolean*/ return new Property("value[x]", "boolean", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3231 case -1668204915: /*valueInteger*/ return new Property("value[x]", "integer", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3232 case 2030761548: /*valueRange*/ return new Property("value[x]", "Range", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3233 case 2030767386: /*valueRatio*/ return new Property("value[x]", "Ratio", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3234 case -962229101: /*valueSampledData*/ return new Property("value[x]", "SampledData", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3235 case -765708322: /*valueTime*/ return new Property("value[x]", "time", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3236 case 1047929900: /*valueDateTime*/ return new Property("value[x]", "dateTime", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3237 case -1524344174: /*valuePeriod*/ return new Property("value[x]", "Period", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3238 case -475566732: /*valueAttachment*/ return new Property("value[x]", "Attachment", "The information determined as a result of making the observation, if the information has a simple value.", 0, 1, value); 3239 case 1034315687: /*dataAbsentReason*/ return new Property("dataAbsentReason", "CodeableConcept", "Provides a reason why the expected value in the element Observation.value[x] is missing.", 0, 1, dataAbsentReason); 3240 case -297950712: /*interpretation*/ return new Property("interpretation", "CodeableConcept", "A categorical assessment of an observation value. For example, high, low, normal.", 0, java.lang.Integer.MAX_VALUE, interpretation); 3241 case 3387378: /*note*/ return new Property("note", "Annotation", "Comments about the observation or the results.", 0, java.lang.Integer.MAX_VALUE, note); 3242 case 1702620169: /*bodySite*/ return new Property("bodySite", "CodeableConcept", "Indicates the site on the subject's body where the observation was made (i.e. the target site).", 0, 1, bodySite); 3243 case -1001731599: /*bodyStructure*/ return new Property("bodyStructure", "Reference(BodyStructure)", "Indicates the body structure on the subject's body where the observation was made (i.e. the target site).", 0, 1, bodyStructure); 3244 case -1077554975: /*method*/ return new Property("method", "CodeableConcept", "Indicates the mechanism used to perform the observation.", 0, 1, method); 3245 case -2132868344: /*specimen*/ return new Property("specimen", "Reference(Specimen|Group)", "The specimen that was used when this observation was made.", 0, 1, specimen); 3246 case -1335157162: /*device*/ return new Property("device", "Reference(Device|DeviceMetric)", "The device used to generate the observation data.", 0, 1, device); 3247 case -1912545102: /*referenceRange*/ return new Property("referenceRange", "", "Guidance on how to interpret the value by comparison to a normal or recommended range. Multiple reference ranges are interpreted as an \"OR\". In other words, to represent two distinct target populations, two `referenceRange` elements would be used.", 0, java.lang.Integer.MAX_VALUE, referenceRange); 3248 case -458019372: /*hasMember*/ return new Property("hasMember", "Reference(Observation|QuestionnaireResponse|MolecularSequence)", "This observation is 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); 3249 case 1077922663: /*derivedFrom*/ return new Property("derivedFrom", "Reference(DocumentReference|ImagingStudy|ImagingSelection|QuestionnaireResponse|Observation|MolecularSequence|GenomicStudy)", "The target resource that represents a measurement from which this observation value is derived. For example, a calculated anion gap or a fetal measurement based on an ultrasound image.", 0, java.lang.Integer.MAX_VALUE, derivedFrom); 3250 case -1399907075: /*component*/ return new Property("component", "", "Some observations have multiple component observations. These component observations are expressed as separate code value pairs that share the same attributes. Examples include systolic and diastolic component observations for blood pressure measurement and multiple component observations for genetics observations.", 0, java.lang.Integer.MAX_VALUE, component); 3251 default: return super.getNamedProperty(_hash, _name, _checkValid); 3252 } 3253 3254 } 3255 3256 @Override 3257 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 3258 switch (hash) { 3259 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 3260 case -246883639: /*instantiates*/ return this.instantiates == null ? new Base[0] : new Base[] {this.instantiates}; // DataType 3261 case -332612366: /*basedOn*/ return this.basedOn == null ? new Base[0] : this.basedOn.toArray(new Base[this.basedOn.size()]); // Reference 3262 case -680451314: /*triggeredBy*/ return this.triggeredBy == null ? new Base[0] : this.triggeredBy.toArray(new Base[this.triggeredBy.size()]); // ObservationTriggeredByComponent 3263 case -995410646: /*partOf*/ return this.partOf == null ? new Base[0] : this.partOf.toArray(new Base[this.partOf.size()]); // Reference 3264 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<ObservationStatus> 3265 case 50511102: /*category*/ return this.category == null ? new Base[0] : this.category.toArray(new Base[this.category.size()]); // CodeableConcept 3266 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 3267 case -1867885268: /*subject*/ return this.subject == null ? new Base[0] : new Base[] {this.subject}; // Reference 3268 case 97604824: /*focus*/ return this.focus == null ? new Base[0] : this.focus.toArray(new Base[this.focus.size()]); // Reference 3269 case 1524132147: /*encounter*/ return this.encounter == null ? new Base[0] : new Base[] {this.encounter}; // Reference 3270 case -1468651097: /*effective*/ return this.effective == null ? new Base[0] : new Base[] {this.effective}; // DataType 3271 case -1179159893: /*issued*/ return this.issued == null ? new Base[0] : new Base[] {this.issued}; // InstantType 3272 case 481140686: /*performer*/ return this.performer == null ? new Base[0] : this.performer.toArray(new Base[this.performer.size()]); // Reference 3273 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // DataType 3274 case 1034315687: /*dataAbsentReason*/ return this.dataAbsentReason == null ? new Base[0] : new Base[] {this.dataAbsentReason}; // CodeableConcept 3275 case -297950712: /*interpretation*/ return this.interpretation == null ? new Base[0] : this.interpretation.toArray(new Base[this.interpretation.size()]); // CodeableConcept 3276 case 3387378: /*note*/ return this.note == null ? new Base[0] : this.note.toArray(new Base[this.note.size()]); // Annotation 3277 case 1702620169: /*bodySite*/ return this.bodySite == null ? new Base[0] : new Base[] {this.bodySite}; // CodeableConcept 3278 case -1001731599: /*bodyStructure*/ return this.bodyStructure == null ? new Base[0] : new Base[] {this.bodyStructure}; // Reference 3279 case -1077554975: /*method*/ return this.method == null ? new Base[0] : new Base[] {this.method}; // CodeableConcept 3280 case -2132868344: /*specimen*/ return this.specimen == null ? new Base[0] : new Base[] {this.specimen}; // Reference 3281 case -1335157162: /*device*/ return this.device == null ? new Base[0] : new Base[] {this.device}; // Reference 3282 case -1912545102: /*referenceRange*/ return this.referenceRange == null ? new Base[0] : this.referenceRange.toArray(new Base[this.referenceRange.size()]); // ObservationReferenceRangeComponent 3283 case -458019372: /*hasMember*/ return this.hasMember == null ? new Base[0] : this.hasMember.toArray(new Base[this.hasMember.size()]); // Reference 3284 case 1077922663: /*derivedFrom*/ return this.derivedFrom == null ? new Base[0] : this.derivedFrom.toArray(new Base[this.derivedFrom.size()]); // Reference 3285 case -1399907075: /*component*/ return this.component == null ? new Base[0] : this.component.toArray(new Base[this.component.size()]); // ObservationComponentComponent 3286 default: return super.getProperty(hash, name, checkValid); 3287 } 3288 3289 } 3290 3291 @Override 3292 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3293 switch (hash) { 3294 case -1618432855: // identifier 3295 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); // Identifier 3296 return value; 3297 case -246883639: // instantiates 3298 this.instantiates = TypeConvertor.castToType(value); // DataType 3299 return value; 3300 case -332612366: // basedOn 3301 this.getBasedOn().add(TypeConvertor.castToReference(value)); // Reference 3302 return value; 3303 case -680451314: // triggeredBy 3304 this.getTriggeredBy().add((ObservationTriggeredByComponent) value); // ObservationTriggeredByComponent 3305 return value; 3306 case -995410646: // partOf 3307 this.getPartOf().add(TypeConvertor.castToReference(value)); // Reference 3308 return value; 3309 case -892481550: // status 3310 value = new ObservationStatusEnumFactory().fromType(TypeConvertor.castToCode(value)); 3311 this.status = (Enumeration) value; // Enumeration<ObservationStatus> 3312 return value; 3313 case 50511102: // category 3314 this.getCategory().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 3315 return value; 3316 case 3059181: // code 3317 this.code = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3318 return value; 3319 case -1867885268: // subject 3320 this.subject = TypeConvertor.castToReference(value); // Reference 3321 return value; 3322 case 97604824: // focus 3323 this.getFocus().add(TypeConvertor.castToReference(value)); // Reference 3324 return value; 3325 case 1524132147: // encounter 3326 this.encounter = TypeConvertor.castToReference(value); // Reference 3327 return value; 3328 case -1468651097: // effective 3329 this.effective = TypeConvertor.castToType(value); // DataType 3330 return value; 3331 case -1179159893: // issued 3332 this.issued = TypeConvertor.castToInstant(value); // InstantType 3333 return value; 3334 case 481140686: // performer 3335 this.getPerformer().add(TypeConvertor.castToReference(value)); // Reference 3336 return value; 3337 case 111972721: // value 3338 this.value = TypeConvertor.castToType(value); // DataType 3339 return value; 3340 case 1034315687: // dataAbsentReason 3341 this.dataAbsentReason = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3342 return value; 3343 case -297950712: // interpretation 3344 this.getInterpretation().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 3345 return value; 3346 case 3387378: // note 3347 this.getNote().add(TypeConvertor.castToAnnotation(value)); // Annotation 3348 return value; 3349 case 1702620169: // bodySite 3350 this.bodySite = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3351 return value; 3352 case -1001731599: // bodyStructure 3353 this.bodyStructure = TypeConvertor.castToReference(value); // Reference 3354 return value; 3355 case -1077554975: // method 3356 this.method = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3357 return value; 3358 case -2132868344: // specimen 3359 this.specimen = TypeConvertor.castToReference(value); // Reference 3360 return value; 3361 case -1335157162: // device 3362 this.device = TypeConvertor.castToReference(value); // Reference 3363 return value; 3364 case -1912545102: // referenceRange 3365 this.getReferenceRange().add((ObservationReferenceRangeComponent) value); // ObservationReferenceRangeComponent 3366 return value; 3367 case -458019372: // hasMember 3368 this.getHasMember().add(TypeConvertor.castToReference(value)); // Reference 3369 return value; 3370 case 1077922663: // derivedFrom 3371 this.getDerivedFrom().add(TypeConvertor.castToReference(value)); // Reference 3372 return value; 3373 case -1399907075: // component 3374 this.getComponent().add((ObservationComponentComponent) value); // ObservationComponentComponent 3375 return value; 3376 default: return super.setProperty(hash, name, value); 3377 } 3378 3379 } 3380 3381 @Override 3382 public Base setProperty(String name, Base value) throws FHIRException { 3383 if (name.equals("identifier")) { 3384 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); 3385 } else if (name.equals("instantiates[x]")) { 3386 this.instantiates = TypeConvertor.castToType(value); // DataType 3387 } else if (name.equals("basedOn")) { 3388 this.getBasedOn().add(TypeConvertor.castToReference(value)); 3389 } else if (name.equals("triggeredBy")) { 3390 this.getTriggeredBy().add((ObservationTriggeredByComponent) value); 3391 } else if (name.equals("partOf")) { 3392 this.getPartOf().add(TypeConvertor.castToReference(value)); 3393 } else if (name.equals("status")) { 3394 value = new ObservationStatusEnumFactory().fromType(TypeConvertor.castToCode(value)); 3395 this.status = (Enumeration) value; // Enumeration<ObservationStatus> 3396 } else if (name.equals("category")) { 3397 this.getCategory().add(TypeConvertor.castToCodeableConcept(value)); 3398 } else if (name.equals("code")) { 3399 this.code = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3400 } else if (name.equals("subject")) { 3401 this.subject = TypeConvertor.castToReference(value); // Reference 3402 } else if (name.equals("focus")) { 3403 this.getFocus().add(TypeConvertor.castToReference(value)); 3404 } else if (name.equals("encounter")) { 3405 this.encounter = TypeConvertor.castToReference(value); // Reference 3406 } else if (name.equals("effective[x]")) { 3407 this.effective = TypeConvertor.castToType(value); // DataType 3408 } else if (name.equals("issued")) { 3409 this.issued = TypeConvertor.castToInstant(value); // InstantType 3410 } else if (name.equals("performer")) { 3411 this.getPerformer().add(TypeConvertor.castToReference(value)); 3412 } else if (name.equals("value[x]")) { 3413 this.value = TypeConvertor.castToType(value); // DataType 3414 } else if (name.equals("dataAbsentReason")) { 3415 this.dataAbsentReason = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3416 } else if (name.equals("interpretation")) { 3417 this.getInterpretation().add(TypeConvertor.castToCodeableConcept(value)); 3418 } else if (name.equals("note")) { 3419 this.getNote().add(TypeConvertor.castToAnnotation(value)); 3420 } else if (name.equals("bodySite")) { 3421 this.bodySite = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3422 } else if (name.equals("bodyStructure")) { 3423 this.bodyStructure = TypeConvertor.castToReference(value); // Reference 3424 } else if (name.equals("method")) { 3425 this.method = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3426 } else if (name.equals("specimen")) { 3427 this.specimen = TypeConvertor.castToReference(value); // Reference 3428 } else if (name.equals("device")) { 3429 this.device = TypeConvertor.castToReference(value); // Reference 3430 } else if (name.equals("referenceRange")) { 3431 this.getReferenceRange().add((ObservationReferenceRangeComponent) value); 3432 } else if (name.equals("hasMember")) { 3433 this.getHasMember().add(TypeConvertor.castToReference(value)); 3434 } else if (name.equals("derivedFrom")) { 3435 this.getDerivedFrom().add(TypeConvertor.castToReference(value)); 3436 } else if (name.equals("component")) { 3437 this.getComponent().add((ObservationComponentComponent) value); 3438 } else 3439 return super.setProperty(name, value); 3440 return value; 3441 } 3442 3443 @Override 3444 public Base makeProperty(int hash, String name) throws FHIRException { 3445 switch (hash) { 3446 case -1618432855: return addIdentifier(); 3447 case -1926387433: return getInstantiates(); 3448 case -246883639: return getInstantiates(); 3449 case -332612366: return addBasedOn(); 3450 case -680451314: return addTriggeredBy(); 3451 case -995410646: return addPartOf(); 3452 case -892481550: return getStatusElement(); 3453 case 50511102: return addCategory(); 3454 case 3059181: return getCode(); 3455 case -1867885268: return getSubject(); 3456 case 97604824: return addFocus(); 3457 case 1524132147: return getEncounter(); 3458 case 247104889: return getEffective(); 3459 case -1468651097: return getEffective(); 3460 case -1179159893: return getIssuedElement(); 3461 case 481140686: return addPerformer(); 3462 case -1410166417: return getValue(); 3463 case 111972721: return getValue(); 3464 case 1034315687: return getDataAbsentReason(); 3465 case -297950712: return addInterpretation(); 3466 case 3387378: return addNote(); 3467 case 1702620169: return getBodySite(); 3468 case -1001731599: return getBodyStructure(); 3469 case -1077554975: return getMethod(); 3470 case -2132868344: return getSpecimen(); 3471 case -1335157162: return getDevice(); 3472 case -1912545102: return addReferenceRange(); 3473 case -458019372: return addHasMember(); 3474 case 1077922663: return addDerivedFrom(); 3475 case -1399907075: return addComponent(); 3476 default: return super.makeProperty(hash, name); 3477 } 3478 3479 } 3480 3481 @Override 3482 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 3483 switch (hash) { 3484 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 3485 case -246883639: /*instantiates*/ return new String[] {"canonical", "Reference"}; 3486 case -332612366: /*basedOn*/ return new String[] {"Reference"}; 3487 case -680451314: /*triggeredBy*/ return new String[] {}; 3488 case -995410646: /*partOf*/ return new String[] {"Reference"}; 3489 case -892481550: /*status*/ return new String[] {"code"}; 3490 case 50511102: /*category*/ return new String[] {"CodeableConcept"}; 3491 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 3492 case -1867885268: /*subject*/ return new String[] {"Reference"}; 3493 case 97604824: /*focus*/ return new String[] {"Reference"}; 3494 case 1524132147: /*encounter*/ return new String[] {"Reference"}; 3495 case -1468651097: /*effective*/ return new String[] {"dateTime", "Period", "Timing", "instant"}; 3496 case -1179159893: /*issued*/ return new String[] {"instant"}; 3497 case 481140686: /*performer*/ return new String[] {"Reference"}; 3498 case 111972721: /*value*/ return new String[] {"Quantity", "CodeableConcept", "string", "boolean", "integer", "Range", "Ratio", "SampledData", "time", "dateTime", "Period", "Attachment"}; 3499 case 1034315687: /*dataAbsentReason*/ return new String[] {"CodeableConcept"}; 3500 case -297950712: /*interpretation*/ return new String[] {"CodeableConcept"}; 3501 case 3387378: /*note*/ return new String[] {"Annotation"}; 3502 case 1702620169: /*bodySite*/ return new String[] {"CodeableConcept"}; 3503 case -1001731599: /*bodyStructure*/ return new String[] {"Reference"}; 3504 case -1077554975: /*method*/ return new String[] {"CodeableConcept"}; 3505 case -2132868344: /*specimen*/ return new String[] {"Reference"}; 3506 case -1335157162: /*device*/ return new String[] {"Reference"}; 3507 case -1912545102: /*referenceRange*/ return new String[] {}; 3508 case -458019372: /*hasMember*/ return new String[] {"Reference"}; 3509 case 1077922663: /*derivedFrom*/ return new String[] {"Reference"}; 3510 case -1399907075: /*component*/ return new String[] {}; 3511 default: return super.getTypesForProperty(hash, name); 3512 } 3513 3514 } 3515 3516 @Override 3517 public Base addChild(String name) throws FHIRException { 3518 if (name.equals("identifier")) { 3519 return addIdentifier(); 3520 } 3521 else if (name.equals("instantiatesCanonical")) { 3522 this.instantiates = new CanonicalType(); 3523 return this.instantiates; 3524 } 3525 else if (name.equals("instantiatesReference")) { 3526 this.instantiates = new Reference(); 3527 return this.instantiates; 3528 } 3529 else if (name.equals("basedOn")) { 3530 return addBasedOn(); 3531 } 3532 else if (name.equals("triggeredBy")) { 3533 return addTriggeredBy(); 3534 } 3535 else if (name.equals("partOf")) { 3536 return addPartOf(); 3537 } 3538 else if (name.equals("status")) { 3539 throw new FHIRException("Cannot call addChild on a primitive type Observation.status"); 3540 } 3541 else if (name.equals("category")) { 3542 return addCategory(); 3543 } 3544 else if (name.equals("code")) { 3545 this.code = new CodeableConcept(); 3546 return this.code; 3547 } 3548 else if (name.equals("subject")) { 3549 this.subject = new Reference(); 3550 return this.subject; 3551 } 3552 else if (name.equals("focus")) { 3553 return addFocus(); 3554 } 3555 else if (name.equals("encounter")) { 3556 this.encounter = new Reference(); 3557 return this.encounter; 3558 } 3559 else if (name.equals("effectiveDateTime")) { 3560 this.effective = new DateTimeType(); 3561 return this.effective; 3562 } 3563 else if (name.equals("effectivePeriod")) { 3564 this.effective = new Period(); 3565 return this.effective; 3566 } 3567 else if (name.equals("effectiveTiming")) { 3568 this.effective = new Timing(); 3569 return this.effective; 3570 } 3571 else if (name.equals("effectiveInstant")) { 3572 this.effective = new InstantType(); 3573 return this.effective; 3574 } 3575 else if (name.equals("issued")) { 3576 throw new FHIRException("Cannot call addChild on a primitive type Observation.issued"); 3577 } 3578 else if (name.equals("performer")) { 3579 return addPerformer(); 3580 } 3581 else if (name.equals("valueQuantity")) { 3582 this.value = new Quantity(); 3583 return this.value; 3584 } 3585 else if (name.equals("valueCodeableConcept")) { 3586 this.value = new CodeableConcept(); 3587 return this.value; 3588 } 3589 else if (name.equals("valueString")) { 3590 this.value = new StringType(); 3591 return this.value; 3592 } 3593 else if (name.equals("valueBoolean")) { 3594 this.value = new BooleanType(); 3595 return this.value; 3596 } 3597 else if (name.equals("valueInteger")) { 3598 this.value = new IntegerType(); 3599 return this.value; 3600 } 3601 else if (name.equals("valueRange")) { 3602 this.value = new Range(); 3603 return this.value; 3604 } 3605 else if (name.equals("valueRatio")) { 3606 this.value = new Ratio(); 3607 return this.value; 3608 } 3609 else if (name.equals("valueSampledData")) { 3610 this.value = new SampledData(); 3611 return this.value; 3612 } 3613 else if (name.equals("valueTime")) { 3614 this.value = new TimeType(); 3615 return this.value; 3616 } 3617 else if (name.equals("valueDateTime")) { 3618 this.value = new DateTimeType(); 3619 return this.value; 3620 } 3621 else if (name.equals("valuePeriod")) { 3622 this.value = new Period(); 3623 return this.value; 3624 } 3625 else if (name.equals("valueAttachment")) { 3626 this.value = new Attachment(); 3627 return this.value; 3628 } 3629 else if (name.equals("dataAbsentReason")) { 3630 this.dataAbsentReason = new CodeableConcept(); 3631 return this.dataAbsentReason; 3632 } 3633 else if (name.equals("interpretation")) { 3634 return addInterpretation(); 3635 } 3636 else if (name.equals("note")) { 3637 return addNote(); 3638 } 3639 else if (name.equals("bodySite")) { 3640 this.bodySite = new CodeableConcept(); 3641 return this.bodySite; 3642 } 3643 else if (name.equals("bodyStructure")) { 3644 this.bodyStructure = new Reference(); 3645 return this.bodyStructure; 3646 } 3647 else if (name.equals("method")) { 3648 this.method = new CodeableConcept(); 3649 return this.method; 3650 } 3651 else if (name.equals("specimen")) { 3652 this.specimen = new Reference(); 3653 return this.specimen; 3654 } 3655 else if (name.equals("device")) { 3656 this.device = new Reference(); 3657 return this.device; 3658 } 3659 else if (name.equals("referenceRange")) { 3660 return addReferenceRange(); 3661 } 3662 else if (name.equals("hasMember")) { 3663 return addHasMember(); 3664 } 3665 else if (name.equals("derivedFrom")) { 3666 return addDerivedFrom(); 3667 } 3668 else if (name.equals("component")) { 3669 return addComponent(); 3670 } 3671 else 3672 return super.addChild(name); 3673 } 3674 3675 public String fhirType() { 3676 return "Observation"; 3677 3678 } 3679 3680 public Observation copy() { 3681 Observation dst = new Observation(); 3682 copyValues(dst); 3683 return dst; 3684 } 3685 3686 public void copyValues(Observation dst) { 3687 super.copyValues(dst); 3688 if (identifier != null) { 3689 dst.identifier = new ArrayList<Identifier>(); 3690 for (Identifier i : identifier) 3691 dst.identifier.add(i.copy()); 3692 }; 3693 dst.instantiates = instantiates == null ? null : instantiates.copy(); 3694 if (basedOn != null) { 3695 dst.basedOn = new ArrayList<Reference>(); 3696 for (Reference i : basedOn) 3697 dst.basedOn.add(i.copy()); 3698 }; 3699 if (triggeredBy != null) { 3700 dst.triggeredBy = new ArrayList<ObservationTriggeredByComponent>(); 3701 for (ObservationTriggeredByComponent i : triggeredBy) 3702 dst.triggeredBy.add(i.copy()); 3703 }; 3704 if (partOf != null) { 3705 dst.partOf = new ArrayList<Reference>(); 3706 for (Reference i : partOf) 3707 dst.partOf.add(i.copy()); 3708 }; 3709 dst.status = status == null ? null : status.copy(); 3710 if (category != null) { 3711 dst.category = new ArrayList<CodeableConcept>(); 3712 for (CodeableConcept i : category) 3713 dst.category.add(i.copy()); 3714 }; 3715 dst.code = code == null ? null : code.copy(); 3716 dst.subject = subject == null ? null : subject.copy(); 3717 if (focus != null) { 3718 dst.focus = new ArrayList<Reference>(); 3719 for (Reference i : focus) 3720 dst.focus.add(i.copy()); 3721 }; 3722 dst.encounter = encounter == null ? null : encounter.copy(); 3723 dst.effective = effective == null ? null : effective.copy(); 3724 dst.issued = issued == null ? null : issued.copy(); 3725 if (performer != null) { 3726 dst.performer = new ArrayList<Reference>(); 3727 for (Reference i : performer) 3728 dst.performer.add(i.copy()); 3729 }; 3730 dst.value = value == null ? null : value.copy(); 3731 dst.dataAbsentReason = dataAbsentReason == null ? null : dataAbsentReason.copy(); 3732 if (interpretation != null) { 3733 dst.interpretation = new ArrayList<CodeableConcept>(); 3734 for (CodeableConcept i : interpretation) 3735 dst.interpretation.add(i.copy()); 3736 }; 3737 if (note != null) { 3738 dst.note = new ArrayList<Annotation>(); 3739 for (Annotation i : note) 3740 dst.note.add(i.copy()); 3741 }; 3742 dst.bodySite = bodySite == null ? null : bodySite.copy(); 3743 dst.bodyStructure = bodyStructure == null ? null : bodyStructure.copy(); 3744 dst.method = method == null ? null : method.copy(); 3745 dst.specimen = specimen == null ? null : specimen.copy(); 3746 dst.device = device == null ? null : device.copy(); 3747 if (referenceRange != null) { 3748 dst.referenceRange = new ArrayList<ObservationReferenceRangeComponent>(); 3749 for (ObservationReferenceRangeComponent i : referenceRange) 3750 dst.referenceRange.add(i.copy()); 3751 }; 3752 if (hasMember != null) { 3753 dst.hasMember = new ArrayList<Reference>(); 3754 for (Reference i : hasMember) 3755 dst.hasMember.add(i.copy()); 3756 }; 3757 if (derivedFrom != null) { 3758 dst.derivedFrom = new ArrayList<Reference>(); 3759 for (Reference i : derivedFrom) 3760 dst.derivedFrom.add(i.copy()); 3761 }; 3762 if (component != null) { 3763 dst.component = new ArrayList<ObservationComponentComponent>(); 3764 for (ObservationComponentComponent i : component) 3765 dst.component.add(i.copy()); 3766 }; 3767 } 3768 3769 protected Observation typedCopy() { 3770 return copy(); 3771 } 3772 3773 @Override 3774 public boolean equalsDeep(Base other_) { 3775 if (!super.equalsDeep(other_)) 3776 return false; 3777 if (!(other_ instanceof Observation)) 3778 return false; 3779 Observation o = (Observation) other_; 3780 return compareDeep(identifier, o.identifier, true) && compareDeep(instantiates, o.instantiates, true) 3781 && compareDeep(basedOn, o.basedOn, true) && compareDeep(triggeredBy, o.triggeredBy, true) && compareDeep(partOf, o.partOf, true) 3782 && compareDeep(status, o.status, true) && compareDeep(category, o.category, true) && compareDeep(code, o.code, true) 3783 && compareDeep(subject, o.subject, true) && compareDeep(focus, o.focus, true) && compareDeep(encounter, o.encounter, true) 3784 && compareDeep(effective, o.effective, true) && compareDeep(issued, o.issued, true) && compareDeep(performer, o.performer, true) 3785 && compareDeep(value, o.value, true) && compareDeep(dataAbsentReason, o.dataAbsentReason, true) 3786 && compareDeep(interpretation, o.interpretation, true) && compareDeep(note, o.note, true) && compareDeep(bodySite, o.bodySite, true) 3787 && compareDeep(bodyStructure, o.bodyStructure, true) && compareDeep(method, o.method, true) && compareDeep(specimen, o.specimen, true) 3788 && compareDeep(device, o.device, true) && compareDeep(referenceRange, o.referenceRange, true) && compareDeep(hasMember, o.hasMember, true) 3789 && compareDeep(derivedFrom, o.derivedFrom, true) && compareDeep(component, o.component, true); 3790 } 3791 3792 @Override 3793 public boolean equalsShallow(Base other_) { 3794 if (!super.equalsShallow(other_)) 3795 return false; 3796 if (!(other_ instanceof Observation)) 3797 return false; 3798 Observation o = (Observation) other_; 3799 return compareValues(status, o.status, true) && compareValues(issued, o.issued, true); 3800 } 3801 3802 public boolean isEmpty() { 3803 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, instantiates, basedOn 3804 , triggeredBy, partOf, status, category, code, subject, focus, encounter, effective 3805 , issued, performer, value, dataAbsentReason, interpretation, note, bodySite, bodyStructure 3806 , method, specimen, device, referenceRange, hasMember, derivedFrom, component 3807 ); 3808 } 3809 3810 @Override 3811 public ResourceType getResourceType() { 3812 return ResourceType.Observation; 3813 } 3814 3815 /** 3816 * Search parameter: <b>based-on</b> 3817 * <p> 3818 * Description: <b>Reference to the service request.</b><br> 3819 * Type: <b>reference</b><br> 3820 * Path: <b>Observation.basedOn</b><br> 3821 * </p> 3822 */ 3823 @SearchParamDefinition(name="based-on", path="Observation.basedOn", description="Reference to the service request.", type="reference", target={CarePlan.class, DeviceRequest.class, ImmunizationRecommendation.class, MedicationRequest.class, NutritionOrder.class, ServiceRequest.class } ) 3824 public static final String SP_BASED_ON = "based-on"; 3825 /** 3826 * <b>Fluent Client</b> search parameter constant for <b>based-on</b> 3827 * <p> 3828 * Description: <b>Reference to the service request.</b><br> 3829 * Type: <b>reference</b><br> 3830 * Path: <b>Observation.basedOn</b><br> 3831 * </p> 3832 */ 3833 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam BASED_ON = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_BASED_ON); 3834 3835/** 3836 * Constant for fluent queries to be used to add include statements. Specifies 3837 * the path value of "<b>Observation:based-on</b>". 3838 */ 3839 public static final ca.uhn.fhir.model.api.Include INCLUDE_BASED_ON = new ca.uhn.fhir.model.api.Include("Observation:based-on").toLocked(); 3840 3841 /** 3842 * Search parameter: <b>category</b> 3843 * <p> 3844 * Description: <b>The classification of the type of observation</b><br> 3845 * Type: <b>token</b><br> 3846 * Path: <b>Observation.category</b><br> 3847 * </p> 3848 */ 3849 @SearchParamDefinition(name="category", path="Observation.category", description="The classification of the type of observation", type="token" ) 3850 public static final String SP_CATEGORY = "category"; 3851 /** 3852 * <b>Fluent Client</b> search parameter constant for <b>category</b> 3853 * <p> 3854 * Description: <b>The classification of the type of observation</b><br> 3855 * Type: <b>token</b><br> 3856 * Path: <b>Observation.category</b><br> 3857 * </p> 3858 */ 3859 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CATEGORY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CATEGORY); 3860 3861 /** 3862 * Search parameter: <b>code-value-concept</b> 3863 * <p> 3864 * Description: <b>Code and coded value parameter pair</b><br> 3865 * Type: <b>composite</b><br> 3866 * Path: <b>Observation</b><br> 3867 * </p> 3868 */ 3869 @SearchParamDefinition(name="code-value-concept", path="Observation", description="Code and coded value parameter pair", type="composite", compositeOf={"code", "value-concept"} ) 3870 public static final String SP_CODE_VALUE_CONCEPT = "code-value-concept"; 3871 /** 3872 * <b>Fluent Client</b> search parameter constant for <b>code-value-concept</b> 3873 * <p> 3874 * Description: <b>Code and coded value parameter pair</b><br> 3875 * Type: <b>composite</b><br> 3876 * Path: <b>Observation</b><br> 3877 * </p> 3878 */ 3879 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam> CODE_VALUE_CONCEPT = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam>(SP_CODE_VALUE_CONCEPT); 3880 3881 /** 3882 * Search parameter: <b>code-value-date</b> 3883 * <p> 3884 * Description: <b>Code and date/time value parameter pair</b><br> 3885 * Type: <b>composite</b><br> 3886 * Path: <b>Observation</b><br> 3887 * </p> 3888 */ 3889 @SearchParamDefinition(name="code-value-date", path="Observation", description="Code and date/time value parameter pair", type="composite", compositeOf={"code", "value-date"} ) 3890 public static final String SP_CODE_VALUE_DATE = "code-value-date"; 3891 /** 3892 * <b>Fluent Client</b> search parameter constant for <b>code-value-date</b> 3893 * <p> 3894 * Description: <b>Code and date/time value parameter pair</b><br> 3895 * Type: <b>composite</b><br> 3896 * Path: <b>Observation</b><br> 3897 * </p> 3898 */ 3899 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.DateClientParam> CODE_VALUE_DATE = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.DateClientParam>(SP_CODE_VALUE_DATE); 3900 3901 /** 3902 * Search parameter: <b>code-value-quantity</b> 3903 * <p> 3904 * Description: <b>Code and quantity value parameter pair</b><br> 3905 * Type: <b>composite</b><br> 3906 * Path: <b>Observation</b><br> 3907 * </p> 3908 */ 3909 @SearchParamDefinition(name="code-value-quantity", path="Observation", description="Code and quantity value parameter pair", type="composite", compositeOf={"code", "value-quantity"} ) 3910 public static final String SP_CODE_VALUE_QUANTITY = "code-value-quantity"; 3911 /** 3912 * <b>Fluent Client</b> search parameter constant for <b>code-value-quantity</b> 3913 * <p> 3914 * Description: <b>Code and quantity value parameter pair</b><br> 3915 * Type: <b>composite</b><br> 3916 * Path: <b>Observation</b><br> 3917 * </p> 3918 */ 3919 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam> CODE_VALUE_QUANTITY = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam>(SP_CODE_VALUE_QUANTITY); 3920 3921 /** 3922 * Search parameter: <b>code-value-string</b> 3923 * <p> 3924 * Description: <b>Code and string value parameter pair</b><br> 3925 * Type: <b>composite</b><br> 3926 * Path: <b>Observation</b><br> 3927 * </p> 3928 */ 3929 @SearchParamDefinition(name="code-value-string", path="Observation", description="Code and string value parameter pair", type="composite", compositeOf={"code", "value-string"} ) 3930 public static final String SP_CODE_VALUE_STRING = "code-value-string"; 3931 /** 3932 * <b>Fluent Client</b> search parameter constant for <b>code-value-string</b> 3933 * <p> 3934 * Description: <b>Code and string value parameter pair</b><br> 3935 * Type: <b>composite</b><br> 3936 * Path: <b>Observation</b><br> 3937 * </p> 3938 */ 3939 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.StringClientParam> CODE_VALUE_STRING = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.StringClientParam>(SP_CODE_VALUE_STRING); 3940 3941 /** 3942 * Search parameter: <b>combo-code-value-concept</b> 3943 * <p> 3944 * Description: <b>Code and coded value parameter pair, including in components</b><br> 3945 * Type: <b>composite</b><br> 3946 * Path: <b>Observation | Observation.component</b><br> 3947 * </p> 3948 */ 3949 @SearchParamDefinition(name="combo-code-value-concept", path="Observation | Observation.component", description="Code and coded value parameter pair, including in components", type="composite", compositeOf={"combo-code", "combo-value-concept"} ) 3950 public static final String SP_COMBO_CODE_VALUE_CONCEPT = "combo-code-value-concept"; 3951 /** 3952 * <b>Fluent Client</b> search parameter constant for <b>combo-code-value-concept</b> 3953 * <p> 3954 * Description: <b>Code and coded value parameter pair, including in components</b><br> 3955 * Type: <b>composite</b><br> 3956 * Path: <b>Observation | Observation.component</b><br> 3957 * </p> 3958 */ 3959 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam> COMBO_CODE_VALUE_CONCEPT = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam>(SP_COMBO_CODE_VALUE_CONCEPT); 3960 3961 /** 3962 * Search parameter: <b>combo-code-value-quantity</b> 3963 * <p> 3964 * Description: <b>Code and quantity value parameter pair, including in components</b><br> 3965 * Type: <b>composite</b><br> 3966 * Path: <b>Observation | Observation.component</b><br> 3967 * </p> 3968 */ 3969 @SearchParamDefinition(name="combo-code-value-quantity", path="Observation | Observation.component", description="Code and quantity value parameter pair, including in components", type="composite", compositeOf={"combo-code", "combo-value-quantity"} ) 3970 public static final String SP_COMBO_CODE_VALUE_QUANTITY = "combo-code-value-quantity"; 3971 /** 3972 * <b>Fluent Client</b> search parameter constant for <b>combo-code-value-quantity</b> 3973 * <p> 3974 * Description: <b>Code and quantity value parameter pair, including in components</b><br> 3975 * Type: <b>composite</b><br> 3976 * Path: <b>Observation | Observation.component</b><br> 3977 * </p> 3978 */ 3979 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam> COMBO_CODE_VALUE_QUANTITY = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam>(SP_COMBO_CODE_VALUE_QUANTITY); 3980 3981 /** 3982 * Search parameter: <b>combo-code</b> 3983 * <p> 3984 * Description: <b>The code of the observation type or component type</b><br> 3985 * Type: <b>token</b><br> 3986 * Path: <b>Observation.code | Observation.component.code</b><br> 3987 * </p> 3988 */ 3989 @SearchParamDefinition(name="combo-code", path="Observation.code | Observation.component.code", description="The code of the observation type or component type", type="token" ) 3990 public static final String SP_COMBO_CODE = "combo-code"; 3991 /** 3992 * <b>Fluent Client</b> search parameter constant for <b>combo-code</b> 3993 * <p> 3994 * Description: <b>The code of the observation type or component type</b><br> 3995 * Type: <b>token</b><br> 3996 * Path: <b>Observation.code | Observation.component.code</b><br> 3997 * </p> 3998 */ 3999 public static final ca.uhn.fhir.rest.gclient.TokenClientParam COMBO_CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_COMBO_CODE); 4000 4001 /** 4002 * Search parameter: <b>combo-data-absent-reason</b> 4003 * <p> 4004 * Description: <b>The reason why the expected value in the element Observation.value[x] or Observation.component.value[x] is missing.</b><br> 4005 * Type: <b>token</b><br> 4006 * Path: <b>Observation.dataAbsentReason | Observation.component.dataAbsentReason</b><br> 4007 * </p> 4008 */ 4009 @SearchParamDefinition(name="combo-data-absent-reason", path="Observation.dataAbsentReason | Observation.component.dataAbsentReason", description="The reason why the expected value in the element Observation.value[x] or Observation.component.value[x] is missing.", type="token" ) 4010 public static final String SP_COMBO_DATA_ABSENT_REASON = "combo-data-absent-reason"; 4011 /** 4012 * <b>Fluent Client</b> search parameter constant for <b>combo-data-absent-reason</b> 4013 * <p> 4014 * Description: <b>The reason why the expected value in the element Observation.value[x] or Observation.component.value[x] is missing.</b><br> 4015 * Type: <b>token</b><br> 4016 * Path: <b>Observation.dataAbsentReason | Observation.component.dataAbsentReason</b><br> 4017 * </p> 4018 */ 4019 public static final ca.uhn.fhir.rest.gclient.TokenClientParam COMBO_DATA_ABSENT_REASON = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_COMBO_DATA_ABSENT_REASON); 4020 4021 /** 4022 * Search parameter: <b>combo-value-concept</b> 4023 * <p> 4024 * Description: <b>The value or component value of the observation, if the value is a CodeableConcept</b><br> 4025 * Type: <b>token</b><br> 4026 * Path: <b>(Observation.value as CodeableConcept) | (Observation.component.value as CodeableConcept)</b><br> 4027 * </p> 4028 */ 4029 @SearchParamDefinition(name="combo-value-concept", path="(Observation.value as CodeableConcept) | (Observation.component.value as CodeableConcept)", description="The value or component value of the observation, if the value is a CodeableConcept", type="token" ) 4030 public static final String SP_COMBO_VALUE_CONCEPT = "combo-value-concept"; 4031 /** 4032 * <b>Fluent Client</b> search parameter constant for <b>combo-value-concept</b> 4033 * <p> 4034 * Description: <b>The value or component value of the observation, if the value is a CodeableConcept</b><br> 4035 * Type: <b>token</b><br> 4036 * Path: <b>(Observation.value as CodeableConcept) | (Observation.component.value as CodeableConcept)</b><br> 4037 * </p> 4038 */ 4039 public static final ca.uhn.fhir.rest.gclient.TokenClientParam COMBO_VALUE_CONCEPT = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_COMBO_VALUE_CONCEPT); 4040 4041 /** 4042 * Search parameter: <b>combo-value-quantity</b> 4043 * <p> 4044 * Description: <b>The value or component value of the observation, if the value is a Quantity, or a SampledData (just search on the bounds of the values in sampled data)</b><br> 4045 * Type: <b>quantity</b><br> 4046 * Path: <b>(Observation.value as Quantity) | (Observation.value as SampledData) | (Observation.component.value as Quantity) | (Observation.component.value as SampledData)</b><br> 4047 * </p> 4048 */ 4049 @SearchParamDefinition(name="combo-value-quantity", path="(Observation.value as Quantity) | (Observation.value as SampledData) | (Observation.component.value as Quantity) | (Observation.component.value as SampledData)", description="The value or component value of the observation, if the value is a Quantity, or a SampledData (just search on the bounds of the values in sampled data)", type="quantity" ) 4050 public static final String SP_COMBO_VALUE_QUANTITY = "combo-value-quantity"; 4051 /** 4052 * <b>Fluent Client</b> search parameter constant for <b>combo-value-quantity</b> 4053 * <p> 4054 * Description: <b>The value or component value of the observation, if the value is a Quantity, or a SampledData (just search on the bounds of the values in sampled data)</b><br> 4055 * Type: <b>quantity</b><br> 4056 * Path: <b>(Observation.value as Quantity) | (Observation.value as SampledData) | (Observation.component.value as Quantity) | (Observation.component.value as SampledData)</b><br> 4057 * </p> 4058 */ 4059 public static final ca.uhn.fhir.rest.gclient.QuantityClientParam COMBO_VALUE_QUANTITY = new ca.uhn.fhir.rest.gclient.QuantityClientParam(SP_COMBO_VALUE_QUANTITY); 4060 4061 /** 4062 * Search parameter: <b>component-code-value-concept</b> 4063 * <p> 4064 * Description: <b>Component code and component coded value parameter pair</b><br> 4065 * Type: <b>composite</b><br> 4066 * Path: <b>Observation.component</b><br> 4067 * </p> 4068 */ 4069 @SearchParamDefinition(name="component-code-value-concept", path="Observation.component", description="Component code and component coded value parameter pair", type="composite", compositeOf={"component-code", "component-value-concept"} ) 4070 public static final String SP_COMPONENT_CODE_VALUE_CONCEPT = "component-code-value-concept"; 4071 /** 4072 * <b>Fluent Client</b> search parameter constant for <b>component-code-value-concept</b> 4073 * <p> 4074 * Description: <b>Component code and component coded value parameter pair</b><br> 4075 * Type: <b>composite</b><br> 4076 * Path: <b>Observation.component</b><br> 4077 * </p> 4078 */ 4079 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam> COMPONENT_CODE_VALUE_CONCEPT = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam>(SP_COMPONENT_CODE_VALUE_CONCEPT); 4080 4081 /** 4082 * Search parameter: <b>component-code-value-quantity</b> 4083 * <p> 4084 * Description: <b>Component code and component quantity value parameter pair</b><br> 4085 * Type: <b>composite</b><br> 4086 * Path: <b>Observation.component</b><br> 4087 * </p> 4088 */ 4089 @SearchParamDefinition(name="component-code-value-quantity", path="Observation.component", description="Component code and component quantity value parameter pair", type="composite", compositeOf={"component-code", "component-value-quantity"} ) 4090 public static final String SP_COMPONENT_CODE_VALUE_QUANTITY = "component-code-value-quantity"; 4091 /** 4092 * <b>Fluent Client</b> search parameter constant for <b>component-code-value-quantity</b> 4093 * <p> 4094 * Description: <b>Component code and component quantity value parameter pair</b><br> 4095 * Type: <b>composite</b><br> 4096 * Path: <b>Observation.component</b><br> 4097 * </p> 4098 */ 4099 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam> COMPONENT_CODE_VALUE_QUANTITY = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam>(SP_COMPONENT_CODE_VALUE_QUANTITY); 4100 4101 /** 4102 * Search parameter: <b>component-code</b> 4103 * <p> 4104 * Description: <b>The component code of the observation type</b><br> 4105 * Type: <b>token</b><br> 4106 * Path: <b>Observation.component.code</b><br> 4107 * </p> 4108 */ 4109 @SearchParamDefinition(name="component-code", path="Observation.component.code", description="The component code of the observation type", type="token" ) 4110 public static final String SP_COMPONENT_CODE = "component-code"; 4111 /** 4112 * <b>Fluent Client</b> search parameter constant for <b>component-code</b> 4113 * <p> 4114 * Description: <b>The component code of the observation type</b><br> 4115 * Type: <b>token</b><br> 4116 * Path: <b>Observation.component.code</b><br> 4117 * </p> 4118 */ 4119 public static final ca.uhn.fhir.rest.gclient.TokenClientParam COMPONENT_CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_COMPONENT_CODE); 4120 4121 /** 4122 * Search parameter: <b>component-data-absent-reason</b> 4123 * <p> 4124 * Description: <b>The reason why the expected value in the element Observation.component.value[x] is missing.</b><br> 4125 * Type: <b>token</b><br> 4126 * Path: <b>Observation.component.dataAbsentReason</b><br> 4127 * </p> 4128 */ 4129 @SearchParamDefinition(name="component-data-absent-reason", path="Observation.component.dataAbsentReason", description="The reason why the expected value in the element Observation.component.value[x] is missing.", type="token" ) 4130 public static final String SP_COMPONENT_DATA_ABSENT_REASON = "component-data-absent-reason"; 4131 /** 4132 * <b>Fluent Client</b> search parameter constant for <b>component-data-absent-reason</b> 4133 * <p> 4134 * Description: <b>The reason why the expected value in the element Observation.component.value[x] is missing.</b><br> 4135 * Type: <b>token</b><br> 4136 * Path: <b>Observation.component.dataAbsentReason</b><br> 4137 * </p> 4138 */ 4139 public static final ca.uhn.fhir.rest.gclient.TokenClientParam COMPONENT_DATA_ABSENT_REASON = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_COMPONENT_DATA_ABSENT_REASON); 4140 4141 /** 4142 * Search parameter: <b>component-value-concept</b> 4143 * <p> 4144 * Description: <b>The value of the component observation, if the value is a CodeableConcept</b><br> 4145 * Type: <b>token</b><br> 4146 * Path: <b>(Observation.component.value as CodeableConcept)</b><br> 4147 * </p> 4148 */ 4149 @SearchParamDefinition(name="component-value-concept", path="(Observation.component.value as CodeableConcept)", description="The value of the component observation, if the value is a CodeableConcept", type="token" ) 4150 public static final String SP_COMPONENT_VALUE_CONCEPT = "component-value-concept"; 4151 /** 4152 * <b>Fluent Client</b> search parameter constant for <b>component-value-concept</b> 4153 * <p> 4154 * Description: <b>The value of the component observation, if the value is a CodeableConcept</b><br> 4155 * Type: <b>token</b><br> 4156 * Path: <b>(Observation.component.value as CodeableConcept)</b><br> 4157 * </p> 4158 */ 4159 public static final ca.uhn.fhir.rest.gclient.TokenClientParam COMPONENT_VALUE_CONCEPT = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_COMPONENT_VALUE_CONCEPT); 4160 4161 /** 4162 * Search parameter: <b>component-value-quantity</b> 4163 * <p> 4164 * Description: <b>The value of the component observation, if the value is a Quantity, or a SampledData (just search on the bounds of the values in sampled data)</b><br> 4165 * Type: <b>quantity</b><br> 4166 * Path: <b>(Observation.component.value as Quantity) | (Observation.component.value as SampledData)</b><br> 4167 * </p> 4168 */ 4169 @SearchParamDefinition(name="component-value-quantity", path="(Observation.component.value as Quantity) | (Observation.component.value as SampledData)", description="The value of the component observation, if the value is a Quantity, or a SampledData (just search on the bounds of the values in sampled data)", type="quantity" ) 4170 public static final String SP_COMPONENT_VALUE_QUANTITY = "component-value-quantity"; 4171 /** 4172 * <b>Fluent Client</b> search parameter constant for <b>component-value-quantity</b> 4173 * <p> 4174 * Description: <b>The value of the component observation, if the value is a Quantity, or a SampledData (just search on the bounds of the values in sampled data)</b><br> 4175 * Type: <b>quantity</b><br> 4176 * Path: <b>(Observation.component.value as Quantity) | (Observation.component.value as SampledData)</b><br> 4177 * </p> 4178 */ 4179 public static final ca.uhn.fhir.rest.gclient.QuantityClientParam COMPONENT_VALUE_QUANTITY = new ca.uhn.fhir.rest.gclient.QuantityClientParam(SP_COMPONENT_VALUE_QUANTITY); 4180 4181 /** 4182 * Search parameter: <b>data-absent-reason</b> 4183 * <p> 4184 * Description: <b>The reason why the expected value in the element Observation.value[x] is missing.</b><br> 4185 * Type: <b>token</b><br> 4186 * Path: <b>Observation.dataAbsentReason</b><br> 4187 * </p> 4188 */ 4189 @SearchParamDefinition(name="data-absent-reason", path="Observation.dataAbsentReason", description="The reason why the expected value in the element Observation.value[x] is missing.", type="token" ) 4190 public static final String SP_DATA_ABSENT_REASON = "data-absent-reason"; 4191 /** 4192 * <b>Fluent Client</b> search parameter constant for <b>data-absent-reason</b> 4193 * <p> 4194 * Description: <b>The reason why the expected value in the element Observation.value[x] is missing.</b><br> 4195 * Type: <b>token</b><br> 4196 * Path: <b>Observation.dataAbsentReason</b><br> 4197 * </p> 4198 */ 4199 public static final ca.uhn.fhir.rest.gclient.TokenClientParam DATA_ABSENT_REASON = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_DATA_ABSENT_REASON); 4200 4201 /** 4202 * Search parameter: <b>derived-from</b> 4203 * <p> 4204 * Description: <b>Related measurements the observation is made from</b><br> 4205 * Type: <b>reference</b><br> 4206 * Path: <b>Observation.derivedFrom</b><br> 4207 * </p> 4208 */ 4209 @SearchParamDefinition(name="derived-from", path="Observation.derivedFrom", description="Related measurements the observation is made from", type="reference", target={DocumentReference.class, GenomicStudy.class, ImagingSelection.class, ImagingStudy.class, MolecularSequence.class, Observation.class, QuestionnaireResponse.class } ) 4210 public static final String SP_DERIVED_FROM = "derived-from"; 4211 /** 4212 * <b>Fluent Client</b> search parameter constant for <b>derived-from</b> 4213 * <p> 4214 * Description: <b>Related measurements the observation is made from</b><br> 4215 * Type: <b>reference</b><br> 4216 * Path: <b>Observation.derivedFrom</b><br> 4217 * </p> 4218 */ 4219 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam DERIVED_FROM = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_DERIVED_FROM); 4220 4221/** 4222 * Constant for fluent queries to be used to add include statements. Specifies 4223 * the path value of "<b>Observation:derived-from</b>". 4224 */ 4225 public static final ca.uhn.fhir.model.api.Include INCLUDE_DERIVED_FROM = new ca.uhn.fhir.model.api.Include("Observation:derived-from").toLocked(); 4226 4227 /** 4228 * Search parameter: <b>device</b> 4229 * <p> 4230 * Description: <b>The Device that generated the observation data.</b><br> 4231 * Type: <b>reference</b><br> 4232 * Path: <b>Observation.device</b><br> 4233 * </p> 4234 */ 4235 @SearchParamDefinition(name="device", path="Observation.device", description="The Device that generated the observation data.", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Device") }, target={Device.class, DeviceMetric.class } ) 4236 public static final String SP_DEVICE = "device"; 4237 /** 4238 * <b>Fluent Client</b> search parameter constant for <b>device</b> 4239 * <p> 4240 * Description: <b>The Device that generated the observation data.</b><br> 4241 * Type: <b>reference</b><br> 4242 * Path: <b>Observation.device</b><br> 4243 * </p> 4244 */ 4245 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam DEVICE = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_DEVICE); 4246 4247/** 4248 * Constant for fluent queries to be used to add include statements. Specifies 4249 * the path value of "<b>Observation:device</b>". 4250 */ 4251 public static final ca.uhn.fhir.model.api.Include INCLUDE_DEVICE = new ca.uhn.fhir.model.api.Include("Observation:device").toLocked(); 4252 4253 /** 4254 * Search parameter: <b>focus</b> 4255 * <p> 4256 * Description: <b>The focus of an observation when the focus is not the patient of record.</b><br> 4257 * Type: <b>reference</b><br> 4258 * Path: <b>Observation.focus</b><br> 4259 * </p> 4260 */ 4261 @SearchParamDefinition(name="focus", path="Observation.focus", description="The focus of an observation when the focus is not the patient of record.", type="reference", target={Account.class, ActivityDefinition.class, ActorDefinition.class, AdministrableProductDefinition.class, AdverseEvent.class, AllergyIntolerance.class, Appointment.class, AppointmentResponse.class, ArtifactAssessment.class, AuditEvent.class, Basic.class, Binary.class, BiologicallyDerivedProduct.class, BodyStructure.class, Bundle.class, CapabilityStatement.class, CarePlan.class, CareTeam.class, ChargeItem.class, ChargeItemDefinition.class, Citation.class, Claim.class, ClaimResponse.class, ClinicalImpression.class, ClinicalUseDefinition.class, CodeSystem.class, Communication.class, CommunicationRequest.class, CompartmentDefinition.class, Composition.class, ConceptMap.class, Condition.class, ConditionDefinition.class, Consent.class, Contract.class, Coverage.class, CoverageEligibilityRequest.class, CoverageEligibilityResponse.class, DetectedIssue.class, Device.class, DeviceDefinition.class, DeviceDispense.class, DeviceMetric.class, DeviceRequest.class, DeviceUsage.class, DiagnosticReport.class, DocumentManifest.class, DocumentReference.class, Encounter.class, Endpoint.class, EnrollmentRequest.class, EnrollmentResponse.class, EpisodeOfCare.class, EventDefinition.class, Evidence.class, EvidenceReport.class, EvidenceVariable.class, ExampleScenario.class, ExplanationOfBenefit.class, FamilyMemberHistory.class, Flag.class, FormularyItem.class, GenomicStudy.class, Goal.class, GraphDefinition.class, Group.class, GuidanceResponse.class, HealthcareService.class, ImagingSelection.class, ImagingStudy.class, Immunization.class, ImmunizationEvaluation.class, ImmunizationRecommendation.class, ImplementationGuide.class, Ingredient.class, InsurancePlan.class, InventoryReport.class, Invoice.class, Library.class, Linkage.class, ListResource.class, Location.class, ManufacturedItemDefinition.class, Measure.class, MeasureReport.class, Medication.class, MedicationAdministration.class, MedicationDispense.class, MedicationKnowledge.class, MedicationRequest.class, MedicationUsage.class, MedicinalProductDefinition.class, MessageDefinition.class, MessageHeader.class, MolecularSequence.class, NamingSystem.class, NutritionIntake.class, NutritionOrder.class, NutritionProduct.class, Observation.class, ObservationDefinition.class, OperationDefinition.class, OperationOutcome.class, Organization.class, OrganizationAffiliation.class, PackagedProductDefinition.class, Patient.class, PaymentNotice.class, PaymentReconciliation.class, Permission.class, Person.class, PlanDefinition.class, Practitioner.class, PractitionerRole.class, Procedure.class, Provenance.class, Questionnaire.class, QuestionnaireResponse.class, RegulatedAuthorization.class, RelatedPerson.class, RequestOrchestration.class, Requirements.class, ResearchStudy.class, ResearchSubject.class, RiskAssessment.class, Schedule.class, SearchParameter.class, ServiceRequest.class, Slot.class, Specimen.class, SpecimenDefinition.class, StructureDefinition.class, StructureMap.class, Subscription.class, SubscriptionStatus.class, SubscriptionTopic.class, Substance.class, SubstanceDefinition.class, SubstanceNucleicAcid.class, SubstancePolymer.class, SubstanceProtein.class, SubstanceReferenceInformation.class, SubstanceSourceMaterial.class, SupplyDelivery.class, SupplyRequest.class, Task.class, TerminologyCapabilities.class, TestReport.class, TestScript.class, Transport.class, ValueSet.class, VerificationResult.class, VisionPrescription.class } ) 4262 public static final String SP_FOCUS = "focus"; 4263 /** 4264 * <b>Fluent Client</b> search parameter constant for <b>focus</b> 4265 * <p> 4266 * Description: <b>The focus of an observation when the focus is not the patient of record.</b><br> 4267 * Type: <b>reference</b><br> 4268 * Path: <b>Observation.focus</b><br> 4269 * </p> 4270 */ 4271 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam FOCUS = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_FOCUS); 4272 4273/** 4274 * Constant for fluent queries to be used to add include statements. Specifies 4275 * the path value of "<b>Observation:focus</b>". 4276 */ 4277 public static final ca.uhn.fhir.model.api.Include INCLUDE_FOCUS = new ca.uhn.fhir.model.api.Include("Observation:focus").toLocked(); 4278 4279 /** 4280 * Search parameter: <b>has-member</b> 4281 * <p> 4282 * Description: <b>Related resource that belongs to the Observation group</b><br> 4283 * Type: <b>reference</b><br> 4284 * Path: <b>Observation.hasMember</b><br> 4285 * </p> 4286 */ 4287 @SearchParamDefinition(name="has-member", path="Observation.hasMember", description="Related resource that belongs to the Observation group", type="reference", target={MolecularSequence.class, Observation.class, QuestionnaireResponse.class } ) 4288 public static final String SP_HAS_MEMBER = "has-member"; 4289 /** 4290 * <b>Fluent Client</b> search parameter constant for <b>has-member</b> 4291 * <p> 4292 * Description: <b>Related resource that belongs to the Observation group</b><br> 4293 * Type: <b>reference</b><br> 4294 * Path: <b>Observation.hasMember</b><br> 4295 * </p> 4296 */ 4297 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam HAS_MEMBER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_HAS_MEMBER); 4298 4299/** 4300 * Constant for fluent queries to be used to add include statements. Specifies 4301 * the path value of "<b>Observation:has-member</b>". 4302 */ 4303 public static final ca.uhn.fhir.model.api.Include INCLUDE_HAS_MEMBER = new ca.uhn.fhir.model.api.Include("Observation:has-member").toLocked(); 4304 4305 /** 4306 * Search parameter: <b>method</b> 4307 * <p> 4308 * Description: <b>The method used for the observation</b><br> 4309 * Type: <b>token</b><br> 4310 * Path: <b>Observation.method</b><br> 4311 * </p> 4312 */ 4313 @SearchParamDefinition(name="method", path="Observation.method", description="The method used for the observation", type="token" ) 4314 public static final String SP_METHOD = "method"; 4315 /** 4316 * <b>Fluent Client</b> search parameter constant for <b>method</b> 4317 * <p> 4318 * Description: <b>The method used for the observation</b><br> 4319 * Type: <b>token</b><br> 4320 * Path: <b>Observation.method</b><br> 4321 * </p> 4322 */ 4323 public static final ca.uhn.fhir.rest.gclient.TokenClientParam METHOD = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_METHOD); 4324 4325 /** 4326 * Search parameter: <b>part-of</b> 4327 * <p> 4328 * Description: <b>Part of referenced event</b><br> 4329 * Type: <b>reference</b><br> 4330 * Path: <b>Observation.partOf</b><br> 4331 * </p> 4332 */ 4333 @SearchParamDefinition(name="part-of", path="Observation.partOf", description="Part of referenced event", type="reference", target={GenomicStudy.class, ImagingStudy.class, Immunization.class, MedicationAdministration.class, MedicationDispense.class, MedicationUsage.class, Procedure.class } ) 4334 public static final String SP_PART_OF = "part-of"; 4335 /** 4336 * <b>Fluent Client</b> search parameter constant for <b>part-of</b> 4337 * <p> 4338 * Description: <b>Part of referenced event</b><br> 4339 * Type: <b>reference</b><br> 4340 * Path: <b>Observation.partOf</b><br> 4341 * </p> 4342 */ 4343 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PART_OF = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PART_OF); 4344 4345/** 4346 * Constant for fluent queries to be used to add include statements. Specifies 4347 * the path value of "<b>Observation:part-of</b>". 4348 */ 4349 public static final ca.uhn.fhir.model.api.Include INCLUDE_PART_OF = new ca.uhn.fhir.model.api.Include("Observation:part-of").toLocked(); 4350 4351 /** 4352 * Search parameter: <b>performer</b> 4353 * <p> 4354 * Description: <b>Who performed the observation</b><br> 4355 * Type: <b>reference</b><br> 4356 * Path: <b>Observation.performer</b><br> 4357 * </p> 4358 */ 4359 @SearchParamDefinition(name="performer", path="Observation.performer", description="Who performed the observation", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Patient"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Practitioner"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for RelatedPerson") }, target={CareTeam.class, Organization.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } ) 4360 public static final String SP_PERFORMER = "performer"; 4361 /** 4362 * <b>Fluent Client</b> search parameter constant for <b>performer</b> 4363 * <p> 4364 * Description: <b>Who performed the observation</b><br> 4365 * Type: <b>reference</b><br> 4366 * Path: <b>Observation.performer</b><br> 4367 * </p> 4368 */ 4369 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PERFORMER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PERFORMER); 4370 4371/** 4372 * Constant for fluent queries to be used to add include statements. Specifies 4373 * the path value of "<b>Observation:performer</b>". 4374 */ 4375 public static final ca.uhn.fhir.model.api.Include INCLUDE_PERFORMER = new ca.uhn.fhir.model.api.Include("Observation:performer").toLocked(); 4376 4377 /** 4378 * Search parameter: <b>specimen</b> 4379 * <p> 4380 * Description: <b>Specimen used for this observation</b><br> 4381 * Type: <b>reference</b><br> 4382 * Path: <b>Observation.specimen</b><br> 4383 * </p> 4384 */ 4385 @SearchParamDefinition(name="specimen", path="Observation.specimen", description="Specimen used for this observation", type="reference", target={Group.class, Specimen.class } ) 4386 public static final String SP_SPECIMEN = "specimen"; 4387 /** 4388 * <b>Fluent Client</b> search parameter constant for <b>specimen</b> 4389 * <p> 4390 * Description: <b>Specimen used for this observation</b><br> 4391 * Type: <b>reference</b><br> 4392 * Path: <b>Observation.specimen</b><br> 4393 * </p> 4394 */ 4395 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SPECIMEN = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SPECIMEN); 4396 4397/** 4398 * Constant for fluent queries to be used to add include statements. Specifies 4399 * the path value of "<b>Observation:specimen</b>". 4400 */ 4401 public static final ca.uhn.fhir.model.api.Include INCLUDE_SPECIMEN = new ca.uhn.fhir.model.api.Include("Observation:specimen").toLocked(); 4402 4403 /** 4404 * Search parameter: <b>status</b> 4405 * <p> 4406 * Description: <b>The status of the observation</b><br> 4407 * Type: <b>token</b><br> 4408 * Path: <b>Observation.status</b><br> 4409 * </p> 4410 */ 4411 @SearchParamDefinition(name="status", path="Observation.status", description="The status of the observation", type="token" ) 4412 public static final String SP_STATUS = "status"; 4413 /** 4414 * <b>Fluent Client</b> search parameter constant for <b>status</b> 4415 * <p> 4416 * Description: <b>The status of the observation</b><br> 4417 * Type: <b>token</b><br> 4418 * Path: <b>Observation.status</b><br> 4419 * </p> 4420 */ 4421 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 4422 4423 /** 4424 * Search parameter: <b>subject</b> 4425 * <p> 4426 * Description: <b>The subject that the observation is about</b><br> 4427 * Type: <b>reference</b><br> 4428 * Path: <b>Observation.subject</b><br> 4429 * </p> 4430 */ 4431 @SearchParamDefinition(name="subject", path="Observation.subject", description="The subject that the observation is about", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Device"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Patient") }, target={BiologicallyDerivedProduct.class, Device.class, Group.class, Location.class, Medication.class, NutritionProduct.class, Organization.class, Patient.class, Practitioner.class, Procedure.class, Substance.class } ) 4432 public static final String SP_SUBJECT = "subject"; 4433 /** 4434 * <b>Fluent Client</b> search parameter constant for <b>subject</b> 4435 * <p> 4436 * Description: <b>The subject that the observation is about</b><br> 4437 * Type: <b>reference</b><br> 4438 * Path: <b>Observation.subject</b><br> 4439 * </p> 4440 */ 4441 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SUBJECT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SUBJECT); 4442 4443/** 4444 * Constant for fluent queries to be used to add include statements. Specifies 4445 * the path value of "<b>Observation:subject</b>". 4446 */ 4447 public static final ca.uhn.fhir.model.api.Include INCLUDE_SUBJECT = new ca.uhn.fhir.model.api.Include("Observation:subject").toLocked(); 4448 4449 /** 4450 * Search parameter: <b>value-concept</b> 4451 * <p> 4452 * Description: <b>The value of the observation, if the value is a CodeableConcept</b><br> 4453 * Type: <b>token</b><br> 4454 * Path: <b>(Observation.value as CodeableConcept)</b><br> 4455 * </p> 4456 */ 4457 @SearchParamDefinition(name="value-concept", path="(Observation.value as CodeableConcept)", description="The value of the observation, if the value is a CodeableConcept", type="token" ) 4458 public static final String SP_VALUE_CONCEPT = "value-concept"; 4459 /** 4460 * <b>Fluent Client</b> search parameter constant for <b>value-concept</b> 4461 * <p> 4462 * Description: <b>The value of the observation, if the value is a CodeableConcept</b><br> 4463 * Type: <b>token</b><br> 4464 * Path: <b>(Observation.value as CodeableConcept)</b><br> 4465 * </p> 4466 */ 4467 public static final ca.uhn.fhir.rest.gclient.TokenClientParam VALUE_CONCEPT = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_VALUE_CONCEPT); 4468 4469 /** 4470 * Search parameter: <b>value-date</b> 4471 * <p> 4472 * Description: <b>The value of the observation, if the value is a date or period of time</b><br> 4473 * Type: <b>date</b><br> 4474 * Path: <b>(Observation.value as dateTime) | (Observation.value as Period)</b><br> 4475 * </p> 4476 */ 4477 @SearchParamDefinition(name="value-date", path="(Observation.value as dateTime) | (Observation.value as Period)", description="The value of the observation, if the value is a date or period of time", type="date" ) 4478 public static final String SP_VALUE_DATE = "value-date"; 4479 /** 4480 * <b>Fluent Client</b> search parameter constant for <b>value-date</b> 4481 * <p> 4482 * Description: <b>The value of the observation, if the value is a date or period of time</b><br> 4483 * Type: <b>date</b><br> 4484 * Path: <b>(Observation.value as dateTime) | (Observation.value as Period)</b><br> 4485 * </p> 4486 */ 4487 public static final ca.uhn.fhir.rest.gclient.DateClientParam VALUE_DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_VALUE_DATE); 4488 4489 /** 4490 * Search parameter: <b>value-quantity</b> 4491 * <p> 4492 * Description: <b>The value of the observation, if the value is a Quantity, or a SampledData (just search on the bounds of the values in sampled data)</b><br> 4493 * Type: <b>quantity</b><br> 4494 * Path: <b>(Observation.value as Quantity) | (Observation.value as SampledData)</b><br> 4495 * </p> 4496 */ 4497 @SearchParamDefinition(name="value-quantity", path="(Observation.value as Quantity) | (Observation.value as SampledData)", description="The value of the observation, if the value is a Quantity, or a SampledData (just search on the bounds of the values in sampled data)", type="quantity" ) 4498 public static final String SP_VALUE_QUANTITY = "value-quantity"; 4499 /** 4500 * <b>Fluent Client</b> search parameter constant for <b>value-quantity</b> 4501 * <p> 4502 * Description: <b>The value of the observation, if the value is a Quantity, or a SampledData (just search on the bounds of the values in sampled data)</b><br> 4503 * Type: <b>quantity</b><br> 4504 * Path: <b>(Observation.value as Quantity) | (Observation.value as SampledData)</b><br> 4505 * </p> 4506 */ 4507 public static final ca.uhn.fhir.rest.gclient.QuantityClientParam VALUE_QUANTITY = new ca.uhn.fhir.rest.gclient.QuantityClientParam(SP_VALUE_QUANTITY); 4508 4509 /** 4510 * Search parameter: <b>value-string</b> 4511 * <p> 4512 * Description: <b>The value of the observation, if the value is a string, and also searches in CodeableConcept.text</b><br> 4513 * Type: <b>string</b><br> 4514 * Path: <b>(Observation.value as string) | (Observation.value as CodeableConcept).text</b><br> 4515 * </p> 4516 */ 4517 @SearchParamDefinition(name="value-string", path="(Observation.value as string) | (Observation.value as CodeableConcept).text", description="The value of the observation, if the value is a string, and also searches in CodeableConcept.text", type="string" ) 4518 public static final String SP_VALUE_STRING = "value-string"; 4519 /** 4520 * <b>Fluent Client</b> search parameter constant for <b>value-string</b> 4521 * <p> 4522 * Description: <b>The value of the observation, if the value is a string, and also searches in CodeableConcept.text</b><br> 4523 * Type: <b>string</b><br> 4524 * Path: <b>(Observation.value as string) | (Observation.value as CodeableConcept).text</b><br> 4525 * </p> 4526 */ 4527 public static final ca.uhn.fhir.rest.gclient.StringClientParam VALUE_STRING = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_VALUE_STRING); 4528 4529 /** 4530 * Search parameter: <b>code</b> 4531 * <p> 4532 * Description: <b>Multiple Resources: 4533 4534* [AllergyIntolerance](allergyintolerance.html): Code that identifies the allergy or intolerance 4535* [Condition](condition.html): Code for the condition 4536* [DeviceRequest](devicerequest.html): Code for what is being requested/ordered 4537* [DiagnosticReport](diagnosticreport.html): The code for the report, as opposed to codes for the atomic results, which are the names on the observation resource referred to from the result 4538* [FamilyMemberHistory](familymemberhistory.html): A search by a condition code 4539* [List](list.html): What the purpose of this list is 4540* [Medication](medication.html): Returns medications for a specific code 4541* [MedicationAdministration](medicationadministration.html): Return administrations of this medication code 4542* [MedicationDispense](medicationdispense.html): Returns dispenses of this medicine code 4543* [MedicationRequest](medicationrequest.html): Return prescriptions of this medication code 4544* [MedicationUsage](medicationusage.html): Return statements of this medication code 4545* [Observation](observation.html): The code of the observation type 4546* [Procedure](procedure.html): A code to identify a procedure 4547</b><br> 4548 * Type: <b>token</b><br> 4549 * Path: <b>AllergyIntolerance.code | AllergyIntolerance.reaction.substance | Condition.code | DeviceRequest.code.concept | DiagnosticReport.code | FamilyMemberHistory.condition.code | List.code | Medication.code | MedicationAdministration.medication.concept | MedicationDispense.medication.concept | MedicationRequest.medication.concept | MedicationUsage.medication.concept | Observation.code | Procedure.code</b><br> 4550 * </p> 4551 */ 4552 @SearchParamDefinition(name="code", path="AllergyIntolerance.code | AllergyIntolerance.reaction.substance | Condition.code | DeviceRequest.code.concept | DiagnosticReport.code | FamilyMemberHistory.condition.code | List.code | Medication.code | MedicationAdministration.medication.concept | MedicationDispense.medication.concept | MedicationRequest.medication.concept | MedicationUsage.medication.concept | Observation.code | Procedure.code", description="Multiple Resources: \r\n\r\n* [AllergyIntolerance](allergyintolerance.html): Code that identifies the allergy or intolerance\r\n* [Condition](condition.html): Code for the condition\r\n* [DeviceRequest](devicerequest.html): Code for what is being requested/ordered\r\n* [DiagnosticReport](diagnosticreport.html): The code for the report, as opposed to codes for the atomic results, which are the names on the observation resource referred to from the result\r\n* [FamilyMemberHistory](familymemberhistory.html): A search by a condition code\r\n* [List](list.html): What the purpose of this list is\r\n* [Medication](medication.html): Returns medications for a specific code\r\n* [MedicationAdministration](medicationadministration.html): Return administrations of this medication code\r\n* [MedicationDispense](medicationdispense.html): Returns dispenses of this medicine code\r\n* [MedicationRequest](medicationrequest.html): Return prescriptions of this medication code\r\n* [MedicationUsage](medicationusage.html): Return statements of this medication code\r\n* [Observation](observation.html): The code of the observation type\r\n* [Procedure](procedure.html): A code to identify a procedure\r\n", type="token" ) 4553 public static final String SP_CODE = "code"; 4554 /** 4555 * <b>Fluent Client</b> search parameter constant for <b>code</b> 4556 * <p> 4557 * Description: <b>Multiple Resources: 4558 4559* [AllergyIntolerance](allergyintolerance.html): Code that identifies the allergy or intolerance 4560* [Condition](condition.html): Code for the condition 4561* [DeviceRequest](devicerequest.html): Code for what is being requested/ordered 4562* [DiagnosticReport](diagnosticreport.html): The code for the report, as opposed to codes for the atomic results, which are the names on the observation resource referred to from the result 4563* [FamilyMemberHistory](familymemberhistory.html): A search by a condition code 4564* [List](list.html): What the purpose of this list is 4565* [Medication](medication.html): Returns medications for a specific code 4566* [MedicationAdministration](medicationadministration.html): Return administrations of this medication code 4567* [MedicationDispense](medicationdispense.html): Returns dispenses of this medicine code 4568* [MedicationRequest](medicationrequest.html): Return prescriptions of this medication code 4569* [MedicationUsage](medicationusage.html): Return statements of this medication code 4570* [Observation](observation.html): The code of the observation type 4571* [Procedure](procedure.html): A code to identify a procedure 4572</b><br> 4573 * Type: <b>token</b><br> 4574 * Path: <b>AllergyIntolerance.code | AllergyIntolerance.reaction.substance | Condition.code | DeviceRequest.code.concept | DiagnosticReport.code | FamilyMemberHistory.condition.code | List.code | Medication.code | MedicationAdministration.medication.concept | MedicationDispense.medication.concept | MedicationRequest.medication.concept | MedicationUsage.medication.concept | Observation.code | Procedure.code</b><br> 4575 * </p> 4576 */ 4577 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CODE); 4578 4579 /** 4580 * Search parameter: <b>date</b> 4581 * <p> 4582 * Description: <b>Multiple Resources: 4583 4584* [AllergyIntolerance](allergyintolerance.html): Date first version of the resource instance was recorded 4585* [CarePlan](careplan.html): Time period plan covers 4586* [CareTeam](careteam.html): A date within the coverage time period. 4587* [ClinicalImpression](clinicalimpression.html): When the assessment was documented 4588* [Composition](composition.html): Composition editing time 4589* [Consent](consent.html): When consent was agreed to 4590* [DiagnosticReport](diagnosticreport.html): The clinically relevant time of the report 4591* [Encounter](encounter.html): A date within the actualPeriod the Encounter lasted 4592* [EpisodeOfCare](episodeofcare.html): The provided date search value falls within the episode of care's period 4593* [FamilyMemberHistory](familymemberhistory.html): When history was recorded or last updated 4594* [Flag](flag.html): Time period when flag is active 4595* [Immunization](immunization.html): Vaccination (non)-Administration Date 4596* [List](list.html): When the list was prepared 4597* [Observation](observation.html): Obtained date/time. If the obtained element is a period, a date that falls in the period 4598* [Procedure](procedure.html): When the procedure occurred or is occurring 4599* [RiskAssessment](riskassessment.html): When was assessment made? 4600* [SupplyRequest](supplyrequest.html): When the request was made 4601</b><br> 4602 * Type: <b>date</b><br> 4603 * Path: <b>AllergyIntolerance.recordedDate | CarePlan.period | ClinicalImpression.date | Composition.date | Consent.dateTime | DiagnosticReport.effective | Encounter.actualPeriod | EpisodeOfCare.period | FamilyMemberHistory.date | Flag.period | (Immunization.occurrence as dateTime) | List.date | Observation.effective | Procedure.occurrence | (RiskAssessment.occurrence as dateTime) | SupplyRequest.authoredOn</b><br> 4604 * </p> 4605 */ 4606 @SearchParamDefinition(name="date", path="AllergyIntolerance.recordedDate | CarePlan.period | ClinicalImpression.date | Composition.date | Consent.dateTime | DiagnosticReport.effective | Encounter.actualPeriod | EpisodeOfCare.period | FamilyMemberHistory.date | Flag.period | (Immunization.occurrence as dateTime) | List.date | Observation.effective | Procedure.occurrence | (RiskAssessment.occurrence as dateTime) | SupplyRequest.authoredOn", description="Multiple Resources: \r\n\r\n* [AllergyIntolerance](allergyintolerance.html): Date first version of the resource instance was recorded\r\n* [CarePlan](careplan.html): Time period plan covers\r\n* [CareTeam](careteam.html): A date within the coverage time period.\r\n* [ClinicalImpression](clinicalimpression.html): When the assessment was documented\r\n* [Composition](composition.html): Composition editing time\r\n* [Consent](consent.html): When consent was agreed to\r\n* [DiagnosticReport](diagnosticreport.html): The clinically relevant time of the report\r\n* [Encounter](encounter.html): A date within the actualPeriod the Encounter lasted\r\n* [EpisodeOfCare](episodeofcare.html): The provided date search value falls within the episode of care's period\r\n* [FamilyMemberHistory](familymemberhistory.html): When history was recorded or last updated\r\n* [Flag](flag.html): Time period when flag is active\r\n* [Immunization](immunization.html): Vaccination (non)-Administration Date\r\n* [List](list.html): When the list was prepared\r\n* [Observation](observation.html): Obtained date/time. If the obtained element is a period, a date that falls in the period\r\n* [Procedure](procedure.html): When the procedure occurred or is occurring\r\n* [RiskAssessment](riskassessment.html): When was assessment made?\r\n* [SupplyRequest](supplyrequest.html): When the request was made\r\n", type="date" ) 4607 public static final String SP_DATE = "date"; 4608 /** 4609 * <b>Fluent Client</b> search parameter constant for <b>date</b> 4610 * <p> 4611 * Description: <b>Multiple Resources: 4612 4613* [AllergyIntolerance](allergyintolerance.html): Date first version of the resource instance was recorded 4614* [CarePlan](careplan.html): Time period plan covers 4615* [CareTeam](careteam.html): A date within the coverage time period. 4616* [ClinicalImpression](clinicalimpression.html): When the assessment was documented 4617* [Composition](composition.html): Composition editing time 4618* [Consent](consent.html): When consent was agreed to 4619* [DiagnosticReport](diagnosticreport.html): The clinically relevant time of the report 4620* [Encounter](encounter.html): A date within the actualPeriod the Encounter lasted 4621* [EpisodeOfCare](episodeofcare.html): The provided date search value falls within the episode of care's period 4622* [FamilyMemberHistory](familymemberhistory.html): When history was recorded or last updated 4623* [Flag](flag.html): Time period when flag is active 4624* [Immunization](immunization.html): Vaccination (non)-Administration Date 4625* [List](list.html): When the list was prepared 4626* [Observation](observation.html): Obtained date/time. If the obtained element is a period, a date that falls in the period 4627* [Procedure](procedure.html): When the procedure occurred or is occurring 4628* [RiskAssessment](riskassessment.html): When was assessment made? 4629* [SupplyRequest](supplyrequest.html): When the request was made 4630</b><br> 4631 * Type: <b>date</b><br> 4632 * Path: <b>AllergyIntolerance.recordedDate | CarePlan.period | ClinicalImpression.date | Composition.date | Consent.dateTime | DiagnosticReport.effective | Encounter.actualPeriod | EpisodeOfCare.period | FamilyMemberHistory.date | Flag.period | (Immunization.occurrence as dateTime) | List.date | Observation.effective | Procedure.occurrence | (RiskAssessment.occurrence as dateTime) | SupplyRequest.authoredOn</b><br> 4633 * </p> 4634 */ 4635 public static final ca.uhn.fhir.rest.gclient.DateClientParam DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_DATE); 4636 4637 /** 4638 * Search parameter: <b>encounter</b> 4639 * <p> 4640 * Description: <b>Multiple Resources: 4641 4642* [Composition](composition.html): Context of the Composition 4643* [DeviceRequest](devicerequest.html): Encounter during which request was created 4644* [DiagnosticReport](diagnosticreport.html): The Encounter when the order was made 4645* [Flag](flag.html): Alert relevant during encounter 4646* [List](list.html): Context in which list created 4647* [NutritionOrder](nutritionorder.html): Return nutrition orders with this encounter identifier 4648* [Observation](observation.html): Encounter related to the observation 4649* [Procedure](procedure.html): The Encounter during which this Procedure was created 4650* [RiskAssessment](riskassessment.html): Where was assessment performed? 4651* [ServiceRequest](servicerequest.html): An encounter in which this request is made 4652* [VisionPrescription](visionprescription.html): Return prescriptions with this encounter identifier 4653</b><br> 4654 * Type: <b>reference</b><br> 4655 * Path: <b>Composition.encounter | DeviceRequest.encounter | DiagnosticReport.encounter | Flag.encounter | List.encounter | NutritionOrder.encounter | Observation.encounter | Procedure.encounter | RiskAssessment.encounter | ServiceRequest.encounter | VisionPrescription.encounter</b><br> 4656 * </p> 4657 */ 4658 @SearchParamDefinition(name="encounter", path="Composition.encounter | DeviceRequest.encounter | DiagnosticReport.encounter | Flag.encounter | List.encounter | NutritionOrder.encounter | Observation.encounter | Procedure.encounter | RiskAssessment.encounter | ServiceRequest.encounter | VisionPrescription.encounter", description="Multiple Resources: \r\n\r\n* [Composition](composition.html): Context of the Composition\r\n* [DeviceRequest](devicerequest.html): Encounter during which request was created\r\n* [DiagnosticReport](diagnosticreport.html): The Encounter when the order was made\r\n* [Flag](flag.html): Alert relevant during encounter\r\n* [List](list.html): Context in which list created\r\n* [NutritionOrder](nutritionorder.html): Return nutrition orders with this encounter identifier\r\n* [Observation](observation.html): Encounter related to the observation\r\n* [Procedure](procedure.html): The Encounter during which this Procedure was created\r\n* [RiskAssessment](riskassessment.html): Where was assessment performed?\r\n* [ServiceRequest](servicerequest.html): An encounter in which this request is made\r\n* [VisionPrescription](visionprescription.html): Return prescriptions with this encounter identifier\r\n", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Encounter") }, target={Encounter.class } ) 4659 public static final String SP_ENCOUNTER = "encounter"; 4660 /** 4661 * <b>Fluent Client</b> search parameter constant for <b>encounter</b> 4662 * <p> 4663 * Description: <b>Multiple Resources: 4664 4665* [Composition](composition.html): Context of the Composition 4666* [DeviceRequest](devicerequest.html): Encounter during which request was created 4667* [DiagnosticReport](diagnosticreport.html): The Encounter when the order was made 4668* [Flag](flag.html): Alert relevant during encounter 4669* [List](list.html): Context in which list created 4670* [NutritionOrder](nutritionorder.html): Return nutrition orders with this encounter identifier 4671* [Observation](observation.html): Encounter related to the observation 4672* [Procedure](procedure.html): The Encounter during which this Procedure was created 4673* [RiskAssessment](riskassessment.html): Where was assessment performed? 4674* [ServiceRequest](servicerequest.html): An encounter in which this request is made 4675* [VisionPrescription](visionprescription.html): Return prescriptions with this encounter identifier 4676</b><br> 4677 * Type: <b>reference</b><br> 4678 * Path: <b>Composition.encounter | DeviceRequest.encounter | DiagnosticReport.encounter | Flag.encounter | List.encounter | NutritionOrder.encounter | Observation.encounter | Procedure.encounter | RiskAssessment.encounter | ServiceRequest.encounter | VisionPrescription.encounter</b><br> 4679 * </p> 4680 */ 4681 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ENCOUNTER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ENCOUNTER); 4682 4683/** 4684 * Constant for fluent queries to be used to add include statements. Specifies 4685 * the path value of "<b>Observation:encounter</b>". 4686 */ 4687 public static final ca.uhn.fhir.model.api.Include INCLUDE_ENCOUNTER = new ca.uhn.fhir.model.api.Include("Observation:encounter").toLocked(); 4688 4689 /** 4690 * Search parameter: <b>identifier</b> 4691 * <p> 4692 * Description: <b>Multiple Resources: 4693 4694* [AllergyIntolerance](allergyintolerance.html): External ids for this item 4695* [CarePlan](careplan.html): External Ids for this plan 4696* [CareTeam](careteam.html): External Ids for this team 4697* [Composition](composition.html): Version-independent identifier for the Composition 4698* [Condition](condition.html): A unique identifier of the condition record 4699* [Consent](consent.html): Identifier for this record (external references) 4700* [DetectedIssue](detectedissue.html): Unique id for the detected issue 4701* [DeviceRequest](devicerequest.html): Business identifier for request/order 4702* [DiagnosticReport](diagnosticreport.html): An identifier for the report 4703* [DocumentManifest](documentmanifest.html): Unique Identifier for the set of documents 4704* [DocumentReference](documentreference.html): Identifier of the attachment binary 4705* [Encounter](encounter.html): Identifier(s) by which this encounter is known 4706* [EpisodeOfCare](episodeofcare.html): Business Identifier(s) relevant for this EpisodeOfCare 4707* [FamilyMemberHistory](familymemberhistory.html): A search by a record identifier 4708* [Goal](goal.html): External Ids for this goal 4709* [ImagingStudy](imagingstudy.html): Identifiers for the Study, such as DICOM Study Instance UID 4710* [Immunization](immunization.html): Business identifier 4711* [List](list.html): Business identifier 4712* [MedicationAdministration](medicationadministration.html): Return administrations with this external identifier 4713* [MedicationDispense](medicationdispense.html): Returns dispenses with this external identifier 4714* [MedicationRequest](medicationrequest.html): Return prescriptions with this external identifier 4715* [MedicationUsage](medicationusage.html): Return statements with this external identifier 4716* [NutritionOrder](nutritionorder.html): Return nutrition orders with this external identifier 4717* [Observation](observation.html): The unique id for a particular observation 4718* [Procedure](procedure.html): A unique identifier for a procedure 4719* [RiskAssessment](riskassessment.html): Unique identifier for the assessment 4720* [ServiceRequest](servicerequest.html): Identifiers assigned to this order 4721* [SupplyDelivery](supplydelivery.html): External identifier 4722* [SupplyRequest](supplyrequest.html): Business Identifier for SupplyRequest 4723* [VisionPrescription](visionprescription.html): Return prescriptions with this external identifier 4724</b><br> 4725 * Type: <b>token</b><br> 4726 * Path: <b>AllergyIntolerance.identifier | CarePlan.identifier | CareTeam.identifier | Composition.identifier | Condition.identifier | Consent.identifier | DetectedIssue.identifier | DeviceRequest.identifier | DiagnosticReport.identifier | DocumentManifest.masterIdentifier | DocumentManifest.identifier | DocumentReference.identifier | Encounter.identifier | EpisodeOfCare.identifier | FamilyMemberHistory.identifier | Goal.identifier | ImagingStudy.identifier | Immunization.identifier | List.identifier | MedicationAdministration.identifier | MedicationDispense.identifier | MedicationRequest.identifier | MedicationUsage.identifier | NutritionOrder.identifier | Observation.identifier | Procedure.identifier | RiskAssessment.identifier | ServiceRequest.identifier | SupplyDelivery.identifier | SupplyRequest.identifier | VisionPrescription.identifier</b><br> 4727 * </p> 4728 */ 4729 @SearchParamDefinition(name="identifier", path="AllergyIntolerance.identifier | CarePlan.identifier | CareTeam.identifier | Composition.identifier | Condition.identifier | Consent.identifier | DetectedIssue.identifier | DeviceRequest.identifier | DiagnosticReport.identifier | DocumentManifest.masterIdentifier | DocumentManifest.identifier | DocumentReference.identifier | Encounter.identifier | EpisodeOfCare.identifier | FamilyMemberHistory.identifier | Goal.identifier | ImagingStudy.identifier | Immunization.identifier | List.identifier | MedicationAdministration.identifier | MedicationDispense.identifier | MedicationRequest.identifier | MedicationUsage.identifier | NutritionOrder.identifier | Observation.identifier | Procedure.identifier | RiskAssessment.identifier | ServiceRequest.identifier | SupplyDelivery.identifier | SupplyRequest.identifier | VisionPrescription.identifier", description="Multiple Resources: \r\n\r\n* [AllergyIntolerance](allergyintolerance.html): External ids for this item\r\n* [CarePlan](careplan.html): External Ids for this plan\r\n* [CareTeam](careteam.html): External Ids for this team\r\n* [Composition](composition.html): Version-independent identifier for the Composition\r\n* [Condition](condition.html): A unique identifier of the condition record\r\n* [Consent](consent.html): Identifier for this record (external references)\r\n* [DetectedIssue](detectedissue.html): Unique id for the detected issue\r\n* [DeviceRequest](devicerequest.html): Business identifier for request/order\r\n* [DiagnosticReport](diagnosticreport.html): An identifier for the report\r\n* [DocumentManifest](documentmanifest.html): Unique Identifier for the set of documents\r\n* [DocumentReference](documentreference.html): Identifier of the attachment binary\r\n* [Encounter](encounter.html): Identifier(s) by which this encounter is known\r\n* [EpisodeOfCare](episodeofcare.html): Business Identifier(s) relevant for this EpisodeOfCare\r\n* [FamilyMemberHistory](familymemberhistory.html): A search by a record identifier\r\n* [Goal](goal.html): External Ids for this goal\r\n* [ImagingStudy](imagingstudy.html): Identifiers for the Study, such as DICOM Study Instance UID\r\n* [Immunization](immunization.html): Business identifier\r\n* [List](list.html): Business identifier\r\n* [MedicationAdministration](medicationadministration.html): Return administrations with this external identifier\r\n* [MedicationDispense](medicationdispense.html): Returns dispenses with this external identifier\r\n* [MedicationRequest](medicationrequest.html): Return prescriptions with this external identifier\r\n* [MedicationUsage](medicationusage.html): Return statements with this external identifier\r\n* [NutritionOrder](nutritionorder.html): Return nutrition orders with this external identifier\r\n* [Observation](observation.html): The unique id for a particular observation\r\n* [Procedure](procedure.html): A unique identifier for a procedure\r\n* [RiskAssessment](riskassessment.html): Unique identifier for the assessment\r\n* [ServiceRequest](servicerequest.html): Identifiers assigned to this order\r\n* [SupplyDelivery](supplydelivery.html): External identifier\r\n* [SupplyRequest](supplyrequest.html): Business Identifier for SupplyRequest\r\n* [VisionPrescription](visionprescription.html): Return prescriptions with this external identifier\r\n", type="token" ) 4730 public static final String SP_IDENTIFIER = "identifier"; 4731 /** 4732 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 4733 * <p> 4734 * Description: <b>Multiple Resources: 4735 4736* [AllergyIntolerance](allergyintolerance.html): External ids for this item 4737* [CarePlan](careplan.html): External Ids for this plan 4738* [CareTeam](careteam.html): External Ids for this team 4739* [Composition](composition.html): Version-independent identifier for the Composition 4740* [Condition](condition.html): A unique identifier of the condition record 4741* [Consent](consent.html): Identifier for this record (external references) 4742* [DetectedIssue](detectedissue.html): Unique id for the detected issue 4743* [DeviceRequest](devicerequest.html): Business identifier for request/order 4744* [DiagnosticReport](diagnosticreport.html): An identifier for the report 4745* [DocumentManifest](documentmanifest.html): Unique Identifier for the set of documents 4746* [DocumentReference](documentreference.html): Identifier of the attachment binary 4747* [Encounter](encounter.html): Identifier(s) by which this encounter is known 4748* [EpisodeOfCare](episodeofcare.html): Business Identifier(s) relevant for this EpisodeOfCare 4749* [FamilyMemberHistory](familymemberhistory.html): A search by a record identifier 4750* [Goal](goal.html): External Ids for this goal 4751* [ImagingStudy](imagingstudy.html): Identifiers for the Study, such as DICOM Study Instance UID 4752* [Immunization](immunization.html): Business identifier 4753* [List](list.html): Business identifier 4754* [MedicationAdministration](medicationadministration.html): Return administrations with this external identifier 4755* [MedicationDispense](medicationdispense.html): Returns dispenses with this external identifier 4756* [MedicationRequest](medicationrequest.html): Return prescriptions with this external identifier 4757* [MedicationUsage](medicationusage.html): Return statements with this external identifier 4758* [NutritionOrder](nutritionorder.html): Return nutrition orders with this external identifier 4759* [Observation](observation.html): The unique id for a particular observation 4760* [Procedure](procedure.html): A unique identifier for a procedure 4761* [RiskAssessment](riskassessment.html): Unique identifier for the assessment 4762* [ServiceRequest](servicerequest.html): Identifiers assigned to this order 4763* [SupplyDelivery](supplydelivery.html): External identifier 4764* [SupplyRequest](supplyrequest.html): Business Identifier for SupplyRequest 4765* [VisionPrescription](visionprescription.html): Return prescriptions with this external identifier 4766</b><br> 4767 * Type: <b>token</b><br> 4768 * Path: <b>AllergyIntolerance.identifier | CarePlan.identifier | CareTeam.identifier | Composition.identifier | Condition.identifier | Consent.identifier | DetectedIssue.identifier | DeviceRequest.identifier | DiagnosticReport.identifier | DocumentManifest.masterIdentifier | DocumentManifest.identifier | DocumentReference.identifier | Encounter.identifier | EpisodeOfCare.identifier | FamilyMemberHistory.identifier | Goal.identifier | ImagingStudy.identifier | Immunization.identifier | List.identifier | MedicationAdministration.identifier | MedicationDispense.identifier | MedicationRequest.identifier | MedicationUsage.identifier | NutritionOrder.identifier | Observation.identifier | Procedure.identifier | RiskAssessment.identifier | ServiceRequest.identifier | SupplyDelivery.identifier | SupplyRequest.identifier | VisionPrescription.identifier</b><br> 4769 * </p> 4770 */ 4771 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 4772 4773 /** 4774 * Search parameter: <b>patient</b> 4775 * <p> 4776 * Description: <b>Multiple Resources: 4777 4778* [AllergyIntolerance](allergyintolerance.html): Who the sensitivity is for 4779* [CarePlan](careplan.html): Who the care plan is for 4780* [CareTeam](careteam.html): Who care team is for 4781* [ClinicalImpression](clinicalimpression.html): Patient assessed 4782* [Composition](composition.html): Who and/or what the composition is about 4783* [Condition](condition.html): Who has the condition? 4784* [Consent](consent.html): Who the consent applies to 4785* [DetectedIssue](detectedissue.html): Associated patient 4786* [DeviceRequest](devicerequest.html): Individual the service is ordered for 4787* [DeviceUsage](deviceusage.html): Search by patient who used / uses the device 4788* [DiagnosticReport](diagnosticreport.html): The subject of the report if a patient 4789* [DocumentManifest](documentmanifest.html): The subject of the set of documents 4790* [DocumentReference](documentreference.html): Who/what is the subject of the document 4791* [Encounter](encounter.html): The patient present at the encounter 4792* [EpisodeOfCare](episodeofcare.html): The patient who is the focus of this episode of care 4793* [FamilyMemberHistory](familymemberhistory.html): The identity of a subject to list family member history items for 4794* [Flag](flag.html): The identity of a subject to list flags for 4795* [Goal](goal.html): Who this goal is intended for 4796* [ImagingStudy](imagingstudy.html): Who the study is about 4797* [Immunization](immunization.html): The patient for the vaccination record 4798* [List](list.html): If all resources have the same subject 4799* [MedicationAdministration](medicationadministration.html): The identity of a patient to list administrations for 4800* [MedicationDispense](medicationdispense.html): The identity of a patient to list dispenses for 4801* [MedicationRequest](medicationrequest.html): Returns prescriptions for a specific patient 4802* [MedicationUsage](medicationusage.html): Returns statements for a specific patient. 4803* [NutritionOrder](nutritionorder.html): The identity of the individual or set of individuals who requires the diet, formula or nutritional supplement 4804* [Observation](observation.html): The subject that the observation is about (if patient) 4805* [Procedure](procedure.html): Search by subject - a patient 4806* [RiskAssessment](riskassessment.html): Who/what does assessment apply to? 4807* [ServiceRequest](servicerequest.html): Search by subject - a patient 4808* [SupplyDelivery](supplydelivery.html): Patient for whom the item is supplied 4809* [VisionPrescription](visionprescription.html): The identity of a patient to list dispenses for 4810</b><br> 4811 * Type: <b>reference</b><br> 4812 * Path: <b>AllergyIntolerance.patient | CarePlan.subject.where(resolve() is Patient) | CareTeam.subject.where(resolve() is Patient) | ClinicalImpression.subject.where(resolve() is Patient) | Composition.subject.where(resolve() is Patient) | Condition.subject.where(resolve() is Patient) | Consent.subject.where(resolve() is Patient) | DetectedIssue.subject | DeviceRequest.subject.where(resolve() is Patient) | DeviceUsage.patient | DiagnosticReport.subject.where(resolve() is Patient) | DocumentManifest.subject.where(resolve() is Patient) | DocumentReference.subject.where(resolve() is Patient) | Encounter.subject.where(resolve() is Patient) | EpisodeOfCare.patient | FamilyMemberHistory.patient | Flag.subject.where(resolve() is Patient) | Goal.subject.where(resolve() is Patient) | ImagingStudy.subject.where(resolve() is Patient) | Immunization.patient | List.subject.where(resolve() is Patient) | MedicationAdministration.subject.where(resolve() is Patient) | MedicationDispense.subject.where(resolve() is Patient) | MedicationRequest.subject.where(resolve() is Patient) | MedicationUsage.subject.where(resolve() is Patient) | NutritionOrder.subject.where(resolve() is Patient) | Observation.subject.where(resolve() is Patient) | Procedure.subject.where(resolve() is Patient) | RiskAssessment.subject.where(resolve() is Patient) | ServiceRequest.subject.where(resolve() is Patient) | SupplyDelivery.patient | VisionPrescription.patient</b><br> 4813 * </p> 4814 */ 4815 @SearchParamDefinition(name="patient", path="AllergyIntolerance.patient | CarePlan.subject.where(resolve() is Patient) | CareTeam.subject.where(resolve() is Patient) | ClinicalImpression.subject.where(resolve() is Patient) | Composition.subject.where(resolve() is Patient) | Condition.subject.where(resolve() is Patient) | Consent.subject.where(resolve() is Patient) | DetectedIssue.subject | DeviceRequest.subject.where(resolve() is Patient) | DeviceUsage.patient | DiagnosticReport.subject.where(resolve() is Patient) | DocumentManifest.subject.where(resolve() is Patient) | DocumentReference.subject.where(resolve() is Patient) | Encounter.subject.where(resolve() is Patient) | EpisodeOfCare.patient | FamilyMemberHistory.patient | Flag.subject.where(resolve() is Patient) | Goal.subject.where(resolve() is Patient) | ImagingStudy.subject.where(resolve() is Patient) | Immunization.patient | List.subject.where(resolve() is Patient) | MedicationAdministration.subject.where(resolve() is Patient) | MedicationDispense.subject.where(resolve() is Patient) | MedicationRequest.subject.where(resolve() is Patient) | MedicationUsage.subject.where(resolve() is Patient) | NutritionOrder.subject.where(resolve() is Patient) | Observation.subject.where(resolve() is Patient) | Procedure.subject.where(resolve() is Patient) | RiskAssessment.subject.where(resolve() is Patient) | ServiceRequest.subject.where(resolve() is Patient) | SupplyDelivery.patient | VisionPrescription.patient", description="Multiple Resources: \r\n\r\n* [AllergyIntolerance](allergyintolerance.html): Who the sensitivity is for\r\n* [CarePlan](careplan.html): Who the care plan is for\r\n* [CareTeam](careteam.html): Who care team is for\r\n* [ClinicalImpression](clinicalimpression.html): Patient assessed\r\n* [Composition](composition.html): Who and/or what the composition is about\r\n* [Condition](condition.html): Who has the condition?\r\n* [Consent](consent.html): Who the consent applies to\r\n* [DetectedIssue](detectedissue.html): Associated patient\r\n* [DeviceRequest](devicerequest.html): Individual the service is ordered for\r\n* [DeviceUsage](deviceusage.html): Search by patient who used / uses the device\r\n* [DiagnosticReport](diagnosticreport.html): The subject of the report if a patient\r\n* [DocumentManifest](documentmanifest.html): The subject of the set of documents\r\n* [DocumentReference](documentreference.html): Who/what is the subject of the document\r\n* [Encounter](encounter.html): The patient present at the encounter\r\n* [EpisodeOfCare](episodeofcare.html): The patient who is the focus of this episode of care\r\n* [FamilyMemberHistory](familymemberhistory.html): The identity of a subject to list family member history items for\r\n* [Flag](flag.html): The identity of a subject to list flags for\r\n* [Goal](goal.html): Who this goal is intended for\r\n* [ImagingStudy](imagingstudy.html): Who the study is about\r\n* [Immunization](immunization.html): The patient for the vaccination record\r\n* [List](list.html): If all resources have the same subject\r\n* [MedicationAdministration](medicationadministration.html): The identity of a patient to list administrations for\r\n* [MedicationDispense](medicationdispense.html): The identity of a patient to list dispenses for\r\n* [MedicationRequest](medicationrequest.html): Returns prescriptions for a specific patient\r\n* [MedicationUsage](medicationusage.html): Returns statements for a specific patient.\r\n* [NutritionOrder](nutritionorder.html): The identity of the individual or set of individuals who requires the diet, formula or nutritional supplement\r\n* [Observation](observation.html): The subject that the observation is about (if patient)\r\n* [Procedure](procedure.html): Search by subject - a patient\r\n* [RiskAssessment](riskassessment.html): Who/what does assessment apply to?\r\n* [ServiceRequest](servicerequest.html): Search by subject - a patient\r\n* [SupplyDelivery](supplydelivery.html): Patient for whom the item is supplied\r\n* [VisionPrescription](visionprescription.html): The identity of a patient to list dispenses for\r\n", type="reference", target={BiologicallyDerivedProduct.class, Device.class, Group.class, Location.class, Medication.class, NutritionProduct.class, Organization.class, Patient.class, Practitioner.class, Procedure.class, Substance.class } ) 4816 public static final String SP_PATIENT = "patient"; 4817 /** 4818 * <b>Fluent Client</b> search parameter constant for <b>patient</b> 4819 * <p> 4820 * Description: <b>Multiple Resources: 4821 4822* [AllergyIntolerance](allergyintolerance.html): Who the sensitivity is for 4823* [CarePlan](careplan.html): Who the care plan is for 4824* [CareTeam](careteam.html): Who care team is for 4825* [ClinicalImpression](clinicalimpression.html): Patient assessed 4826* [Composition](composition.html): Who and/or what the composition is about 4827* [Condition](condition.html): Who has the condition? 4828* [Consent](consent.html): Who the consent applies to 4829* [DetectedIssue](detectedissue.html): Associated patient 4830* [DeviceRequest](devicerequest.html): Individual the service is ordered for 4831* [DeviceUsage](deviceusage.html): Search by patient who used / uses the device 4832* [DiagnosticReport](diagnosticreport.html): The subject of the report if a patient 4833* [DocumentManifest](documentmanifest.html): The subject of the set of documents 4834* [DocumentReference](documentreference.html): Who/what is the subject of the document 4835* [Encounter](encounter.html): The patient present at the encounter 4836* [EpisodeOfCare](episodeofcare.html): The patient who is the focus of this episode of care 4837* [FamilyMemberHistory](familymemberhistory.html): The identity of a subject to list family member history items for 4838* [Flag](flag.html): The identity of a subject to list flags for 4839* [Goal](goal.html): Who this goal is intended for 4840* [ImagingStudy](imagingstudy.html): Who the study is about 4841* [Immunization](immunization.html): The patient for the vaccination record 4842* [List](list.html): If all resources have the same subject 4843* [MedicationAdministration](medicationadministration.html): The identity of a patient to list administrations for 4844* [MedicationDispense](medicationdispense.html): The identity of a patient to list dispenses for 4845* [MedicationRequest](medicationrequest.html): Returns prescriptions for a specific patient 4846* [MedicationUsage](medicationusage.html): Returns statements for a specific patient. 4847* [NutritionOrder](nutritionorder.html): The identity of the individual or set of individuals who requires the diet, formula or nutritional supplement 4848* [Observation](observation.html): The subject that the observation is about (if patient) 4849* [Procedure](procedure.html): Search by subject - a patient 4850* [RiskAssessment](riskassessment.html): Who/what does assessment apply to? 4851* [ServiceRequest](servicerequest.html): Search by subject - a patient 4852* [SupplyDelivery](supplydelivery.html): Patient for whom the item is supplied 4853* [VisionPrescription](visionprescription.html): The identity of a patient to list dispenses for 4854</b><br> 4855 * Type: <b>reference</b><br> 4856 * Path: <b>AllergyIntolerance.patient | CarePlan.subject.where(resolve() is Patient) | CareTeam.subject.where(resolve() is Patient) | ClinicalImpression.subject.where(resolve() is Patient) | Composition.subject.where(resolve() is Patient) | Condition.subject.where(resolve() is Patient) | Consent.subject.where(resolve() is Patient) | DetectedIssue.subject | DeviceRequest.subject.where(resolve() is Patient) | DeviceUsage.patient | DiagnosticReport.subject.where(resolve() is Patient) | DocumentManifest.subject.where(resolve() is Patient) | DocumentReference.subject.where(resolve() is Patient) | Encounter.subject.where(resolve() is Patient) | EpisodeOfCare.patient | FamilyMemberHistory.patient | Flag.subject.where(resolve() is Patient) | Goal.subject.where(resolve() is Patient) | ImagingStudy.subject.where(resolve() is Patient) | Immunization.patient | List.subject.where(resolve() is Patient) | MedicationAdministration.subject.where(resolve() is Patient) | MedicationDispense.subject.where(resolve() is Patient) | MedicationRequest.subject.where(resolve() is Patient) | MedicationUsage.subject.where(resolve() is Patient) | NutritionOrder.subject.where(resolve() is Patient) | Observation.subject.where(resolve() is Patient) | Procedure.subject.where(resolve() is Patient) | RiskAssessment.subject.where(resolve() is Patient) | ServiceRequest.subject.where(resolve() is Patient) | SupplyDelivery.patient | VisionPrescription.patient</b><br> 4857 * </p> 4858 */ 4859 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT); 4860 4861/** 4862 * Constant for fluent queries to be used to add include statements. Specifies 4863 * the path value of "<b>Observation:patient</b>". 4864 */ 4865 public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("Observation:patient").toLocked(); 4866 4867 4868} 4869