
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 Tue, Dec 28, 2021 07:16+1100 for FHIR v5.0.0-snapshot1 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 * Risk of harmful or undesirable, physiological response which is unique to an individual and associated with exposure to a substance. 052 */ 053@ResourceDef(name="AllergyIntolerance", profile="http://hl7.org/fhir/StructureDefinition/AllergyIntolerance") 054public class AllergyIntolerance extends DomainResource { 055 056 public enum AllergyIntoleranceCategory { 057 /** 058 * Any substance consumed to provide nutritional support for the body. 059 */ 060 FOOD, 061 /** 062 * Substances administered to achieve a physiological effect. 063 */ 064 MEDICATION, 065 /** 066 * Any substances that are encountered in the environment, including any substance not already classified as food, medication, or biologic. 067 */ 068 ENVIRONMENT, 069 /** 070 * A preparation that is synthesized from living organisms or their products, especially a human or animal protein, such as a hormone or antitoxin, that is used as a diagnostic, preventive, or therapeutic agent. Examples of biologic medications include: vaccines; allergenic extracts, which are used for both diagnosis and treatment (for example, allergy shots); gene therapies; cellular therapies. There are other biologic products, such as tissues, which are not typically associated with allergies. 071 */ 072 BIOLOGIC, 073 /** 074 * added to help the parsers with the generic types 075 */ 076 NULL; 077 public static AllergyIntoleranceCategory fromCode(String codeString) throws FHIRException { 078 if (codeString == null || "".equals(codeString)) 079 return null; 080 if ("food".equals(codeString)) 081 return FOOD; 082 if ("medication".equals(codeString)) 083 return MEDICATION; 084 if ("environment".equals(codeString)) 085 return ENVIRONMENT; 086 if ("biologic".equals(codeString)) 087 return BIOLOGIC; 088 if (Configuration.isAcceptInvalidEnums()) 089 return null; 090 else 091 throw new FHIRException("Unknown AllergyIntoleranceCategory code '"+codeString+"'"); 092 } 093 public String toCode() { 094 switch (this) { 095 case FOOD: return "food"; 096 case MEDICATION: return "medication"; 097 case ENVIRONMENT: return "environment"; 098 case BIOLOGIC: return "biologic"; 099 default: return "?"; 100 } 101 } 102 public String getSystem() { 103 switch (this) { 104 case FOOD: return "http://hl7.org/fhir/allergy-intolerance-category"; 105 case MEDICATION: return "http://hl7.org/fhir/allergy-intolerance-category"; 106 case ENVIRONMENT: return "http://hl7.org/fhir/allergy-intolerance-category"; 107 case BIOLOGIC: return "http://hl7.org/fhir/allergy-intolerance-category"; 108 default: return "?"; 109 } 110 } 111 public String getDefinition() { 112 switch (this) { 113 case FOOD: return "Any substance consumed to provide nutritional support for the body."; 114 case MEDICATION: return "Substances administered to achieve a physiological effect."; 115 case ENVIRONMENT: return "Any substances that are encountered in the environment, including any substance not already classified as food, medication, or biologic."; 116 case BIOLOGIC: return "A preparation that is synthesized from living organisms or their products, especially a human or animal protein, such as a hormone or antitoxin, that is used as a diagnostic, preventive, or therapeutic agent. Examples of biologic medications include: vaccines; allergenic extracts, which are used for both diagnosis and treatment (for example, allergy shots); gene therapies; cellular therapies. There are other biologic products, such as tissues, which are not typically associated with allergies."; 117 default: return "?"; 118 } 119 } 120 public String getDisplay() { 121 switch (this) { 122 case FOOD: return "Food"; 123 case MEDICATION: return "Medication"; 124 case ENVIRONMENT: return "Environment"; 125 case BIOLOGIC: return "Biologic"; 126 default: return "?"; 127 } 128 } 129 } 130 131 public static class AllergyIntoleranceCategoryEnumFactory implements EnumFactory<AllergyIntoleranceCategory> { 132 public AllergyIntoleranceCategory fromCode(String codeString) throws IllegalArgumentException { 133 if (codeString == null || "".equals(codeString)) 134 if (codeString == null || "".equals(codeString)) 135 return null; 136 if ("food".equals(codeString)) 137 return AllergyIntoleranceCategory.FOOD; 138 if ("medication".equals(codeString)) 139 return AllergyIntoleranceCategory.MEDICATION; 140 if ("environment".equals(codeString)) 141 return AllergyIntoleranceCategory.ENVIRONMENT; 142 if ("biologic".equals(codeString)) 143 return AllergyIntoleranceCategory.BIOLOGIC; 144 throw new IllegalArgumentException("Unknown AllergyIntoleranceCategory code '"+codeString+"'"); 145 } 146 public Enumeration<AllergyIntoleranceCategory> fromType(Base code) throws FHIRException { 147 if (code == null) 148 return null; 149 if (code.isEmpty()) 150 return new Enumeration<AllergyIntoleranceCategory>(this); 151 String codeString = ((PrimitiveType) code).asStringValue(); 152 if (codeString == null || "".equals(codeString)) 153 return null; 154 if ("food".equals(codeString)) 155 return new Enumeration<AllergyIntoleranceCategory>(this, AllergyIntoleranceCategory.FOOD); 156 if ("medication".equals(codeString)) 157 return new Enumeration<AllergyIntoleranceCategory>(this, AllergyIntoleranceCategory.MEDICATION); 158 if ("environment".equals(codeString)) 159 return new Enumeration<AllergyIntoleranceCategory>(this, AllergyIntoleranceCategory.ENVIRONMENT); 160 if ("biologic".equals(codeString)) 161 return new Enumeration<AllergyIntoleranceCategory>(this, AllergyIntoleranceCategory.BIOLOGIC); 162 throw new FHIRException("Unknown AllergyIntoleranceCategory code '"+codeString+"'"); 163 } 164 public String toCode(AllergyIntoleranceCategory code) { 165 if (code == AllergyIntoleranceCategory.FOOD) 166 return "food"; 167 if (code == AllergyIntoleranceCategory.MEDICATION) 168 return "medication"; 169 if (code == AllergyIntoleranceCategory.ENVIRONMENT) 170 return "environment"; 171 if (code == AllergyIntoleranceCategory.BIOLOGIC) 172 return "biologic"; 173 return "?"; 174 } 175 public String toSystem(AllergyIntoleranceCategory code) { 176 return code.getSystem(); 177 } 178 } 179 180 public enum AllergyIntoleranceCriticality { 181 /** 182 * Worst case result of a future exposure is not assessed to be life-threatening or having high potential for organ system failure. 183 */ 184 LOW, 185 /** 186 * Worst case result of a future exposure is assessed to be life-threatening or having high potential for organ system failure. 187 */ 188 HIGH, 189 /** 190 * Unable to assess the worst case result of a future exposure. 191 */ 192 UNABLETOASSESS, 193 /** 194 * added to help the parsers with the generic types 195 */ 196 NULL; 197 public static AllergyIntoleranceCriticality fromCode(String codeString) throws FHIRException { 198 if (codeString == null || "".equals(codeString)) 199 return null; 200 if ("low".equals(codeString)) 201 return LOW; 202 if ("high".equals(codeString)) 203 return HIGH; 204 if ("unable-to-assess".equals(codeString)) 205 return UNABLETOASSESS; 206 if (Configuration.isAcceptInvalidEnums()) 207 return null; 208 else 209 throw new FHIRException("Unknown AllergyIntoleranceCriticality code '"+codeString+"'"); 210 } 211 public String toCode() { 212 switch (this) { 213 case LOW: return "low"; 214 case HIGH: return "high"; 215 case UNABLETOASSESS: return "unable-to-assess"; 216 default: return "?"; 217 } 218 } 219 public String getSystem() { 220 switch (this) { 221 case LOW: return "http://hl7.org/fhir/allergy-intolerance-criticality"; 222 case HIGH: return "http://hl7.org/fhir/allergy-intolerance-criticality"; 223 case UNABLETOASSESS: return "http://hl7.org/fhir/allergy-intolerance-criticality"; 224 default: return "?"; 225 } 226 } 227 public String getDefinition() { 228 switch (this) { 229 case LOW: return "Worst case result of a future exposure is not assessed to be life-threatening or having high potential for organ system failure."; 230 case HIGH: return "Worst case result of a future exposure is assessed to be life-threatening or having high potential for organ system failure."; 231 case UNABLETOASSESS: return "Unable to assess the worst case result of a future exposure."; 232 default: return "?"; 233 } 234 } 235 public String getDisplay() { 236 switch (this) { 237 case LOW: return "Low Risk"; 238 case HIGH: return "High Risk"; 239 case UNABLETOASSESS: return "Unable to Assess Risk"; 240 default: return "?"; 241 } 242 } 243 } 244 245 public static class AllergyIntoleranceCriticalityEnumFactory implements EnumFactory<AllergyIntoleranceCriticality> { 246 public AllergyIntoleranceCriticality fromCode(String codeString) throws IllegalArgumentException { 247 if (codeString == null || "".equals(codeString)) 248 if (codeString == null || "".equals(codeString)) 249 return null; 250 if ("low".equals(codeString)) 251 return AllergyIntoleranceCriticality.LOW; 252 if ("high".equals(codeString)) 253 return AllergyIntoleranceCriticality.HIGH; 254 if ("unable-to-assess".equals(codeString)) 255 return AllergyIntoleranceCriticality.UNABLETOASSESS; 256 throw new IllegalArgumentException("Unknown AllergyIntoleranceCriticality code '"+codeString+"'"); 257 } 258 public Enumeration<AllergyIntoleranceCriticality> fromType(Base code) throws FHIRException { 259 if (code == null) 260 return null; 261 if (code.isEmpty()) 262 return new Enumeration<AllergyIntoleranceCriticality>(this); 263 String codeString = ((PrimitiveType) code).asStringValue(); 264 if (codeString == null || "".equals(codeString)) 265 return null; 266 if ("low".equals(codeString)) 267 return new Enumeration<AllergyIntoleranceCriticality>(this, AllergyIntoleranceCriticality.LOW); 268 if ("high".equals(codeString)) 269 return new Enumeration<AllergyIntoleranceCriticality>(this, AllergyIntoleranceCriticality.HIGH); 270 if ("unable-to-assess".equals(codeString)) 271 return new Enumeration<AllergyIntoleranceCriticality>(this, AllergyIntoleranceCriticality.UNABLETOASSESS); 272 throw new FHIRException("Unknown AllergyIntoleranceCriticality code '"+codeString+"'"); 273 } 274 public String toCode(AllergyIntoleranceCriticality code) { 275 if (code == AllergyIntoleranceCriticality.LOW) 276 return "low"; 277 if (code == AllergyIntoleranceCriticality.HIGH) 278 return "high"; 279 if (code == AllergyIntoleranceCriticality.UNABLETOASSESS) 280 return "unable-to-assess"; 281 return "?"; 282 } 283 public String toSystem(AllergyIntoleranceCriticality code) { 284 return code.getSystem(); 285 } 286 } 287 288 public enum AllergyIntoleranceSeverity { 289 /** 290 * Causes mild physiological effects. 291 */ 292 MILD, 293 /** 294 * Causes moderate physiological effects. 295 */ 296 MODERATE, 297 /** 298 * Causes severe physiological effects. 299 */ 300 SEVERE, 301 /** 302 * added to help the parsers with the generic types 303 */ 304 NULL; 305 public static AllergyIntoleranceSeverity fromCode(String codeString) throws FHIRException { 306 if (codeString == null || "".equals(codeString)) 307 return null; 308 if ("mild".equals(codeString)) 309 return MILD; 310 if ("moderate".equals(codeString)) 311 return MODERATE; 312 if ("severe".equals(codeString)) 313 return SEVERE; 314 if (Configuration.isAcceptInvalidEnums()) 315 return null; 316 else 317 throw new FHIRException("Unknown AllergyIntoleranceSeverity code '"+codeString+"'"); 318 } 319 public String toCode() { 320 switch (this) { 321 case MILD: return "mild"; 322 case MODERATE: return "moderate"; 323 case SEVERE: return "severe"; 324 default: return "?"; 325 } 326 } 327 public String getSystem() { 328 switch (this) { 329 case MILD: return "http://hl7.org/fhir/reaction-event-severity"; 330 case MODERATE: return "http://hl7.org/fhir/reaction-event-severity"; 331 case SEVERE: return "http://hl7.org/fhir/reaction-event-severity"; 332 default: return "?"; 333 } 334 } 335 public String getDefinition() { 336 switch (this) { 337 case MILD: return "Causes mild physiological effects."; 338 case MODERATE: return "Causes moderate physiological effects."; 339 case SEVERE: return "Causes severe physiological effects."; 340 default: return "?"; 341 } 342 } 343 public String getDisplay() { 344 switch (this) { 345 case MILD: return "Mild"; 346 case MODERATE: return "Moderate"; 347 case SEVERE: return "Severe"; 348 default: return "?"; 349 } 350 } 351 } 352 353 public static class AllergyIntoleranceSeverityEnumFactory implements EnumFactory<AllergyIntoleranceSeverity> { 354 public AllergyIntoleranceSeverity fromCode(String codeString) throws IllegalArgumentException { 355 if (codeString == null || "".equals(codeString)) 356 if (codeString == null || "".equals(codeString)) 357 return null; 358 if ("mild".equals(codeString)) 359 return AllergyIntoleranceSeverity.MILD; 360 if ("moderate".equals(codeString)) 361 return AllergyIntoleranceSeverity.MODERATE; 362 if ("severe".equals(codeString)) 363 return AllergyIntoleranceSeverity.SEVERE; 364 throw new IllegalArgumentException("Unknown AllergyIntoleranceSeverity code '"+codeString+"'"); 365 } 366 public Enumeration<AllergyIntoleranceSeverity> fromType(Base code) throws FHIRException { 367 if (code == null) 368 return null; 369 if (code.isEmpty()) 370 return new Enumeration<AllergyIntoleranceSeverity>(this); 371 String codeString = ((PrimitiveType) code).asStringValue(); 372 if (codeString == null || "".equals(codeString)) 373 return null; 374 if ("mild".equals(codeString)) 375 return new Enumeration<AllergyIntoleranceSeverity>(this, AllergyIntoleranceSeverity.MILD); 376 if ("moderate".equals(codeString)) 377 return new Enumeration<AllergyIntoleranceSeverity>(this, AllergyIntoleranceSeverity.MODERATE); 378 if ("severe".equals(codeString)) 379 return new Enumeration<AllergyIntoleranceSeverity>(this, AllergyIntoleranceSeverity.SEVERE); 380 throw new FHIRException("Unknown AllergyIntoleranceSeverity code '"+codeString+"'"); 381 } 382 public String toCode(AllergyIntoleranceSeverity code) { 383 if (code == AllergyIntoleranceSeverity.MILD) 384 return "mild"; 385 if (code == AllergyIntoleranceSeverity.MODERATE) 386 return "moderate"; 387 if (code == AllergyIntoleranceSeverity.SEVERE) 388 return "severe"; 389 return "?"; 390 } 391 public String toSystem(AllergyIntoleranceSeverity code) { 392 return code.getSystem(); 393 } 394 } 395 396 public enum AllergyIntoleranceType { 397 /** 398 * A propensity for hypersensitive reaction(s) to a substance. These reactions are most typically type I hypersensitivity, plus other \"allergy-like\" reactions, including pseudoallergy. 399 */ 400 ALLERGY, 401 /** 402 * A propensity for adverse reactions to a substance that is not judged to be allergic or \"allergy-like\". These reactions are typically (but not necessarily) non-immune. They are to some degree idiosyncratic and/or patient-specific (i.e. are not a reaction that is expected to occur with most or all patients given similar circumstances). 403 */ 404 INTOLERANCE, 405 /** 406 * added to help the parsers with the generic types 407 */ 408 NULL; 409 public static AllergyIntoleranceType fromCode(String codeString) throws FHIRException { 410 if (codeString == null || "".equals(codeString)) 411 return null; 412 if ("allergy".equals(codeString)) 413 return ALLERGY; 414 if ("intolerance".equals(codeString)) 415 return INTOLERANCE; 416 if (Configuration.isAcceptInvalidEnums()) 417 return null; 418 else 419 throw new FHIRException("Unknown AllergyIntoleranceType code '"+codeString+"'"); 420 } 421 public String toCode() { 422 switch (this) { 423 case ALLERGY: return "allergy"; 424 case INTOLERANCE: return "intolerance"; 425 default: return "?"; 426 } 427 } 428 public String getSystem() { 429 switch (this) { 430 case ALLERGY: return "http://hl7.org/fhir/allergy-intolerance-type"; 431 case INTOLERANCE: return "http://hl7.org/fhir/allergy-intolerance-type"; 432 default: return "?"; 433 } 434 } 435 public String getDefinition() { 436 switch (this) { 437 case ALLERGY: return "A propensity for hypersensitive reaction(s) to a substance. These reactions are most typically type I hypersensitivity, plus other \"allergy-like\" reactions, including pseudoallergy."; 438 case INTOLERANCE: return "A propensity for adverse reactions to a substance that is not judged to be allergic or \"allergy-like\". These reactions are typically (but not necessarily) non-immune. They are to some degree idiosyncratic and/or patient-specific (i.e. are not a reaction that is expected to occur with most or all patients given similar circumstances)."; 439 default: return "?"; 440 } 441 } 442 public String getDisplay() { 443 switch (this) { 444 case ALLERGY: return "Allergy"; 445 case INTOLERANCE: return "Intolerance"; 446 default: return "?"; 447 } 448 } 449 } 450 451 public static class AllergyIntoleranceTypeEnumFactory implements EnumFactory<AllergyIntoleranceType> { 452 public AllergyIntoleranceType fromCode(String codeString) throws IllegalArgumentException { 453 if (codeString == null || "".equals(codeString)) 454 if (codeString == null || "".equals(codeString)) 455 return null; 456 if ("allergy".equals(codeString)) 457 return AllergyIntoleranceType.ALLERGY; 458 if ("intolerance".equals(codeString)) 459 return AllergyIntoleranceType.INTOLERANCE; 460 throw new IllegalArgumentException("Unknown AllergyIntoleranceType code '"+codeString+"'"); 461 } 462 public Enumeration<AllergyIntoleranceType> fromType(Base code) throws FHIRException { 463 if (code == null) 464 return null; 465 if (code.isEmpty()) 466 return new Enumeration<AllergyIntoleranceType>(this); 467 String codeString = ((PrimitiveType) code).asStringValue(); 468 if (codeString == null || "".equals(codeString)) 469 return null; 470 if ("allergy".equals(codeString)) 471 return new Enumeration<AllergyIntoleranceType>(this, AllergyIntoleranceType.ALLERGY); 472 if ("intolerance".equals(codeString)) 473 return new Enumeration<AllergyIntoleranceType>(this, AllergyIntoleranceType.INTOLERANCE); 474 throw new FHIRException("Unknown AllergyIntoleranceType code '"+codeString+"'"); 475 } 476 public String toCode(AllergyIntoleranceType code) { 477 if (code == AllergyIntoleranceType.ALLERGY) 478 return "allergy"; 479 if (code == AllergyIntoleranceType.INTOLERANCE) 480 return "intolerance"; 481 return "?"; 482 } 483 public String toSystem(AllergyIntoleranceType code) { 484 return code.getSystem(); 485 } 486 } 487 488 @Block() 489 public static class AllergyIntoleranceReactionComponent extends BackboneElement implements IBaseBackboneElement { 490 /** 491 * Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance. 492 */ 493 @Child(name = "substance", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 494 @Description(shortDefinition="Specific substance or pharmaceutical product considered to be responsible for event", formalDefinition="Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance." ) 495 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/substance-code") 496 protected CodeableConcept substance; 497 498 /** 499 * Clinical symptoms and/or signs that are observed or associated with the adverse reaction event. 500 */ 501 @Child(name = "manifestation", type = {CodeableReference.class}, order=2, min=1, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 502 @Description(shortDefinition="Clinical symptoms/signs associated with the Event", formalDefinition="Clinical symptoms and/or signs that are observed or associated with the adverse reaction event." ) 503 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/clinical-findings") 504 protected List<CodeableReference> manifestation; 505 506 /** 507 * Text description about the reaction as a whole, including details of the manifestation if required. 508 */ 509 @Child(name = "description", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false) 510 @Description(shortDefinition="Description of the event as a whole", formalDefinition="Text description about the reaction as a whole, including details of the manifestation if required." ) 511 protected StringType description; 512 513 /** 514 * Record of the date and/or time of the onset of the Reaction. 515 */ 516 @Child(name = "onset", type = {DateTimeType.class}, order=4, min=0, max=1, modifier=false, summary=false) 517 @Description(shortDefinition="Date(/time) when manifestations showed", formalDefinition="Record of the date and/or time of the onset of the Reaction." ) 518 protected DateTimeType onset; 519 520 /** 521 * Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations. 522 */ 523 @Child(name = "severity", type = {CodeType.class}, order=5, min=0, max=1, modifier=false, summary=false) 524 @Description(shortDefinition="mild | moderate | severe (of event as a whole)", formalDefinition="Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations." ) 525 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/reaction-event-severity") 526 protected Enumeration<AllergyIntoleranceSeverity> severity; 527 528 /** 529 * Identification of the route by which the subject was exposed to the substance. 530 */ 531 @Child(name = "exposureRoute", type = {CodeableConcept.class}, order=6, min=0, max=1, modifier=false, summary=false) 532 @Description(shortDefinition="How the subject was exposed to the substance", formalDefinition="Identification of the route by which the subject was exposed to the substance." ) 533 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/route-codes") 534 protected CodeableConcept exposureRoute; 535 536 /** 537 * Additional text about the adverse reaction event not captured in other fields. 538 */ 539 @Child(name = "note", type = {Annotation.class}, order=7, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 540 @Description(shortDefinition="Text about event not captured in other fields", formalDefinition="Additional text about the adverse reaction event not captured in other fields." ) 541 protected List<Annotation> note; 542 543 private static final long serialVersionUID = 1007789961L; 544 545 /** 546 * Constructor 547 */ 548 public AllergyIntoleranceReactionComponent() { 549 super(); 550 } 551 552 /** 553 * Constructor 554 */ 555 public AllergyIntoleranceReactionComponent(CodeableReference manifestation) { 556 super(); 557 this.addManifestation(manifestation); 558 } 559 560 /** 561 * @return {@link #substance} (Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.) 562 */ 563 public CodeableConcept getSubstance() { 564 if (this.substance == null) 565 if (Configuration.errorOnAutoCreate()) 566 throw new Error("Attempt to auto-create AllergyIntoleranceReactionComponent.substance"); 567 else if (Configuration.doAutoCreate()) 568 this.substance = new CodeableConcept(); // cc 569 return this.substance; 570 } 571 572 public boolean hasSubstance() { 573 return this.substance != null && !this.substance.isEmpty(); 574 } 575 576 /** 577 * @param value {@link #substance} (Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.) 578 */ 579 public AllergyIntoleranceReactionComponent setSubstance(CodeableConcept value) { 580 this.substance = value; 581 return this; 582 } 583 584 /** 585 * @return {@link #manifestation} (Clinical symptoms and/or signs that are observed or associated with the adverse reaction event.) 586 */ 587 public List<CodeableReference> getManifestation() { 588 if (this.manifestation == null) 589 this.manifestation = new ArrayList<CodeableReference>(); 590 return this.manifestation; 591 } 592 593 /** 594 * @return Returns a reference to <code>this</code> for easy method chaining 595 */ 596 public AllergyIntoleranceReactionComponent setManifestation(List<CodeableReference> theManifestation) { 597 this.manifestation = theManifestation; 598 return this; 599 } 600 601 public boolean hasManifestation() { 602 if (this.manifestation == null) 603 return false; 604 for (CodeableReference item : this.manifestation) 605 if (!item.isEmpty()) 606 return true; 607 return false; 608 } 609 610 public CodeableReference addManifestation() { //3 611 CodeableReference t = new CodeableReference(); 612 if (this.manifestation == null) 613 this.manifestation = new ArrayList<CodeableReference>(); 614 this.manifestation.add(t); 615 return t; 616 } 617 618 public AllergyIntoleranceReactionComponent addManifestation(CodeableReference t) { //3 619 if (t == null) 620 return this; 621 if (this.manifestation == null) 622 this.manifestation = new ArrayList<CodeableReference>(); 623 this.manifestation.add(t); 624 return this; 625 } 626 627 /** 628 * @return The first repetition of repeating field {@link #manifestation}, creating it if it does not already exist {3} 629 */ 630 public CodeableReference getManifestationFirstRep() { 631 if (getManifestation().isEmpty()) { 632 addManifestation(); 633 } 634 return getManifestation().get(0); 635 } 636 637 /** 638 * @return {@link #description} (Text description about the reaction as a whole, including details of the manifestation if required.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 639 */ 640 public StringType getDescriptionElement() { 641 if (this.description == null) 642 if (Configuration.errorOnAutoCreate()) 643 throw new Error("Attempt to auto-create AllergyIntoleranceReactionComponent.description"); 644 else if (Configuration.doAutoCreate()) 645 this.description = new StringType(); // bb 646 return this.description; 647 } 648 649 public boolean hasDescriptionElement() { 650 return this.description != null && !this.description.isEmpty(); 651 } 652 653 public boolean hasDescription() { 654 return this.description != null && !this.description.isEmpty(); 655 } 656 657 /** 658 * @param value {@link #description} (Text description about the reaction as a whole, including details of the manifestation if required.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 659 */ 660 public AllergyIntoleranceReactionComponent setDescriptionElement(StringType value) { 661 this.description = value; 662 return this; 663 } 664 665 /** 666 * @return Text description about the reaction as a whole, including details of the manifestation if required. 667 */ 668 public String getDescription() { 669 return this.description == null ? null : this.description.getValue(); 670 } 671 672 /** 673 * @param value Text description about the reaction as a whole, including details of the manifestation if required. 674 */ 675 public AllergyIntoleranceReactionComponent setDescription(String value) { 676 if (Utilities.noString(value)) 677 this.description = null; 678 else { 679 if (this.description == null) 680 this.description = new StringType(); 681 this.description.setValue(value); 682 } 683 return this; 684 } 685 686 /** 687 * @return {@link #onset} (Record of the date and/or time of the onset of the Reaction.). This is the underlying object with id, value and extensions. The accessor "getOnset" gives direct access to the value 688 */ 689 public DateTimeType getOnsetElement() { 690 if (this.onset == null) 691 if (Configuration.errorOnAutoCreate()) 692 throw new Error("Attempt to auto-create AllergyIntoleranceReactionComponent.onset"); 693 else if (Configuration.doAutoCreate()) 694 this.onset = new DateTimeType(); // bb 695 return this.onset; 696 } 697 698 public boolean hasOnsetElement() { 699 return this.onset != null && !this.onset.isEmpty(); 700 } 701 702 public boolean hasOnset() { 703 return this.onset != null && !this.onset.isEmpty(); 704 } 705 706 /** 707 * @param value {@link #onset} (Record of the date and/or time of the onset of the Reaction.). This is the underlying object with id, value and extensions. The accessor "getOnset" gives direct access to the value 708 */ 709 public AllergyIntoleranceReactionComponent setOnsetElement(DateTimeType value) { 710 this.onset = value; 711 return this; 712 } 713 714 /** 715 * @return Record of the date and/or time of the onset of the Reaction. 716 */ 717 public Date getOnset() { 718 return this.onset == null ? null : this.onset.getValue(); 719 } 720 721 /** 722 * @param value Record of the date and/or time of the onset of the Reaction. 723 */ 724 public AllergyIntoleranceReactionComponent setOnset(Date value) { 725 if (value == null) 726 this.onset = null; 727 else { 728 if (this.onset == null) 729 this.onset = new DateTimeType(); 730 this.onset.setValue(value); 731 } 732 return this; 733 } 734 735 /** 736 * @return {@link #severity} (Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations.). This is the underlying object with id, value and extensions. The accessor "getSeverity" gives direct access to the value 737 */ 738 public Enumeration<AllergyIntoleranceSeverity> getSeverityElement() { 739 if (this.severity == null) 740 if (Configuration.errorOnAutoCreate()) 741 throw new Error("Attempt to auto-create AllergyIntoleranceReactionComponent.severity"); 742 else if (Configuration.doAutoCreate()) 743 this.severity = new Enumeration<AllergyIntoleranceSeverity>(new AllergyIntoleranceSeverityEnumFactory()); // bb 744 return this.severity; 745 } 746 747 public boolean hasSeverityElement() { 748 return this.severity != null && !this.severity.isEmpty(); 749 } 750 751 public boolean hasSeverity() { 752 return this.severity != null && !this.severity.isEmpty(); 753 } 754 755 /** 756 * @param value {@link #severity} (Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations.). This is the underlying object with id, value and extensions. The accessor "getSeverity" gives direct access to the value 757 */ 758 public AllergyIntoleranceReactionComponent setSeverityElement(Enumeration<AllergyIntoleranceSeverity> value) { 759 this.severity = value; 760 return this; 761 } 762 763 /** 764 * @return Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations. 765 */ 766 public AllergyIntoleranceSeverity getSeverity() { 767 return this.severity == null ? null : this.severity.getValue(); 768 } 769 770 /** 771 * @param value Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations. 772 */ 773 public AllergyIntoleranceReactionComponent setSeverity(AllergyIntoleranceSeverity value) { 774 if (value == null) 775 this.severity = null; 776 else { 777 if (this.severity == null) 778 this.severity = new Enumeration<AllergyIntoleranceSeverity>(new AllergyIntoleranceSeverityEnumFactory()); 779 this.severity.setValue(value); 780 } 781 return this; 782 } 783 784 /** 785 * @return {@link #exposureRoute} (Identification of the route by which the subject was exposed to the substance.) 786 */ 787 public CodeableConcept getExposureRoute() { 788 if (this.exposureRoute == null) 789 if (Configuration.errorOnAutoCreate()) 790 throw new Error("Attempt to auto-create AllergyIntoleranceReactionComponent.exposureRoute"); 791 else if (Configuration.doAutoCreate()) 792 this.exposureRoute = new CodeableConcept(); // cc 793 return this.exposureRoute; 794 } 795 796 public boolean hasExposureRoute() { 797 return this.exposureRoute != null && !this.exposureRoute.isEmpty(); 798 } 799 800 /** 801 * @param value {@link #exposureRoute} (Identification of the route by which the subject was exposed to the substance.) 802 */ 803 public AllergyIntoleranceReactionComponent setExposureRoute(CodeableConcept value) { 804 this.exposureRoute = value; 805 return this; 806 } 807 808 /** 809 * @return {@link #note} (Additional text about the adverse reaction event not captured in other fields.) 810 */ 811 public List<Annotation> getNote() { 812 if (this.note == null) 813 this.note = new ArrayList<Annotation>(); 814 return this.note; 815 } 816 817 /** 818 * @return Returns a reference to <code>this</code> for easy method chaining 819 */ 820 public AllergyIntoleranceReactionComponent setNote(List<Annotation> theNote) { 821 this.note = theNote; 822 return this; 823 } 824 825 public boolean hasNote() { 826 if (this.note == null) 827 return false; 828 for (Annotation item : this.note) 829 if (!item.isEmpty()) 830 return true; 831 return false; 832 } 833 834 public Annotation addNote() { //3 835 Annotation t = new Annotation(); 836 if (this.note == null) 837 this.note = new ArrayList<Annotation>(); 838 this.note.add(t); 839 return t; 840 } 841 842 public AllergyIntoleranceReactionComponent addNote(Annotation t) { //3 843 if (t == null) 844 return this; 845 if (this.note == null) 846 this.note = new ArrayList<Annotation>(); 847 this.note.add(t); 848 return this; 849 } 850 851 /** 852 * @return The first repetition of repeating field {@link #note}, creating it if it does not already exist {3} 853 */ 854 public Annotation getNoteFirstRep() { 855 if (getNote().isEmpty()) { 856 addNote(); 857 } 858 return getNote().get(0); 859 } 860 861 protected void listChildren(List<Property> children) { 862 super.listChildren(children); 863 children.add(new Property("substance", "CodeableConcept", "Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.", 0, 1, substance)); 864 children.add(new Property("manifestation", "CodeableReference(Observation)", "Clinical symptoms and/or signs that are observed or associated with the adverse reaction event.", 0, java.lang.Integer.MAX_VALUE, manifestation)); 865 children.add(new Property("description", "string", "Text description about the reaction as a whole, including details of the manifestation if required.", 0, 1, description)); 866 children.add(new Property("onset", "dateTime", "Record of the date and/or time of the onset of the Reaction.", 0, 1, onset)); 867 children.add(new Property("severity", "code", "Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations.", 0, 1, severity)); 868 children.add(new Property("exposureRoute", "CodeableConcept", "Identification of the route by which the subject was exposed to the substance.", 0, 1, exposureRoute)); 869 children.add(new Property("note", "Annotation", "Additional text about the adverse reaction event not captured in other fields.", 0, java.lang.Integer.MAX_VALUE, note)); 870 } 871 872 @Override 873 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 874 switch (_hash) { 875 case 530040176: /*substance*/ return new Property("substance", "CodeableConcept", "Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.", 0, 1, substance); 876 case 1115984422: /*manifestation*/ return new Property("manifestation", "CodeableReference(Observation)", "Clinical symptoms and/or signs that are observed or associated with the adverse reaction event.", 0, java.lang.Integer.MAX_VALUE, manifestation); 877 case -1724546052: /*description*/ return new Property("description", "string", "Text description about the reaction as a whole, including details of the manifestation if required.", 0, 1, description); 878 case 105901603: /*onset*/ return new Property("onset", "dateTime", "Record of the date and/or time of the onset of the Reaction.", 0, 1, onset); 879 case 1478300413: /*severity*/ return new Property("severity", "code", "Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations.", 0, 1, severity); 880 case 421286274: /*exposureRoute*/ return new Property("exposureRoute", "CodeableConcept", "Identification of the route by which the subject was exposed to the substance.", 0, 1, exposureRoute); 881 case 3387378: /*note*/ return new Property("note", "Annotation", "Additional text about the adverse reaction event not captured in other fields.", 0, java.lang.Integer.MAX_VALUE, note); 882 default: return super.getNamedProperty(_hash, _name, _checkValid); 883 } 884 885 } 886 887 @Override 888 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 889 switch (hash) { 890 case 530040176: /*substance*/ return this.substance == null ? new Base[0] : new Base[] {this.substance}; // CodeableConcept 891 case 1115984422: /*manifestation*/ return this.manifestation == null ? new Base[0] : this.manifestation.toArray(new Base[this.manifestation.size()]); // CodeableReference 892 case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType 893 case 105901603: /*onset*/ return this.onset == null ? new Base[0] : new Base[] {this.onset}; // DateTimeType 894 case 1478300413: /*severity*/ return this.severity == null ? new Base[0] : new Base[] {this.severity}; // Enumeration<AllergyIntoleranceSeverity> 895 case 421286274: /*exposureRoute*/ return this.exposureRoute == null ? new Base[0] : new Base[] {this.exposureRoute}; // CodeableConcept 896 case 3387378: /*note*/ return this.note == null ? new Base[0] : this.note.toArray(new Base[this.note.size()]); // Annotation 897 default: return super.getProperty(hash, name, checkValid); 898 } 899 900 } 901 902 @Override 903 public Base setProperty(int hash, String name, Base value) throws FHIRException { 904 switch (hash) { 905 case 530040176: // substance 906 this.substance = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 907 return value; 908 case 1115984422: // manifestation 909 this.getManifestation().add(TypeConvertor.castToCodeableReference(value)); // CodeableReference 910 return value; 911 case -1724546052: // description 912 this.description = TypeConvertor.castToString(value); // StringType 913 return value; 914 case 105901603: // onset 915 this.onset = TypeConvertor.castToDateTime(value); // DateTimeType 916 return value; 917 case 1478300413: // severity 918 value = new AllergyIntoleranceSeverityEnumFactory().fromType(TypeConvertor.castToCode(value)); 919 this.severity = (Enumeration) value; // Enumeration<AllergyIntoleranceSeverity> 920 return value; 921 case 421286274: // exposureRoute 922 this.exposureRoute = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 923 return value; 924 case 3387378: // note 925 this.getNote().add(TypeConvertor.castToAnnotation(value)); // Annotation 926 return value; 927 default: return super.setProperty(hash, name, value); 928 } 929 930 } 931 932 @Override 933 public Base setProperty(String name, Base value) throws FHIRException { 934 if (name.equals("substance")) { 935 this.substance = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 936 } else if (name.equals("manifestation")) { 937 this.getManifestation().add(TypeConvertor.castToCodeableReference(value)); 938 } else if (name.equals("description")) { 939 this.description = TypeConvertor.castToString(value); // StringType 940 } else if (name.equals("onset")) { 941 this.onset = TypeConvertor.castToDateTime(value); // DateTimeType 942 } else if (name.equals("severity")) { 943 value = new AllergyIntoleranceSeverityEnumFactory().fromType(TypeConvertor.castToCode(value)); 944 this.severity = (Enumeration) value; // Enumeration<AllergyIntoleranceSeverity> 945 } else if (name.equals("exposureRoute")) { 946 this.exposureRoute = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 947 } else if (name.equals("note")) { 948 this.getNote().add(TypeConvertor.castToAnnotation(value)); 949 } else 950 return super.setProperty(name, value); 951 return value; 952 } 953 954 @Override 955 public Base makeProperty(int hash, String name) throws FHIRException { 956 switch (hash) { 957 case 530040176: return getSubstance(); 958 case 1115984422: return addManifestation(); 959 case -1724546052: return getDescriptionElement(); 960 case 105901603: return getOnsetElement(); 961 case 1478300413: return getSeverityElement(); 962 case 421286274: return getExposureRoute(); 963 case 3387378: return addNote(); 964 default: return super.makeProperty(hash, name); 965 } 966 967 } 968 969 @Override 970 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 971 switch (hash) { 972 case 530040176: /*substance*/ return new String[] {"CodeableConcept"}; 973 case 1115984422: /*manifestation*/ return new String[] {"CodeableReference"}; 974 case -1724546052: /*description*/ return new String[] {"string"}; 975 case 105901603: /*onset*/ return new String[] {"dateTime"}; 976 case 1478300413: /*severity*/ return new String[] {"code"}; 977 case 421286274: /*exposureRoute*/ return new String[] {"CodeableConcept"}; 978 case 3387378: /*note*/ return new String[] {"Annotation"}; 979 default: return super.getTypesForProperty(hash, name); 980 } 981 982 } 983 984 @Override 985 public Base addChild(String name) throws FHIRException { 986 if (name.equals("substance")) { 987 this.substance = new CodeableConcept(); 988 return this.substance; 989 } 990 else if (name.equals("manifestation")) { 991 return addManifestation(); 992 } 993 else if (name.equals("description")) { 994 throw new FHIRException("Cannot call addChild on a primitive type AllergyIntolerance.reaction.description"); 995 } 996 else if (name.equals("onset")) { 997 throw new FHIRException("Cannot call addChild on a primitive type AllergyIntolerance.reaction.onset"); 998 } 999 else if (name.equals("severity")) { 1000 throw new FHIRException("Cannot call addChild on a primitive type AllergyIntolerance.reaction.severity"); 1001 } 1002 else if (name.equals("exposureRoute")) { 1003 this.exposureRoute = new CodeableConcept(); 1004 return this.exposureRoute; 1005 } 1006 else if (name.equals("note")) { 1007 return addNote(); 1008 } 1009 else 1010 return super.addChild(name); 1011 } 1012 1013 public AllergyIntoleranceReactionComponent copy() { 1014 AllergyIntoleranceReactionComponent dst = new AllergyIntoleranceReactionComponent(); 1015 copyValues(dst); 1016 return dst; 1017 } 1018 1019 public void copyValues(AllergyIntoleranceReactionComponent dst) { 1020 super.copyValues(dst); 1021 dst.substance = substance == null ? null : substance.copy(); 1022 if (manifestation != null) { 1023 dst.manifestation = new ArrayList<CodeableReference>(); 1024 for (CodeableReference i : manifestation) 1025 dst.manifestation.add(i.copy()); 1026 }; 1027 dst.description = description == null ? null : description.copy(); 1028 dst.onset = onset == null ? null : onset.copy(); 1029 dst.severity = severity == null ? null : severity.copy(); 1030 dst.exposureRoute = exposureRoute == null ? null : exposureRoute.copy(); 1031 if (note != null) { 1032 dst.note = new ArrayList<Annotation>(); 1033 for (Annotation i : note) 1034 dst.note.add(i.copy()); 1035 }; 1036 } 1037 1038 @Override 1039 public boolean equalsDeep(Base other_) { 1040 if (!super.equalsDeep(other_)) 1041 return false; 1042 if (!(other_ instanceof AllergyIntoleranceReactionComponent)) 1043 return false; 1044 AllergyIntoleranceReactionComponent o = (AllergyIntoleranceReactionComponent) other_; 1045 return compareDeep(substance, o.substance, true) && compareDeep(manifestation, o.manifestation, true) 1046 && compareDeep(description, o.description, true) && compareDeep(onset, o.onset, true) && compareDeep(severity, o.severity, true) 1047 && compareDeep(exposureRoute, o.exposureRoute, true) && compareDeep(note, o.note, true); 1048 } 1049 1050 @Override 1051 public boolean equalsShallow(Base other_) { 1052 if (!super.equalsShallow(other_)) 1053 return false; 1054 if (!(other_ instanceof AllergyIntoleranceReactionComponent)) 1055 return false; 1056 AllergyIntoleranceReactionComponent o = (AllergyIntoleranceReactionComponent) other_; 1057 return compareValues(description, o.description, true) && compareValues(onset, o.onset, true) && compareValues(severity, o.severity, true) 1058 ; 1059 } 1060 1061 public boolean isEmpty() { 1062 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(substance, manifestation, description 1063 , onset, severity, exposureRoute, note); 1064 } 1065 1066 public String fhirType() { 1067 return "AllergyIntolerance.reaction"; 1068 1069 } 1070 1071 } 1072 1073 /** 1074 * Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server. 1075 */ 1076 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1077 @Description(shortDefinition="External ids for this item", formalDefinition="Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server." ) 1078 protected List<Identifier> identifier; 1079 1080 /** 1081 * The clinical status of the allergy or intolerance. 1082 */ 1083 @Child(name = "clinicalStatus", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=true, summary=true) 1084 @Description(shortDefinition="active | inactive | resolved", formalDefinition="The clinical status of the allergy or intolerance." ) 1085 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/allergyintolerance-clinical") 1086 protected CodeableConcept clinicalStatus; 1087 1088 /** 1089 * Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product). The verification status pertains to the allergy or intolerance, itself, not to any specific AllergyIntolerance attribute. 1090 */ 1091 @Child(name = "verificationStatus", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=true, summary=true) 1092 @Description(shortDefinition="unconfirmed | presumed | confirmed | refuted | entered-in-error", formalDefinition="Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product). The verification status pertains to the allergy or intolerance, itself, not to any specific AllergyIntolerance attribute." ) 1093 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/allergyintolerance-verification") 1094 protected CodeableConcept verificationStatus; 1095 1096 /** 1097 * Identification of the underlying physiological mechanism for the reaction risk. 1098 */ 1099 @Child(name = "type", type = {CodeType.class}, order=3, min=0, max=1, modifier=false, summary=true) 1100 @Description(shortDefinition="allergy | intolerance - Underlying mechanism (if known)", formalDefinition="Identification of the underlying physiological mechanism for the reaction risk." ) 1101 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/allergy-intolerance-type") 1102 protected Enumeration<AllergyIntoleranceType> type; 1103 1104 /** 1105 * Category of the identified substance. 1106 */ 1107 @Child(name = "category", type = {CodeType.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1108 @Description(shortDefinition="food | medication | environment | biologic", formalDefinition="Category of the identified substance." ) 1109 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/allergy-intolerance-category") 1110 protected List<Enumeration<AllergyIntoleranceCategory>> category; 1111 1112 /** 1113 * Estimate of the potential clinical harm, or seriousness, of the reaction to the identified substance. 1114 */ 1115 @Child(name = "criticality", type = {CodeType.class}, order=5, min=0, max=1, modifier=false, summary=true) 1116 @Description(shortDefinition="low | high | unable-to-assess", formalDefinition="Estimate of the potential clinical harm, or seriousness, of the reaction to the identified substance." ) 1117 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/allergy-intolerance-criticality") 1118 protected Enumeration<AllergyIntoleranceCriticality> criticality; 1119 1120 /** 1121 * Code for an allergy or intolerance statement (either a positive or a negated/excluded statement). This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., "Latex"), an allergy or intolerance condition (e.g., "Latex allergy"), or a negated/excluded code for a specific substance or class (e.g., "No latex allergy") or a general or categorical negated statement (e.g., "No known allergy", "No known drug allergies"). Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance. 1122 */ 1123 @Child(name = "code", type = {CodeableConcept.class}, order=6, min=0, max=1, modifier=false, summary=true) 1124 @Description(shortDefinition="Code that identifies the allergy or intolerance", formalDefinition="Code for an allergy or intolerance statement (either a positive or a negated/excluded statement). This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., \"Latex\"), an allergy or intolerance condition (e.g., \"Latex allergy\"), or a negated/excluded code for a specific substance or class (e.g., \"No latex allergy\") or a general or categorical negated statement (e.g., \"No known allergy\", \"No known drug allergies\"). Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance." ) 1125 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/allergyintolerance-code") 1126 protected CodeableConcept code; 1127 1128 /** 1129 * The patient who has the allergy or intolerance. 1130 */ 1131 @Child(name = "patient", type = {Patient.class}, order=7, min=1, max=1, modifier=false, summary=true) 1132 @Description(shortDefinition="Who the sensitivity is for", formalDefinition="The patient who has the allergy or intolerance." ) 1133 protected Reference patient; 1134 1135 /** 1136 * The encounter when the allergy or intolerance was asserted. 1137 */ 1138 @Child(name = "encounter", type = {Encounter.class}, order=8, min=0, max=1, modifier=false, summary=false) 1139 @Description(shortDefinition="Encounter when the allergy or intolerance was asserted", formalDefinition="The encounter when the allergy or intolerance was asserted." ) 1140 protected Reference encounter; 1141 1142 /** 1143 * Estimated or actual date, date-time, or age when allergy or intolerance was identified. 1144 */ 1145 @Child(name = "onset", type = {DateTimeType.class, Age.class, Period.class, Range.class, StringType.class}, order=9, min=0, max=1, modifier=false, summary=false) 1146 @Description(shortDefinition="When allergy or intolerance was identified", formalDefinition="Estimated or actual date, date-time, or age when allergy or intolerance was identified." ) 1147 protected DataType onset; 1148 1149 /** 1150 * The recordedDate represents when this particular AllergyIntolerance record was created in the system, which is often a system-generated date. 1151 */ 1152 @Child(name = "recordedDate", type = {DateTimeType.class}, order=10, min=0, max=1, modifier=false, summary=false) 1153 @Description(shortDefinition="Date first version of the resource instance was recorded", formalDefinition="The recordedDate represents when this particular AllergyIntolerance record was created in the system, which is often a system-generated date." ) 1154 protected DateTimeType recordedDate; 1155 1156 /** 1157 * Individual who recorded the record and takes responsibility for its content. 1158 */ 1159 @Child(name = "recorder", type = {Practitioner.class, PractitionerRole.class, Patient.class, RelatedPerson.class, Organization.class}, order=11, min=0, max=1, modifier=false, summary=false) 1160 @Description(shortDefinition="Who recorded the sensitivity", formalDefinition="Individual who recorded the record and takes responsibility for its content." ) 1161 protected Reference recorder; 1162 1163 /** 1164 * The source of the information about the allergy that is recorded. 1165 */ 1166 @Child(name = "asserter", type = {Patient.class, RelatedPerson.class, Practitioner.class, PractitionerRole.class}, order=12, min=0, max=1, modifier=false, summary=true) 1167 @Description(shortDefinition="Source of the information about the allergy", formalDefinition="The source of the information about the allergy that is recorded." ) 1168 protected Reference asserter; 1169 1170 /** 1171 * Represents the date and/or time of the last known occurrence of a reaction event. 1172 */ 1173 @Child(name = "lastOccurrence", type = {DateTimeType.class}, order=13, min=0, max=1, modifier=false, summary=false) 1174 @Description(shortDefinition="Date(/time) of last known occurrence of a reaction", formalDefinition="Represents the date and/or time of the last known occurrence of a reaction event." ) 1175 protected DateTimeType lastOccurrence; 1176 1177 /** 1178 * Additional narrative about the propensity for the Adverse Reaction, not captured in other fields. 1179 */ 1180 @Child(name = "note", type = {Annotation.class}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1181 @Description(shortDefinition="Additional text not captured in other fields", formalDefinition="Additional narrative about the propensity for the Adverse Reaction, not captured in other fields." ) 1182 protected List<Annotation> note; 1183 1184 /** 1185 * Details about each adverse reaction event linked to exposure to the identified substance. 1186 */ 1187 @Child(name = "reaction", type = {}, order=15, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1188 @Description(shortDefinition="Adverse Reaction Events linked to exposure to substance", formalDefinition="Details about each adverse reaction event linked to exposure to the identified substance." ) 1189 protected List<AllergyIntoleranceReactionComponent> reaction; 1190 1191 private static final long serialVersionUID = 1489554196L; 1192 1193 /** 1194 * Constructor 1195 */ 1196 public AllergyIntolerance() { 1197 super(); 1198 } 1199 1200 /** 1201 * Constructor 1202 */ 1203 public AllergyIntolerance(Reference patient) { 1204 super(); 1205 this.setPatient(patient); 1206 } 1207 1208 /** 1209 * @return {@link #identifier} (Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server.) 1210 */ 1211 public List<Identifier> getIdentifier() { 1212 if (this.identifier == null) 1213 this.identifier = new ArrayList<Identifier>(); 1214 return this.identifier; 1215 } 1216 1217 /** 1218 * @return Returns a reference to <code>this</code> for easy method chaining 1219 */ 1220 public AllergyIntolerance setIdentifier(List<Identifier> theIdentifier) { 1221 this.identifier = theIdentifier; 1222 return this; 1223 } 1224 1225 public boolean hasIdentifier() { 1226 if (this.identifier == null) 1227 return false; 1228 for (Identifier item : this.identifier) 1229 if (!item.isEmpty()) 1230 return true; 1231 return false; 1232 } 1233 1234 public Identifier addIdentifier() { //3 1235 Identifier t = new Identifier(); 1236 if (this.identifier == null) 1237 this.identifier = new ArrayList<Identifier>(); 1238 this.identifier.add(t); 1239 return t; 1240 } 1241 1242 public AllergyIntolerance addIdentifier(Identifier t) { //3 1243 if (t == null) 1244 return this; 1245 if (this.identifier == null) 1246 this.identifier = new ArrayList<Identifier>(); 1247 this.identifier.add(t); 1248 return this; 1249 } 1250 1251 /** 1252 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist {3} 1253 */ 1254 public Identifier getIdentifierFirstRep() { 1255 if (getIdentifier().isEmpty()) { 1256 addIdentifier(); 1257 } 1258 return getIdentifier().get(0); 1259 } 1260 1261 /** 1262 * @return {@link #clinicalStatus} (The clinical status of the allergy or intolerance.) 1263 */ 1264 public CodeableConcept getClinicalStatus() { 1265 if (this.clinicalStatus == null) 1266 if (Configuration.errorOnAutoCreate()) 1267 throw new Error("Attempt to auto-create AllergyIntolerance.clinicalStatus"); 1268 else if (Configuration.doAutoCreate()) 1269 this.clinicalStatus = new CodeableConcept(); // cc 1270 return this.clinicalStatus; 1271 } 1272 1273 public boolean hasClinicalStatus() { 1274 return this.clinicalStatus != null && !this.clinicalStatus.isEmpty(); 1275 } 1276 1277 /** 1278 * @param value {@link #clinicalStatus} (The clinical status of the allergy or intolerance.) 1279 */ 1280 public AllergyIntolerance setClinicalStatus(CodeableConcept value) { 1281 this.clinicalStatus = value; 1282 return this; 1283 } 1284 1285 /** 1286 * @return {@link #verificationStatus} (Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product). The verification status pertains to the allergy or intolerance, itself, not to any specific AllergyIntolerance attribute.) 1287 */ 1288 public CodeableConcept getVerificationStatus() { 1289 if (this.verificationStatus == null) 1290 if (Configuration.errorOnAutoCreate()) 1291 throw new Error("Attempt to auto-create AllergyIntolerance.verificationStatus"); 1292 else if (Configuration.doAutoCreate()) 1293 this.verificationStatus = new CodeableConcept(); // cc 1294 return this.verificationStatus; 1295 } 1296 1297 public boolean hasVerificationStatus() { 1298 return this.verificationStatus != null && !this.verificationStatus.isEmpty(); 1299 } 1300 1301 /** 1302 * @param value {@link #verificationStatus} (Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product). The verification status pertains to the allergy or intolerance, itself, not to any specific AllergyIntolerance attribute.) 1303 */ 1304 public AllergyIntolerance setVerificationStatus(CodeableConcept value) { 1305 this.verificationStatus = value; 1306 return this; 1307 } 1308 1309 /** 1310 * @return {@link #type} (Identification of the underlying physiological mechanism for the reaction risk.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value 1311 */ 1312 public Enumeration<AllergyIntoleranceType> getTypeElement() { 1313 if (this.type == null) 1314 if (Configuration.errorOnAutoCreate()) 1315 throw new Error("Attempt to auto-create AllergyIntolerance.type"); 1316 else if (Configuration.doAutoCreate()) 1317 this.type = new Enumeration<AllergyIntoleranceType>(new AllergyIntoleranceTypeEnumFactory()); // bb 1318 return this.type; 1319 } 1320 1321 public boolean hasTypeElement() { 1322 return this.type != null && !this.type.isEmpty(); 1323 } 1324 1325 public boolean hasType() { 1326 return this.type != null && !this.type.isEmpty(); 1327 } 1328 1329 /** 1330 * @param value {@link #type} (Identification of the underlying physiological mechanism for the reaction risk.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value 1331 */ 1332 public AllergyIntolerance setTypeElement(Enumeration<AllergyIntoleranceType> value) { 1333 this.type = value; 1334 return this; 1335 } 1336 1337 /** 1338 * @return Identification of the underlying physiological mechanism for the reaction risk. 1339 */ 1340 public AllergyIntoleranceType getType() { 1341 return this.type == null ? null : this.type.getValue(); 1342 } 1343 1344 /** 1345 * @param value Identification of the underlying physiological mechanism for the reaction risk. 1346 */ 1347 public AllergyIntolerance setType(AllergyIntoleranceType value) { 1348 if (value == null) 1349 this.type = null; 1350 else { 1351 if (this.type == null) 1352 this.type = new Enumeration<AllergyIntoleranceType>(new AllergyIntoleranceTypeEnumFactory()); 1353 this.type.setValue(value); 1354 } 1355 return this; 1356 } 1357 1358 /** 1359 * @return {@link #category} (Category of the identified substance.) 1360 */ 1361 public List<Enumeration<AllergyIntoleranceCategory>> getCategory() { 1362 if (this.category == null) 1363 this.category = new ArrayList<Enumeration<AllergyIntoleranceCategory>>(); 1364 return this.category; 1365 } 1366 1367 /** 1368 * @return Returns a reference to <code>this</code> for easy method chaining 1369 */ 1370 public AllergyIntolerance setCategory(List<Enumeration<AllergyIntoleranceCategory>> theCategory) { 1371 this.category = theCategory; 1372 return this; 1373 } 1374 1375 public boolean hasCategory() { 1376 if (this.category == null) 1377 return false; 1378 for (Enumeration<AllergyIntoleranceCategory> item : this.category) 1379 if (!item.isEmpty()) 1380 return true; 1381 return false; 1382 } 1383 1384 /** 1385 * @return {@link #category} (Category of the identified substance.) 1386 */ 1387 public Enumeration<AllergyIntoleranceCategory> addCategoryElement() {//2 1388 Enumeration<AllergyIntoleranceCategory> t = new Enumeration<AllergyIntoleranceCategory>(new AllergyIntoleranceCategoryEnumFactory()); 1389 if (this.category == null) 1390 this.category = new ArrayList<Enumeration<AllergyIntoleranceCategory>>(); 1391 this.category.add(t); 1392 return t; 1393 } 1394 1395 /** 1396 * @param value {@link #category} (Category of the identified substance.) 1397 */ 1398 public AllergyIntolerance addCategory(AllergyIntoleranceCategory value) { //1 1399 Enumeration<AllergyIntoleranceCategory> t = new Enumeration<AllergyIntoleranceCategory>(new AllergyIntoleranceCategoryEnumFactory()); 1400 t.setValue(value); 1401 if (this.category == null) 1402 this.category = new ArrayList<Enumeration<AllergyIntoleranceCategory>>(); 1403 this.category.add(t); 1404 return this; 1405 } 1406 1407 /** 1408 * @param value {@link #category} (Category of the identified substance.) 1409 */ 1410 public boolean hasCategory(AllergyIntoleranceCategory value) { 1411 if (this.category == null) 1412 return false; 1413 for (Enumeration<AllergyIntoleranceCategory> v : this.category) 1414 if (v.getValue().equals(value)) // code 1415 return true; 1416 return false; 1417 } 1418 1419 /** 1420 * @return {@link #criticality} (Estimate of the potential clinical harm, or seriousness, of the reaction to the identified substance.). This is the underlying object with id, value and extensions. The accessor "getCriticality" gives direct access to the value 1421 */ 1422 public Enumeration<AllergyIntoleranceCriticality> getCriticalityElement() { 1423 if (this.criticality == null) 1424 if (Configuration.errorOnAutoCreate()) 1425 throw new Error("Attempt to auto-create AllergyIntolerance.criticality"); 1426 else if (Configuration.doAutoCreate()) 1427 this.criticality = new Enumeration<AllergyIntoleranceCriticality>(new AllergyIntoleranceCriticalityEnumFactory()); // bb 1428 return this.criticality; 1429 } 1430 1431 public boolean hasCriticalityElement() { 1432 return this.criticality != null && !this.criticality.isEmpty(); 1433 } 1434 1435 public boolean hasCriticality() { 1436 return this.criticality != null && !this.criticality.isEmpty(); 1437 } 1438 1439 /** 1440 * @param value {@link #criticality} (Estimate of the potential clinical harm, or seriousness, of the reaction to the identified substance.). This is the underlying object with id, value and extensions. The accessor "getCriticality" gives direct access to the value 1441 */ 1442 public AllergyIntolerance setCriticalityElement(Enumeration<AllergyIntoleranceCriticality> value) { 1443 this.criticality = value; 1444 return this; 1445 } 1446 1447 /** 1448 * @return Estimate of the potential clinical harm, or seriousness, of the reaction to the identified substance. 1449 */ 1450 public AllergyIntoleranceCriticality getCriticality() { 1451 return this.criticality == null ? null : this.criticality.getValue(); 1452 } 1453 1454 /** 1455 * @param value Estimate of the potential clinical harm, or seriousness, of the reaction to the identified substance. 1456 */ 1457 public AllergyIntolerance setCriticality(AllergyIntoleranceCriticality value) { 1458 if (value == null) 1459 this.criticality = null; 1460 else { 1461 if (this.criticality == null) 1462 this.criticality = new Enumeration<AllergyIntoleranceCriticality>(new AllergyIntoleranceCriticalityEnumFactory()); 1463 this.criticality.setValue(value); 1464 } 1465 return this; 1466 } 1467 1468 /** 1469 * @return {@link #code} (Code for an allergy or intolerance statement (either a positive or a negated/excluded statement). This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., "Latex"), an allergy or intolerance condition (e.g., "Latex allergy"), or a negated/excluded code for a specific substance or class (e.g., "No latex allergy") or a general or categorical negated statement (e.g., "No known allergy", "No known drug allergies"). Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.) 1470 */ 1471 public CodeableConcept getCode() { 1472 if (this.code == null) 1473 if (Configuration.errorOnAutoCreate()) 1474 throw new Error("Attempt to auto-create AllergyIntolerance.code"); 1475 else if (Configuration.doAutoCreate()) 1476 this.code = new CodeableConcept(); // cc 1477 return this.code; 1478 } 1479 1480 public boolean hasCode() { 1481 return this.code != null && !this.code.isEmpty(); 1482 } 1483 1484 /** 1485 * @param value {@link #code} (Code for an allergy or intolerance statement (either a positive or a negated/excluded statement). This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., "Latex"), an allergy or intolerance condition (e.g., "Latex allergy"), or a negated/excluded code for a specific substance or class (e.g., "No latex allergy") or a general or categorical negated statement (e.g., "No known allergy", "No known drug allergies"). Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.) 1486 */ 1487 public AllergyIntolerance setCode(CodeableConcept value) { 1488 this.code = value; 1489 return this; 1490 } 1491 1492 /** 1493 * @return {@link #patient} (The patient who has the allergy or intolerance.) 1494 */ 1495 public Reference getPatient() { 1496 if (this.patient == null) 1497 if (Configuration.errorOnAutoCreate()) 1498 throw new Error("Attempt to auto-create AllergyIntolerance.patient"); 1499 else if (Configuration.doAutoCreate()) 1500 this.patient = new Reference(); // cc 1501 return this.patient; 1502 } 1503 1504 public boolean hasPatient() { 1505 return this.patient != null && !this.patient.isEmpty(); 1506 } 1507 1508 /** 1509 * @param value {@link #patient} (The patient who has the allergy or intolerance.) 1510 */ 1511 public AllergyIntolerance setPatient(Reference value) { 1512 this.patient = value; 1513 return this; 1514 } 1515 1516 /** 1517 * @return {@link #encounter} (The encounter when the allergy or intolerance was asserted.) 1518 */ 1519 public Reference getEncounter() { 1520 if (this.encounter == null) 1521 if (Configuration.errorOnAutoCreate()) 1522 throw new Error("Attempt to auto-create AllergyIntolerance.encounter"); 1523 else if (Configuration.doAutoCreate()) 1524 this.encounter = new Reference(); // cc 1525 return this.encounter; 1526 } 1527 1528 public boolean hasEncounter() { 1529 return this.encounter != null && !this.encounter.isEmpty(); 1530 } 1531 1532 /** 1533 * @param value {@link #encounter} (The encounter when the allergy or intolerance was asserted.) 1534 */ 1535 public AllergyIntolerance setEncounter(Reference value) { 1536 this.encounter = value; 1537 return this; 1538 } 1539 1540 /** 1541 * @return {@link #onset} (Estimated or actual date, date-time, or age when allergy or intolerance was identified.) 1542 */ 1543 public DataType getOnset() { 1544 return this.onset; 1545 } 1546 1547 /** 1548 * @return {@link #onset} (Estimated or actual date, date-time, or age when allergy or intolerance was identified.) 1549 */ 1550 public DateTimeType getOnsetDateTimeType() throws FHIRException { 1551 if (this.onset == null) 1552 this.onset = new DateTimeType(); 1553 if (!(this.onset instanceof DateTimeType)) 1554 throw new FHIRException("Type mismatch: the type DateTimeType was expected, but "+this.onset.getClass().getName()+" was encountered"); 1555 return (DateTimeType) this.onset; 1556 } 1557 1558 public boolean hasOnsetDateTimeType() { 1559 return this != null && this.onset instanceof DateTimeType; 1560 } 1561 1562 /** 1563 * @return {@link #onset} (Estimated or actual date, date-time, or age when allergy or intolerance was identified.) 1564 */ 1565 public Age getOnsetAge() throws FHIRException { 1566 if (this.onset == null) 1567 this.onset = new Age(); 1568 if (!(this.onset instanceof Age)) 1569 throw new FHIRException("Type mismatch: the type Age was expected, but "+this.onset.getClass().getName()+" was encountered"); 1570 return (Age) this.onset; 1571 } 1572 1573 public boolean hasOnsetAge() { 1574 return this != null && this.onset instanceof Age; 1575 } 1576 1577 /** 1578 * @return {@link #onset} (Estimated or actual date, date-time, or age when allergy or intolerance was identified.) 1579 */ 1580 public Period getOnsetPeriod() throws FHIRException { 1581 if (this.onset == null) 1582 this.onset = new Period(); 1583 if (!(this.onset instanceof Period)) 1584 throw new FHIRException("Type mismatch: the type Period was expected, but "+this.onset.getClass().getName()+" was encountered"); 1585 return (Period) this.onset; 1586 } 1587 1588 public boolean hasOnsetPeriod() { 1589 return this != null && this.onset instanceof Period; 1590 } 1591 1592 /** 1593 * @return {@link #onset} (Estimated or actual date, date-time, or age when allergy or intolerance was identified.) 1594 */ 1595 public Range getOnsetRange() throws FHIRException { 1596 if (this.onset == null) 1597 this.onset = new Range(); 1598 if (!(this.onset instanceof Range)) 1599 throw new FHIRException("Type mismatch: the type Range was expected, but "+this.onset.getClass().getName()+" was encountered"); 1600 return (Range) this.onset; 1601 } 1602 1603 public boolean hasOnsetRange() { 1604 return this != null && this.onset instanceof Range; 1605 } 1606 1607 /** 1608 * @return {@link #onset} (Estimated or actual date, date-time, or age when allergy or intolerance was identified.) 1609 */ 1610 public StringType getOnsetStringType() throws FHIRException { 1611 if (this.onset == null) 1612 this.onset = new StringType(); 1613 if (!(this.onset instanceof StringType)) 1614 throw new FHIRException("Type mismatch: the type StringType was expected, but "+this.onset.getClass().getName()+" was encountered"); 1615 return (StringType) this.onset; 1616 } 1617 1618 public boolean hasOnsetStringType() { 1619 return this != null && this.onset instanceof StringType; 1620 } 1621 1622 public boolean hasOnset() { 1623 return this.onset != null && !this.onset.isEmpty(); 1624 } 1625 1626 /** 1627 * @param value {@link #onset} (Estimated or actual date, date-time, or age when allergy or intolerance was identified.) 1628 */ 1629 public AllergyIntolerance setOnset(DataType value) { 1630 if (value != null && !(value instanceof DateTimeType || value instanceof Age || value instanceof Period || value instanceof Range || value instanceof StringType)) 1631 throw new Error("Not the right type for AllergyIntolerance.onset[x]: "+value.fhirType()); 1632 this.onset = value; 1633 return this; 1634 } 1635 1636 /** 1637 * @return {@link #recordedDate} (The recordedDate represents when this particular AllergyIntolerance record was created in the system, which is often a system-generated date.). This is the underlying object with id, value and extensions. The accessor "getRecordedDate" gives direct access to the value 1638 */ 1639 public DateTimeType getRecordedDateElement() { 1640 if (this.recordedDate == null) 1641 if (Configuration.errorOnAutoCreate()) 1642 throw new Error("Attempt to auto-create AllergyIntolerance.recordedDate"); 1643 else if (Configuration.doAutoCreate()) 1644 this.recordedDate = new DateTimeType(); // bb 1645 return this.recordedDate; 1646 } 1647 1648 public boolean hasRecordedDateElement() { 1649 return this.recordedDate != null && !this.recordedDate.isEmpty(); 1650 } 1651 1652 public boolean hasRecordedDate() { 1653 return this.recordedDate != null && !this.recordedDate.isEmpty(); 1654 } 1655 1656 /** 1657 * @param value {@link #recordedDate} (The recordedDate represents when this particular AllergyIntolerance record was created in the system, which is often a system-generated date.). This is the underlying object with id, value and extensions. The accessor "getRecordedDate" gives direct access to the value 1658 */ 1659 public AllergyIntolerance setRecordedDateElement(DateTimeType value) { 1660 this.recordedDate = value; 1661 return this; 1662 } 1663 1664 /** 1665 * @return The recordedDate represents when this particular AllergyIntolerance record was created in the system, which is often a system-generated date. 1666 */ 1667 public Date getRecordedDate() { 1668 return this.recordedDate == null ? null : this.recordedDate.getValue(); 1669 } 1670 1671 /** 1672 * @param value The recordedDate represents when this particular AllergyIntolerance record was created in the system, which is often a system-generated date. 1673 */ 1674 public AllergyIntolerance setRecordedDate(Date value) { 1675 if (value == null) 1676 this.recordedDate = null; 1677 else { 1678 if (this.recordedDate == null) 1679 this.recordedDate = new DateTimeType(); 1680 this.recordedDate.setValue(value); 1681 } 1682 return this; 1683 } 1684 1685 /** 1686 * @return {@link #recorder} (Individual who recorded the record and takes responsibility for its content.) 1687 */ 1688 public Reference getRecorder() { 1689 if (this.recorder == null) 1690 if (Configuration.errorOnAutoCreate()) 1691 throw new Error("Attempt to auto-create AllergyIntolerance.recorder"); 1692 else if (Configuration.doAutoCreate()) 1693 this.recorder = new Reference(); // cc 1694 return this.recorder; 1695 } 1696 1697 public boolean hasRecorder() { 1698 return this.recorder != null && !this.recorder.isEmpty(); 1699 } 1700 1701 /** 1702 * @param value {@link #recorder} (Individual who recorded the record and takes responsibility for its content.) 1703 */ 1704 public AllergyIntolerance setRecorder(Reference value) { 1705 this.recorder = value; 1706 return this; 1707 } 1708 1709 /** 1710 * @return {@link #asserter} (The source of the information about the allergy that is recorded.) 1711 */ 1712 public Reference getAsserter() { 1713 if (this.asserter == null) 1714 if (Configuration.errorOnAutoCreate()) 1715 throw new Error("Attempt to auto-create AllergyIntolerance.asserter"); 1716 else if (Configuration.doAutoCreate()) 1717 this.asserter = new Reference(); // cc 1718 return this.asserter; 1719 } 1720 1721 public boolean hasAsserter() { 1722 return this.asserter != null && !this.asserter.isEmpty(); 1723 } 1724 1725 /** 1726 * @param value {@link #asserter} (The source of the information about the allergy that is recorded.) 1727 */ 1728 public AllergyIntolerance setAsserter(Reference value) { 1729 this.asserter = value; 1730 return this; 1731 } 1732 1733 /** 1734 * @return {@link #lastOccurrence} (Represents the date and/or time of the last known occurrence of a reaction event.). This is the underlying object with id, value and extensions. The accessor "getLastOccurrence" gives direct access to the value 1735 */ 1736 public DateTimeType getLastOccurrenceElement() { 1737 if (this.lastOccurrence == null) 1738 if (Configuration.errorOnAutoCreate()) 1739 throw new Error("Attempt to auto-create AllergyIntolerance.lastOccurrence"); 1740 else if (Configuration.doAutoCreate()) 1741 this.lastOccurrence = new DateTimeType(); // bb 1742 return this.lastOccurrence; 1743 } 1744 1745 public boolean hasLastOccurrenceElement() { 1746 return this.lastOccurrence != null && !this.lastOccurrence.isEmpty(); 1747 } 1748 1749 public boolean hasLastOccurrence() { 1750 return this.lastOccurrence != null && !this.lastOccurrence.isEmpty(); 1751 } 1752 1753 /** 1754 * @param value {@link #lastOccurrence} (Represents the date and/or time of the last known occurrence of a reaction event.). This is the underlying object with id, value and extensions. The accessor "getLastOccurrence" gives direct access to the value 1755 */ 1756 public AllergyIntolerance setLastOccurrenceElement(DateTimeType value) { 1757 this.lastOccurrence = value; 1758 return this; 1759 } 1760 1761 /** 1762 * @return Represents the date and/or time of the last known occurrence of a reaction event. 1763 */ 1764 public Date getLastOccurrence() { 1765 return this.lastOccurrence == null ? null : this.lastOccurrence.getValue(); 1766 } 1767 1768 /** 1769 * @param value Represents the date and/or time of the last known occurrence of a reaction event. 1770 */ 1771 public AllergyIntolerance setLastOccurrence(Date value) { 1772 if (value == null) 1773 this.lastOccurrence = null; 1774 else { 1775 if (this.lastOccurrence == null) 1776 this.lastOccurrence = new DateTimeType(); 1777 this.lastOccurrence.setValue(value); 1778 } 1779 return this; 1780 } 1781 1782 /** 1783 * @return {@link #note} (Additional narrative about the propensity for the Adverse Reaction, not captured in other fields.) 1784 */ 1785 public List<Annotation> getNote() { 1786 if (this.note == null) 1787 this.note = new ArrayList<Annotation>(); 1788 return this.note; 1789 } 1790 1791 /** 1792 * @return Returns a reference to <code>this</code> for easy method chaining 1793 */ 1794 public AllergyIntolerance setNote(List<Annotation> theNote) { 1795 this.note = theNote; 1796 return this; 1797 } 1798 1799 public boolean hasNote() { 1800 if (this.note == null) 1801 return false; 1802 for (Annotation item : this.note) 1803 if (!item.isEmpty()) 1804 return true; 1805 return false; 1806 } 1807 1808 public Annotation addNote() { //3 1809 Annotation t = new Annotation(); 1810 if (this.note == null) 1811 this.note = new ArrayList<Annotation>(); 1812 this.note.add(t); 1813 return t; 1814 } 1815 1816 public AllergyIntolerance addNote(Annotation t) { //3 1817 if (t == null) 1818 return this; 1819 if (this.note == null) 1820 this.note = new ArrayList<Annotation>(); 1821 this.note.add(t); 1822 return this; 1823 } 1824 1825 /** 1826 * @return The first repetition of repeating field {@link #note}, creating it if it does not already exist {3} 1827 */ 1828 public Annotation getNoteFirstRep() { 1829 if (getNote().isEmpty()) { 1830 addNote(); 1831 } 1832 return getNote().get(0); 1833 } 1834 1835 /** 1836 * @return {@link #reaction} (Details about each adverse reaction event linked to exposure to the identified substance.) 1837 */ 1838 public List<AllergyIntoleranceReactionComponent> getReaction() { 1839 if (this.reaction == null) 1840 this.reaction = new ArrayList<AllergyIntoleranceReactionComponent>(); 1841 return this.reaction; 1842 } 1843 1844 /** 1845 * @return Returns a reference to <code>this</code> for easy method chaining 1846 */ 1847 public AllergyIntolerance setReaction(List<AllergyIntoleranceReactionComponent> theReaction) { 1848 this.reaction = theReaction; 1849 return this; 1850 } 1851 1852 public boolean hasReaction() { 1853 if (this.reaction == null) 1854 return false; 1855 for (AllergyIntoleranceReactionComponent item : this.reaction) 1856 if (!item.isEmpty()) 1857 return true; 1858 return false; 1859 } 1860 1861 public AllergyIntoleranceReactionComponent addReaction() { //3 1862 AllergyIntoleranceReactionComponent t = new AllergyIntoleranceReactionComponent(); 1863 if (this.reaction == null) 1864 this.reaction = new ArrayList<AllergyIntoleranceReactionComponent>(); 1865 this.reaction.add(t); 1866 return t; 1867 } 1868 1869 public AllergyIntolerance addReaction(AllergyIntoleranceReactionComponent t) { //3 1870 if (t == null) 1871 return this; 1872 if (this.reaction == null) 1873 this.reaction = new ArrayList<AllergyIntoleranceReactionComponent>(); 1874 this.reaction.add(t); 1875 return this; 1876 } 1877 1878 /** 1879 * @return The first repetition of repeating field {@link #reaction}, creating it if it does not already exist {3} 1880 */ 1881 public AllergyIntoleranceReactionComponent getReactionFirstRep() { 1882 if (getReaction().isEmpty()) { 1883 addReaction(); 1884 } 1885 return getReaction().get(0); 1886 } 1887 1888 protected void listChildren(List<Property> children) { 1889 super.listChildren(children); 1890 children.add(new Property("identifier", "Identifier", "Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server.", 0, java.lang.Integer.MAX_VALUE, identifier)); 1891 children.add(new Property("clinicalStatus", "CodeableConcept", "The clinical status of the allergy or intolerance.", 0, 1, clinicalStatus)); 1892 children.add(new Property("verificationStatus", "CodeableConcept", "Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product). The verification status pertains to the allergy or intolerance, itself, not to any specific AllergyIntolerance attribute.", 0, 1, verificationStatus)); 1893 children.add(new Property("type", "code", "Identification of the underlying physiological mechanism for the reaction risk.", 0, 1, type)); 1894 children.add(new Property("category", "code", "Category of the identified substance.", 0, java.lang.Integer.MAX_VALUE, category)); 1895 children.add(new Property("criticality", "code", "Estimate of the potential clinical harm, or seriousness, of the reaction to the identified substance.", 0, 1, criticality)); 1896 children.add(new Property("code", "CodeableConcept", "Code for an allergy or intolerance statement (either a positive or a negated/excluded statement). This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., \"Latex\"), an allergy or intolerance condition (e.g., \"Latex allergy\"), or a negated/excluded code for a specific substance or class (e.g., \"No latex allergy\") or a general or categorical negated statement (e.g., \"No known allergy\", \"No known drug allergies\"). Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.", 0, 1, code)); 1897 children.add(new Property("patient", "Reference(Patient)", "The patient who has the allergy or intolerance.", 0, 1, patient)); 1898 children.add(new Property("encounter", "Reference(Encounter)", "The encounter when the allergy or intolerance was asserted.", 0, 1, encounter)); 1899 children.add(new Property("onset[x]", "dateTime|Age|Period|Range|string", "Estimated or actual date, date-time, or age when allergy or intolerance was identified.", 0, 1, onset)); 1900 children.add(new Property("recordedDate", "dateTime", "The recordedDate represents when this particular AllergyIntolerance record was created in the system, which is often a system-generated date.", 0, 1, recordedDate)); 1901 children.add(new Property("recorder", "Reference(Practitioner|PractitionerRole|Patient|RelatedPerson|Organization)", "Individual who recorded the record and takes responsibility for its content.", 0, 1, recorder)); 1902 children.add(new Property("asserter", "Reference(Patient|RelatedPerson|Practitioner|PractitionerRole)", "The source of the information about the allergy that is recorded.", 0, 1, asserter)); 1903 children.add(new Property("lastOccurrence", "dateTime", "Represents the date and/or time of the last known occurrence of a reaction event.", 0, 1, lastOccurrence)); 1904 children.add(new Property("note", "Annotation", "Additional narrative about the propensity for the Adverse Reaction, not captured in other fields.", 0, java.lang.Integer.MAX_VALUE, note)); 1905 children.add(new Property("reaction", "", "Details about each adverse reaction event linked to exposure to the identified substance.", 0, java.lang.Integer.MAX_VALUE, reaction)); 1906 } 1907 1908 @Override 1909 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1910 switch (_hash) { 1911 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server.", 0, java.lang.Integer.MAX_VALUE, identifier); 1912 case -462853915: /*clinicalStatus*/ return new Property("clinicalStatus", "CodeableConcept", "The clinical status of the allergy or intolerance.", 0, 1, clinicalStatus); 1913 case -842509843: /*verificationStatus*/ return new Property("verificationStatus", "CodeableConcept", "Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product). The verification status pertains to the allergy or intolerance, itself, not to any specific AllergyIntolerance attribute.", 0, 1, verificationStatus); 1914 case 3575610: /*type*/ return new Property("type", "code", "Identification of the underlying physiological mechanism for the reaction risk.", 0, 1, type); 1915 case 50511102: /*category*/ return new Property("category", "code", "Category of the identified substance.", 0, java.lang.Integer.MAX_VALUE, category); 1916 case -1608054609: /*criticality*/ return new Property("criticality", "code", "Estimate of the potential clinical harm, or seriousness, of the reaction to the identified substance.", 0, 1, criticality); 1917 case 3059181: /*code*/ return new Property("code", "CodeableConcept", "Code for an allergy or intolerance statement (either a positive or a negated/excluded statement). This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., \"Latex\"), an allergy or intolerance condition (e.g., \"Latex allergy\"), or a negated/excluded code for a specific substance or class (e.g., \"No latex allergy\") or a general or categorical negated statement (e.g., \"No known allergy\", \"No known drug allergies\"). Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'. If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.", 0, 1, code); 1918 case -791418107: /*patient*/ return new Property("patient", "Reference(Patient)", "The patient who has the allergy or intolerance.", 0, 1, patient); 1919 case 1524132147: /*encounter*/ return new Property("encounter", "Reference(Encounter)", "The encounter when the allergy or intolerance was asserted.", 0, 1, encounter); 1920 case -1886216323: /*onset[x]*/ return new Property("onset[x]", "dateTime|Age|Period|Range|string", "Estimated or actual date, date-time, or age when allergy or intolerance was identified.", 0, 1, onset); 1921 case 105901603: /*onset*/ return new Property("onset[x]", "dateTime|Age|Period|Range|string", "Estimated or actual date, date-time, or age when allergy or intolerance was identified.", 0, 1, onset); 1922 case -1701663010: /*onsetDateTime*/ return new Property("onset[x]", "dateTime", "Estimated or actual date, date-time, or age when allergy or intolerance was identified.", 0, 1, onset); 1923 case -1886241828: /*onsetAge*/ return new Property("onset[x]", "Age", "Estimated or actual date, date-time, or age when allergy or intolerance was identified.", 0, 1, onset); 1924 case -1545082428: /*onsetPeriod*/ return new Property("onset[x]", "Period", "Estimated or actual date, date-time, or age when allergy or intolerance was identified.", 0, 1, onset); 1925 case -186664742: /*onsetRange*/ return new Property("onset[x]", "Range", "Estimated or actual date, date-time, or age when allergy or intolerance was identified.", 0, 1, onset); 1926 case -1445342188: /*onsetString*/ return new Property("onset[x]", "string", "Estimated or actual date, date-time, or age when allergy or intolerance was identified.", 0, 1, onset); 1927 case -1952893826: /*recordedDate*/ return new Property("recordedDate", "dateTime", "The recordedDate represents when this particular AllergyIntolerance record was created in the system, which is often a system-generated date.", 0, 1, recordedDate); 1928 case -799233858: /*recorder*/ return new Property("recorder", "Reference(Practitioner|PractitionerRole|Patient|RelatedPerson|Organization)", "Individual who recorded the record and takes responsibility for its content.", 0, 1, recorder); 1929 case -373242253: /*asserter*/ return new Property("asserter", "Reference(Patient|RelatedPerson|Practitioner|PractitionerRole)", "The source of the information about the allergy that is recorded.", 0, 1, asserter); 1930 case 1896977671: /*lastOccurrence*/ return new Property("lastOccurrence", "dateTime", "Represents the date and/or time of the last known occurrence of a reaction event.", 0, 1, lastOccurrence); 1931 case 3387378: /*note*/ return new Property("note", "Annotation", "Additional narrative about the propensity for the Adverse Reaction, not captured in other fields.", 0, java.lang.Integer.MAX_VALUE, note); 1932 case -867509719: /*reaction*/ return new Property("reaction", "", "Details about each adverse reaction event linked to exposure to the identified substance.", 0, java.lang.Integer.MAX_VALUE, reaction); 1933 default: return super.getNamedProperty(_hash, _name, _checkValid); 1934 } 1935 1936 } 1937 1938 @Override 1939 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1940 switch (hash) { 1941 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 1942 case -462853915: /*clinicalStatus*/ return this.clinicalStatus == null ? new Base[0] : new Base[] {this.clinicalStatus}; // CodeableConcept 1943 case -842509843: /*verificationStatus*/ return this.verificationStatus == null ? new Base[0] : new Base[] {this.verificationStatus}; // CodeableConcept 1944 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // Enumeration<AllergyIntoleranceType> 1945 case 50511102: /*category*/ return this.category == null ? new Base[0] : this.category.toArray(new Base[this.category.size()]); // Enumeration<AllergyIntoleranceCategory> 1946 case -1608054609: /*criticality*/ return this.criticality == null ? new Base[0] : new Base[] {this.criticality}; // Enumeration<AllergyIntoleranceCriticality> 1947 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 1948 case -791418107: /*patient*/ return this.patient == null ? new Base[0] : new Base[] {this.patient}; // Reference 1949 case 1524132147: /*encounter*/ return this.encounter == null ? new Base[0] : new Base[] {this.encounter}; // Reference 1950 case 105901603: /*onset*/ return this.onset == null ? new Base[0] : new Base[] {this.onset}; // DataType 1951 case -1952893826: /*recordedDate*/ return this.recordedDate == null ? new Base[0] : new Base[] {this.recordedDate}; // DateTimeType 1952 case -799233858: /*recorder*/ return this.recorder == null ? new Base[0] : new Base[] {this.recorder}; // Reference 1953 case -373242253: /*asserter*/ return this.asserter == null ? new Base[0] : new Base[] {this.asserter}; // Reference 1954 case 1896977671: /*lastOccurrence*/ return this.lastOccurrence == null ? new Base[0] : new Base[] {this.lastOccurrence}; // DateTimeType 1955 case 3387378: /*note*/ return this.note == null ? new Base[0] : this.note.toArray(new Base[this.note.size()]); // Annotation 1956 case -867509719: /*reaction*/ return this.reaction == null ? new Base[0] : this.reaction.toArray(new Base[this.reaction.size()]); // AllergyIntoleranceReactionComponent 1957 default: return super.getProperty(hash, name, checkValid); 1958 } 1959 1960 } 1961 1962 @Override 1963 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1964 switch (hash) { 1965 case -1618432855: // identifier 1966 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); // Identifier 1967 return value; 1968 case -462853915: // clinicalStatus 1969 this.clinicalStatus = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1970 return value; 1971 case -842509843: // verificationStatus 1972 this.verificationStatus = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1973 return value; 1974 case 3575610: // type 1975 value = new AllergyIntoleranceTypeEnumFactory().fromType(TypeConvertor.castToCode(value)); 1976 this.type = (Enumeration) value; // Enumeration<AllergyIntoleranceType> 1977 return value; 1978 case 50511102: // category 1979 value = new AllergyIntoleranceCategoryEnumFactory().fromType(TypeConvertor.castToCode(value)); 1980 this.getCategory().add((Enumeration) value); // Enumeration<AllergyIntoleranceCategory> 1981 return value; 1982 case -1608054609: // criticality 1983 value = new AllergyIntoleranceCriticalityEnumFactory().fromType(TypeConvertor.castToCode(value)); 1984 this.criticality = (Enumeration) value; // Enumeration<AllergyIntoleranceCriticality> 1985 return value; 1986 case 3059181: // code 1987 this.code = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1988 return value; 1989 case -791418107: // patient 1990 this.patient = TypeConvertor.castToReference(value); // Reference 1991 return value; 1992 case 1524132147: // encounter 1993 this.encounter = TypeConvertor.castToReference(value); // Reference 1994 return value; 1995 case 105901603: // onset 1996 this.onset = TypeConvertor.castToType(value); // DataType 1997 return value; 1998 case -1952893826: // recordedDate 1999 this.recordedDate = TypeConvertor.castToDateTime(value); // DateTimeType 2000 return value; 2001 case -799233858: // recorder 2002 this.recorder = TypeConvertor.castToReference(value); // Reference 2003 return value; 2004 case -373242253: // asserter 2005 this.asserter = TypeConvertor.castToReference(value); // Reference 2006 return value; 2007 case 1896977671: // lastOccurrence 2008 this.lastOccurrence = TypeConvertor.castToDateTime(value); // DateTimeType 2009 return value; 2010 case 3387378: // note 2011 this.getNote().add(TypeConvertor.castToAnnotation(value)); // Annotation 2012 return value; 2013 case -867509719: // reaction 2014 this.getReaction().add((AllergyIntoleranceReactionComponent) value); // AllergyIntoleranceReactionComponent 2015 return value; 2016 default: return super.setProperty(hash, name, value); 2017 } 2018 2019 } 2020 2021 @Override 2022 public Base setProperty(String name, Base value) throws FHIRException { 2023 if (name.equals("identifier")) { 2024 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); 2025 } else if (name.equals("clinicalStatus")) { 2026 this.clinicalStatus = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2027 } else if (name.equals("verificationStatus")) { 2028 this.verificationStatus = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2029 } else if (name.equals("type")) { 2030 value = new AllergyIntoleranceTypeEnumFactory().fromType(TypeConvertor.castToCode(value)); 2031 this.type = (Enumeration) value; // Enumeration<AllergyIntoleranceType> 2032 } else if (name.equals("category")) { 2033 value = new AllergyIntoleranceCategoryEnumFactory().fromType(TypeConvertor.castToCode(value)); 2034 this.getCategory().add((Enumeration) value); 2035 } else if (name.equals("criticality")) { 2036 value = new AllergyIntoleranceCriticalityEnumFactory().fromType(TypeConvertor.castToCode(value)); 2037 this.criticality = (Enumeration) value; // Enumeration<AllergyIntoleranceCriticality> 2038 } else if (name.equals("code")) { 2039 this.code = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2040 } else if (name.equals("patient")) { 2041 this.patient = TypeConvertor.castToReference(value); // Reference 2042 } else if (name.equals("encounter")) { 2043 this.encounter = TypeConvertor.castToReference(value); // Reference 2044 } else if (name.equals("onset[x]")) { 2045 this.onset = TypeConvertor.castToType(value); // DataType 2046 } else if (name.equals("recordedDate")) { 2047 this.recordedDate = TypeConvertor.castToDateTime(value); // DateTimeType 2048 } else if (name.equals("recorder")) { 2049 this.recorder = TypeConvertor.castToReference(value); // Reference 2050 } else if (name.equals("asserter")) { 2051 this.asserter = TypeConvertor.castToReference(value); // Reference 2052 } else if (name.equals("lastOccurrence")) { 2053 this.lastOccurrence = TypeConvertor.castToDateTime(value); // DateTimeType 2054 } else if (name.equals("note")) { 2055 this.getNote().add(TypeConvertor.castToAnnotation(value)); 2056 } else if (name.equals("reaction")) { 2057 this.getReaction().add((AllergyIntoleranceReactionComponent) value); 2058 } else 2059 return super.setProperty(name, value); 2060 return value; 2061 } 2062 2063 @Override 2064 public Base makeProperty(int hash, String name) throws FHIRException { 2065 switch (hash) { 2066 case -1618432855: return addIdentifier(); 2067 case -462853915: return getClinicalStatus(); 2068 case -842509843: return getVerificationStatus(); 2069 case 3575610: return getTypeElement(); 2070 case 50511102: return addCategoryElement(); 2071 case -1608054609: return getCriticalityElement(); 2072 case 3059181: return getCode(); 2073 case -791418107: return getPatient(); 2074 case 1524132147: return getEncounter(); 2075 case -1886216323: return getOnset(); 2076 case 105901603: return getOnset(); 2077 case -1952893826: return getRecordedDateElement(); 2078 case -799233858: return getRecorder(); 2079 case -373242253: return getAsserter(); 2080 case 1896977671: return getLastOccurrenceElement(); 2081 case 3387378: return addNote(); 2082 case -867509719: return addReaction(); 2083 default: return super.makeProperty(hash, name); 2084 } 2085 2086 } 2087 2088 @Override 2089 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2090 switch (hash) { 2091 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 2092 case -462853915: /*clinicalStatus*/ return new String[] {"CodeableConcept"}; 2093 case -842509843: /*verificationStatus*/ return new String[] {"CodeableConcept"}; 2094 case 3575610: /*type*/ return new String[] {"code"}; 2095 case 50511102: /*category*/ return new String[] {"code"}; 2096 case -1608054609: /*criticality*/ return new String[] {"code"}; 2097 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 2098 case -791418107: /*patient*/ return new String[] {"Reference"}; 2099 case 1524132147: /*encounter*/ return new String[] {"Reference"}; 2100 case 105901603: /*onset*/ return new String[] {"dateTime", "Age", "Period", "Range", "string"}; 2101 case -1952893826: /*recordedDate*/ return new String[] {"dateTime"}; 2102 case -799233858: /*recorder*/ return new String[] {"Reference"}; 2103 case -373242253: /*asserter*/ return new String[] {"Reference"}; 2104 case 1896977671: /*lastOccurrence*/ return new String[] {"dateTime"}; 2105 case 3387378: /*note*/ return new String[] {"Annotation"}; 2106 case -867509719: /*reaction*/ return new String[] {}; 2107 default: return super.getTypesForProperty(hash, name); 2108 } 2109 2110 } 2111 2112 @Override 2113 public Base addChild(String name) throws FHIRException { 2114 if (name.equals("identifier")) { 2115 return addIdentifier(); 2116 } 2117 else if (name.equals("clinicalStatus")) { 2118 this.clinicalStatus = new CodeableConcept(); 2119 return this.clinicalStatus; 2120 } 2121 else if (name.equals("verificationStatus")) { 2122 this.verificationStatus = new CodeableConcept(); 2123 return this.verificationStatus; 2124 } 2125 else if (name.equals("type")) { 2126 throw new FHIRException("Cannot call addChild on a primitive type AllergyIntolerance.type"); 2127 } 2128 else if (name.equals("category")) { 2129 throw new FHIRException("Cannot call addChild on a primitive type AllergyIntolerance.category"); 2130 } 2131 else if (name.equals("criticality")) { 2132 throw new FHIRException("Cannot call addChild on a primitive type AllergyIntolerance.criticality"); 2133 } 2134 else if (name.equals("code")) { 2135 this.code = new CodeableConcept(); 2136 return this.code; 2137 } 2138 else if (name.equals("patient")) { 2139 this.patient = new Reference(); 2140 return this.patient; 2141 } 2142 else if (name.equals("encounter")) { 2143 this.encounter = new Reference(); 2144 return this.encounter; 2145 } 2146 else if (name.equals("onsetDateTime")) { 2147 this.onset = new DateTimeType(); 2148 return this.onset; 2149 } 2150 else if (name.equals("onsetAge")) { 2151 this.onset = new Age(); 2152 return this.onset; 2153 } 2154 else if (name.equals("onsetPeriod")) { 2155 this.onset = new Period(); 2156 return this.onset; 2157 } 2158 else if (name.equals("onsetRange")) { 2159 this.onset = new Range(); 2160 return this.onset; 2161 } 2162 else if (name.equals("onsetString")) { 2163 this.onset = new StringType(); 2164 return this.onset; 2165 } 2166 else if (name.equals("recordedDate")) { 2167 throw new FHIRException("Cannot call addChild on a primitive type AllergyIntolerance.recordedDate"); 2168 } 2169 else if (name.equals("recorder")) { 2170 this.recorder = new Reference(); 2171 return this.recorder; 2172 } 2173 else if (name.equals("asserter")) { 2174 this.asserter = new Reference(); 2175 return this.asserter; 2176 } 2177 else if (name.equals("lastOccurrence")) { 2178 throw new FHIRException("Cannot call addChild on a primitive type AllergyIntolerance.lastOccurrence"); 2179 } 2180 else if (name.equals("note")) { 2181 return addNote(); 2182 } 2183 else if (name.equals("reaction")) { 2184 return addReaction(); 2185 } 2186 else 2187 return super.addChild(name); 2188 } 2189 2190 public String fhirType() { 2191 return "AllergyIntolerance"; 2192 2193 } 2194 2195 public AllergyIntolerance copy() { 2196 AllergyIntolerance dst = new AllergyIntolerance(); 2197 copyValues(dst); 2198 return dst; 2199 } 2200 2201 public void copyValues(AllergyIntolerance dst) { 2202 super.copyValues(dst); 2203 if (identifier != null) { 2204 dst.identifier = new ArrayList<Identifier>(); 2205 for (Identifier i : identifier) 2206 dst.identifier.add(i.copy()); 2207 }; 2208 dst.clinicalStatus = clinicalStatus == null ? null : clinicalStatus.copy(); 2209 dst.verificationStatus = verificationStatus == null ? null : verificationStatus.copy(); 2210 dst.type = type == null ? null : type.copy(); 2211 if (category != null) { 2212 dst.category = new ArrayList<Enumeration<AllergyIntoleranceCategory>>(); 2213 for (Enumeration<AllergyIntoleranceCategory> i : category) 2214 dst.category.add(i.copy()); 2215 }; 2216 dst.criticality = criticality == null ? null : criticality.copy(); 2217 dst.code = code == null ? null : code.copy(); 2218 dst.patient = patient == null ? null : patient.copy(); 2219 dst.encounter = encounter == null ? null : encounter.copy(); 2220 dst.onset = onset == null ? null : onset.copy(); 2221 dst.recordedDate = recordedDate == null ? null : recordedDate.copy(); 2222 dst.recorder = recorder == null ? null : recorder.copy(); 2223 dst.asserter = asserter == null ? null : asserter.copy(); 2224 dst.lastOccurrence = lastOccurrence == null ? null : lastOccurrence.copy(); 2225 if (note != null) { 2226 dst.note = new ArrayList<Annotation>(); 2227 for (Annotation i : note) 2228 dst.note.add(i.copy()); 2229 }; 2230 if (reaction != null) { 2231 dst.reaction = new ArrayList<AllergyIntoleranceReactionComponent>(); 2232 for (AllergyIntoleranceReactionComponent i : reaction) 2233 dst.reaction.add(i.copy()); 2234 }; 2235 } 2236 2237 protected AllergyIntolerance typedCopy() { 2238 return copy(); 2239 } 2240 2241 @Override 2242 public boolean equalsDeep(Base other_) { 2243 if (!super.equalsDeep(other_)) 2244 return false; 2245 if (!(other_ instanceof AllergyIntolerance)) 2246 return false; 2247 AllergyIntolerance o = (AllergyIntolerance) other_; 2248 return compareDeep(identifier, o.identifier, true) && compareDeep(clinicalStatus, o.clinicalStatus, true) 2249 && compareDeep(verificationStatus, o.verificationStatus, true) && compareDeep(type, o.type, true) 2250 && compareDeep(category, o.category, true) && compareDeep(criticality, o.criticality, true) && compareDeep(code, o.code, true) 2251 && compareDeep(patient, o.patient, true) && compareDeep(encounter, o.encounter, true) && compareDeep(onset, o.onset, true) 2252 && compareDeep(recordedDate, o.recordedDate, true) && compareDeep(recorder, o.recorder, true) && compareDeep(asserter, o.asserter, true) 2253 && compareDeep(lastOccurrence, o.lastOccurrence, true) && compareDeep(note, o.note, true) && compareDeep(reaction, o.reaction, true) 2254 ; 2255 } 2256 2257 @Override 2258 public boolean equalsShallow(Base other_) { 2259 if (!super.equalsShallow(other_)) 2260 return false; 2261 if (!(other_ instanceof AllergyIntolerance)) 2262 return false; 2263 AllergyIntolerance o = (AllergyIntolerance) other_; 2264 return compareValues(type, o.type, true) && compareValues(category, o.category, true) && compareValues(criticality, o.criticality, true) 2265 && compareValues(recordedDate, o.recordedDate, true) && compareValues(lastOccurrence, o.lastOccurrence, true) 2266 ; 2267 } 2268 2269 public boolean isEmpty() { 2270 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, clinicalStatus 2271 , verificationStatus, type, category, criticality, code, patient, encounter, onset 2272 , recordedDate, recorder, asserter, lastOccurrence, note, reaction); 2273 } 2274 2275 @Override 2276 public ResourceType getResourceType() { 2277 return ResourceType.AllergyIntolerance; 2278 } 2279 2280 /** 2281 * Search parameter: <b>asserter</b> 2282 * <p> 2283 * Description: <b>Source of the information about the allergy</b><br> 2284 * Type: <b>reference</b><br> 2285 * Path: <b>AllergyIntolerance.asserter</b><br> 2286 * </p> 2287 */ 2288 @SearchParamDefinition(name="asserter", path="AllergyIntolerance.asserter", description="Source of the information about the allergy", 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={Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } ) 2289 public static final String SP_ASSERTER = "asserter"; 2290 /** 2291 * <b>Fluent Client</b> search parameter constant for <b>asserter</b> 2292 * <p> 2293 * Description: <b>Source of the information about the allergy</b><br> 2294 * Type: <b>reference</b><br> 2295 * Path: <b>AllergyIntolerance.asserter</b><br> 2296 * </p> 2297 */ 2298 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ASSERTER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ASSERTER); 2299 2300/** 2301 * Constant for fluent queries to be used to add include statements. Specifies 2302 * the path value of "<b>AllergyIntolerance:asserter</b>". 2303 */ 2304 public static final ca.uhn.fhir.model.api.Include INCLUDE_ASSERTER = new ca.uhn.fhir.model.api.Include("AllergyIntolerance:asserter").toLocked(); 2305 2306 /** 2307 * Search parameter: <b>category</b> 2308 * <p> 2309 * Description: <b>food | medication | environment | biologic</b><br> 2310 * Type: <b>token</b><br> 2311 * Path: <b>AllergyIntolerance.category</b><br> 2312 * </p> 2313 */ 2314 @SearchParamDefinition(name="category", path="AllergyIntolerance.category", description="food | medication | environment | biologic", type="token" ) 2315 public static final String SP_CATEGORY = "category"; 2316 /** 2317 * <b>Fluent Client</b> search parameter constant for <b>category</b> 2318 * <p> 2319 * Description: <b>food | medication | environment | biologic</b><br> 2320 * Type: <b>token</b><br> 2321 * Path: <b>AllergyIntolerance.category</b><br> 2322 * </p> 2323 */ 2324 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CATEGORY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CATEGORY); 2325 2326 /** 2327 * Search parameter: <b>clinical-status</b> 2328 * <p> 2329 * Description: <b>active | inactive | resolved</b><br> 2330 * Type: <b>token</b><br> 2331 * Path: <b>AllergyIntolerance.clinicalStatus</b><br> 2332 * </p> 2333 */ 2334 @SearchParamDefinition(name="clinical-status", path="AllergyIntolerance.clinicalStatus", description="active | inactive | resolved", type="token" ) 2335 public static final String SP_CLINICAL_STATUS = "clinical-status"; 2336 /** 2337 * <b>Fluent Client</b> search parameter constant for <b>clinical-status</b> 2338 * <p> 2339 * Description: <b>active | inactive | resolved</b><br> 2340 * Type: <b>token</b><br> 2341 * Path: <b>AllergyIntolerance.clinicalStatus</b><br> 2342 * </p> 2343 */ 2344 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CLINICAL_STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CLINICAL_STATUS); 2345 2346 /** 2347 * Search parameter: <b>criticality</b> 2348 * <p> 2349 * Description: <b>low | high | unable-to-assess</b><br> 2350 * Type: <b>token</b><br> 2351 * Path: <b>AllergyIntolerance.criticality</b><br> 2352 * </p> 2353 */ 2354 @SearchParamDefinition(name="criticality", path="AllergyIntolerance.criticality", description="low | high | unable-to-assess", type="token" ) 2355 public static final String SP_CRITICALITY = "criticality"; 2356 /** 2357 * <b>Fluent Client</b> search parameter constant for <b>criticality</b> 2358 * <p> 2359 * Description: <b>low | high | unable-to-assess</b><br> 2360 * Type: <b>token</b><br> 2361 * Path: <b>AllergyIntolerance.criticality</b><br> 2362 * </p> 2363 */ 2364 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CRITICALITY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CRITICALITY); 2365 2366 /** 2367 * Search parameter: <b>last-date</b> 2368 * <p> 2369 * Description: <b>Date(/time) of last known occurrence of a reaction</b><br> 2370 * Type: <b>date</b><br> 2371 * Path: <b>AllergyIntolerance.lastOccurrence</b><br> 2372 * </p> 2373 */ 2374 @SearchParamDefinition(name="last-date", path="AllergyIntolerance.lastOccurrence", description="Date(/time) of last known occurrence of a reaction", type="date" ) 2375 public static final String SP_LAST_DATE = "last-date"; 2376 /** 2377 * <b>Fluent Client</b> search parameter constant for <b>last-date</b> 2378 * <p> 2379 * Description: <b>Date(/time) of last known occurrence of a reaction</b><br> 2380 * Type: <b>date</b><br> 2381 * Path: <b>AllergyIntolerance.lastOccurrence</b><br> 2382 * </p> 2383 */ 2384 public static final ca.uhn.fhir.rest.gclient.DateClientParam LAST_DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_LAST_DATE); 2385 2386 /** 2387 * Search parameter: <b>manifestation-code</b> 2388 * <p> 2389 * Description: <b>Clinical symptoms/signs associated with the Event</b><br> 2390 * Type: <b>token</b><br> 2391 * Path: <b>AllergyIntolerance.reaction.manifestation.concept</b><br> 2392 * </p> 2393 */ 2394 @SearchParamDefinition(name="manifestation-code", path="AllergyIntolerance.reaction.manifestation.concept", description="Clinical symptoms/signs associated with the Event", type="token" ) 2395 public static final String SP_MANIFESTATION_CODE = "manifestation-code"; 2396 /** 2397 * <b>Fluent Client</b> search parameter constant for <b>manifestation-code</b> 2398 * <p> 2399 * Description: <b>Clinical symptoms/signs associated with the Event</b><br> 2400 * Type: <b>token</b><br> 2401 * Path: <b>AllergyIntolerance.reaction.manifestation.concept</b><br> 2402 * </p> 2403 */ 2404 public static final ca.uhn.fhir.rest.gclient.TokenClientParam MANIFESTATION_CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_MANIFESTATION_CODE); 2405 2406 /** 2407 * Search parameter: <b>manifestation-reference</b> 2408 * <p> 2409 * Description: <b>Clinical symptoms/signs associated with the Event</b><br> 2410 * Type: <b>reference</b><br> 2411 * Path: <b>AllergyIntolerance.reaction.manifestation.reference</b><br> 2412 * </p> 2413 */ 2414 @SearchParamDefinition(name="manifestation-reference", path="AllergyIntolerance.reaction.manifestation.reference", description="Clinical symptoms/signs associated with the Event", type="reference" ) 2415 public static final String SP_MANIFESTATION_REFERENCE = "manifestation-reference"; 2416 /** 2417 * <b>Fluent Client</b> search parameter constant for <b>manifestation-reference</b> 2418 * <p> 2419 * Description: <b>Clinical symptoms/signs associated with the Event</b><br> 2420 * Type: <b>reference</b><br> 2421 * Path: <b>AllergyIntolerance.reaction.manifestation.reference</b><br> 2422 * </p> 2423 */ 2424 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam MANIFESTATION_REFERENCE = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_MANIFESTATION_REFERENCE); 2425 2426/** 2427 * Constant for fluent queries to be used to add include statements. Specifies 2428 * the path value of "<b>AllergyIntolerance:manifestation-reference</b>". 2429 */ 2430 public static final ca.uhn.fhir.model.api.Include INCLUDE_MANIFESTATION_REFERENCE = new ca.uhn.fhir.model.api.Include("AllergyIntolerance:manifestation-reference").toLocked(); 2431 2432 /** 2433 * Search parameter: <b>recorder</b> 2434 * <p> 2435 * Description: <b>Who recorded the sensitivity</b><br> 2436 * Type: <b>reference</b><br> 2437 * Path: <b>AllergyIntolerance.recorder</b><br> 2438 * </p> 2439 */ 2440 @SearchParamDefinition(name="recorder", path="AllergyIntolerance.recorder", description="Who recorded the sensitivity", 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") }, target={Organization.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } ) 2441 public static final String SP_RECORDER = "recorder"; 2442 /** 2443 * <b>Fluent Client</b> search parameter constant for <b>recorder</b> 2444 * <p> 2445 * Description: <b>Who recorded the sensitivity</b><br> 2446 * Type: <b>reference</b><br> 2447 * Path: <b>AllergyIntolerance.recorder</b><br> 2448 * </p> 2449 */ 2450 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam RECORDER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_RECORDER); 2451 2452/** 2453 * Constant for fluent queries to be used to add include statements. Specifies 2454 * the path value of "<b>AllergyIntolerance:recorder</b>". 2455 */ 2456 public static final ca.uhn.fhir.model.api.Include INCLUDE_RECORDER = new ca.uhn.fhir.model.api.Include("AllergyIntolerance:recorder").toLocked(); 2457 2458 /** 2459 * Search parameter: <b>route</b> 2460 * <p> 2461 * Description: <b>How the subject was exposed to the substance</b><br> 2462 * Type: <b>token</b><br> 2463 * Path: <b>AllergyIntolerance.reaction.exposureRoute</b><br> 2464 * </p> 2465 */ 2466 @SearchParamDefinition(name="route", path="AllergyIntolerance.reaction.exposureRoute", description="How the subject was exposed to the substance", type="token" ) 2467 public static final String SP_ROUTE = "route"; 2468 /** 2469 * <b>Fluent Client</b> search parameter constant for <b>route</b> 2470 * <p> 2471 * Description: <b>How the subject was exposed to the substance</b><br> 2472 * Type: <b>token</b><br> 2473 * Path: <b>AllergyIntolerance.reaction.exposureRoute</b><br> 2474 * </p> 2475 */ 2476 public static final ca.uhn.fhir.rest.gclient.TokenClientParam ROUTE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_ROUTE); 2477 2478 /** 2479 * Search parameter: <b>severity</b> 2480 * <p> 2481 * Description: <b>mild | moderate | severe (of event as a whole)</b><br> 2482 * Type: <b>token</b><br> 2483 * Path: <b>AllergyIntolerance.reaction.severity</b><br> 2484 * </p> 2485 */ 2486 @SearchParamDefinition(name="severity", path="AllergyIntolerance.reaction.severity", description="mild | moderate | severe (of event as a whole)", type="token" ) 2487 public static final String SP_SEVERITY = "severity"; 2488 /** 2489 * <b>Fluent Client</b> search parameter constant for <b>severity</b> 2490 * <p> 2491 * Description: <b>mild | moderate | severe (of event as a whole)</b><br> 2492 * Type: <b>token</b><br> 2493 * Path: <b>AllergyIntolerance.reaction.severity</b><br> 2494 * </p> 2495 */ 2496 public static final ca.uhn.fhir.rest.gclient.TokenClientParam SEVERITY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_SEVERITY); 2497 2498 /** 2499 * Search parameter: <b>verification-status</b> 2500 * <p> 2501 * Description: <b>unconfirmed | presumed | confirmed | refuted | entered-in-error</b><br> 2502 * Type: <b>token</b><br> 2503 * Path: <b>AllergyIntolerance.verificationStatus</b><br> 2504 * </p> 2505 */ 2506 @SearchParamDefinition(name="verification-status", path="AllergyIntolerance.verificationStatus", description="unconfirmed | presumed | confirmed | refuted | entered-in-error", type="token" ) 2507 public static final String SP_VERIFICATION_STATUS = "verification-status"; 2508 /** 2509 * <b>Fluent Client</b> search parameter constant for <b>verification-status</b> 2510 * <p> 2511 * Description: <b>unconfirmed | presumed | confirmed | refuted | entered-in-error</b><br> 2512 * Type: <b>token</b><br> 2513 * Path: <b>AllergyIntolerance.verificationStatus</b><br> 2514 * </p> 2515 */ 2516 public static final ca.uhn.fhir.rest.gclient.TokenClientParam VERIFICATION_STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_VERIFICATION_STATUS); 2517 2518 /** 2519 * Search parameter: <b>code</b> 2520 * <p> 2521 * Description: <b>Multiple Resources: 2522 2523* [AllergyIntolerance](allergyintolerance.html): Code that identifies the allergy or intolerance 2524* [Condition](condition.html): Code for the condition 2525* [DeviceRequest](devicerequest.html): Code for what is being requested/ordered 2526* [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 2527* [FamilyMemberHistory](familymemberhistory.html): A search by a condition code 2528* [List](list.html): What the purpose of this list is 2529* [Medication](medication.html): Returns medications for a specific code 2530* [MedicationAdministration](medicationadministration.html): Return administrations of this medication code 2531* [MedicationDispense](medicationdispense.html): Returns dispenses of this medicine code 2532* [MedicationRequest](medicationrequest.html): Return prescriptions of this medication code 2533* [MedicationUsage](medicationusage.html): Return statements of this medication code 2534* [Observation](observation.html): The code of the observation type 2535* [Procedure](procedure.html): A code to identify a procedure 2536* [ServiceRequest](servicerequest.html): What is being requested/ordered 2537</b><br> 2538 * Type: <b>token</b><br> 2539 * 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 | ServiceRequest.code</b><br> 2540 * </p> 2541 */ 2542 @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 | ServiceRequest.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* [ServiceRequest](servicerequest.html): What is being requested/ordered\r\n", type="token" ) 2543 public static final String SP_CODE = "code"; 2544 /** 2545 * <b>Fluent Client</b> search parameter constant for <b>code</b> 2546 * <p> 2547 * Description: <b>Multiple Resources: 2548 2549* [AllergyIntolerance](allergyintolerance.html): Code that identifies the allergy or intolerance 2550* [Condition](condition.html): Code for the condition 2551* [DeviceRequest](devicerequest.html): Code for what is being requested/ordered 2552* [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 2553* [FamilyMemberHistory](familymemberhistory.html): A search by a condition code 2554* [List](list.html): What the purpose of this list is 2555* [Medication](medication.html): Returns medications for a specific code 2556* [MedicationAdministration](medicationadministration.html): Return administrations of this medication code 2557* [MedicationDispense](medicationdispense.html): Returns dispenses of this medicine code 2558* [MedicationRequest](medicationrequest.html): Return prescriptions of this medication code 2559* [MedicationUsage](medicationusage.html): Return statements of this medication code 2560* [Observation](observation.html): The code of the observation type 2561* [Procedure](procedure.html): A code to identify a procedure 2562* [ServiceRequest](servicerequest.html): What is being requested/ordered 2563</b><br> 2564 * Type: <b>token</b><br> 2565 * 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 | ServiceRequest.code</b><br> 2566 * </p> 2567 */ 2568 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CODE); 2569 2570 /** 2571 * Search parameter: <b>date</b> 2572 * <p> 2573 * Description: <b>Multiple Resources: 2574 2575* [AllergyIntolerance](allergyintolerance.html): Date first version of the resource instance was recorded 2576* [CarePlan](careplan.html): Time period plan covers 2577* [CareTeam](careteam.html): A date within the coverage time period. 2578* [ClinicalImpression](clinicalimpression.html): When the assessment was documented 2579* [Composition](composition.html): Composition editing time 2580* [Consent](consent.html): When consent was agreed to 2581* [DiagnosticReport](diagnosticreport.html): The clinically relevant time of the report 2582* [Encounter](encounter.html): A date within the actualPeriod the Encounter lasted 2583* [EpisodeOfCare](episodeofcare.html): The provided date search value falls within the episode of care's period 2584* [FamilyMemberHistory](familymemberhistory.html): When history was recorded or last updated 2585* [Flag](flag.html): Time period when flag is active 2586* [Immunization](immunization.html): Vaccination (non)-Administration Date 2587* [List](list.html): When the list was prepared 2588* [Observation](observation.html): Obtained date/time. If the obtained element is a period, a date that falls in the period 2589* [Procedure](procedure.html): When the procedure occurred or is occurring 2590* [RiskAssessment](riskassessment.html): When was assessment made? 2591* [SupplyRequest](supplyrequest.html): When the request was made 2592</b><br> 2593 * Type: <b>date</b><br> 2594 * 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> 2595 * </p> 2596 */ 2597 @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" ) 2598 public static final String SP_DATE = "date"; 2599 /** 2600 * <b>Fluent Client</b> search parameter constant for <b>date</b> 2601 * <p> 2602 * Description: <b>Multiple Resources: 2603 2604* [AllergyIntolerance](allergyintolerance.html): Date first version of the resource instance was recorded 2605* [CarePlan](careplan.html): Time period plan covers 2606* [CareTeam](careteam.html): A date within the coverage time period. 2607* [ClinicalImpression](clinicalimpression.html): When the assessment was documented 2608* [Composition](composition.html): Composition editing time 2609* [Consent](consent.html): When consent was agreed to 2610* [DiagnosticReport](diagnosticreport.html): The clinically relevant time of the report 2611* [Encounter](encounter.html): A date within the actualPeriod the Encounter lasted 2612* [EpisodeOfCare](episodeofcare.html): The provided date search value falls within the episode of care's period 2613* [FamilyMemberHistory](familymemberhistory.html): When history was recorded or last updated 2614* [Flag](flag.html): Time period when flag is active 2615* [Immunization](immunization.html): Vaccination (non)-Administration Date 2616* [List](list.html): When the list was prepared 2617* [Observation](observation.html): Obtained date/time. If the obtained element is a period, a date that falls in the period 2618* [Procedure](procedure.html): When the procedure occurred or is occurring 2619* [RiskAssessment](riskassessment.html): When was assessment made? 2620* [SupplyRequest](supplyrequest.html): When the request was made 2621</b><br> 2622 * Type: <b>date</b><br> 2623 * 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> 2624 * </p> 2625 */ 2626 public static final ca.uhn.fhir.rest.gclient.DateClientParam DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_DATE); 2627 2628 /** 2629 * Search parameter: <b>identifier</b> 2630 * <p> 2631 * Description: <b>Multiple Resources: 2632 2633* [AllergyIntolerance](allergyintolerance.html): External ids for this item 2634* [CarePlan](careplan.html): External Ids for this plan 2635* [CareTeam](careteam.html): External Ids for this team 2636* [Composition](composition.html): Version-independent identifier for the Composition 2637* [Condition](condition.html): A unique identifier of the condition record 2638* [Consent](consent.html): Identifier for this record (external references) 2639* [DetectedIssue](detectedissue.html): Unique id for the detected issue 2640* [DeviceRequest](devicerequest.html): Business identifier for request/order 2641* [DiagnosticReport](diagnosticreport.html): An identifier for the report 2642* [DocumentManifest](documentmanifest.html): Unique Identifier for the set of documents 2643* [DocumentReference](documentreference.html): Identifier of the attachment binary 2644* [Encounter](encounter.html): Identifier(s) by which this encounter is known 2645* [EpisodeOfCare](episodeofcare.html): Business Identifier(s) relevant for this EpisodeOfCare 2646* [FamilyMemberHistory](familymemberhistory.html): A search by a record identifier 2647* [Goal](goal.html): External Ids for this goal 2648* [ImagingStudy](imagingstudy.html): Identifiers for the Study, such as DICOM Study Instance UID 2649* [Immunization](immunization.html): Business identifier 2650* [List](list.html): Business identifier 2651* [MedicationAdministration](medicationadministration.html): Return administrations with this external identifier 2652* [MedicationDispense](medicationdispense.html): Returns dispenses with this external identifier 2653* [MedicationRequest](medicationrequest.html): Return prescriptions with this external identifier 2654* [MedicationUsage](medicationusage.html): Return statements with this external identifier 2655* [NutritionOrder](nutritionorder.html): Return nutrition orders with this external identifier 2656* [Observation](observation.html): The unique id for a particular observation 2657* [Procedure](procedure.html): A unique identifier for a procedure 2658* [RiskAssessment](riskassessment.html): Unique identifier for the assessment 2659* [ServiceRequest](servicerequest.html): Identifiers assigned to this order 2660* [SupplyDelivery](supplydelivery.html): External identifier 2661* [SupplyRequest](supplyrequest.html): Business Identifier for SupplyRequest 2662* [VisionPrescription](visionprescription.html): Return prescriptions with this external identifier 2663</b><br> 2664 * Type: <b>token</b><br> 2665 * 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.content.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> 2666 * </p> 2667 */ 2668 @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.content.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" ) 2669 public static final String SP_IDENTIFIER = "identifier"; 2670 /** 2671 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 2672 * <p> 2673 * Description: <b>Multiple Resources: 2674 2675* [AllergyIntolerance](allergyintolerance.html): External ids for this item 2676* [CarePlan](careplan.html): External Ids for this plan 2677* [CareTeam](careteam.html): External Ids for this team 2678* [Composition](composition.html): Version-independent identifier for the Composition 2679* [Condition](condition.html): A unique identifier of the condition record 2680* [Consent](consent.html): Identifier for this record (external references) 2681* [DetectedIssue](detectedissue.html): Unique id for the detected issue 2682* [DeviceRequest](devicerequest.html): Business identifier for request/order 2683* [DiagnosticReport](diagnosticreport.html): An identifier for the report 2684* [DocumentManifest](documentmanifest.html): Unique Identifier for the set of documents 2685* [DocumentReference](documentreference.html): Identifier of the attachment binary 2686* [Encounter](encounter.html): Identifier(s) by which this encounter is known 2687* [EpisodeOfCare](episodeofcare.html): Business Identifier(s) relevant for this EpisodeOfCare 2688* [FamilyMemberHistory](familymemberhistory.html): A search by a record identifier 2689* [Goal](goal.html): External Ids for this goal 2690* [ImagingStudy](imagingstudy.html): Identifiers for the Study, such as DICOM Study Instance UID 2691* [Immunization](immunization.html): Business identifier 2692* [List](list.html): Business identifier 2693* [MedicationAdministration](medicationadministration.html): Return administrations with this external identifier 2694* [MedicationDispense](medicationdispense.html): Returns dispenses with this external identifier 2695* [MedicationRequest](medicationrequest.html): Return prescriptions with this external identifier 2696* [MedicationUsage](medicationusage.html): Return statements with this external identifier 2697* [NutritionOrder](nutritionorder.html): Return nutrition orders with this external identifier 2698* [Observation](observation.html): The unique id for a particular observation 2699* [Procedure](procedure.html): A unique identifier for a procedure 2700* [RiskAssessment](riskassessment.html): Unique identifier for the assessment 2701* [ServiceRequest](servicerequest.html): Identifiers assigned to this order 2702* [SupplyDelivery](supplydelivery.html): External identifier 2703* [SupplyRequest](supplyrequest.html): Business Identifier for SupplyRequest 2704* [VisionPrescription](visionprescription.html): Return prescriptions with this external identifier 2705</b><br> 2706 * Type: <b>token</b><br> 2707 * 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.content.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> 2708 * </p> 2709 */ 2710 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 2711 2712 /** 2713 * Search parameter: <b>patient</b> 2714 * <p> 2715 * Description: <b>Multiple Resources: 2716 2717* [AllergyIntolerance](allergyintolerance.html): Who the sensitivity is for 2718* [CarePlan](careplan.html): Who the care plan is for 2719* [CareTeam](careteam.html): Who care team is for 2720* [ClinicalImpression](clinicalimpression.html): Patient assessed 2721* [Composition](composition.html): Who and/or what the composition is about 2722* [Condition](condition.html): Who has the condition? 2723* [Consent](consent.html): Who the consent applies to 2724* [DetectedIssue](detectedissue.html): Associated patient 2725* [DeviceRequest](devicerequest.html): Individual the service is ordered for 2726* [DeviceUsage](deviceusage.html): Search by patient who used / uses the device 2727* [DiagnosticReport](diagnosticreport.html): The subject of the report if a patient 2728* [DocumentManifest](documentmanifest.html): The subject of the set of documents 2729* [DocumentReference](documentreference.html): Who/what is the subject of the document 2730* [Encounter](encounter.html): The patient present at the encounter 2731* [EpisodeOfCare](episodeofcare.html): The patient who is the focus of this episode of care 2732* [FamilyMemberHistory](familymemberhistory.html): The identity of a subject to list family member history items for 2733* [Flag](flag.html): The identity of a subject to list flags for 2734* [Goal](goal.html): Who this goal is intended for 2735* [ImagingStudy](imagingstudy.html): Who the study is about 2736* [Immunization](immunization.html): The patient for the vaccination record 2737* [List](list.html): If all resources have the same subject 2738* [MedicationAdministration](medicationadministration.html): The identity of a patient to list administrations for 2739* [MedicationDispense](medicationdispense.html): The identity of a patient to list dispenses for 2740* [MedicationRequest](medicationrequest.html): Returns prescriptions for a specific patient 2741* [MedicationUsage](medicationusage.html): Returns statements for a specific patient. 2742* [NutritionOrder](nutritionorder.html): The identity of the person who requires the diet, formula or nutritional supplement 2743* [Observation](observation.html): The subject that the observation is about (if patient) 2744* [Procedure](procedure.html): Search by subject - a patient 2745* [RiskAssessment](riskassessment.html): Who/what does assessment apply to? 2746* [ServiceRequest](servicerequest.html): Search by subject - a patient 2747* [SupplyDelivery](supplydelivery.html): Patient for whom the item is supplied 2748* [VisionPrescription](visionprescription.html): The identity of a patient to list dispenses for 2749</b><br> 2750 * Type: <b>reference</b><br> 2751 * 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.patient | 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.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> 2752 * </p> 2753 */ 2754 @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.patient | 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.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 person 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", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Patient") }, target={Account.class, ActivityDefinition.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, CapabilityStatement2.class, CarePlan.class, CareTeam.class, ChargeItem.class, ChargeItemDefinition.class, Citation.class, Claim.class, ClaimResponse.class, ClinicalImpression.class, ClinicalUseDefinition.class, ClinicalUseIssue.class, CodeSystem.class, Communication.class, CommunicationRequest.class, CompartmentDefinition.class, Composition.class, ConceptMap.class, ConceptMap2.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, 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, RequestGroup.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, ValueSet.class, VerificationResult.class, VisionPrescription.class } ) 2755 public static final String SP_PATIENT = "patient"; 2756 /** 2757 * <b>Fluent Client</b> search parameter constant for <b>patient</b> 2758 * <p> 2759 * Description: <b>Multiple Resources: 2760 2761* [AllergyIntolerance](allergyintolerance.html): Who the sensitivity is for 2762* [CarePlan](careplan.html): Who the care plan is for 2763* [CareTeam](careteam.html): Who care team is for 2764* [ClinicalImpression](clinicalimpression.html): Patient assessed 2765* [Composition](composition.html): Who and/or what the composition is about 2766* [Condition](condition.html): Who has the condition? 2767* [Consent](consent.html): Who the consent applies to 2768* [DetectedIssue](detectedissue.html): Associated patient 2769* [DeviceRequest](devicerequest.html): Individual the service is ordered for 2770* [DeviceUsage](deviceusage.html): Search by patient who used / uses the device 2771* [DiagnosticReport](diagnosticreport.html): The subject of the report if a patient 2772* [DocumentManifest](documentmanifest.html): The subject of the set of documents 2773* [DocumentReference](documentreference.html): Who/what is the subject of the document 2774* [Encounter](encounter.html): The patient present at the encounter 2775* [EpisodeOfCare](episodeofcare.html): The patient who is the focus of this episode of care 2776* [FamilyMemberHistory](familymemberhistory.html): The identity of a subject to list family member history items for 2777* [Flag](flag.html): The identity of a subject to list flags for 2778* [Goal](goal.html): Who this goal is intended for 2779* [ImagingStudy](imagingstudy.html): Who the study is about 2780* [Immunization](immunization.html): The patient for the vaccination record 2781* [List](list.html): If all resources have the same subject 2782* [MedicationAdministration](medicationadministration.html): The identity of a patient to list administrations for 2783* [MedicationDispense](medicationdispense.html): The identity of a patient to list dispenses for 2784* [MedicationRequest](medicationrequest.html): Returns prescriptions for a specific patient 2785* [MedicationUsage](medicationusage.html): Returns statements for a specific patient. 2786* [NutritionOrder](nutritionorder.html): The identity of the person who requires the diet, formula or nutritional supplement 2787* [Observation](observation.html): The subject that the observation is about (if patient) 2788* [Procedure](procedure.html): Search by subject - a patient 2789* [RiskAssessment](riskassessment.html): Who/what does assessment apply to? 2790* [ServiceRequest](servicerequest.html): Search by subject - a patient 2791* [SupplyDelivery](supplydelivery.html): Patient for whom the item is supplied 2792* [VisionPrescription](visionprescription.html): The identity of a patient to list dispenses for 2793</b><br> 2794 * Type: <b>reference</b><br> 2795 * 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.patient | 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.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> 2796 * </p> 2797 */ 2798 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT); 2799 2800/** 2801 * Constant for fluent queries to be used to add include statements. Specifies 2802 * the path value of "<b>AllergyIntolerance:patient</b>". 2803 */ 2804 public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("AllergyIntolerance:patient").toLocked(); 2805 2806 /** 2807 * Search parameter: <b>type</b> 2808 * <p> 2809 * Description: <b>Multiple Resources: 2810 2811* [AllergyIntolerance](allergyintolerance.html): allergy | intolerance - Underlying mechanism (if known) 2812* [Composition](composition.html): Kind of composition (LOINC if possible) 2813* [DocumentManifest](documentmanifest.html): Kind of document set 2814* [DocumentReference](documentreference.html): Kind of document (LOINC if possible) 2815* [Encounter](encounter.html): Specific type of encounter 2816* [EpisodeOfCare](episodeofcare.html): Type/class - e.g. specialist referral, disease management 2817</b><br> 2818 * Type: <b>token</b><br> 2819 * Path: <b>AllergyIntolerance.type | Composition.type | DocumentManifest.type | DocumentReference.type | Encounter.type | EpisodeOfCare.type</b><br> 2820 * </p> 2821 */ 2822 @SearchParamDefinition(name="type", path="AllergyIntolerance.type | Composition.type | DocumentManifest.type | DocumentReference.type | Encounter.type | EpisodeOfCare.type", description="Multiple Resources: \r\n\r\n* [AllergyIntolerance](allergyintolerance.html): allergy | intolerance - Underlying mechanism (if known)\r\n* [Composition](composition.html): Kind of composition (LOINC if possible)\r\n* [DocumentManifest](documentmanifest.html): Kind of document set\r\n* [DocumentReference](documentreference.html): Kind of document (LOINC if possible)\r\n* [Encounter](encounter.html): Specific type of encounter\r\n* [EpisodeOfCare](episodeofcare.html): Type/class - e.g. specialist referral, disease management\r\n", type="token" ) 2823 public static final String SP_TYPE = "type"; 2824 /** 2825 * <b>Fluent Client</b> search parameter constant for <b>type</b> 2826 * <p> 2827 * Description: <b>Multiple Resources: 2828 2829* [AllergyIntolerance](allergyintolerance.html): allergy | intolerance - Underlying mechanism (if known) 2830* [Composition](composition.html): Kind of composition (LOINC if possible) 2831* [DocumentManifest](documentmanifest.html): Kind of document set 2832* [DocumentReference](documentreference.html): Kind of document (LOINC if possible) 2833* [Encounter](encounter.html): Specific type of encounter 2834* [EpisodeOfCare](episodeofcare.html): Type/class - e.g. specialist referral, disease management 2835</b><br> 2836 * Type: <b>token</b><br> 2837 * Path: <b>AllergyIntolerance.type | Composition.type | DocumentManifest.type | DocumentReference.type | Encounter.type | EpisodeOfCare.type</b><br> 2838 * </p> 2839 */ 2840 public static final ca.uhn.fhir.rest.gclient.TokenClientParam TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_TYPE); 2841 2842 2843} 2844