001package org.hl7.fhir.dstu3.model; 002 003/* 004 Copyright (c) 2011+, HL7, Inc. 005 All rights reserved. 006 007 Redistribution and use in source and binary forms, with or without modification, 008 are permitted provided that the following conditions are met: 009 010 * Redistributions of source code must retain the above copyright notice, this 011 list of conditions and the following disclaimer. 012 * Redistributions in binary form must reproduce the above copyright notice, 013 this list of conditions and the following disclaimer in the documentation 014 and/or other materials provided with the distribution. 015 * Neither the name of HL7 nor the names of its contributors may be used to 016 endorse or promote products derived from this software without specific 017 prior written permission. 018 019 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 020 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 021 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 022 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 023 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 024 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 025 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 026 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 027 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 028 POSSIBILITY OF SUCH DAMAGE. 029 030*/ 031 032// Generated on Mon, Apr 17, 2017 17:38-0400 for FHIR v3.0.1 033 034import java.util.*; 035 036import org.hl7.fhir.utilities.Utilities; 037import ca.uhn.fhir.model.api.annotation.ResourceDef; 038import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 039import ca.uhn.fhir.model.api.annotation.Child; 040import ca.uhn.fhir.model.api.annotation.ChildOrder; 041import ca.uhn.fhir.model.api.annotation.Description; 042import ca.uhn.fhir.model.api.annotation.Block; 043import org.hl7.fhir.instance.model.api.*; 044import org.hl7.fhir.exceptions.FHIRException; 045/** 046 * A clinical condition, problem, diagnosis, or other event, situation, issue, or clinical concept that has risen to a level of concern. 047 */ 048@ResourceDef(name="Condition", profile="http://hl7.org/fhir/Profile/Condition") 049public class Condition extends DomainResource { 050 051 public enum ConditionClinicalStatus { 052 /** 053 * The subject is currently experiencing the symptoms of the condition or there is evidence of the condition. 054 */ 055 ACTIVE, 056 /** 057 * The subject is having a relapse or re-experiencing the condition after a period of remission or presumed resolution. 058 */ 059 RECURRENCE, 060 /** 061 * The subject is no longer experiencing the symptoms of the condition or there is no longer evidence of the condition. 062 */ 063 INACTIVE, 064 /** 065 * The subject is no longer experiencing the symptoms of the condition, but there is a risk of the symptoms returning. 066 */ 067 REMISSION, 068 /** 069 * The subject is no longer experiencing the symptoms of the condition and there is a negligible perceived risk of the symptoms returning. 070 */ 071 RESOLVED, 072 /** 073 * added to help the parsers with the generic types 074 */ 075 NULL; 076 public static ConditionClinicalStatus fromCode(String codeString) throws FHIRException { 077 if (codeString == null || "".equals(codeString)) 078 return null; 079 if ("active".equals(codeString)) 080 return ACTIVE; 081 if ("recurrence".equals(codeString)) 082 return RECURRENCE; 083 if ("inactive".equals(codeString)) 084 return INACTIVE; 085 if ("remission".equals(codeString)) 086 return REMISSION; 087 if ("resolved".equals(codeString)) 088 return RESOLVED; 089 if (Configuration.isAcceptInvalidEnums()) 090 return null; 091 else 092 throw new FHIRException("Unknown ConditionClinicalStatus code '"+codeString+"'"); 093 } 094 public String toCode() { 095 switch (this) { 096 case ACTIVE: return "active"; 097 case RECURRENCE: return "recurrence"; 098 case INACTIVE: return "inactive"; 099 case REMISSION: return "remission"; 100 case RESOLVED: return "resolved"; 101 default: return "?"; 102 } 103 } 104 public String getSystem() { 105 switch (this) { 106 case ACTIVE: return "http://hl7.org/fhir/condition-clinical"; 107 case RECURRENCE: return "http://hl7.org/fhir/condition-clinical"; 108 case INACTIVE: return "http://hl7.org/fhir/condition-clinical"; 109 case REMISSION: return "http://hl7.org/fhir/condition-clinical"; 110 case RESOLVED: return "http://hl7.org/fhir/condition-clinical"; 111 default: return "?"; 112 } 113 } 114 public String getDefinition() { 115 switch (this) { 116 case ACTIVE: return "The subject is currently experiencing the symptoms of the condition or there is evidence of the condition."; 117 case RECURRENCE: return "The subject is having a relapse or re-experiencing the condition after a period of remission or presumed resolution."; 118 case INACTIVE: return "The subject is no longer experiencing the symptoms of the condition or there is no longer evidence of the condition."; 119 case REMISSION: return "The subject is no longer experiencing the symptoms of the condition, but there is a risk of the symptoms returning."; 120 case RESOLVED: return "The subject is no longer experiencing the symptoms of the condition and there is a negligible perceived risk of the symptoms returning."; 121 default: return "?"; 122 } 123 } 124 public String getDisplay() { 125 switch (this) { 126 case ACTIVE: return "Active"; 127 case RECURRENCE: return "Recurrence"; 128 case INACTIVE: return "Inactive"; 129 case REMISSION: return "Remission"; 130 case RESOLVED: return "Resolved"; 131 default: return "?"; 132 } 133 } 134 } 135 136 public static class ConditionClinicalStatusEnumFactory implements EnumFactory<ConditionClinicalStatus> { 137 public ConditionClinicalStatus fromCode(String codeString) throws IllegalArgumentException { 138 if (codeString == null || "".equals(codeString)) 139 if (codeString == null || "".equals(codeString)) 140 return null; 141 if ("active".equals(codeString)) 142 return ConditionClinicalStatus.ACTIVE; 143 if ("recurrence".equals(codeString)) 144 return ConditionClinicalStatus.RECURRENCE; 145 if ("inactive".equals(codeString)) 146 return ConditionClinicalStatus.INACTIVE; 147 if ("remission".equals(codeString)) 148 return ConditionClinicalStatus.REMISSION; 149 if ("resolved".equals(codeString)) 150 return ConditionClinicalStatus.RESOLVED; 151 throw new IllegalArgumentException("Unknown ConditionClinicalStatus code '"+codeString+"'"); 152 } 153 public Enumeration<ConditionClinicalStatus> fromType(Base code) throws FHIRException { 154 if (code == null) 155 return null; 156 if (code.isEmpty()) 157 return new Enumeration<ConditionClinicalStatus>(this); 158 String codeString = ((PrimitiveType) code).asStringValue(); 159 if (codeString == null || "".equals(codeString)) 160 return null; 161 if ("active".equals(codeString)) 162 return new Enumeration<ConditionClinicalStatus>(this, ConditionClinicalStatus.ACTIVE); 163 if ("recurrence".equals(codeString)) 164 return new Enumeration<ConditionClinicalStatus>(this, ConditionClinicalStatus.RECURRENCE); 165 if ("inactive".equals(codeString)) 166 return new Enumeration<ConditionClinicalStatus>(this, ConditionClinicalStatus.INACTIVE); 167 if ("remission".equals(codeString)) 168 return new Enumeration<ConditionClinicalStatus>(this, ConditionClinicalStatus.REMISSION); 169 if ("resolved".equals(codeString)) 170 return new Enumeration<ConditionClinicalStatus>(this, ConditionClinicalStatus.RESOLVED); 171 throw new FHIRException("Unknown ConditionClinicalStatus code '"+codeString+"'"); 172 } 173 public String toCode(ConditionClinicalStatus code) { 174 if (code == ConditionClinicalStatus.ACTIVE) 175 return "active"; 176 if (code == ConditionClinicalStatus.RECURRENCE) 177 return "recurrence"; 178 if (code == ConditionClinicalStatus.INACTIVE) 179 return "inactive"; 180 if (code == ConditionClinicalStatus.REMISSION) 181 return "remission"; 182 if (code == ConditionClinicalStatus.RESOLVED) 183 return "resolved"; 184 return "?"; 185 } 186 public String toSystem(ConditionClinicalStatus code) { 187 return code.getSystem(); 188 } 189 } 190 191 public enum ConditionVerificationStatus { 192 /** 193 * This is a tentative diagnosis - still a candidate that is under consideration. 194 */ 195 PROVISIONAL, 196 /** 197 * One of a set of potential (and typically mutually exclusive) diagnoses asserted to further guide the diagnostic process and preliminary treatment. 198 */ 199 DIFFERENTIAL, 200 /** 201 * There is sufficient diagnostic and/or clinical evidence to treat this as a confirmed condition. 202 */ 203 CONFIRMED, 204 /** 205 * This condition has been ruled out by diagnostic and clinical evidence. 206 */ 207 REFUTED, 208 /** 209 * The statement was entered in error and is not valid. 210 */ 211 ENTEREDINERROR, 212 /** 213 * The condition status is unknown. Note that "unknown" is a value of last resort and every attempt should be made to provide a meaningful value other than "unknown". 214 */ 215 UNKNOWN, 216 /** 217 * added to help the parsers with the generic types 218 */ 219 NULL; 220 public static ConditionVerificationStatus fromCode(String codeString) throws FHIRException { 221 if (codeString == null || "".equals(codeString)) 222 return null; 223 if ("provisional".equals(codeString)) 224 return PROVISIONAL; 225 if ("differential".equals(codeString)) 226 return DIFFERENTIAL; 227 if ("confirmed".equals(codeString)) 228 return CONFIRMED; 229 if ("refuted".equals(codeString)) 230 return REFUTED; 231 if ("entered-in-error".equals(codeString)) 232 return ENTEREDINERROR; 233 if ("unknown".equals(codeString)) 234 return UNKNOWN; 235 if (Configuration.isAcceptInvalidEnums()) 236 return null; 237 else 238 throw new FHIRException("Unknown ConditionVerificationStatus code '"+codeString+"'"); 239 } 240 public String toCode() { 241 switch (this) { 242 case PROVISIONAL: return "provisional"; 243 case DIFFERENTIAL: return "differential"; 244 case CONFIRMED: return "confirmed"; 245 case REFUTED: return "refuted"; 246 case ENTEREDINERROR: return "entered-in-error"; 247 case UNKNOWN: return "unknown"; 248 default: return "?"; 249 } 250 } 251 public String getSystem() { 252 switch (this) { 253 case PROVISIONAL: return "http://hl7.org/fhir/condition-ver-status"; 254 case DIFFERENTIAL: return "http://hl7.org/fhir/condition-ver-status"; 255 case CONFIRMED: return "http://hl7.org/fhir/condition-ver-status"; 256 case REFUTED: return "http://hl7.org/fhir/condition-ver-status"; 257 case ENTEREDINERROR: return "http://hl7.org/fhir/condition-ver-status"; 258 case UNKNOWN: return "http://hl7.org/fhir/condition-ver-status"; 259 default: return "?"; 260 } 261 } 262 public String getDefinition() { 263 switch (this) { 264 case PROVISIONAL: return "This is a tentative diagnosis - still a candidate that is under consideration."; 265 case DIFFERENTIAL: return "One of a set of potential (and typically mutually exclusive) diagnoses asserted to further guide the diagnostic process and preliminary treatment."; 266 case CONFIRMED: return "There is sufficient diagnostic and/or clinical evidence to treat this as a confirmed condition."; 267 case REFUTED: return "This condition has been ruled out by diagnostic and clinical evidence."; 268 case ENTEREDINERROR: return "The statement was entered in error and is not valid."; 269 case UNKNOWN: return "The condition status is unknown. Note that \"unknown\" is a value of last resort and every attempt should be made to provide a meaningful value other than \"unknown\"."; 270 default: return "?"; 271 } 272 } 273 public String getDisplay() { 274 switch (this) { 275 case PROVISIONAL: return "Provisional"; 276 case DIFFERENTIAL: return "Differential"; 277 case CONFIRMED: return "Confirmed"; 278 case REFUTED: return "Refuted"; 279 case ENTEREDINERROR: return "Entered In Error"; 280 case UNKNOWN: return "Unknown"; 281 default: return "?"; 282 } 283 } 284 } 285 286 public static class ConditionVerificationStatusEnumFactory implements EnumFactory<ConditionVerificationStatus> { 287 public ConditionVerificationStatus fromCode(String codeString) throws IllegalArgumentException { 288 if (codeString == null || "".equals(codeString)) 289 if (codeString == null || "".equals(codeString)) 290 return null; 291 if ("provisional".equals(codeString)) 292 return ConditionVerificationStatus.PROVISIONAL; 293 if ("differential".equals(codeString)) 294 return ConditionVerificationStatus.DIFFERENTIAL; 295 if ("confirmed".equals(codeString)) 296 return ConditionVerificationStatus.CONFIRMED; 297 if ("refuted".equals(codeString)) 298 return ConditionVerificationStatus.REFUTED; 299 if ("entered-in-error".equals(codeString)) 300 return ConditionVerificationStatus.ENTEREDINERROR; 301 if ("unknown".equals(codeString)) 302 return ConditionVerificationStatus.UNKNOWN; 303 throw new IllegalArgumentException("Unknown ConditionVerificationStatus code '"+codeString+"'"); 304 } 305 public Enumeration<ConditionVerificationStatus> fromType(Base code) throws FHIRException { 306 if (code == null) 307 return null; 308 if (code.isEmpty()) 309 return new Enumeration<ConditionVerificationStatus>(this); 310 String codeString = ((PrimitiveType) code).asStringValue(); 311 if (codeString == null || "".equals(codeString)) 312 return null; 313 if ("provisional".equals(codeString)) 314 return new Enumeration<ConditionVerificationStatus>(this, ConditionVerificationStatus.PROVISIONAL); 315 if ("differential".equals(codeString)) 316 return new Enumeration<ConditionVerificationStatus>(this, ConditionVerificationStatus.DIFFERENTIAL); 317 if ("confirmed".equals(codeString)) 318 return new Enumeration<ConditionVerificationStatus>(this, ConditionVerificationStatus.CONFIRMED); 319 if ("refuted".equals(codeString)) 320 return new Enumeration<ConditionVerificationStatus>(this, ConditionVerificationStatus.REFUTED); 321 if ("entered-in-error".equals(codeString)) 322 return new Enumeration<ConditionVerificationStatus>(this, ConditionVerificationStatus.ENTEREDINERROR); 323 if ("unknown".equals(codeString)) 324 return new Enumeration<ConditionVerificationStatus>(this, ConditionVerificationStatus.UNKNOWN); 325 throw new FHIRException("Unknown ConditionVerificationStatus code '"+codeString+"'"); 326 } 327 public String toCode(ConditionVerificationStatus code) { 328 if (code == ConditionVerificationStatus.PROVISIONAL) 329 return "provisional"; 330 if (code == ConditionVerificationStatus.DIFFERENTIAL) 331 return "differential"; 332 if (code == ConditionVerificationStatus.CONFIRMED) 333 return "confirmed"; 334 if (code == ConditionVerificationStatus.REFUTED) 335 return "refuted"; 336 if (code == ConditionVerificationStatus.ENTEREDINERROR) 337 return "entered-in-error"; 338 if (code == ConditionVerificationStatus.UNKNOWN) 339 return "unknown"; 340 return "?"; 341 } 342 public String toSystem(ConditionVerificationStatus code) { 343 return code.getSystem(); 344 } 345 } 346 347 @Block() 348 public static class ConditionStageComponent extends BackboneElement implements IBaseBackboneElement { 349 /** 350 * A simple summary of the stage such as "Stage 3". The determination of the stage is disease-specific. 351 */ 352 @Child(name = "summary", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 353 @Description(shortDefinition="Simple summary (disease specific)", formalDefinition="A simple summary of the stage such as \"Stage 3\". The determination of the stage is disease-specific." ) 354 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/condition-stage") 355 protected CodeableConcept summary; 356 357 /** 358 * Reference to a formal record of the evidence on which the staging assessment is based. 359 */ 360 @Child(name = "assessment", type = {ClinicalImpression.class, DiagnosticReport.class, Observation.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 361 @Description(shortDefinition="Formal record of assessment", formalDefinition="Reference to a formal record of the evidence on which the staging assessment is based." ) 362 protected List<Reference> assessment; 363 /** 364 * The actual objects that are the target of the reference (Reference to a formal record of the evidence on which the staging assessment is based.) 365 */ 366 protected List<Resource> assessmentTarget; 367 368 369 private static final long serialVersionUID = -1961530405L; 370 371 /** 372 * Constructor 373 */ 374 public ConditionStageComponent() { 375 super(); 376 } 377 378 /** 379 * @return {@link #summary} (A simple summary of the stage such as "Stage 3". The determination of the stage is disease-specific.) 380 */ 381 public CodeableConcept getSummary() { 382 if (this.summary == null) 383 if (Configuration.errorOnAutoCreate()) 384 throw new Error("Attempt to auto-create ConditionStageComponent.summary"); 385 else if (Configuration.doAutoCreate()) 386 this.summary = new CodeableConcept(); // cc 387 return this.summary; 388 } 389 390 public boolean hasSummary() { 391 return this.summary != null && !this.summary.isEmpty(); 392 } 393 394 /** 395 * @param value {@link #summary} (A simple summary of the stage such as "Stage 3". The determination of the stage is disease-specific.) 396 */ 397 public ConditionStageComponent setSummary(CodeableConcept value) { 398 this.summary = value; 399 return this; 400 } 401 402 /** 403 * @return {@link #assessment} (Reference to a formal record of the evidence on which the staging assessment is based.) 404 */ 405 public List<Reference> getAssessment() { 406 if (this.assessment == null) 407 this.assessment = new ArrayList<Reference>(); 408 return this.assessment; 409 } 410 411 /** 412 * @return Returns a reference to <code>this</code> for easy method chaining 413 */ 414 public ConditionStageComponent setAssessment(List<Reference> theAssessment) { 415 this.assessment = theAssessment; 416 return this; 417 } 418 419 public boolean hasAssessment() { 420 if (this.assessment == null) 421 return false; 422 for (Reference item : this.assessment) 423 if (!item.isEmpty()) 424 return true; 425 return false; 426 } 427 428 public Reference addAssessment() { //3 429 Reference t = new Reference(); 430 if (this.assessment == null) 431 this.assessment = new ArrayList<Reference>(); 432 this.assessment.add(t); 433 return t; 434 } 435 436 public ConditionStageComponent addAssessment(Reference t) { //3 437 if (t == null) 438 return this; 439 if (this.assessment == null) 440 this.assessment = new ArrayList<Reference>(); 441 this.assessment.add(t); 442 return this; 443 } 444 445 /** 446 * @return The first repetition of repeating field {@link #assessment}, creating it if it does not already exist 447 */ 448 public Reference getAssessmentFirstRep() { 449 if (getAssessment().isEmpty()) { 450 addAssessment(); 451 } 452 return getAssessment().get(0); 453 } 454 455 /** 456 * @deprecated Use Reference#setResource(IBaseResource) instead 457 */ 458 @Deprecated 459 public List<Resource> getAssessmentTarget() { 460 if (this.assessmentTarget == null) 461 this.assessmentTarget = new ArrayList<Resource>(); 462 return this.assessmentTarget; 463 } 464 465 protected void listChildren(List<Property> childrenList) { 466 super.listChildren(childrenList); 467 childrenList.add(new Property("summary", "CodeableConcept", "A simple summary of the stage such as \"Stage 3\". The determination of the stage is disease-specific.", 0, java.lang.Integer.MAX_VALUE, summary)); 468 childrenList.add(new Property("assessment", "Reference(ClinicalImpression|DiagnosticReport|Observation)", "Reference to a formal record of the evidence on which the staging assessment is based.", 0, java.lang.Integer.MAX_VALUE, assessment)); 469 } 470 471 @Override 472 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 473 switch (hash) { 474 case -1857640538: /*summary*/ return this.summary == null ? new Base[0] : new Base[] {this.summary}; // CodeableConcept 475 case 2119382722: /*assessment*/ return this.assessment == null ? new Base[0] : this.assessment.toArray(new Base[this.assessment.size()]); // Reference 476 default: return super.getProperty(hash, name, checkValid); 477 } 478 479 } 480 481 @Override 482 public Base setProperty(int hash, String name, Base value) throws FHIRException { 483 switch (hash) { 484 case -1857640538: // summary 485 this.summary = castToCodeableConcept(value); // CodeableConcept 486 return value; 487 case 2119382722: // assessment 488 this.getAssessment().add(castToReference(value)); // Reference 489 return value; 490 default: return super.setProperty(hash, name, value); 491 } 492 493 } 494 495 @Override 496 public Base setProperty(String name, Base value) throws FHIRException { 497 if (name.equals("summary")) { 498 this.summary = castToCodeableConcept(value); // CodeableConcept 499 } else if (name.equals("assessment")) { 500 this.getAssessment().add(castToReference(value)); 501 } else 502 return super.setProperty(name, value); 503 return value; 504 } 505 506 @Override 507 public Base makeProperty(int hash, String name) throws FHIRException { 508 switch (hash) { 509 case -1857640538: return getSummary(); 510 case 2119382722: return addAssessment(); 511 default: return super.makeProperty(hash, name); 512 } 513 514 } 515 516 @Override 517 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 518 switch (hash) { 519 case -1857640538: /*summary*/ return new String[] {"CodeableConcept"}; 520 case 2119382722: /*assessment*/ return new String[] {"Reference"}; 521 default: return super.getTypesForProperty(hash, name); 522 } 523 524 } 525 526 @Override 527 public Base addChild(String name) throws FHIRException { 528 if (name.equals("summary")) { 529 this.summary = new CodeableConcept(); 530 return this.summary; 531 } 532 else if (name.equals("assessment")) { 533 return addAssessment(); 534 } 535 else 536 return super.addChild(name); 537 } 538 539 public ConditionStageComponent copy() { 540 ConditionStageComponent dst = new ConditionStageComponent(); 541 copyValues(dst); 542 dst.summary = summary == null ? null : summary.copy(); 543 if (assessment != null) { 544 dst.assessment = new ArrayList<Reference>(); 545 for (Reference i : assessment) 546 dst.assessment.add(i.copy()); 547 }; 548 return dst; 549 } 550 551 @Override 552 public boolean equalsDeep(Base other) { 553 if (!super.equalsDeep(other)) 554 return false; 555 if (!(other instanceof ConditionStageComponent)) 556 return false; 557 ConditionStageComponent o = (ConditionStageComponent) other; 558 return compareDeep(summary, o.summary, true) && compareDeep(assessment, o.assessment, true); 559 } 560 561 @Override 562 public boolean equalsShallow(Base other) { 563 if (!super.equalsShallow(other)) 564 return false; 565 if (!(other instanceof ConditionStageComponent)) 566 return false; 567 ConditionStageComponent o = (ConditionStageComponent) other; 568 return true; 569 } 570 571 public boolean isEmpty() { 572 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(summary, assessment); 573 } 574 575 public String fhirType() { 576 return "Condition.stage"; 577 578 } 579 580 } 581 582 @Block() 583 public static class ConditionEvidenceComponent extends BackboneElement implements IBaseBackboneElement { 584 /** 585 * A manifestation or symptom that led to the recording of this condition. 586 */ 587 @Child(name = "code", type = {CodeableConcept.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 588 @Description(shortDefinition="Manifestation/symptom", formalDefinition="A manifestation or symptom that led to the recording of this condition." ) 589 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/manifestation-or-symptom") 590 protected List<CodeableConcept> code; 591 592 /** 593 * Links to other relevant information, including pathology reports. 594 */ 595 @Child(name = "detail", type = {Reference.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 596 @Description(shortDefinition="Supporting information found elsewhere", formalDefinition="Links to other relevant information, including pathology reports." ) 597 protected List<Reference> detail; 598 /** 599 * The actual objects that are the target of the reference (Links to other relevant information, including pathology reports.) 600 */ 601 protected List<Resource> detailTarget; 602 603 604 private static final long serialVersionUID = 1135831276L; 605 606 /** 607 * Constructor 608 */ 609 public ConditionEvidenceComponent() { 610 super(); 611 } 612 613 /** 614 * @return {@link #code} (A manifestation or symptom that led to the recording of this condition.) 615 */ 616 public List<CodeableConcept> getCode() { 617 if (this.code == null) 618 this.code = new ArrayList<CodeableConcept>(); 619 return this.code; 620 } 621 622 /** 623 * @return Returns a reference to <code>this</code> for easy method chaining 624 */ 625 public ConditionEvidenceComponent setCode(List<CodeableConcept> theCode) { 626 this.code = theCode; 627 return this; 628 } 629 630 public boolean hasCode() { 631 if (this.code == null) 632 return false; 633 for (CodeableConcept item : this.code) 634 if (!item.isEmpty()) 635 return true; 636 return false; 637 } 638 639 public CodeableConcept addCode() { //3 640 CodeableConcept t = new CodeableConcept(); 641 if (this.code == null) 642 this.code = new ArrayList<CodeableConcept>(); 643 this.code.add(t); 644 return t; 645 } 646 647 public ConditionEvidenceComponent addCode(CodeableConcept t) { //3 648 if (t == null) 649 return this; 650 if (this.code == null) 651 this.code = new ArrayList<CodeableConcept>(); 652 this.code.add(t); 653 return this; 654 } 655 656 /** 657 * @return The first repetition of repeating field {@link #code}, creating it if it does not already exist 658 */ 659 public CodeableConcept getCodeFirstRep() { 660 if (getCode().isEmpty()) { 661 addCode(); 662 } 663 return getCode().get(0); 664 } 665 666 /** 667 * @return {@link #detail} (Links to other relevant information, including pathology reports.) 668 */ 669 public List<Reference> getDetail() { 670 if (this.detail == null) 671 this.detail = new ArrayList<Reference>(); 672 return this.detail; 673 } 674 675 /** 676 * @return Returns a reference to <code>this</code> for easy method chaining 677 */ 678 public ConditionEvidenceComponent setDetail(List<Reference> theDetail) { 679 this.detail = theDetail; 680 return this; 681 } 682 683 public boolean hasDetail() { 684 if (this.detail == null) 685 return false; 686 for (Reference item : this.detail) 687 if (!item.isEmpty()) 688 return true; 689 return false; 690 } 691 692 public Reference addDetail() { //3 693 Reference t = new Reference(); 694 if (this.detail == null) 695 this.detail = new ArrayList<Reference>(); 696 this.detail.add(t); 697 return t; 698 } 699 700 public ConditionEvidenceComponent addDetail(Reference t) { //3 701 if (t == null) 702 return this; 703 if (this.detail == null) 704 this.detail = new ArrayList<Reference>(); 705 this.detail.add(t); 706 return this; 707 } 708 709 /** 710 * @return The first repetition of repeating field {@link #detail}, creating it if it does not already exist 711 */ 712 public Reference getDetailFirstRep() { 713 if (getDetail().isEmpty()) { 714 addDetail(); 715 } 716 return getDetail().get(0); 717 } 718 719 /** 720 * @deprecated Use Reference#setResource(IBaseResource) instead 721 */ 722 @Deprecated 723 public List<Resource> getDetailTarget() { 724 if (this.detailTarget == null) 725 this.detailTarget = new ArrayList<Resource>(); 726 return this.detailTarget; 727 } 728 729 protected void listChildren(List<Property> childrenList) { 730 super.listChildren(childrenList); 731 childrenList.add(new Property("code", "CodeableConcept", "A manifestation or symptom that led to the recording of this condition.", 0, java.lang.Integer.MAX_VALUE, code)); 732 childrenList.add(new Property("detail", "Reference(Any)", "Links to other relevant information, including pathology reports.", 0, java.lang.Integer.MAX_VALUE, detail)); 733 } 734 735 @Override 736 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 737 switch (hash) { 738 case 3059181: /*code*/ return this.code == null ? new Base[0] : this.code.toArray(new Base[this.code.size()]); // CodeableConcept 739 case -1335224239: /*detail*/ return this.detail == null ? new Base[0] : this.detail.toArray(new Base[this.detail.size()]); // Reference 740 default: return super.getProperty(hash, name, checkValid); 741 } 742 743 } 744 745 @Override 746 public Base setProperty(int hash, String name, Base value) throws FHIRException { 747 switch (hash) { 748 case 3059181: // code 749 this.getCode().add(castToCodeableConcept(value)); // CodeableConcept 750 return value; 751 case -1335224239: // detail 752 this.getDetail().add(castToReference(value)); // Reference 753 return value; 754 default: return super.setProperty(hash, name, value); 755 } 756 757 } 758 759 @Override 760 public Base setProperty(String name, Base value) throws FHIRException { 761 if (name.equals("code")) { 762 this.getCode().add(castToCodeableConcept(value)); 763 } else if (name.equals("detail")) { 764 this.getDetail().add(castToReference(value)); 765 } else 766 return super.setProperty(name, value); 767 return value; 768 } 769 770 @Override 771 public Base makeProperty(int hash, String name) throws FHIRException { 772 switch (hash) { 773 case 3059181: return addCode(); 774 case -1335224239: return addDetail(); 775 default: return super.makeProperty(hash, name); 776 } 777 778 } 779 780 @Override 781 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 782 switch (hash) { 783 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 784 case -1335224239: /*detail*/ return new String[] {"Reference"}; 785 default: return super.getTypesForProperty(hash, name); 786 } 787 788 } 789 790 @Override 791 public Base addChild(String name) throws FHIRException { 792 if (name.equals("code")) { 793 return addCode(); 794 } 795 else if (name.equals("detail")) { 796 return addDetail(); 797 } 798 else 799 return super.addChild(name); 800 } 801 802 public ConditionEvidenceComponent copy() { 803 ConditionEvidenceComponent dst = new ConditionEvidenceComponent(); 804 copyValues(dst); 805 if (code != null) { 806 dst.code = new ArrayList<CodeableConcept>(); 807 for (CodeableConcept i : code) 808 dst.code.add(i.copy()); 809 }; 810 if (detail != null) { 811 dst.detail = new ArrayList<Reference>(); 812 for (Reference i : detail) 813 dst.detail.add(i.copy()); 814 }; 815 return dst; 816 } 817 818 @Override 819 public boolean equalsDeep(Base other) { 820 if (!super.equalsDeep(other)) 821 return false; 822 if (!(other instanceof ConditionEvidenceComponent)) 823 return false; 824 ConditionEvidenceComponent o = (ConditionEvidenceComponent) other; 825 return compareDeep(code, o.code, true) && compareDeep(detail, o.detail, true); 826 } 827 828 @Override 829 public boolean equalsShallow(Base other) { 830 if (!super.equalsShallow(other)) 831 return false; 832 if (!(other instanceof ConditionEvidenceComponent)) 833 return false; 834 ConditionEvidenceComponent o = (ConditionEvidenceComponent) other; 835 return true; 836 } 837 838 public boolean isEmpty() { 839 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, detail); 840 } 841 842 public String fhirType() { 843 return "Condition.evidence"; 844 845 } 846 847 } 848 849 /** 850 * This records identifiers associated with this condition that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation). 851 */ 852 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 853 @Description(shortDefinition="External Ids for this condition", formalDefinition="This records identifiers associated with this condition that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation)." ) 854 protected List<Identifier> identifier; 855 856 /** 857 * The clinical status of the condition. 858 */ 859 @Child(name = "clinicalStatus", type = {CodeType.class}, order=1, min=0, max=1, modifier=true, summary=true) 860 @Description(shortDefinition="active | recurrence | inactive | remission | resolved", formalDefinition="The clinical status of the condition." ) 861 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/condition-clinical") 862 protected Enumeration<ConditionClinicalStatus> clinicalStatus; 863 864 /** 865 * The verification status to support the clinical status of the condition. 866 */ 867 @Child(name = "verificationStatus", type = {CodeType.class}, order=2, min=0, max=1, modifier=true, summary=true) 868 @Description(shortDefinition="provisional | differential | confirmed | refuted | entered-in-error | unknown", formalDefinition="The verification status to support the clinical status of the condition." ) 869 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/condition-ver-status") 870 protected Enumeration<ConditionVerificationStatus> verificationStatus; 871 872 /** 873 * A category assigned to the condition. 874 */ 875 @Child(name = "category", type = {CodeableConcept.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 876 @Description(shortDefinition="problem-list-item | encounter-diagnosis", formalDefinition="A category assigned to the condition." ) 877 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/condition-category") 878 protected List<CodeableConcept> category; 879 880 /** 881 * A subjective assessment of the severity of the condition as evaluated by the clinician. 882 */ 883 @Child(name = "severity", type = {CodeableConcept.class}, order=4, min=0, max=1, modifier=false, summary=false) 884 @Description(shortDefinition="Subjective severity of condition", formalDefinition="A subjective assessment of the severity of the condition as evaluated by the clinician." ) 885 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/condition-severity") 886 protected CodeableConcept severity; 887 888 /** 889 * Identification of the condition, problem or diagnosis. 890 */ 891 @Child(name = "code", type = {CodeableConcept.class}, order=5, min=0, max=1, modifier=false, summary=true) 892 @Description(shortDefinition="Identification of the condition, problem or diagnosis", formalDefinition="Identification of the condition, problem or diagnosis." ) 893 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/condition-code") 894 protected CodeableConcept code; 895 896 /** 897 * The anatomical location where this condition manifests itself. 898 */ 899 @Child(name = "bodySite", type = {CodeableConcept.class}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 900 @Description(shortDefinition="Anatomical location, if relevant", formalDefinition="The anatomical location where this condition manifests itself." ) 901 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/body-site") 902 protected List<CodeableConcept> bodySite; 903 904 /** 905 * Indicates the patient or group who the condition record is associated with. 906 */ 907 @Child(name = "subject", type = {Patient.class, Group.class}, order=7, min=1, max=1, modifier=false, summary=true) 908 @Description(shortDefinition="Who has the condition?", formalDefinition="Indicates the patient or group who the condition record is associated with." ) 909 protected Reference subject; 910 911 /** 912 * The actual object that is the target of the reference (Indicates the patient or group who the condition record is associated with.) 913 */ 914 protected Resource subjectTarget; 915 916 /** 917 * Encounter during which the condition was first asserted. 918 */ 919 @Child(name = "context", type = {Encounter.class, EpisodeOfCare.class}, order=8, min=0, max=1, modifier=false, summary=true) 920 @Description(shortDefinition="Encounter or episode when condition first asserted", formalDefinition="Encounter during which the condition was first asserted." ) 921 protected Reference context; 922 923 /** 924 * The actual object that is the target of the reference (Encounter during which the condition was first asserted.) 925 */ 926 protected Resource contextTarget; 927 928 /** 929 * Estimated or actual date or date-time the condition began, in the opinion of the clinician. 930 */ 931 @Child(name = "onset", type = {DateTimeType.class, Age.class, Period.class, Range.class, StringType.class}, order=9, min=0, max=1, modifier=false, summary=true) 932 @Description(shortDefinition="Estimated or actual date, date-time, or age", formalDefinition="Estimated or actual date or date-time the condition began, in the opinion of the clinician." ) 933 protected Type onset; 934 935 /** 936 * The date or estimated date that the condition resolved or went into remission. This is called "abatement" because of the many overloaded connotations associated with "remission" or "resolution" - Conditions are never really resolved, but they can abate. 937 */ 938 @Child(name = "abatement", type = {DateTimeType.class, Age.class, BooleanType.class, Period.class, Range.class, StringType.class}, order=10, min=0, max=1, modifier=false, summary=false) 939 @Description(shortDefinition="If/when in resolution/remission", formalDefinition="The date or estimated date that the condition resolved or went into remission. This is called \"abatement\" because of the many overloaded connotations associated with \"remission\" or \"resolution\" - Conditions are never really resolved, but they can abate." ) 940 protected Type abatement; 941 942 /** 943 * The date on which the existance of the Condition was first asserted or acknowledged. 944 */ 945 @Child(name = "assertedDate", type = {DateTimeType.class}, order=11, min=0, max=1, modifier=false, summary=true) 946 @Description(shortDefinition="Date record was believed accurate", formalDefinition="The date on which the existance of the Condition was first asserted or acknowledged." ) 947 protected DateTimeType assertedDate; 948 949 /** 950 * Individual who is making the condition statement. 951 */ 952 @Child(name = "asserter", type = {Practitioner.class, Patient.class, RelatedPerson.class}, order=12, min=0, max=1, modifier=false, summary=true) 953 @Description(shortDefinition="Person who asserts this condition", formalDefinition="Individual who is making the condition statement." ) 954 protected Reference asserter; 955 956 /** 957 * The actual object that is the target of the reference (Individual who is making the condition statement.) 958 */ 959 protected Resource asserterTarget; 960 961 /** 962 * Clinical stage or grade of a condition. May include formal severity assessments. 963 */ 964 @Child(name = "stage", type = {}, order=13, min=0, max=1, modifier=false, summary=false) 965 @Description(shortDefinition="Stage/grade, usually assessed formally", formalDefinition="Clinical stage or grade of a condition. May include formal severity assessments." ) 966 protected ConditionStageComponent stage; 967 968 /** 969 * Supporting Evidence / manifestations that are the basis on which this condition is suspected or confirmed. 970 */ 971 @Child(name = "evidence", type = {}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 972 @Description(shortDefinition="Supporting evidence", formalDefinition="Supporting Evidence / manifestations that are the basis on which this condition is suspected or confirmed." ) 973 protected List<ConditionEvidenceComponent> evidence; 974 975 /** 976 * Additional information about the Condition. This is a general notes/comments entry for description of the Condition, its diagnosis and prognosis. 977 */ 978 @Child(name = "note", type = {Annotation.class}, order=15, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 979 @Description(shortDefinition="Additional information about the Condition", formalDefinition="Additional information about the Condition. This is a general notes/comments entry for description of the Condition, its diagnosis and prognosis." ) 980 protected List<Annotation> note; 981 982 private static final long serialVersionUID = -585250376L; 983 984 /** 985 * Constructor 986 */ 987 public Condition() { 988 super(); 989 } 990 991 /** 992 * Constructor 993 */ 994 public Condition(Reference subject) { 995 super(); 996 this.subject = subject; 997 } 998 999 /** 1000 * @return {@link #identifier} (This records identifiers associated with this condition that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).) 1001 */ 1002 public List<Identifier> getIdentifier() { 1003 if (this.identifier == null) 1004 this.identifier = new ArrayList<Identifier>(); 1005 return this.identifier; 1006 } 1007 1008 /** 1009 * @return Returns a reference to <code>this</code> for easy method chaining 1010 */ 1011 public Condition setIdentifier(List<Identifier> theIdentifier) { 1012 this.identifier = theIdentifier; 1013 return this; 1014 } 1015 1016 public boolean hasIdentifier() { 1017 if (this.identifier == null) 1018 return false; 1019 for (Identifier item : this.identifier) 1020 if (!item.isEmpty()) 1021 return true; 1022 return false; 1023 } 1024 1025 public Identifier addIdentifier() { //3 1026 Identifier t = new Identifier(); 1027 if (this.identifier == null) 1028 this.identifier = new ArrayList<Identifier>(); 1029 this.identifier.add(t); 1030 return t; 1031 } 1032 1033 public Condition addIdentifier(Identifier t) { //3 1034 if (t == null) 1035 return this; 1036 if (this.identifier == null) 1037 this.identifier = new ArrayList<Identifier>(); 1038 this.identifier.add(t); 1039 return this; 1040 } 1041 1042 /** 1043 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist 1044 */ 1045 public Identifier getIdentifierFirstRep() { 1046 if (getIdentifier().isEmpty()) { 1047 addIdentifier(); 1048 } 1049 return getIdentifier().get(0); 1050 } 1051 1052 /** 1053 * @return {@link #clinicalStatus} (The clinical status of the condition.). This is the underlying object with id, value and extensions. The accessor "getClinicalStatus" gives direct access to the value 1054 */ 1055 public Enumeration<ConditionClinicalStatus> getClinicalStatusElement() { 1056 if (this.clinicalStatus == null) 1057 if (Configuration.errorOnAutoCreate()) 1058 throw new Error("Attempt to auto-create Condition.clinicalStatus"); 1059 else if (Configuration.doAutoCreate()) 1060 this.clinicalStatus = new Enumeration<ConditionClinicalStatus>(new ConditionClinicalStatusEnumFactory()); // bb 1061 return this.clinicalStatus; 1062 } 1063 1064 public boolean hasClinicalStatusElement() { 1065 return this.clinicalStatus != null && !this.clinicalStatus.isEmpty(); 1066 } 1067 1068 public boolean hasClinicalStatus() { 1069 return this.clinicalStatus != null && !this.clinicalStatus.isEmpty(); 1070 } 1071 1072 /** 1073 * @param value {@link #clinicalStatus} (The clinical status of the condition.). This is the underlying object with id, value and extensions. The accessor "getClinicalStatus" gives direct access to the value 1074 */ 1075 public Condition setClinicalStatusElement(Enumeration<ConditionClinicalStatus> value) { 1076 this.clinicalStatus = value; 1077 return this; 1078 } 1079 1080 /** 1081 * @return The clinical status of the condition. 1082 */ 1083 public ConditionClinicalStatus getClinicalStatus() { 1084 return this.clinicalStatus == null ? null : this.clinicalStatus.getValue(); 1085 } 1086 1087 /** 1088 * @param value The clinical status of the condition. 1089 */ 1090 public Condition setClinicalStatus(ConditionClinicalStatus value) { 1091 if (value == null) 1092 this.clinicalStatus = null; 1093 else { 1094 if (this.clinicalStatus == null) 1095 this.clinicalStatus = new Enumeration<ConditionClinicalStatus>(new ConditionClinicalStatusEnumFactory()); 1096 this.clinicalStatus.setValue(value); 1097 } 1098 return this; 1099 } 1100 1101 /** 1102 * @return {@link #verificationStatus} (The verification status to support the clinical status of the condition.). This is the underlying object with id, value and extensions. The accessor "getVerificationStatus" gives direct access to the value 1103 */ 1104 public Enumeration<ConditionVerificationStatus> getVerificationStatusElement() { 1105 if (this.verificationStatus == null) 1106 if (Configuration.errorOnAutoCreate()) 1107 throw new Error("Attempt to auto-create Condition.verificationStatus"); 1108 else if (Configuration.doAutoCreate()) 1109 this.verificationStatus = new Enumeration<ConditionVerificationStatus>(new ConditionVerificationStatusEnumFactory()); // bb 1110 return this.verificationStatus; 1111 } 1112 1113 public boolean hasVerificationStatusElement() { 1114 return this.verificationStatus != null && !this.verificationStatus.isEmpty(); 1115 } 1116 1117 public boolean hasVerificationStatus() { 1118 return this.verificationStatus != null && !this.verificationStatus.isEmpty(); 1119 } 1120 1121 /** 1122 * @param value {@link #verificationStatus} (The verification status to support the clinical status of the condition.). This is the underlying object with id, value and extensions. The accessor "getVerificationStatus" gives direct access to the value 1123 */ 1124 public Condition setVerificationStatusElement(Enumeration<ConditionVerificationStatus> value) { 1125 this.verificationStatus = value; 1126 return this; 1127 } 1128 1129 /** 1130 * @return The verification status to support the clinical status of the condition. 1131 */ 1132 public ConditionVerificationStatus getVerificationStatus() { 1133 return this.verificationStatus == null ? null : this.verificationStatus.getValue(); 1134 } 1135 1136 /** 1137 * @param value The verification status to support the clinical status of the condition. 1138 */ 1139 public Condition setVerificationStatus(ConditionVerificationStatus value) { 1140 if (value == null) 1141 this.verificationStatus = null; 1142 else { 1143 if (this.verificationStatus == null) 1144 this.verificationStatus = new Enumeration<ConditionVerificationStatus>(new ConditionVerificationStatusEnumFactory()); 1145 this.verificationStatus.setValue(value); 1146 } 1147 return this; 1148 } 1149 1150 /** 1151 * @return {@link #category} (A category assigned to the condition.) 1152 */ 1153 public List<CodeableConcept> getCategory() { 1154 if (this.category == null) 1155 this.category = new ArrayList<CodeableConcept>(); 1156 return this.category; 1157 } 1158 1159 /** 1160 * @return Returns a reference to <code>this</code> for easy method chaining 1161 */ 1162 public Condition setCategory(List<CodeableConcept> theCategory) { 1163 this.category = theCategory; 1164 return this; 1165 } 1166 1167 public boolean hasCategory() { 1168 if (this.category == null) 1169 return false; 1170 for (CodeableConcept item : this.category) 1171 if (!item.isEmpty()) 1172 return true; 1173 return false; 1174 } 1175 1176 public CodeableConcept addCategory() { //3 1177 CodeableConcept t = new CodeableConcept(); 1178 if (this.category == null) 1179 this.category = new ArrayList<CodeableConcept>(); 1180 this.category.add(t); 1181 return t; 1182 } 1183 1184 public Condition addCategory(CodeableConcept t) { //3 1185 if (t == null) 1186 return this; 1187 if (this.category == null) 1188 this.category = new ArrayList<CodeableConcept>(); 1189 this.category.add(t); 1190 return this; 1191 } 1192 1193 /** 1194 * @return The first repetition of repeating field {@link #category}, creating it if it does not already exist 1195 */ 1196 public CodeableConcept getCategoryFirstRep() { 1197 if (getCategory().isEmpty()) { 1198 addCategory(); 1199 } 1200 return getCategory().get(0); 1201 } 1202 1203 /** 1204 * @return {@link #severity} (A subjective assessment of the severity of the condition as evaluated by the clinician.) 1205 */ 1206 public CodeableConcept getSeverity() { 1207 if (this.severity == null) 1208 if (Configuration.errorOnAutoCreate()) 1209 throw new Error("Attempt to auto-create Condition.severity"); 1210 else if (Configuration.doAutoCreate()) 1211 this.severity = new CodeableConcept(); // cc 1212 return this.severity; 1213 } 1214 1215 public boolean hasSeverity() { 1216 return this.severity != null && !this.severity.isEmpty(); 1217 } 1218 1219 /** 1220 * @param value {@link #severity} (A subjective assessment of the severity of the condition as evaluated by the clinician.) 1221 */ 1222 public Condition setSeverity(CodeableConcept value) { 1223 this.severity = value; 1224 return this; 1225 } 1226 1227 /** 1228 * @return {@link #code} (Identification of the condition, problem or diagnosis.) 1229 */ 1230 public CodeableConcept getCode() { 1231 if (this.code == null) 1232 if (Configuration.errorOnAutoCreate()) 1233 throw new Error("Attempt to auto-create Condition.code"); 1234 else if (Configuration.doAutoCreate()) 1235 this.code = new CodeableConcept(); // cc 1236 return this.code; 1237 } 1238 1239 public boolean hasCode() { 1240 return this.code != null && !this.code.isEmpty(); 1241 } 1242 1243 /** 1244 * @param value {@link #code} (Identification of the condition, problem or diagnosis.) 1245 */ 1246 public Condition setCode(CodeableConcept value) { 1247 this.code = value; 1248 return this; 1249 } 1250 1251 /** 1252 * @return {@link #bodySite} (The anatomical location where this condition manifests itself.) 1253 */ 1254 public List<CodeableConcept> getBodySite() { 1255 if (this.bodySite == null) 1256 this.bodySite = new ArrayList<CodeableConcept>(); 1257 return this.bodySite; 1258 } 1259 1260 /** 1261 * @return Returns a reference to <code>this</code> for easy method chaining 1262 */ 1263 public Condition setBodySite(List<CodeableConcept> theBodySite) { 1264 this.bodySite = theBodySite; 1265 return this; 1266 } 1267 1268 public boolean hasBodySite() { 1269 if (this.bodySite == null) 1270 return false; 1271 for (CodeableConcept item : this.bodySite) 1272 if (!item.isEmpty()) 1273 return true; 1274 return false; 1275 } 1276 1277 public CodeableConcept addBodySite() { //3 1278 CodeableConcept t = new CodeableConcept(); 1279 if (this.bodySite == null) 1280 this.bodySite = new ArrayList<CodeableConcept>(); 1281 this.bodySite.add(t); 1282 return t; 1283 } 1284 1285 public Condition addBodySite(CodeableConcept t) { //3 1286 if (t == null) 1287 return this; 1288 if (this.bodySite == null) 1289 this.bodySite = new ArrayList<CodeableConcept>(); 1290 this.bodySite.add(t); 1291 return this; 1292 } 1293 1294 /** 1295 * @return The first repetition of repeating field {@link #bodySite}, creating it if it does not already exist 1296 */ 1297 public CodeableConcept getBodySiteFirstRep() { 1298 if (getBodySite().isEmpty()) { 1299 addBodySite(); 1300 } 1301 return getBodySite().get(0); 1302 } 1303 1304 /** 1305 * @return {@link #subject} (Indicates the patient or group who the condition record is associated with.) 1306 */ 1307 public Reference getSubject() { 1308 if (this.subject == null) 1309 if (Configuration.errorOnAutoCreate()) 1310 throw new Error("Attempt to auto-create Condition.subject"); 1311 else if (Configuration.doAutoCreate()) 1312 this.subject = new Reference(); // cc 1313 return this.subject; 1314 } 1315 1316 public boolean hasSubject() { 1317 return this.subject != null && !this.subject.isEmpty(); 1318 } 1319 1320 /** 1321 * @param value {@link #subject} (Indicates the patient or group who the condition record is associated with.) 1322 */ 1323 public Condition setSubject(Reference value) { 1324 this.subject = value; 1325 return this; 1326 } 1327 1328 /** 1329 * @return {@link #subject} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (Indicates the patient or group who the condition record is associated with.) 1330 */ 1331 public Resource getSubjectTarget() { 1332 return this.subjectTarget; 1333 } 1334 1335 /** 1336 * @param value {@link #subject} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (Indicates the patient or group who the condition record is associated with.) 1337 */ 1338 public Condition setSubjectTarget(Resource value) { 1339 this.subjectTarget = value; 1340 return this; 1341 } 1342 1343 /** 1344 * @return {@link #context} (Encounter during which the condition was first asserted.) 1345 */ 1346 public Reference getContext() { 1347 if (this.context == null) 1348 if (Configuration.errorOnAutoCreate()) 1349 throw new Error("Attempt to auto-create Condition.context"); 1350 else if (Configuration.doAutoCreate()) 1351 this.context = new Reference(); // cc 1352 return this.context; 1353 } 1354 1355 public boolean hasContext() { 1356 return this.context != null && !this.context.isEmpty(); 1357 } 1358 1359 /** 1360 * @param value {@link #context} (Encounter during which the condition was first asserted.) 1361 */ 1362 public Condition setContext(Reference value) { 1363 this.context = value; 1364 return this; 1365 } 1366 1367 /** 1368 * @return {@link #context} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (Encounter during which the condition was first asserted.) 1369 */ 1370 public Resource getContextTarget() { 1371 return this.contextTarget; 1372 } 1373 1374 /** 1375 * @param value {@link #context} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (Encounter during which the condition was first asserted.) 1376 */ 1377 public Condition setContextTarget(Resource value) { 1378 this.contextTarget = value; 1379 return this; 1380 } 1381 1382 /** 1383 * @return {@link #onset} (Estimated or actual date or date-time the condition began, in the opinion of the clinician.) 1384 */ 1385 public Type getOnset() { 1386 return this.onset; 1387 } 1388 1389 /** 1390 * @return {@link #onset} (Estimated or actual date or date-time the condition began, in the opinion of the clinician.) 1391 */ 1392 public DateTimeType getOnsetDateTimeType() throws FHIRException { 1393 if (!(this.onset instanceof DateTimeType)) 1394 throw new FHIRException("Type mismatch: the type DateTimeType was expected, but "+this.onset.getClass().getName()+" was encountered"); 1395 return (DateTimeType) this.onset; 1396 } 1397 1398 public boolean hasOnsetDateTimeType() { 1399 return this.onset instanceof DateTimeType; 1400 } 1401 1402 /** 1403 * @return {@link #onset} (Estimated or actual date or date-time the condition began, in the opinion of the clinician.) 1404 */ 1405 public Age getOnsetAge() throws FHIRException { 1406 if (!(this.onset instanceof Age)) 1407 throw new FHIRException("Type mismatch: the type Age was expected, but "+this.onset.getClass().getName()+" was encountered"); 1408 return (Age) this.onset; 1409 } 1410 1411 public boolean hasOnsetAge() { 1412 return this.onset instanceof Age; 1413 } 1414 1415 /** 1416 * @return {@link #onset} (Estimated or actual date or date-time the condition began, in the opinion of the clinician.) 1417 */ 1418 public Period getOnsetPeriod() throws FHIRException { 1419 if (!(this.onset instanceof Period)) 1420 throw new FHIRException("Type mismatch: the type Period was expected, but "+this.onset.getClass().getName()+" was encountered"); 1421 return (Period) this.onset; 1422 } 1423 1424 public boolean hasOnsetPeriod() { 1425 return this.onset instanceof Period; 1426 } 1427 1428 /** 1429 * @return {@link #onset} (Estimated or actual date or date-time the condition began, in the opinion of the clinician.) 1430 */ 1431 public Range getOnsetRange() throws FHIRException { 1432 if (!(this.onset instanceof Range)) 1433 throw new FHIRException("Type mismatch: the type Range was expected, but "+this.onset.getClass().getName()+" was encountered"); 1434 return (Range) this.onset; 1435 } 1436 1437 public boolean hasOnsetRange() { 1438 return this.onset instanceof Range; 1439 } 1440 1441 /** 1442 * @return {@link #onset} (Estimated or actual date or date-time the condition began, in the opinion of the clinician.) 1443 */ 1444 public StringType getOnsetStringType() throws FHIRException { 1445 if (!(this.onset instanceof StringType)) 1446 throw new FHIRException("Type mismatch: the type StringType was expected, but "+this.onset.getClass().getName()+" was encountered"); 1447 return (StringType) this.onset; 1448 } 1449 1450 public boolean hasOnsetStringType() { 1451 return this.onset instanceof StringType; 1452 } 1453 1454 public boolean hasOnset() { 1455 return this.onset != null && !this.onset.isEmpty(); 1456 } 1457 1458 /** 1459 * @param value {@link #onset} (Estimated or actual date or date-time the condition began, in the opinion of the clinician.) 1460 */ 1461 public Condition setOnset(Type value) { 1462 this.onset = value; 1463 return this; 1464 } 1465 1466 /** 1467 * @return {@link #abatement} (The date or estimated date that the condition resolved or went into remission. This is called "abatement" because of the many overloaded connotations associated with "remission" or "resolution" - Conditions are never really resolved, but they can abate.) 1468 */ 1469 public Type getAbatement() { 1470 return this.abatement; 1471 } 1472 1473 /** 1474 * @return {@link #abatement} (The date or estimated date that the condition resolved or went into remission. This is called "abatement" because of the many overloaded connotations associated with "remission" or "resolution" - Conditions are never really resolved, but they can abate.) 1475 */ 1476 public DateTimeType getAbatementDateTimeType() throws FHIRException { 1477 if (!(this.abatement instanceof DateTimeType)) 1478 throw new FHIRException("Type mismatch: the type DateTimeType was expected, but "+this.abatement.getClass().getName()+" was encountered"); 1479 return (DateTimeType) this.abatement; 1480 } 1481 1482 public boolean hasAbatementDateTimeType() { 1483 return this.abatement instanceof DateTimeType; 1484 } 1485 1486 /** 1487 * @return {@link #abatement} (The date or estimated date that the condition resolved or went into remission. This is called "abatement" because of the many overloaded connotations associated with "remission" or "resolution" - Conditions are never really resolved, but they can abate.) 1488 */ 1489 public Age getAbatementAge() throws FHIRException { 1490 if (!(this.abatement instanceof Age)) 1491 throw new FHIRException("Type mismatch: the type Age was expected, but "+this.abatement.getClass().getName()+" was encountered"); 1492 return (Age) this.abatement; 1493 } 1494 1495 public boolean hasAbatementAge() { 1496 return this.abatement instanceof Age; 1497 } 1498 1499 /** 1500 * @return {@link #abatement} (The date or estimated date that the condition resolved or went into remission. This is called "abatement" because of the many overloaded connotations associated with "remission" or "resolution" - Conditions are never really resolved, but they can abate.) 1501 */ 1502 public BooleanType getAbatementBooleanType() throws FHIRException { 1503 if (!(this.abatement instanceof BooleanType)) 1504 throw new FHIRException("Type mismatch: the type BooleanType was expected, but "+this.abatement.getClass().getName()+" was encountered"); 1505 return (BooleanType) this.abatement; 1506 } 1507 1508 public boolean hasAbatementBooleanType() { 1509 return this.abatement instanceof BooleanType; 1510 } 1511 1512 /** 1513 * @return {@link #abatement} (The date or estimated date that the condition resolved or went into remission. This is called "abatement" because of the many overloaded connotations associated with "remission" or "resolution" - Conditions are never really resolved, but they can abate.) 1514 */ 1515 public Period getAbatementPeriod() throws FHIRException { 1516 if (!(this.abatement instanceof Period)) 1517 throw new FHIRException("Type mismatch: the type Period was expected, but "+this.abatement.getClass().getName()+" was encountered"); 1518 return (Period) this.abatement; 1519 } 1520 1521 public boolean hasAbatementPeriod() { 1522 return this.abatement instanceof Period; 1523 } 1524 1525 /** 1526 * @return {@link #abatement} (The date or estimated date that the condition resolved or went into remission. This is called "abatement" because of the many overloaded connotations associated with "remission" or "resolution" - Conditions are never really resolved, but they can abate.) 1527 */ 1528 public Range getAbatementRange() throws FHIRException { 1529 if (!(this.abatement instanceof Range)) 1530 throw new FHIRException("Type mismatch: the type Range was expected, but "+this.abatement.getClass().getName()+" was encountered"); 1531 return (Range) this.abatement; 1532 } 1533 1534 public boolean hasAbatementRange() { 1535 return this.abatement instanceof Range; 1536 } 1537 1538 /** 1539 * @return {@link #abatement} (The date or estimated date that the condition resolved or went into remission. This is called "abatement" because of the many overloaded connotations associated with "remission" or "resolution" - Conditions are never really resolved, but they can abate.) 1540 */ 1541 public StringType getAbatementStringType() throws FHIRException { 1542 if (!(this.abatement instanceof StringType)) 1543 throw new FHIRException("Type mismatch: the type StringType was expected, but "+this.abatement.getClass().getName()+" was encountered"); 1544 return (StringType) this.abatement; 1545 } 1546 1547 public boolean hasAbatementStringType() { 1548 return this.abatement instanceof StringType; 1549 } 1550 1551 public boolean hasAbatement() { 1552 return this.abatement != null && !this.abatement.isEmpty(); 1553 } 1554 1555 /** 1556 * @param value {@link #abatement} (The date or estimated date that the condition resolved or went into remission. This is called "abatement" because of the many overloaded connotations associated with "remission" or "resolution" - Conditions are never really resolved, but they can abate.) 1557 */ 1558 public Condition setAbatement(Type value) { 1559 this.abatement = value; 1560 return this; 1561 } 1562 1563 /** 1564 * @return {@link #assertedDate} (The date on which the existance of the Condition was first asserted or acknowledged.). This is the underlying object with id, value and extensions. The accessor "getAssertedDate" gives direct access to the value 1565 */ 1566 public DateTimeType getAssertedDateElement() { 1567 if (this.assertedDate == null) 1568 if (Configuration.errorOnAutoCreate()) 1569 throw new Error("Attempt to auto-create Condition.assertedDate"); 1570 else if (Configuration.doAutoCreate()) 1571 this.assertedDate = new DateTimeType(); // bb 1572 return this.assertedDate; 1573 } 1574 1575 public boolean hasAssertedDateElement() { 1576 return this.assertedDate != null && !this.assertedDate.isEmpty(); 1577 } 1578 1579 public boolean hasAssertedDate() { 1580 return this.assertedDate != null && !this.assertedDate.isEmpty(); 1581 } 1582 1583 /** 1584 * @param value {@link #assertedDate} (The date on which the existance of the Condition was first asserted or acknowledged.). This is the underlying object with id, value and extensions. The accessor "getAssertedDate" gives direct access to the value 1585 */ 1586 public Condition setAssertedDateElement(DateTimeType value) { 1587 this.assertedDate = value; 1588 return this; 1589 } 1590 1591 /** 1592 * @return The date on which the existance of the Condition was first asserted or acknowledged. 1593 */ 1594 public Date getAssertedDate() { 1595 return this.assertedDate == null ? null : this.assertedDate.getValue(); 1596 } 1597 1598 /** 1599 * @param value The date on which the existance of the Condition was first asserted or acknowledged. 1600 */ 1601 public Condition setAssertedDate(Date value) { 1602 if (value == null) 1603 this.assertedDate = null; 1604 else { 1605 if (this.assertedDate == null) 1606 this.assertedDate = new DateTimeType(); 1607 this.assertedDate.setValue(value); 1608 } 1609 return this; 1610 } 1611 1612 /** 1613 * @return {@link #asserter} (Individual who is making the condition statement.) 1614 */ 1615 public Reference getAsserter() { 1616 if (this.asserter == null) 1617 if (Configuration.errorOnAutoCreate()) 1618 throw new Error("Attempt to auto-create Condition.asserter"); 1619 else if (Configuration.doAutoCreate()) 1620 this.asserter = new Reference(); // cc 1621 return this.asserter; 1622 } 1623 1624 public boolean hasAsserter() { 1625 return this.asserter != null && !this.asserter.isEmpty(); 1626 } 1627 1628 /** 1629 * @param value {@link #asserter} (Individual who is making the condition statement.) 1630 */ 1631 public Condition setAsserter(Reference value) { 1632 this.asserter = value; 1633 return this; 1634 } 1635 1636 /** 1637 * @return {@link #asserter} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (Individual who is making the condition statement.) 1638 */ 1639 public Resource getAsserterTarget() { 1640 return this.asserterTarget; 1641 } 1642 1643 /** 1644 * @param value {@link #asserter} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (Individual who is making the condition statement.) 1645 */ 1646 public Condition setAsserterTarget(Resource value) { 1647 this.asserterTarget = value; 1648 return this; 1649 } 1650 1651 /** 1652 * @return {@link #stage} (Clinical stage or grade of a condition. May include formal severity assessments.) 1653 */ 1654 public ConditionStageComponent getStage() { 1655 if (this.stage == null) 1656 if (Configuration.errorOnAutoCreate()) 1657 throw new Error("Attempt to auto-create Condition.stage"); 1658 else if (Configuration.doAutoCreate()) 1659 this.stage = new ConditionStageComponent(); // cc 1660 return this.stage; 1661 } 1662 1663 public boolean hasStage() { 1664 return this.stage != null && !this.stage.isEmpty(); 1665 } 1666 1667 /** 1668 * @param value {@link #stage} (Clinical stage or grade of a condition. May include formal severity assessments.) 1669 */ 1670 public Condition setStage(ConditionStageComponent value) { 1671 this.stage = value; 1672 return this; 1673 } 1674 1675 /** 1676 * @return {@link #evidence} (Supporting Evidence / manifestations that are the basis on which this condition is suspected or confirmed.) 1677 */ 1678 public List<ConditionEvidenceComponent> getEvidence() { 1679 if (this.evidence == null) 1680 this.evidence = new ArrayList<ConditionEvidenceComponent>(); 1681 return this.evidence; 1682 } 1683 1684 /** 1685 * @return Returns a reference to <code>this</code> for easy method chaining 1686 */ 1687 public Condition setEvidence(List<ConditionEvidenceComponent> theEvidence) { 1688 this.evidence = theEvidence; 1689 return this; 1690 } 1691 1692 public boolean hasEvidence() { 1693 if (this.evidence == null) 1694 return false; 1695 for (ConditionEvidenceComponent item : this.evidence) 1696 if (!item.isEmpty()) 1697 return true; 1698 return false; 1699 } 1700 1701 public ConditionEvidenceComponent addEvidence() { //3 1702 ConditionEvidenceComponent t = new ConditionEvidenceComponent(); 1703 if (this.evidence == null) 1704 this.evidence = new ArrayList<ConditionEvidenceComponent>(); 1705 this.evidence.add(t); 1706 return t; 1707 } 1708 1709 public Condition addEvidence(ConditionEvidenceComponent t) { //3 1710 if (t == null) 1711 return this; 1712 if (this.evidence == null) 1713 this.evidence = new ArrayList<ConditionEvidenceComponent>(); 1714 this.evidence.add(t); 1715 return this; 1716 } 1717 1718 /** 1719 * @return The first repetition of repeating field {@link #evidence}, creating it if it does not already exist 1720 */ 1721 public ConditionEvidenceComponent getEvidenceFirstRep() { 1722 if (getEvidence().isEmpty()) { 1723 addEvidence(); 1724 } 1725 return getEvidence().get(0); 1726 } 1727 1728 /** 1729 * @return {@link #note} (Additional information about the Condition. This is a general notes/comments entry for description of the Condition, its diagnosis and prognosis.) 1730 */ 1731 public List<Annotation> getNote() { 1732 if (this.note == null) 1733 this.note = new ArrayList<Annotation>(); 1734 return this.note; 1735 } 1736 1737 /** 1738 * @return Returns a reference to <code>this</code> for easy method chaining 1739 */ 1740 public Condition setNote(List<Annotation> theNote) { 1741 this.note = theNote; 1742 return this; 1743 } 1744 1745 public boolean hasNote() { 1746 if (this.note == null) 1747 return false; 1748 for (Annotation item : this.note) 1749 if (!item.isEmpty()) 1750 return true; 1751 return false; 1752 } 1753 1754 public Annotation addNote() { //3 1755 Annotation t = new Annotation(); 1756 if (this.note == null) 1757 this.note = new ArrayList<Annotation>(); 1758 this.note.add(t); 1759 return t; 1760 } 1761 1762 public Condition addNote(Annotation t) { //3 1763 if (t == null) 1764 return this; 1765 if (this.note == null) 1766 this.note = new ArrayList<Annotation>(); 1767 this.note.add(t); 1768 return this; 1769 } 1770 1771 /** 1772 * @return The first repetition of repeating field {@link #note}, creating it if it does not already exist 1773 */ 1774 public Annotation getNoteFirstRep() { 1775 if (getNote().isEmpty()) { 1776 addNote(); 1777 } 1778 return getNote().get(0); 1779 } 1780 1781 protected void listChildren(List<Property> childrenList) { 1782 super.listChildren(childrenList); 1783 childrenList.add(new Property("identifier", "Identifier", "This records identifiers associated with this condition that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).", 0, java.lang.Integer.MAX_VALUE, identifier)); 1784 childrenList.add(new Property("clinicalStatus", "code", "The clinical status of the condition.", 0, java.lang.Integer.MAX_VALUE, clinicalStatus)); 1785 childrenList.add(new Property("verificationStatus", "code", "The verification status to support the clinical status of the condition.", 0, java.lang.Integer.MAX_VALUE, verificationStatus)); 1786 childrenList.add(new Property("category", "CodeableConcept", "A category assigned to the condition.", 0, java.lang.Integer.MAX_VALUE, category)); 1787 childrenList.add(new Property("severity", "CodeableConcept", "A subjective assessment of the severity of the condition as evaluated by the clinician.", 0, java.lang.Integer.MAX_VALUE, severity)); 1788 childrenList.add(new Property("code", "CodeableConcept", "Identification of the condition, problem or diagnosis.", 0, java.lang.Integer.MAX_VALUE, code)); 1789 childrenList.add(new Property("bodySite", "CodeableConcept", "The anatomical location where this condition manifests itself.", 0, java.lang.Integer.MAX_VALUE, bodySite)); 1790 childrenList.add(new Property("subject", "Reference(Patient|Group)", "Indicates the patient or group who the condition record is associated with.", 0, java.lang.Integer.MAX_VALUE, subject)); 1791 childrenList.add(new Property("context", "Reference(Encounter|EpisodeOfCare)", "Encounter during which the condition was first asserted.", 0, java.lang.Integer.MAX_VALUE, context)); 1792 childrenList.add(new Property("onset[x]", "dateTime|Age|Period|Range|string", "Estimated or actual date or date-time the condition began, in the opinion of the clinician.", 0, java.lang.Integer.MAX_VALUE, onset)); 1793 childrenList.add(new Property("abatement[x]", "dateTime|Age|boolean|Period|Range|string", "The date or estimated date that the condition resolved or went into remission. This is called \"abatement\" because of the many overloaded connotations associated with \"remission\" or \"resolution\" - Conditions are never really resolved, but they can abate.", 0, java.lang.Integer.MAX_VALUE, abatement)); 1794 childrenList.add(new Property("assertedDate", "dateTime", "The date on which the existance of the Condition was first asserted or acknowledged.", 0, java.lang.Integer.MAX_VALUE, assertedDate)); 1795 childrenList.add(new Property("asserter", "Reference(Practitioner|Patient|RelatedPerson)", "Individual who is making the condition statement.", 0, java.lang.Integer.MAX_VALUE, asserter)); 1796 childrenList.add(new Property("stage", "", "Clinical stage or grade of a condition. May include formal severity assessments.", 0, java.lang.Integer.MAX_VALUE, stage)); 1797 childrenList.add(new Property("evidence", "", "Supporting Evidence / manifestations that are the basis on which this condition is suspected or confirmed.", 0, java.lang.Integer.MAX_VALUE, evidence)); 1798 childrenList.add(new Property("note", "Annotation", "Additional information about the Condition. This is a general notes/comments entry for description of the Condition, its diagnosis and prognosis.", 0, java.lang.Integer.MAX_VALUE, note)); 1799 } 1800 1801 @Override 1802 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1803 switch (hash) { 1804 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 1805 case -462853915: /*clinicalStatus*/ return this.clinicalStatus == null ? new Base[0] : new Base[] {this.clinicalStatus}; // Enumeration<ConditionClinicalStatus> 1806 case -842509843: /*verificationStatus*/ return this.verificationStatus == null ? new Base[0] : new Base[] {this.verificationStatus}; // Enumeration<ConditionVerificationStatus> 1807 case 50511102: /*category*/ return this.category == null ? new Base[0] : this.category.toArray(new Base[this.category.size()]); // CodeableConcept 1808 case 1478300413: /*severity*/ return this.severity == null ? new Base[0] : new Base[] {this.severity}; // CodeableConcept 1809 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 1810 case 1702620169: /*bodySite*/ return this.bodySite == null ? new Base[0] : this.bodySite.toArray(new Base[this.bodySite.size()]); // CodeableConcept 1811 case -1867885268: /*subject*/ return this.subject == null ? new Base[0] : new Base[] {this.subject}; // Reference 1812 case 951530927: /*context*/ return this.context == null ? new Base[0] : new Base[] {this.context}; // Reference 1813 case 105901603: /*onset*/ return this.onset == null ? new Base[0] : new Base[] {this.onset}; // Type 1814 case -921554001: /*abatement*/ return this.abatement == null ? new Base[0] : new Base[] {this.abatement}; // Type 1815 case -174231629: /*assertedDate*/ return this.assertedDate == null ? new Base[0] : new Base[] {this.assertedDate}; // DateTimeType 1816 case -373242253: /*asserter*/ return this.asserter == null ? new Base[0] : new Base[] {this.asserter}; // Reference 1817 case 109757182: /*stage*/ return this.stage == null ? new Base[0] : new Base[] {this.stage}; // ConditionStageComponent 1818 case 382967383: /*evidence*/ return this.evidence == null ? new Base[0] : this.evidence.toArray(new Base[this.evidence.size()]); // ConditionEvidenceComponent 1819 case 3387378: /*note*/ return this.note == null ? new Base[0] : this.note.toArray(new Base[this.note.size()]); // Annotation 1820 default: return super.getProperty(hash, name, checkValid); 1821 } 1822 1823 } 1824 1825 @Override 1826 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1827 switch (hash) { 1828 case -1618432855: // identifier 1829 this.getIdentifier().add(castToIdentifier(value)); // Identifier 1830 return value; 1831 case -462853915: // clinicalStatus 1832 value = new ConditionClinicalStatusEnumFactory().fromType(castToCode(value)); 1833 this.clinicalStatus = (Enumeration) value; // Enumeration<ConditionClinicalStatus> 1834 return value; 1835 case -842509843: // verificationStatus 1836 value = new ConditionVerificationStatusEnumFactory().fromType(castToCode(value)); 1837 this.verificationStatus = (Enumeration) value; // Enumeration<ConditionVerificationStatus> 1838 return value; 1839 case 50511102: // category 1840 this.getCategory().add(castToCodeableConcept(value)); // CodeableConcept 1841 return value; 1842 case 1478300413: // severity 1843 this.severity = castToCodeableConcept(value); // CodeableConcept 1844 return value; 1845 case 3059181: // code 1846 this.code = castToCodeableConcept(value); // CodeableConcept 1847 return value; 1848 case 1702620169: // bodySite 1849 this.getBodySite().add(castToCodeableConcept(value)); // CodeableConcept 1850 return value; 1851 case -1867885268: // subject 1852 this.subject = castToReference(value); // Reference 1853 return value; 1854 case 951530927: // context 1855 this.context = castToReference(value); // Reference 1856 return value; 1857 case 105901603: // onset 1858 this.onset = castToType(value); // Type 1859 return value; 1860 case -921554001: // abatement 1861 this.abatement = castToType(value); // Type 1862 return value; 1863 case -174231629: // assertedDate 1864 this.assertedDate = castToDateTime(value); // DateTimeType 1865 return value; 1866 case -373242253: // asserter 1867 this.asserter = castToReference(value); // Reference 1868 return value; 1869 case 109757182: // stage 1870 this.stage = (ConditionStageComponent) value; // ConditionStageComponent 1871 return value; 1872 case 382967383: // evidence 1873 this.getEvidence().add((ConditionEvidenceComponent) value); // ConditionEvidenceComponent 1874 return value; 1875 case 3387378: // note 1876 this.getNote().add(castToAnnotation(value)); // Annotation 1877 return value; 1878 default: return super.setProperty(hash, name, value); 1879 } 1880 1881 } 1882 1883 @Override 1884 public Base setProperty(String name, Base value) throws FHIRException { 1885 if (name.equals("identifier")) { 1886 this.getIdentifier().add(castToIdentifier(value)); 1887 } else if (name.equals("clinicalStatus")) { 1888 value = new ConditionClinicalStatusEnumFactory().fromType(castToCode(value)); 1889 this.clinicalStatus = (Enumeration) value; // Enumeration<ConditionClinicalStatus> 1890 } else if (name.equals("verificationStatus")) { 1891 value = new ConditionVerificationStatusEnumFactory().fromType(castToCode(value)); 1892 this.verificationStatus = (Enumeration) value; // Enumeration<ConditionVerificationStatus> 1893 } else if (name.equals("category")) { 1894 this.getCategory().add(castToCodeableConcept(value)); 1895 } else if (name.equals("severity")) { 1896 this.severity = castToCodeableConcept(value); // CodeableConcept 1897 } else if (name.equals("code")) { 1898 this.code = castToCodeableConcept(value); // CodeableConcept 1899 } else if (name.equals("bodySite")) { 1900 this.getBodySite().add(castToCodeableConcept(value)); 1901 } else if (name.equals("subject")) { 1902 this.subject = castToReference(value); // Reference 1903 } else if (name.equals("context")) { 1904 this.context = castToReference(value); // Reference 1905 } else if (name.equals("onset[x]")) { 1906 this.onset = castToType(value); // Type 1907 } else if (name.equals("abatement[x]")) { 1908 this.abatement = castToType(value); // Type 1909 } else if (name.equals("assertedDate")) { 1910 this.assertedDate = castToDateTime(value); // DateTimeType 1911 } else if (name.equals("asserter")) { 1912 this.asserter = castToReference(value); // Reference 1913 } else if (name.equals("stage")) { 1914 this.stage = (ConditionStageComponent) value; // ConditionStageComponent 1915 } else if (name.equals("evidence")) { 1916 this.getEvidence().add((ConditionEvidenceComponent) value); 1917 } else if (name.equals("note")) { 1918 this.getNote().add(castToAnnotation(value)); 1919 } else 1920 return super.setProperty(name, value); 1921 return value; 1922 } 1923 1924 @Override 1925 public Base makeProperty(int hash, String name) throws FHIRException { 1926 switch (hash) { 1927 case -1618432855: return addIdentifier(); 1928 case -462853915: return getClinicalStatusElement(); 1929 case -842509843: return getVerificationStatusElement(); 1930 case 50511102: return addCategory(); 1931 case 1478300413: return getSeverity(); 1932 case 3059181: return getCode(); 1933 case 1702620169: return addBodySite(); 1934 case -1867885268: return getSubject(); 1935 case 951530927: return getContext(); 1936 case -1886216323: return getOnset(); 1937 case 105901603: return getOnset(); 1938 case -584196495: return getAbatement(); 1939 case -921554001: return getAbatement(); 1940 case -174231629: return getAssertedDateElement(); 1941 case -373242253: return getAsserter(); 1942 case 109757182: return getStage(); 1943 case 382967383: return addEvidence(); 1944 case 3387378: return addNote(); 1945 default: return super.makeProperty(hash, name); 1946 } 1947 1948 } 1949 1950 @Override 1951 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1952 switch (hash) { 1953 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 1954 case -462853915: /*clinicalStatus*/ return new String[] {"code"}; 1955 case -842509843: /*verificationStatus*/ return new String[] {"code"}; 1956 case 50511102: /*category*/ return new String[] {"CodeableConcept"}; 1957 case 1478300413: /*severity*/ return new String[] {"CodeableConcept"}; 1958 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 1959 case 1702620169: /*bodySite*/ return new String[] {"CodeableConcept"}; 1960 case -1867885268: /*subject*/ return new String[] {"Reference"}; 1961 case 951530927: /*context*/ return new String[] {"Reference"}; 1962 case 105901603: /*onset*/ return new String[] {"dateTime", "Age", "Period", "Range", "string"}; 1963 case -921554001: /*abatement*/ return new String[] {"dateTime", "Age", "boolean", "Period", "Range", "string"}; 1964 case -174231629: /*assertedDate*/ return new String[] {"dateTime"}; 1965 case -373242253: /*asserter*/ return new String[] {"Reference"}; 1966 case 109757182: /*stage*/ return new String[] {}; 1967 case 382967383: /*evidence*/ return new String[] {}; 1968 case 3387378: /*note*/ return new String[] {"Annotation"}; 1969 default: return super.getTypesForProperty(hash, name); 1970 } 1971 1972 } 1973 1974 @Override 1975 public Base addChild(String name) throws FHIRException { 1976 if (name.equals("identifier")) { 1977 return addIdentifier(); 1978 } 1979 else if (name.equals("clinicalStatus")) { 1980 throw new FHIRException("Cannot call addChild on a primitive type Condition.clinicalStatus"); 1981 } 1982 else if (name.equals("verificationStatus")) { 1983 throw new FHIRException("Cannot call addChild on a primitive type Condition.verificationStatus"); 1984 } 1985 else if (name.equals("category")) { 1986 return addCategory(); 1987 } 1988 else if (name.equals("severity")) { 1989 this.severity = new CodeableConcept(); 1990 return this.severity; 1991 } 1992 else if (name.equals("code")) { 1993 this.code = new CodeableConcept(); 1994 return this.code; 1995 } 1996 else if (name.equals("bodySite")) { 1997 return addBodySite(); 1998 } 1999 else if (name.equals("subject")) { 2000 this.subject = new Reference(); 2001 return this.subject; 2002 } 2003 else if (name.equals("context")) { 2004 this.context = new Reference(); 2005 return this.context; 2006 } 2007 else if (name.equals("onsetDateTime")) { 2008 this.onset = new DateTimeType(); 2009 return this.onset; 2010 } 2011 else if (name.equals("onsetAge")) { 2012 this.onset = new Age(); 2013 return this.onset; 2014 } 2015 else if (name.equals("onsetPeriod")) { 2016 this.onset = new Period(); 2017 return this.onset; 2018 } 2019 else if (name.equals("onsetRange")) { 2020 this.onset = new Range(); 2021 return this.onset; 2022 } 2023 else if (name.equals("onsetString")) { 2024 this.onset = new StringType(); 2025 return this.onset; 2026 } 2027 else if (name.equals("abatementDateTime")) { 2028 this.abatement = new DateTimeType(); 2029 return this.abatement; 2030 } 2031 else if (name.equals("abatementAge")) { 2032 this.abatement = new Age(); 2033 return this.abatement; 2034 } 2035 else if (name.equals("abatementBoolean")) { 2036 this.abatement = new BooleanType(); 2037 return this.abatement; 2038 } 2039 else if (name.equals("abatementPeriod")) { 2040 this.abatement = new Period(); 2041 return this.abatement; 2042 } 2043 else if (name.equals("abatementRange")) { 2044 this.abatement = new Range(); 2045 return this.abatement; 2046 } 2047 else if (name.equals("abatementString")) { 2048 this.abatement = new StringType(); 2049 return this.abatement; 2050 } 2051 else if (name.equals("assertedDate")) { 2052 throw new FHIRException("Cannot call addChild on a primitive type Condition.assertedDate"); 2053 } 2054 else if (name.equals("asserter")) { 2055 this.asserter = new Reference(); 2056 return this.asserter; 2057 } 2058 else if (name.equals("stage")) { 2059 this.stage = new ConditionStageComponent(); 2060 return this.stage; 2061 } 2062 else if (name.equals("evidence")) { 2063 return addEvidence(); 2064 } 2065 else if (name.equals("note")) { 2066 return addNote(); 2067 } 2068 else 2069 return super.addChild(name); 2070 } 2071 2072 public String fhirType() { 2073 return "Condition"; 2074 2075 } 2076 2077 public Condition copy() { 2078 Condition dst = new Condition(); 2079 copyValues(dst); 2080 if (identifier != null) { 2081 dst.identifier = new ArrayList<Identifier>(); 2082 for (Identifier i : identifier) 2083 dst.identifier.add(i.copy()); 2084 }; 2085 dst.clinicalStatus = clinicalStatus == null ? null : clinicalStatus.copy(); 2086 dst.verificationStatus = verificationStatus == null ? null : verificationStatus.copy(); 2087 if (category != null) { 2088 dst.category = new ArrayList<CodeableConcept>(); 2089 for (CodeableConcept i : category) 2090 dst.category.add(i.copy()); 2091 }; 2092 dst.severity = severity == null ? null : severity.copy(); 2093 dst.code = code == null ? null : code.copy(); 2094 if (bodySite != null) { 2095 dst.bodySite = new ArrayList<CodeableConcept>(); 2096 for (CodeableConcept i : bodySite) 2097 dst.bodySite.add(i.copy()); 2098 }; 2099 dst.subject = subject == null ? null : subject.copy(); 2100 dst.context = context == null ? null : context.copy(); 2101 dst.onset = onset == null ? null : onset.copy(); 2102 dst.abatement = abatement == null ? null : abatement.copy(); 2103 dst.assertedDate = assertedDate == null ? null : assertedDate.copy(); 2104 dst.asserter = asserter == null ? null : asserter.copy(); 2105 dst.stage = stage == null ? null : stage.copy(); 2106 if (evidence != null) { 2107 dst.evidence = new ArrayList<ConditionEvidenceComponent>(); 2108 for (ConditionEvidenceComponent i : evidence) 2109 dst.evidence.add(i.copy()); 2110 }; 2111 if (note != null) { 2112 dst.note = new ArrayList<Annotation>(); 2113 for (Annotation i : note) 2114 dst.note.add(i.copy()); 2115 }; 2116 return dst; 2117 } 2118 2119 protected Condition typedCopy() { 2120 return copy(); 2121 } 2122 2123 @Override 2124 public boolean equalsDeep(Base other) { 2125 if (!super.equalsDeep(other)) 2126 return false; 2127 if (!(other instanceof Condition)) 2128 return false; 2129 Condition o = (Condition) other; 2130 return compareDeep(identifier, o.identifier, true) && compareDeep(clinicalStatus, o.clinicalStatus, true) 2131 && compareDeep(verificationStatus, o.verificationStatus, true) && compareDeep(category, o.category, true) 2132 && compareDeep(severity, o.severity, true) && compareDeep(code, o.code, true) && compareDeep(bodySite, o.bodySite, true) 2133 && compareDeep(subject, o.subject, true) && compareDeep(context, o.context, true) && compareDeep(onset, o.onset, true) 2134 && compareDeep(abatement, o.abatement, true) && compareDeep(assertedDate, o.assertedDate, true) 2135 && compareDeep(asserter, o.asserter, true) && compareDeep(stage, o.stage, true) && compareDeep(evidence, o.evidence, true) 2136 && compareDeep(note, o.note, true); 2137 } 2138 2139 @Override 2140 public boolean equalsShallow(Base other) { 2141 if (!super.equalsShallow(other)) 2142 return false; 2143 if (!(other instanceof Condition)) 2144 return false; 2145 Condition o = (Condition) other; 2146 return compareValues(clinicalStatus, o.clinicalStatus, true) && compareValues(verificationStatus, o.verificationStatus, true) 2147 && compareValues(assertedDate, o.assertedDate, true); 2148 } 2149 2150 public boolean isEmpty() { 2151 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, clinicalStatus 2152 , verificationStatus, category, severity, code, bodySite, subject, context, onset 2153 , abatement, assertedDate, asserter, stage, evidence, note); 2154 } 2155 2156 @Override 2157 public ResourceType getResourceType() { 2158 return ResourceType.Condition; 2159 } 2160 2161 /** 2162 * Search parameter: <b>severity</b> 2163 * <p> 2164 * Description: <b>The severity of the condition</b><br> 2165 * Type: <b>token</b><br> 2166 * Path: <b>Condition.severity</b><br> 2167 * </p> 2168 */ 2169 @SearchParamDefinition(name="severity", path="Condition.severity", description="The severity of the condition", type="token" ) 2170 public static final String SP_SEVERITY = "severity"; 2171 /** 2172 * <b>Fluent Client</b> search parameter constant for <b>severity</b> 2173 * <p> 2174 * Description: <b>The severity of the condition</b><br> 2175 * Type: <b>token</b><br> 2176 * Path: <b>Condition.severity</b><br> 2177 * </p> 2178 */ 2179 public static final ca.uhn.fhir.rest.gclient.TokenClientParam SEVERITY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_SEVERITY); 2180 2181 /** 2182 * Search parameter: <b>evidence-detail</b> 2183 * <p> 2184 * Description: <b>Supporting information found elsewhere</b><br> 2185 * Type: <b>reference</b><br> 2186 * Path: <b>Condition.evidence.detail</b><br> 2187 * </p> 2188 */ 2189 @SearchParamDefinition(name="evidence-detail", path="Condition.evidence.detail", description="Supporting information found elsewhere", type="reference" ) 2190 public static final String SP_EVIDENCE_DETAIL = "evidence-detail"; 2191 /** 2192 * <b>Fluent Client</b> search parameter constant for <b>evidence-detail</b> 2193 * <p> 2194 * Description: <b>Supporting information found elsewhere</b><br> 2195 * Type: <b>reference</b><br> 2196 * Path: <b>Condition.evidence.detail</b><br> 2197 * </p> 2198 */ 2199 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam EVIDENCE_DETAIL = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_EVIDENCE_DETAIL); 2200 2201/** 2202 * Constant for fluent queries to be used to add include statements. Specifies 2203 * the path value of "<b>Condition:evidence-detail</b>". 2204 */ 2205 public static final ca.uhn.fhir.model.api.Include INCLUDE_EVIDENCE_DETAIL = new ca.uhn.fhir.model.api.Include("Condition:evidence-detail").toLocked(); 2206 2207 /** 2208 * Search parameter: <b>identifier</b> 2209 * <p> 2210 * Description: <b>A unique identifier of the condition record</b><br> 2211 * Type: <b>token</b><br> 2212 * Path: <b>Condition.identifier</b><br> 2213 * </p> 2214 */ 2215 @SearchParamDefinition(name="identifier", path="Condition.identifier", description="A unique identifier of the condition record", type="token" ) 2216 public static final String SP_IDENTIFIER = "identifier"; 2217 /** 2218 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 2219 * <p> 2220 * Description: <b>A unique identifier of the condition record</b><br> 2221 * Type: <b>token</b><br> 2222 * Path: <b>Condition.identifier</b><br> 2223 * </p> 2224 */ 2225 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 2226 2227 /** 2228 * Search parameter: <b>onset-info</b> 2229 * <p> 2230 * Description: <b>Onsets as a string</b><br> 2231 * Type: <b>string</b><br> 2232 * Path: <b>Condition.onset[x]</b><br> 2233 * </p> 2234 */ 2235 @SearchParamDefinition(name="onset-info", path="Condition.onset.as(string)", description="Onsets as a string", type="string" ) 2236 public static final String SP_ONSET_INFO = "onset-info"; 2237 /** 2238 * <b>Fluent Client</b> search parameter constant for <b>onset-info</b> 2239 * <p> 2240 * Description: <b>Onsets as a string</b><br> 2241 * Type: <b>string</b><br> 2242 * Path: <b>Condition.onset[x]</b><br> 2243 * </p> 2244 */ 2245 public static final ca.uhn.fhir.rest.gclient.StringClientParam ONSET_INFO = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ONSET_INFO); 2246 2247 /** 2248 * Search parameter: <b>code</b> 2249 * <p> 2250 * Description: <b>Code for the condition</b><br> 2251 * Type: <b>token</b><br> 2252 * Path: <b>Condition.code</b><br> 2253 * </p> 2254 */ 2255 @SearchParamDefinition(name="code", path="Condition.code", description="Code for the condition", type="token" ) 2256 public static final String SP_CODE = "code"; 2257 /** 2258 * <b>Fluent Client</b> search parameter constant for <b>code</b> 2259 * <p> 2260 * Description: <b>Code for the condition</b><br> 2261 * Type: <b>token</b><br> 2262 * Path: <b>Condition.code</b><br> 2263 * </p> 2264 */ 2265 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CODE); 2266 2267 /** 2268 * Search parameter: <b>evidence</b> 2269 * <p> 2270 * Description: <b>Manifestation/symptom</b><br> 2271 * Type: <b>token</b><br> 2272 * Path: <b>Condition.evidence.code</b><br> 2273 * </p> 2274 */ 2275 @SearchParamDefinition(name="evidence", path="Condition.evidence.code", description="Manifestation/symptom", type="token" ) 2276 public static final String SP_EVIDENCE = "evidence"; 2277 /** 2278 * <b>Fluent Client</b> search parameter constant for <b>evidence</b> 2279 * <p> 2280 * Description: <b>Manifestation/symptom</b><br> 2281 * Type: <b>token</b><br> 2282 * Path: <b>Condition.evidence.code</b><br> 2283 * </p> 2284 */ 2285 public static final ca.uhn.fhir.rest.gclient.TokenClientParam EVIDENCE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_EVIDENCE); 2286 2287 /** 2288 * Search parameter: <b>subject</b> 2289 * <p> 2290 * Description: <b>Who has the condition?</b><br> 2291 * Type: <b>reference</b><br> 2292 * Path: <b>Condition.subject</b><br> 2293 * </p> 2294 */ 2295 @SearchParamDefinition(name="subject", path="Condition.subject", description="Who has the condition?", type="reference", target={Group.class, Patient.class } ) 2296 public static final String SP_SUBJECT = "subject"; 2297 /** 2298 * <b>Fluent Client</b> search parameter constant for <b>subject</b> 2299 * <p> 2300 * Description: <b>Who has the condition?</b><br> 2301 * Type: <b>reference</b><br> 2302 * Path: <b>Condition.subject</b><br> 2303 * </p> 2304 */ 2305 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SUBJECT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SUBJECT); 2306 2307/** 2308 * Constant for fluent queries to be used to add include statements. Specifies 2309 * the path value of "<b>Condition:subject</b>". 2310 */ 2311 public static final ca.uhn.fhir.model.api.Include INCLUDE_SUBJECT = new ca.uhn.fhir.model.api.Include("Condition:subject").toLocked(); 2312 2313 /** 2314 * Search parameter: <b>verification-status</b> 2315 * <p> 2316 * Description: <b>provisional | differential | confirmed | refuted | entered-in-error | unknown</b><br> 2317 * Type: <b>token</b><br> 2318 * Path: <b>Condition.verificationStatus</b><br> 2319 * </p> 2320 */ 2321 @SearchParamDefinition(name="verification-status", path="Condition.verificationStatus", description="provisional | differential | confirmed | refuted | entered-in-error | unknown", type="token" ) 2322 public static final String SP_VERIFICATION_STATUS = "verification-status"; 2323 /** 2324 * <b>Fluent Client</b> search parameter constant for <b>verification-status</b> 2325 * <p> 2326 * Description: <b>provisional | differential | confirmed | refuted | entered-in-error | unknown</b><br> 2327 * Type: <b>token</b><br> 2328 * Path: <b>Condition.verificationStatus</b><br> 2329 * </p> 2330 */ 2331 public static final ca.uhn.fhir.rest.gclient.TokenClientParam VERIFICATION_STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_VERIFICATION_STATUS); 2332 2333 /** 2334 * Search parameter: <b>clinical-status</b> 2335 * <p> 2336 * Description: <b>The clinical status of the condition</b><br> 2337 * Type: <b>token</b><br> 2338 * Path: <b>Condition.clinicalStatus</b><br> 2339 * </p> 2340 */ 2341 @SearchParamDefinition(name="clinical-status", path="Condition.clinicalStatus", description="The clinical status of the condition", type="token" ) 2342 public static final String SP_CLINICAL_STATUS = "clinical-status"; 2343 /** 2344 * <b>Fluent Client</b> search parameter constant for <b>clinical-status</b> 2345 * <p> 2346 * Description: <b>The clinical status of the condition</b><br> 2347 * Type: <b>token</b><br> 2348 * Path: <b>Condition.clinicalStatus</b><br> 2349 * </p> 2350 */ 2351 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CLINICAL_STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CLINICAL_STATUS); 2352 2353 /** 2354 * Search parameter: <b>encounter</b> 2355 * <p> 2356 * Description: <b>Encounter when condition first asserted</b><br> 2357 * Type: <b>reference</b><br> 2358 * Path: <b>Condition.context</b><br> 2359 * </p> 2360 */ 2361 @SearchParamDefinition(name="encounter", path="Condition.context", description="Encounter when condition first asserted", type="reference", target={Encounter.class } ) 2362 public static final String SP_ENCOUNTER = "encounter"; 2363 /** 2364 * <b>Fluent Client</b> search parameter constant for <b>encounter</b> 2365 * <p> 2366 * Description: <b>Encounter when condition first asserted</b><br> 2367 * Type: <b>reference</b><br> 2368 * Path: <b>Condition.context</b><br> 2369 * </p> 2370 */ 2371 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ENCOUNTER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ENCOUNTER); 2372 2373/** 2374 * Constant for fluent queries to be used to add include statements. Specifies 2375 * the path value of "<b>Condition:encounter</b>". 2376 */ 2377 public static final ca.uhn.fhir.model.api.Include INCLUDE_ENCOUNTER = new ca.uhn.fhir.model.api.Include("Condition:encounter").toLocked(); 2378 2379 /** 2380 * Search parameter: <b>abatement-boolean</b> 2381 * <p> 2382 * Description: <b>Abatement boolean (boolean is true or non-boolean values are present)</b><br> 2383 * Type: <b>token</b><br> 2384 * Path: <b>Condition.abatement[x]</b><br> 2385 * </p> 2386 */ 2387 @SearchParamDefinition(name="abatement-boolean", path="Condition.abatement.as(boolean) | Condition.abatement.is(dateTime) | Condition.abatement.is(Age) | Condition.abatement.is(Period) | Condition.abatement.is(Range) | Condition.abatement.is(string)", description="Abatement boolean (boolean is true or non-boolean values are present)", type="token" ) 2388 public static final String SP_ABATEMENT_BOOLEAN = "abatement-boolean"; 2389 /** 2390 * <b>Fluent Client</b> search parameter constant for <b>abatement-boolean</b> 2391 * <p> 2392 * Description: <b>Abatement boolean (boolean is true or non-boolean values are present)</b><br> 2393 * Type: <b>token</b><br> 2394 * Path: <b>Condition.abatement[x]</b><br> 2395 * </p> 2396 */ 2397 public static final ca.uhn.fhir.rest.gclient.TokenClientParam ABATEMENT_BOOLEAN = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_ABATEMENT_BOOLEAN); 2398 2399 /** 2400 * Search parameter: <b>onset-date</b> 2401 * <p> 2402 * Description: <b>Date related onsets (dateTime and Period)</b><br> 2403 * Type: <b>date</b><br> 2404 * Path: <b>Condition.onset[x]</b><br> 2405 * </p> 2406 */ 2407 @SearchParamDefinition(name="onset-date", path="Condition.onset.as(dateTime) | Condition.onset.as(Period)", description="Date related onsets (dateTime and Period)", type="date" ) 2408 public static final String SP_ONSET_DATE = "onset-date"; 2409 /** 2410 * <b>Fluent Client</b> search parameter constant for <b>onset-date</b> 2411 * <p> 2412 * Description: <b>Date related onsets (dateTime and Period)</b><br> 2413 * Type: <b>date</b><br> 2414 * Path: <b>Condition.onset[x]</b><br> 2415 * </p> 2416 */ 2417 public static final ca.uhn.fhir.rest.gclient.DateClientParam ONSET_DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_ONSET_DATE); 2418 2419 /** 2420 * Search parameter: <b>abatement-date</b> 2421 * <p> 2422 * Description: <b>Date-related abatements (dateTime and period)</b><br> 2423 * Type: <b>date</b><br> 2424 * Path: <b>Condition.abatement[x]</b><br> 2425 * </p> 2426 */ 2427 @SearchParamDefinition(name="abatement-date", path="Condition.abatement.as(dateTime) | Condition.abatement.as(Period)", description="Date-related abatements (dateTime and period)", type="date" ) 2428 public static final String SP_ABATEMENT_DATE = "abatement-date"; 2429 /** 2430 * <b>Fluent Client</b> search parameter constant for <b>abatement-date</b> 2431 * <p> 2432 * Description: <b>Date-related abatements (dateTime and period)</b><br> 2433 * Type: <b>date</b><br> 2434 * Path: <b>Condition.abatement[x]</b><br> 2435 * </p> 2436 */ 2437 public static final ca.uhn.fhir.rest.gclient.DateClientParam ABATEMENT_DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_ABATEMENT_DATE); 2438 2439 /** 2440 * Search parameter: <b>asserter</b> 2441 * <p> 2442 * Description: <b>Person who asserts this condition</b><br> 2443 * Type: <b>reference</b><br> 2444 * Path: <b>Condition.asserter</b><br> 2445 * </p> 2446 */ 2447 @SearchParamDefinition(name="asserter", path="Condition.asserter", description="Person who asserts this condition", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Patient"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Practitioner"), @ca.uhn.fhir.model.api.annotation.Compartment(name="RelatedPerson") }, target={Patient.class, Practitioner.class, RelatedPerson.class } ) 2448 public static final String SP_ASSERTER = "asserter"; 2449 /** 2450 * <b>Fluent Client</b> search parameter constant for <b>asserter</b> 2451 * <p> 2452 * Description: <b>Person who asserts this condition</b><br> 2453 * Type: <b>reference</b><br> 2454 * Path: <b>Condition.asserter</b><br> 2455 * </p> 2456 */ 2457 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ASSERTER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ASSERTER); 2458 2459/** 2460 * Constant for fluent queries to be used to add include statements. Specifies 2461 * the path value of "<b>Condition:asserter</b>". 2462 */ 2463 public static final ca.uhn.fhir.model.api.Include INCLUDE_ASSERTER = new ca.uhn.fhir.model.api.Include("Condition:asserter").toLocked(); 2464 2465 /** 2466 * Search parameter: <b>stage</b> 2467 * <p> 2468 * Description: <b>Simple summary (disease specific)</b><br> 2469 * Type: <b>token</b><br> 2470 * Path: <b>Condition.stage.summary</b><br> 2471 * </p> 2472 */ 2473 @SearchParamDefinition(name="stage", path="Condition.stage.summary", description="Simple summary (disease specific)", type="token" ) 2474 public static final String SP_STAGE = "stage"; 2475 /** 2476 * <b>Fluent Client</b> search parameter constant for <b>stage</b> 2477 * <p> 2478 * Description: <b>Simple summary (disease specific)</b><br> 2479 * Type: <b>token</b><br> 2480 * Path: <b>Condition.stage.summary</b><br> 2481 * </p> 2482 */ 2483 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STAGE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STAGE); 2484 2485 /** 2486 * Search parameter: <b>abatement-string</b> 2487 * <p> 2488 * Description: <b>Abatement as a string</b><br> 2489 * Type: <b>string</b><br> 2490 * Path: <b>Condition.abatement[x]</b><br> 2491 * </p> 2492 */ 2493 @SearchParamDefinition(name="abatement-string", path="Condition.abatement.as(string)", description="Abatement as a string", type="string" ) 2494 public static final String SP_ABATEMENT_STRING = "abatement-string"; 2495 /** 2496 * <b>Fluent Client</b> search parameter constant for <b>abatement-string</b> 2497 * <p> 2498 * Description: <b>Abatement as a string</b><br> 2499 * Type: <b>string</b><br> 2500 * Path: <b>Condition.abatement[x]</b><br> 2501 * </p> 2502 */ 2503 public static final ca.uhn.fhir.rest.gclient.StringClientParam ABATEMENT_STRING = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ABATEMENT_STRING); 2504 2505 /** 2506 * Search parameter: <b>patient</b> 2507 * <p> 2508 * Description: <b>Who has the condition?</b><br> 2509 * Type: <b>reference</b><br> 2510 * Path: <b>Condition.subject</b><br> 2511 * </p> 2512 */ 2513 @SearchParamDefinition(name="patient", path="Condition.subject", description="Who has the condition?", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Patient") }, target={Patient.class } ) 2514 public static final String SP_PATIENT = "patient"; 2515 /** 2516 * <b>Fluent Client</b> search parameter constant for <b>patient</b> 2517 * <p> 2518 * Description: <b>Who has the condition?</b><br> 2519 * Type: <b>reference</b><br> 2520 * Path: <b>Condition.subject</b><br> 2521 * </p> 2522 */ 2523 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT); 2524 2525/** 2526 * Constant for fluent queries to be used to add include statements. Specifies 2527 * the path value of "<b>Condition:patient</b>". 2528 */ 2529 public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("Condition:patient").toLocked(); 2530 2531 /** 2532 * Search parameter: <b>context</b> 2533 * <p> 2534 * Description: <b>Encounter or episode when condition first asserted</b><br> 2535 * Type: <b>reference</b><br> 2536 * Path: <b>Condition.context</b><br> 2537 * </p> 2538 */ 2539 @SearchParamDefinition(name="context", path="Condition.context", description="Encounter or episode when condition first asserted", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Encounter") }, target={Encounter.class, EpisodeOfCare.class } ) 2540 public static final String SP_CONTEXT = "context"; 2541 /** 2542 * <b>Fluent Client</b> search parameter constant for <b>context</b> 2543 * <p> 2544 * Description: <b>Encounter or episode when condition first asserted</b><br> 2545 * Type: <b>reference</b><br> 2546 * Path: <b>Condition.context</b><br> 2547 * </p> 2548 */ 2549 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam CONTEXT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_CONTEXT); 2550 2551/** 2552 * Constant for fluent queries to be used to add include statements. Specifies 2553 * the path value of "<b>Condition:context</b>". 2554 */ 2555 public static final ca.uhn.fhir.model.api.Include INCLUDE_CONTEXT = new ca.uhn.fhir.model.api.Include("Condition:context").toLocked(); 2556 2557 /** 2558 * Search parameter: <b>onset-age</b> 2559 * <p> 2560 * Description: <b>Onsets as age or age range</b><br> 2561 * Type: <b>quantity</b><br> 2562 * Path: <b>Condition.onset[x]</b><br> 2563 * </p> 2564 */ 2565 @SearchParamDefinition(name="onset-age", path="Condition.onset.as(Age) | Condition.onset.as(Range)", description="Onsets as age or age range", type="quantity" ) 2566 public static final String SP_ONSET_AGE = "onset-age"; 2567 /** 2568 * <b>Fluent Client</b> search parameter constant for <b>onset-age</b> 2569 * <p> 2570 * Description: <b>Onsets as age or age range</b><br> 2571 * Type: <b>quantity</b><br> 2572 * Path: <b>Condition.onset[x]</b><br> 2573 * </p> 2574 */ 2575 public static final ca.uhn.fhir.rest.gclient.QuantityClientParam ONSET_AGE = new ca.uhn.fhir.rest.gclient.QuantityClientParam(SP_ONSET_AGE); 2576 2577 /** 2578 * Search parameter: <b>abatement-age</b> 2579 * <p> 2580 * Description: <b>Abatement as age or age range</b><br> 2581 * Type: <b>quantity</b><br> 2582 * Path: <b>Condition.abatement[x]</b><br> 2583 * </p> 2584 */ 2585 @SearchParamDefinition(name="abatement-age", path="Condition.abatement.as(Age) | Condition.abatement.as(Range) | Condition.abatement.as(Age)", description="Abatement as age or age range", type="quantity" ) 2586 public static final String SP_ABATEMENT_AGE = "abatement-age"; 2587 /** 2588 * <b>Fluent Client</b> search parameter constant for <b>abatement-age</b> 2589 * <p> 2590 * Description: <b>Abatement as age or age range</b><br> 2591 * Type: <b>quantity</b><br> 2592 * Path: <b>Condition.abatement[x]</b><br> 2593 * </p> 2594 */ 2595 public static final ca.uhn.fhir.rest.gclient.QuantityClientParam ABATEMENT_AGE = new ca.uhn.fhir.rest.gclient.QuantityClientParam(SP_ABATEMENT_AGE); 2596 2597 /** 2598 * Search parameter: <b>asserted-date</b> 2599 * <p> 2600 * Description: <b>Date record was believed accurate</b><br> 2601 * Type: <b>date</b><br> 2602 * Path: <b>Condition.assertedDate</b><br> 2603 * </p> 2604 */ 2605 @SearchParamDefinition(name="asserted-date", path="Condition.assertedDate", description="Date record was believed accurate", type="date" ) 2606 public static final String SP_ASSERTED_DATE = "asserted-date"; 2607 /** 2608 * <b>Fluent Client</b> search parameter constant for <b>asserted-date</b> 2609 * <p> 2610 * Description: <b>Date record was believed accurate</b><br> 2611 * Type: <b>date</b><br> 2612 * Path: <b>Condition.assertedDate</b><br> 2613 * </p> 2614 */ 2615 public static final ca.uhn.fhir.rest.gclient.DateClientParam ASSERTED_DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_ASSERTED_DATE); 2616 2617 /** 2618 * Search parameter: <b>category</b> 2619 * <p> 2620 * Description: <b>The category of the condition</b><br> 2621 * Type: <b>token</b><br> 2622 * Path: <b>Condition.category</b><br> 2623 * </p> 2624 */ 2625 @SearchParamDefinition(name="category", path="Condition.category", description="The category of the condition", type="token" ) 2626 public static final String SP_CATEGORY = "category"; 2627 /** 2628 * <b>Fluent Client</b> search parameter constant for <b>category</b> 2629 * <p> 2630 * Description: <b>The category of the condition</b><br> 2631 * Type: <b>token</b><br> 2632 * Path: <b>Condition.category</b><br> 2633 * </p> 2634 */ 2635 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CATEGORY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CATEGORY); 2636 2637 /** 2638 * Search parameter: <b>body-site</b> 2639 * <p> 2640 * Description: <b>Anatomical location, if relevant</b><br> 2641 * Type: <b>token</b><br> 2642 * Path: <b>Condition.bodySite</b><br> 2643 * </p> 2644 */ 2645 @SearchParamDefinition(name="body-site", path="Condition.bodySite", description="Anatomical location, if relevant", type="token" ) 2646 public static final String SP_BODY_SITE = "body-site"; 2647 /** 2648 * <b>Fluent Client</b> search parameter constant for <b>body-site</b> 2649 * <p> 2650 * Description: <b>Anatomical location, if relevant</b><br> 2651 * Type: <b>token</b><br> 2652 * Path: <b>Condition.bodySite</b><br> 2653 * </p> 2654 */ 2655 public static final ca.uhn.fhir.rest.gclient.TokenClientParam BODY_SITE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_BODY_SITE); 2656 2657 2658} 2659