001package org.hl7.fhir.r4.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 Sun, May 6, 2018 17:51-0400 for FHIR v3.4.0 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 * The findings and interpretation of diagnostic tests performed on patients, groups of patients, devices, and locations, and/or specimens derived from these. The report includes clinical context such as requesting and provider information, and some mix of atomic results, images, textual and coded interpretations, and formatted representation of diagnostic reports. 047 */ 048@ResourceDef(name="DiagnosticReport", profile="http://hl7.org/fhir/Profile/DiagnosticReport") 049public class DiagnosticReport extends DomainResource { 050 051 public enum DiagnosticReportStatus { 052 /** 053 * The existence of the report is registered, but there is nothing yet available. 054 */ 055 REGISTERED, 056 /** 057 * This is a partial (e.g. initial, interim or preliminary) report: data in the report may be incomplete or unverified. 058 */ 059 PARTIAL, 060 /** 061 * Verified early results are available, but not all results are final. 062 */ 063 PRELIMINARY, 064 /** 065 * The report is complete and verified by an authorized person. 066 */ 067 FINAL, 068 /** 069 * Subsequent to being final, the report has been modified. This includes any change in the results, diagnosis, narrative text, or other content of a report that has been issued. 070 */ 071 AMENDED, 072 /** 073 * Subsequent to being final, the report has been modified to correct an error in the report or referenced results. 074 */ 075 CORRECTED, 076 /** 077 * Subsequent to being final, the report has been modified by adding new content. The existing content is unchanged. 078 */ 079 APPENDED, 080 /** 081 * The report is unavailable because the measurement was not started or not completed (also sometimes called "aborted"). 082 */ 083 CANCELLED, 084 /** 085 * The report has been withdrawn following a previous final release. This electronic record should never have existed, though it is possible that real-world decisions were based on it. (If real-world activity has occurred, the status should be "cancelled" rather than "entered-in-error".) 086 */ 087 ENTEREDINERROR, 088 /** 089 * The authoring system does not know which of the status values currently applies to this report. Note: This concept is not to be used for "other" - one of the listed statuses is presumed to apply although which one is not known. 090 */ 091 UNKNOWN, 092 /** 093 * added to help the parsers with the generic types 094 */ 095 NULL; 096 public static DiagnosticReportStatus fromCode(String codeString) throws FHIRException { 097 if (codeString == null || "".equals(codeString)) 098 return null; 099 if ("registered".equals(codeString)) 100 return REGISTERED; 101 if ("partial".equals(codeString)) 102 return PARTIAL; 103 if ("preliminary".equals(codeString)) 104 return PRELIMINARY; 105 if ("final".equals(codeString)) 106 return FINAL; 107 if ("amended".equals(codeString)) 108 return AMENDED; 109 if ("corrected".equals(codeString)) 110 return CORRECTED; 111 if ("appended".equals(codeString)) 112 return APPENDED; 113 if ("cancelled".equals(codeString)) 114 return CANCELLED; 115 if ("entered-in-error".equals(codeString)) 116 return ENTEREDINERROR; 117 if ("unknown".equals(codeString)) 118 return UNKNOWN; 119 if (Configuration.isAcceptInvalidEnums()) 120 return null; 121 else 122 throw new FHIRException("Unknown DiagnosticReportStatus code '"+codeString+"'"); 123 } 124 public String toCode() { 125 switch (this) { 126 case REGISTERED: return "registered"; 127 case PARTIAL: return "partial"; 128 case PRELIMINARY: return "preliminary"; 129 case FINAL: return "final"; 130 case AMENDED: return "amended"; 131 case CORRECTED: return "corrected"; 132 case APPENDED: return "appended"; 133 case CANCELLED: return "cancelled"; 134 case ENTEREDINERROR: return "entered-in-error"; 135 case UNKNOWN: return "unknown"; 136 default: return "?"; 137 } 138 } 139 public String getSystem() { 140 switch (this) { 141 case REGISTERED: return "http://hl7.org/fhir/diagnostic-report-status"; 142 case PARTIAL: return "http://hl7.org/fhir/diagnostic-report-status"; 143 case PRELIMINARY: return "http://hl7.org/fhir/diagnostic-report-status"; 144 case FINAL: return "http://hl7.org/fhir/diagnostic-report-status"; 145 case AMENDED: return "http://hl7.org/fhir/diagnostic-report-status"; 146 case CORRECTED: return "http://hl7.org/fhir/diagnostic-report-status"; 147 case APPENDED: return "http://hl7.org/fhir/diagnostic-report-status"; 148 case CANCELLED: return "http://hl7.org/fhir/diagnostic-report-status"; 149 case ENTEREDINERROR: return "http://hl7.org/fhir/diagnostic-report-status"; 150 case UNKNOWN: return "http://hl7.org/fhir/diagnostic-report-status"; 151 default: return "?"; 152 } 153 } 154 public String getDefinition() { 155 switch (this) { 156 case REGISTERED: return "The existence of the report is registered, but there is nothing yet available."; 157 case PARTIAL: return "This is a partial (e.g. initial, interim or preliminary) report: data in the report may be incomplete or unverified."; 158 case PRELIMINARY: return "Verified early results are available, but not all results are final."; 159 case FINAL: return "The report is complete and verified by an authorized person."; 160 case AMENDED: return "Subsequent to being final, the report has been modified. This includes any change in the results, diagnosis, narrative text, or other content of a report that has been issued."; 161 case CORRECTED: return "Subsequent to being final, the report has been modified to correct an error in the report or referenced results."; 162 case APPENDED: return "Subsequent to being final, the report has been modified by adding new content. The existing content is unchanged."; 163 case CANCELLED: return "The report is unavailable because the measurement was not started or not completed (also sometimes called \"aborted\")."; 164 case ENTEREDINERROR: return "The report has been withdrawn following a previous final release. This electronic record should never have existed, though it is possible that real-world decisions were based on it. (If real-world activity has occurred, the status should be \"cancelled\" rather than \"entered-in-error\".)"; 165 case UNKNOWN: return "The authoring system does not know which of the status values currently applies to this report. Note: This concept is not to be used for \"other\" - one of the listed statuses is presumed to apply although which one is not known."; 166 default: return "?"; 167 } 168 } 169 public String getDisplay() { 170 switch (this) { 171 case REGISTERED: return "Registered"; 172 case PARTIAL: return "Partial"; 173 case PRELIMINARY: return "Preliminary"; 174 case FINAL: return "Final"; 175 case AMENDED: return "Amended"; 176 case CORRECTED: return "Corrected"; 177 case APPENDED: return "Appended"; 178 case CANCELLED: return "Cancelled"; 179 case ENTEREDINERROR: return "Entered in Error"; 180 case UNKNOWN: return "Unknown"; 181 default: return "?"; 182 } 183 } 184 } 185 186 public static class DiagnosticReportStatusEnumFactory implements EnumFactory<DiagnosticReportStatus> { 187 public DiagnosticReportStatus fromCode(String codeString) throws IllegalArgumentException { 188 if (codeString == null || "".equals(codeString)) 189 if (codeString == null || "".equals(codeString)) 190 return null; 191 if ("registered".equals(codeString)) 192 return DiagnosticReportStatus.REGISTERED; 193 if ("partial".equals(codeString)) 194 return DiagnosticReportStatus.PARTIAL; 195 if ("preliminary".equals(codeString)) 196 return DiagnosticReportStatus.PRELIMINARY; 197 if ("final".equals(codeString)) 198 return DiagnosticReportStatus.FINAL; 199 if ("amended".equals(codeString)) 200 return DiagnosticReportStatus.AMENDED; 201 if ("corrected".equals(codeString)) 202 return DiagnosticReportStatus.CORRECTED; 203 if ("appended".equals(codeString)) 204 return DiagnosticReportStatus.APPENDED; 205 if ("cancelled".equals(codeString)) 206 return DiagnosticReportStatus.CANCELLED; 207 if ("entered-in-error".equals(codeString)) 208 return DiagnosticReportStatus.ENTEREDINERROR; 209 if ("unknown".equals(codeString)) 210 return DiagnosticReportStatus.UNKNOWN; 211 throw new IllegalArgumentException("Unknown DiagnosticReportStatus code '"+codeString+"'"); 212 } 213 public Enumeration<DiagnosticReportStatus> fromType(Base code) throws FHIRException { 214 if (code == null) 215 return null; 216 if (code.isEmpty()) 217 return new Enumeration<DiagnosticReportStatus>(this); 218 String codeString = ((PrimitiveType) code).asStringValue(); 219 if (codeString == null || "".equals(codeString)) 220 return null; 221 if ("registered".equals(codeString)) 222 return new Enumeration<DiagnosticReportStatus>(this, DiagnosticReportStatus.REGISTERED); 223 if ("partial".equals(codeString)) 224 return new Enumeration<DiagnosticReportStatus>(this, DiagnosticReportStatus.PARTIAL); 225 if ("preliminary".equals(codeString)) 226 return new Enumeration<DiagnosticReportStatus>(this, DiagnosticReportStatus.PRELIMINARY); 227 if ("final".equals(codeString)) 228 return new Enumeration<DiagnosticReportStatus>(this, DiagnosticReportStatus.FINAL); 229 if ("amended".equals(codeString)) 230 return new Enumeration<DiagnosticReportStatus>(this, DiagnosticReportStatus.AMENDED); 231 if ("corrected".equals(codeString)) 232 return new Enumeration<DiagnosticReportStatus>(this, DiagnosticReportStatus.CORRECTED); 233 if ("appended".equals(codeString)) 234 return new Enumeration<DiagnosticReportStatus>(this, DiagnosticReportStatus.APPENDED); 235 if ("cancelled".equals(codeString)) 236 return new Enumeration<DiagnosticReportStatus>(this, DiagnosticReportStatus.CANCELLED); 237 if ("entered-in-error".equals(codeString)) 238 return new Enumeration<DiagnosticReportStatus>(this, DiagnosticReportStatus.ENTEREDINERROR); 239 if ("unknown".equals(codeString)) 240 return new Enumeration<DiagnosticReportStatus>(this, DiagnosticReportStatus.UNKNOWN); 241 throw new FHIRException("Unknown DiagnosticReportStatus code '"+codeString+"'"); 242 } 243 public String toCode(DiagnosticReportStatus code) { 244 if (code == DiagnosticReportStatus.REGISTERED) 245 return "registered"; 246 if (code == DiagnosticReportStatus.PARTIAL) 247 return "partial"; 248 if (code == DiagnosticReportStatus.PRELIMINARY) 249 return "preliminary"; 250 if (code == DiagnosticReportStatus.FINAL) 251 return "final"; 252 if (code == DiagnosticReportStatus.AMENDED) 253 return "amended"; 254 if (code == DiagnosticReportStatus.CORRECTED) 255 return "corrected"; 256 if (code == DiagnosticReportStatus.APPENDED) 257 return "appended"; 258 if (code == DiagnosticReportStatus.CANCELLED) 259 return "cancelled"; 260 if (code == DiagnosticReportStatus.ENTEREDINERROR) 261 return "entered-in-error"; 262 if (code == DiagnosticReportStatus.UNKNOWN) 263 return "unknown"; 264 return "?"; 265 } 266 public String toSystem(DiagnosticReportStatus code) { 267 return code.getSystem(); 268 } 269 } 270 271 @Block() 272 public static class DiagnosticReportMediaComponent extends BackboneElement implements IBaseBackboneElement { 273 /** 274 * A comment about the image. Typically, this is used to provide an explanation for why the image is included, or to draw the viewer's attention to important features. 275 */ 276 @Child(name = "comment", type = {StringType.class}, order=1, min=0, max=1, modifier=false, summary=false) 277 @Description(shortDefinition="Comment about the image (e.g. explanation)", formalDefinition="A comment about the image. Typically, this is used to provide an explanation for why the image is included, or to draw the viewer's attention to important features." ) 278 protected StringType comment; 279 280 /** 281 * Reference to the image source. 282 */ 283 @Child(name = "link", type = {Media.class}, order=2, min=1, max=1, modifier=false, summary=true) 284 @Description(shortDefinition="Reference to the image source", formalDefinition="Reference to the image source." ) 285 protected Reference link; 286 287 /** 288 * The actual object that is the target of the reference (Reference to the image source.) 289 */ 290 protected Media linkTarget; 291 292 private static final long serialVersionUID = 935791940L; 293 294 /** 295 * Constructor 296 */ 297 public DiagnosticReportMediaComponent() { 298 super(); 299 } 300 301 /** 302 * Constructor 303 */ 304 public DiagnosticReportMediaComponent(Reference link) { 305 super(); 306 this.link = link; 307 } 308 309 /** 310 * @return {@link #comment} (A comment about the image. Typically, this is used to provide an explanation for why the image is included, or to draw the viewer's attention to important features.). This is the underlying object with id, value and extensions. The accessor "getComment" gives direct access to the value 311 */ 312 public StringType getCommentElement() { 313 if (this.comment == null) 314 if (Configuration.errorOnAutoCreate()) 315 throw new Error("Attempt to auto-create DiagnosticReportMediaComponent.comment"); 316 else if (Configuration.doAutoCreate()) 317 this.comment = new StringType(); // bb 318 return this.comment; 319 } 320 321 public boolean hasCommentElement() { 322 return this.comment != null && !this.comment.isEmpty(); 323 } 324 325 public boolean hasComment() { 326 return this.comment != null && !this.comment.isEmpty(); 327 } 328 329 /** 330 * @param value {@link #comment} (A comment about the image. Typically, this is used to provide an explanation for why the image is included, or to draw the viewer's attention to important features.). This is the underlying object with id, value and extensions. The accessor "getComment" gives direct access to the value 331 */ 332 public DiagnosticReportMediaComponent setCommentElement(StringType value) { 333 this.comment = value; 334 return this; 335 } 336 337 /** 338 * @return A comment about the image. Typically, this is used to provide an explanation for why the image is included, or to draw the viewer's attention to important features. 339 */ 340 public String getComment() { 341 return this.comment == null ? null : this.comment.getValue(); 342 } 343 344 /** 345 * @param value A comment about the image. Typically, this is used to provide an explanation for why the image is included, or to draw the viewer's attention to important features. 346 */ 347 public DiagnosticReportMediaComponent setComment(String value) { 348 if (Utilities.noString(value)) 349 this.comment = null; 350 else { 351 if (this.comment == null) 352 this.comment = new StringType(); 353 this.comment.setValue(value); 354 } 355 return this; 356 } 357 358 /** 359 * @return {@link #link} (Reference to the image source.) 360 */ 361 public Reference getLink() { 362 if (this.link == null) 363 if (Configuration.errorOnAutoCreate()) 364 throw new Error("Attempt to auto-create DiagnosticReportMediaComponent.link"); 365 else if (Configuration.doAutoCreate()) 366 this.link = new Reference(); // cc 367 return this.link; 368 } 369 370 public boolean hasLink() { 371 return this.link != null && !this.link.isEmpty(); 372 } 373 374 /** 375 * @param value {@link #link} (Reference to the image source.) 376 */ 377 public DiagnosticReportMediaComponent setLink(Reference value) { 378 this.link = value; 379 return this; 380 } 381 382 /** 383 * @return {@link #link} 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. (Reference to the image source.) 384 */ 385 public Media getLinkTarget() { 386 if (this.linkTarget == null) 387 if (Configuration.errorOnAutoCreate()) 388 throw new Error("Attempt to auto-create DiagnosticReportMediaComponent.link"); 389 else if (Configuration.doAutoCreate()) 390 this.linkTarget = new Media(); // aa 391 return this.linkTarget; 392 } 393 394 /** 395 * @param value {@link #link} 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. (Reference to the image source.) 396 */ 397 public DiagnosticReportMediaComponent setLinkTarget(Media value) { 398 this.linkTarget = value; 399 return this; 400 } 401 402 protected void listChildren(List<Property> children) { 403 super.listChildren(children); 404 children.add(new Property("comment", "string", "A comment about the image. Typically, this is used to provide an explanation for why the image is included, or to draw the viewer's attention to important features.", 0, 1, comment)); 405 children.add(new Property("link", "Reference(Media)", "Reference to the image source.", 0, 1, link)); 406 } 407 408 @Override 409 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 410 switch (_hash) { 411 case 950398559: /*comment*/ return new Property("comment", "string", "A comment about the image. Typically, this is used to provide an explanation for why the image is included, or to draw the viewer's attention to important features.", 0, 1, comment); 412 case 3321850: /*link*/ return new Property("link", "Reference(Media)", "Reference to the image source.", 0, 1, link); 413 default: return super.getNamedProperty(_hash, _name, _checkValid); 414 } 415 416 } 417 418 @Override 419 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 420 switch (hash) { 421 case 950398559: /*comment*/ return this.comment == null ? new Base[0] : new Base[] {this.comment}; // StringType 422 case 3321850: /*link*/ return this.link == null ? new Base[0] : new Base[] {this.link}; // Reference 423 default: return super.getProperty(hash, name, checkValid); 424 } 425 426 } 427 428 @Override 429 public Base setProperty(int hash, String name, Base value) throws FHIRException { 430 switch (hash) { 431 case 950398559: // comment 432 this.comment = castToString(value); // StringType 433 return value; 434 case 3321850: // link 435 this.link = castToReference(value); // Reference 436 return value; 437 default: return super.setProperty(hash, name, value); 438 } 439 440 } 441 442 @Override 443 public Base setProperty(String name, Base value) throws FHIRException { 444 if (name.equals("comment")) { 445 this.comment = castToString(value); // StringType 446 } else if (name.equals("link")) { 447 this.link = castToReference(value); // Reference 448 } else 449 return super.setProperty(name, value); 450 return value; 451 } 452 453 @Override 454 public Base makeProperty(int hash, String name) throws FHIRException { 455 switch (hash) { 456 case 950398559: return getCommentElement(); 457 case 3321850: return getLink(); 458 default: return super.makeProperty(hash, name); 459 } 460 461 } 462 463 @Override 464 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 465 switch (hash) { 466 case 950398559: /*comment*/ return new String[] {"string"}; 467 case 3321850: /*link*/ return new String[] {"Reference"}; 468 default: return super.getTypesForProperty(hash, name); 469 } 470 471 } 472 473 @Override 474 public Base addChild(String name) throws FHIRException { 475 if (name.equals("comment")) { 476 throw new FHIRException("Cannot call addChild on a primitive type DiagnosticReport.comment"); 477 } 478 else if (name.equals("link")) { 479 this.link = new Reference(); 480 return this.link; 481 } 482 else 483 return super.addChild(name); 484 } 485 486 public DiagnosticReportMediaComponent copy() { 487 DiagnosticReportMediaComponent dst = new DiagnosticReportMediaComponent(); 488 copyValues(dst); 489 dst.comment = comment == null ? null : comment.copy(); 490 dst.link = link == null ? null : link.copy(); 491 return dst; 492 } 493 494 @Override 495 public boolean equalsDeep(Base other_) { 496 if (!super.equalsDeep(other_)) 497 return false; 498 if (!(other_ instanceof DiagnosticReportMediaComponent)) 499 return false; 500 DiagnosticReportMediaComponent o = (DiagnosticReportMediaComponent) other_; 501 return compareDeep(comment, o.comment, true) && compareDeep(link, o.link, true); 502 } 503 504 @Override 505 public boolean equalsShallow(Base other_) { 506 if (!super.equalsShallow(other_)) 507 return false; 508 if (!(other_ instanceof DiagnosticReportMediaComponent)) 509 return false; 510 DiagnosticReportMediaComponent o = (DiagnosticReportMediaComponent) other_; 511 return compareValues(comment, o.comment, true); 512 } 513 514 public boolean isEmpty() { 515 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(comment, link); 516 } 517 518 public String fhirType() { 519 return "DiagnosticReport.media"; 520 521 } 522 523 } 524 525 /** 526 * Identifiers assigned to this report by the performer or other systems. 527 */ 528 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 529 @Description(shortDefinition="Business identifier for report", formalDefinition="Identifiers assigned to this report by the performer or other systems." ) 530 protected List<Identifier> identifier; 531 532 /** 533 * Details concerning a service requested. 534 */ 535 @Child(name = "basedOn", type = {CarePlan.class, ImmunizationRecommendation.class, MedicationRequest.class, NutritionOrder.class, ServiceRequest.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 536 @Description(shortDefinition="What was requested", formalDefinition="Details concerning a service requested." ) 537 protected List<Reference> basedOn; 538 /** 539 * The actual objects that are the target of the reference (Details concerning a service requested.) 540 */ 541 protected List<Resource> basedOnTarget; 542 543 544 /** 545 * The status of the diagnostic report. 546 */ 547 @Child(name = "status", type = {CodeType.class}, order=2, min=1, max=1, modifier=true, summary=true) 548 @Description(shortDefinition="registered | partial | preliminary | final +", formalDefinition="The status of the diagnostic report." ) 549 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/diagnostic-report-status") 550 protected Enumeration<DiagnosticReportStatus> status; 551 552 /** 553 * A code that classifies the clinical discipline, department or diagnostic service that created the report (e.g. cardiology, biochemistry, hematology, MRI). This is used for searching, sorting and display purposes. 554 */ 555 @Child(name = "category", type = {CodeableConcept.class}, order=3, min=0, max=1, modifier=false, summary=true) 556 @Description(shortDefinition="Service category", formalDefinition="A code that classifies the clinical discipline, department or diagnostic service that created the report (e.g. cardiology, biochemistry, hematology, MRI). This is used for searching, sorting and display purposes." ) 557 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/diagnostic-service-sections") 558 protected CodeableConcept category; 559 560 /** 561 * A code or name that describes this diagnostic report. 562 */ 563 @Child(name = "code", type = {CodeableConcept.class}, order=4, min=1, max=1, modifier=false, summary=true) 564 @Description(shortDefinition="Name/Code for this diagnostic report", formalDefinition="A code or name that describes this diagnostic report." ) 565 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/report-codes") 566 protected CodeableConcept code; 567 568 /** 569 * The subject of the report. Usually, but not always, this is a patient. However diagnostic services also perform analyses on specimens collected from a variety of other sources. 570 */ 571 @Child(name = "subject", type = {Patient.class, Group.class, Device.class, Location.class}, order=5, min=0, max=1, modifier=false, summary=true) 572 @Description(shortDefinition="The subject of the report - usually, but not always, the patient", formalDefinition="The subject of the report. Usually, but not always, this is a patient. However diagnostic services also perform analyses on specimens collected from a variety of other sources." ) 573 protected Reference subject; 574 575 /** 576 * The actual object that is the target of the reference (The subject of the report. Usually, but not always, this is a patient. However diagnostic services also perform analyses on specimens collected from a variety of other sources.) 577 */ 578 protected Resource subjectTarget; 579 580 /** 581 * The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport per is about. 582 */ 583 @Child(name = "context", type = {Encounter.class, EpisodeOfCare.class}, order=6, min=0, max=1, modifier=false, summary=true) 584 @Description(shortDefinition="Health care event when test ordered", formalDefinition="The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport per is about." ) 585 protected Reference context; 586 587 /** 588 * The actual object that is the target of the reference (The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport per is about.) 589 */ 590 protected Resource contextTarget; 591 592 /** 593 * The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself. 594 */ 595 @Child(name = "effective", type = {DateTimeType.class, Period.class}, order=7, min=0, max=1, modifier=false, summary=true) 596 @Description(shortDefinition="Clinically relevant time/time-period for report", formalDefinition="The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself." ) 597 protected Type effective; 598 599 /** 600 * The date and time that this version of the report was made available to providers, typically after the report was reviewed and verified. 601 */ 602 @Child(name = "issued", type = {InstantType.class}, order=8, min=0, max=1, modifier=false, summary=true) 603 @Description(shortDefinition="DateTime this version was made", formalDefinition="The date and time that this version of the report was made available to providers, typically after the report was reviewed and verified." ) 604 protected InstantType issued; 605 606 /** 607 * The diagnostic service that is responsible for issuing the report. 608 */ 609 @Child(name = "performer", type = {Practitioner.class, PractitionerRole.class, Organization.class, CareTeam.class}, order=9, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 610 @Description(shortDefinition="Responsible Diagnostic Service", formalDefinition="The diagnostic service that is responsible for issuing the report." ) 611 protected List<Reference> performer; 612 /** 613 * The actual objects that are the target of the reference (The diagnostic service that is responsible for issuing the report.) 614 */ 615 protected List<Resource> performerTarget; 616 617 618 /** 619 * The practitioner or organization that is responsible for the report's conclusions and interpretations. 620 */ 621 @Child(name = "resultsInterpreter", type = {Practitioner.class, PractitionerRole.class, Organization.class, CareTeam.class}, order=10, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 622 @Description(shortDefinition="Primary result interpreter", formalDefinition="The practitioner or organization that is responsible for the report's conclusions and interpretations." ) 623 protected List<Reference> resultsInterpreter; 624 /** 625 * The actual objects that are the target of the reference (The practitioner or organization that is responsible for the report's conclusions and interpretations.) 626 */ 627 protected List<Resource> resultsInterpreterTarget; 628 629 630 /** 631 * Details about the specimens on which this diagnostic report is based. 632 */ 633 @Child(name = "specimen", type = {Specimen.class}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 634 @Description(shortDefinition="Specimens this report is based on", formalDefinition="Details about the specimens on which this diagnostic report is based." ) 635 protected List<Reference> specimen; 636 /** 637 * The actual objects that are the target of the reference (Details about the specimens on which this diagnostic report is based.) 638 */ 639 protected List<Specimen> specimenTarget; 640 641 642 /** 643 * Observations that are part of this diagnostic report. Observations can be simple name/value pairs (e.g. "atomic" results), or they can be grouping observations that include references to other members of the group (e.g. "panels"). 644 */ 645 @Child(name = "result", type = {Observation.class}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 646 @Description(shortDefinition="Observations - simple, or complex nested groups", formalDefinition="Observations that are part of this diagnostic report. Observations can be simple name/value pairs (e.g. \"atomic\" results), or they can be grouping observations that include references to other members of the group (e.g. \"panels\")." ) 647 protected List<Reference> result; 648 /** 649 * The actual objects that are the target of the reference (Observations that are part of this diagnostic report. Observations can be simple name/value pairs (e.g. "atomic" results), or they can be grouping observations that include references to other members of the group (e.g. "panels").) 650 */ 651 protected List<Observation> resultTarget; 652 653 654 /** 655 * One or more links to full details of any imaging performed during the diagnostic investigation. Typically, this is imaging performed by DICOM enabled modalities, but this is not required. A fully enabled PACS viewer can use this information to provide views of the source images. 656 */ 657 @Child(name = "imagingStudy", type = {ImagingStudy.class}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 658 @Description(shortDefinition="Reference to full details of imaging associated with the diagnostic report", formalDefinition="One or more links to full details of any imaging performed during the diagnostic investigation. Typically, this is imaging performed by DICOM enabled modalities, but this is not required. A fully enabled PACS viewer can use this information to provide views of the source images." ) 659 protected List<Reference> imagingStudy; 660 /** 661 * The actual objects that are the target of the reference (One or more links to full details of any imaging performed during the diagnostic investigation. Typically, this is imaging performed by DICOM enabled modalities, but this is not required. A fully enabled PACS viewer can use this information to provide views of the source images.) 662 */ 663 protected List<ImagingStudy> imagingStudyTarget; 664 665 666 /** 667 * A list of key images associated with this report. The images are generally created during the diagnostic process, and may be directly of the patient, or of treated specimens (i.e. slides of interest). 668 */ 669 @Child(name = "media", type = {}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 670 @Description(shortDefinition="Key images associated with this report", formalDefinition="A list of key images associated with this report. The images are generally created during the diagnostic process, and may be directly of the patient, or of treated specimens (i.e. slides of interest)." ) 671 protected List<DiagnosticReportMediaComponent> media; 672 673 /** 674 * Concise and clinically contextualized impression / summary of the diagnostic report. 675 */ 676 @Child(name = "conclusion", type = {StringType.class}, order=15, min=0, max=1, modifier=false, summary=false) 677 @Description(shortDefinition="Clinical Interpretation of test results", formalDefinition="Concise and clinically contextualized impression / summary of the diagnostic report." ) 678 protected StringType conclusion; 679 680 /** 681 * Codes for the conclusion. 682 */ 683 @Child(name = "codedDiagnosis", type = {CodeableConcept.class}, order=16, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 684 @Description(shortDefinition="Codes for the conclusion", formalDefinition="Codes for the conclusion." ) 685 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/clinical-findings") 686 protected List<CodeableConcept> codedDiagnosis; 687 688 /** 689 * Rich text representation of the entire result as issued by the diagnostic service. Multiple formats are allowed but they SHALL be semantically equivalent. 690 */ 691 @Child(name = "presentedForm", type = {Attachment.class}, order=17, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 692 @Description(shortDefinition="Entire report as issued", formalDefinition="Rich text representation of the entire result as issued by the diagnostic service. Multiple formats are allowed but they SHALL be semantically equivalent." ) 693 protected List<Attachment> presentedForm; 694 695 private static final long serialVersionUID = 808706953L; 696 697 /** 698 * Constructor 699 */ 700 public DiagnosticReport() { 701 super(); 702 } 703 704 /** 705 * Constructor 706 */ 707 public DiagnosticReport(Enumeration<DiagnosticReportStatus> status, CodeableConcept code) { 708 super(); 709 this.status = status; 710 this.code = code; 711 } 712 713 /** 714 * @return {@link #identifier} (Identifiers assigned to this report by the performer or other systems.) 715 */ 716 public List<Identifier> getIdentifier() { 717 if (this.identifier == null) 718 this.identifier = new ArrayList<Identifier>(); 719 return this.identifier; 720 } 721 722 /** 723 * @return Returns a reference to <code>this</code> for easy method chaining 724 */ 725 public DiagnosticReport setIdentifier(List<Identifier> theIdentifier) { 726 this.identifier = theIdentifier; 727 return this; 728 } 729 730 public boolean hasIdentifier() { 731 if (this.identifier == null) 732 return false; 733 for (Identifier item : this.identifier) 734 if (!item.isEmpty()) 735 return true; 736 return false; 737 } 738 739 public Identifier addIdentifier() { //3 740 Identifier t = new Identifier(); 741 if (this.identifier == null) 742 this.identifier = new ArrayList<Identifier>(); 743 this.identifier.add(t); 744 return t; 745 } 746 747 public DiagnosticReport addIdentifier(Identifier t) { //3 748 if (t == null) 749 return this; 750 if (this.identifier == null) 751 this.identifier = new ArrayList<Identifier>(); 752 this.identifier.add(t); 753 return this; 754 } 755 756 /** 757 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist 758 */ 759 public Identifier getIdentifierFirstRep() { 760 if (getIdentifier().isEmpty()) { 761 addIdentifier(); 762 } 763 return getIdentifier().get(0); 764 } 765 766 /** 767 * @return {@link #basedOn} (Details concerning a service requested.) 768 */ 769 public List<Reference> getBasedOn() { 770 if (this.basedOn == null) 771 this.basedOn = new ArrayList<Reference>(); 772 return this.basedOn; 773 } 774 775 /** 776 * @return Returns a reference to <code>this</code> for easy method chaining 777 */ 778 public DiagnosticReport setBasedOn(List<Reference> theBasedOn) { 779 this.basedOn = theBasedOn; 780 return this; 781 } 782 783 public boolean hasBasedOn() { 784 if (this.basedOn == null) 785 return false; 786 for (Reference item : this.basedOn) 787 if (!item.isEmpty()) 788 return true; 789 return false; 790 } 791 792 public Reference addBasedOn() { //3 793 Reference t = new Reference(); 794 if (this.basedOn == null) 795 this.basedOn = new ArrayList<Reference>(); 796 this.basedOn.add(t); 797 return t; 798 } 799 800 public DiagnosticReport addBasedOn(Reference t) { //3 801 if (t == null) 802 return this; 803 if (this.basedOn == null) 804 this.basedOn = new ArrayList<Reference>(); 805 this.basedOn.add(t); 806 return this; 807 } 808 809 /** 810 * @return The first repetition of repeating field {@link #basedOn}, creating it if it does not already exist 811 */ 812 public Reference getBasedOnFirstRep() { 813 if (getBasedOn().isEmpty()) { 814 addBasedOn(); 815 } 816 return getBasedOn().get(0); 817 } 818 819 /** 820 * @deprecated Use Reference#setResource(IBaseResource) instead 821 */ 822 @Deprecated 823 public List<Resource> getBasedOnTarget() { 824 if (this.basedOnTarget == null) 825 this.basedOnTarget = new ArrayList<Resource>(); 826 return this.basedOnTarget; 827 } 828 829 /** 830 * @return {@link #status} (The status of the diagnostic report.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 831 */ 832 public Enumeration<DiagnosticReportStatus> getStatusElement() { 833 if (this.status == null) 834 if (Configuration.errorOnAutoCreate()) 835 throw new Error("Attempt to auto-create DiagnosticReport.status"); 836 else if (Configuration.doAutoCreate()) 837 this.status = new Enumeration<DiagnosticReportStatus>(new DiagnosticReportStatusEnumFactory()); // bb 838 return this.status; 839 } 840 841 public boolean hasStatusElement() { 842 return this.status != null && !this.status.isEmpty(); 843 } 844 845 public boolean hasStatus() { 846 return this.status != null && !this.status.isEmpty(); 847 } 848 849 /** 850 * @param value {@link #status} (The status of the diagnostic report.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 851 */ 852 public DiagnosticReport setStatusElement(Enumeration<DiagnosticReportStatus> value) { 853 this.status = value; 854 return this; 855 } 856 857 /** 858 * @return The status of the diagnostic report. 859 */ 860 public DiagnosticReportStatus getStatus() { 861 return this.status == null ? null : this.status.getValue(); 862 } 863 864 /** 865 * @param value The status of the diagnostic report. 866 */ 867 public DiagnosticReport setStatus(DiagnosticReportStatus value) { 868 if (this.status == null) 869 this.status = new Enumeration<DiagnosticReportStatus>(new DiagnosticReportStatusEnumFactory()); 870 this.status.setValue(value); 871 return this; 872 } 873 874 /** 875 * @return {@link #category} (A code that classifies the clinical discipline, department or diagnostic service that created the report (e.g. cardiology, biochemistry, hematology, MRI). This is used for searching, sorting and display purposes.) 876 */ 877 public CodeableConcept getCategory() { 878 if (this.category == null) 879 if (Configuration.errorOnAutoCreate()) 880 throw new Error("Attempt to auto-create DiagnosticReport.category"); 881 else if (Configuration.doAutoCreate()) 882 this.category = new CodeableConcept(); // cc 883 return this.category; 884 } 885 886 public boolean hasCategory() { 887 return this.category != null && !this.category.isEmpty(); 888 } 889 890 /** 891 * @param value {@link #category} (A code that classifies the clinical discipline, department or diagnostic service that created the report (e.g. cardiology, biochemistry, hematology, MRI). This is used for searching, sorting and display purposes.) 892 */ 893 public DiagnosticReport setCategory(CodeableConcept value) { 894 this.category = value; 895 return this; 896 } 897 898 /** 899 * @return {@link #code} (A code or name that describes this diagnostic report.) 900 */ 901 public CodeableConcept getCode() { 902 if (this.code == null) 903 if (Configuration.errorOnAutoCreate()) 904 throw new Error("Attempt to auto-create DiagnosticReport.code"); 905 else if (Configuration.doAutoCreate()) 906 this.code = new CodeableConcept(); // cc 907 return this.code; 908 } 909 910 public boolean hasCode() { 911 return this.code != null && !this.code.isEmpty(); 912 } 913 914 /** 915 * @param value {@link #code} (A code or name that describes this diagnostic report.) 916 */ 917 public DiagnosticReport setCode(CodeableConcept value) { 918 this.code = value; 919 return this; 920 } 921 922 /** 923 * @return {@link #subject} (The subject of the report. Usually, but not always, this is a patient. However diagnostic services also perform analyses on specimens collected from a variety of other sources.) 924 */ 925 public Reference getSubject() { 926 if (this.subject == null) 927 if (Configuration.errorOnAutoCreate()) 928 throw new Error("Attempt to auto-create DiagnosticReport.subject"); 929 else if (Configuration.doAutoCreate()) 930 this.subject = new Reference(); // cc 931 return this.subject; 932 } 933 934 public boolean hasSubject() { 935 return this.subject != null && !this.subject.isEmpty(); 936 } 937 938 /** 939 * @param value {@link #subject} (The subject of the report. Usually, but not always, this is a patient. However diagnostic services also perform analyses on specimens collected from a variety of other sources.) 940 */ 941 public DiagnosticReport setSubject(Reference value) { 942 this.subject = value; 943 return this; 944 } 945 946 /** 947 * @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. (The subject of the report. Usually, but not always, this is a patient. However diagnostic services also perform analyses on specimens collected from a variety of other sources.) 948 */ 949 public Resource getSubjectTarget() { 950 return this.subjectTarget; 951 } 952 953 /** 954 * @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. (The subject of the report. Usually, but not always, this is a patient. However diagnostic services also perform analyses on specimens collected from a variety of other sources.) 955 */ 956 public DiagnosticReport setSubjectTarget(Resource value) { 957 this.subjectTarget = value; 958 return this; 959 } 960 961 /** 962 * @return {@link #context} (The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport per is about.) 963 */ 964 public Reference getContext() { 965 if (this.context == null) 966 if (Configuration.errorOnAutoCreate()) 967 throw new Error("Attempt to auto-create DiagnosticReport.context"); 968 else if (Configuration.doAutoCreate()) 969 this.context = new Reference(); // cc 970 return this.context; 971 } 972 973 public boolean hasContext() { 974 return this.context != null && !this.context.isEmpty(); 975 } 976 977 /** 978 * @param value {@link #context} (The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport per is about.) 979 */ 980 public DiagnosticReport setContext(Reference value) { 981 this.context = value; 982 return this; 983 } 984 985 /** 986 * @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. (The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport per is about.) 987 */ 988 public Resource getContextTarget() { 989 return this.contextTarget; 990 } 991 992 /** 993 * @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. (The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport per is about.) 994 */ 995 public DiagnosticReport setContextTarget(Resource value) { 996 this.contextTarget = value; 997 return this; 998 } 999 1000 /** 1001 * @return {@link #effective} (The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself.) 1002 */ 1003 public Type getEffective() { 1004 return this.effective; 1005 } 1006 1007 /** 1008 * @return {@link #effective} (The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself.) 1009 */ 1010 public DateTimeType getEffectiveDateTimeType() throws FHIRException { 1011 if (this.effective == null) 1012 return null; 1013 if (!(this.effective instanceof DateTimeType)) 1014 throw new FHIRException("Type mismatch: the type DateTimeType was expected, but "+this.effective.getClass().getName()+" was encountered"); 1015 return (DateTimeType) this.effective; 1016 } 1017 1018 public boolean hasEffectiveDateTimeType() { 1019 return this != null && this.effective instanceof DateTimeType; 1020 } 1021 1022 /** 1023 * @return {@link #effective} (The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself.) 1024 */ 1025 public Period getEffectivePeriod() throws FHIRException { 1026 if (this.effective == null) 1027 return null; 1028 if (!(this.effective instanceof Period)) 1029 throw new FHIRException("Type mismatch: the type Period was expected, but "+this.effective.getClass().getName()+" was encountered"); 1030 return (Period) this.effective; 1031 } 1032 1033 public boolean hasEffectivePeriod() { 1034 return this != null && this.effective instanceof Period; 1035 } 1036 1037 public boolean hasEffective() { 1038 return this.effective != null && !this.effective.isEmpty(); 1039 } 1040 1041 /** 1042 * @param value {@link #effective} (The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself.) 1043 */ 1044 public DiagnosticReport setEffective(Type value) { 1045 if (value != null && !(value instanceof DateTimeType || value instanceof Period)) 1046 throw new Error("Not the right type for DiagnosticReport.effective[x]: "+value.fhirType()); 1047 this.effective = value; 1048 return this; 1049 } 1050 1051 /** 1052 * @return {@link #issued} (The date and time that this version of the report was made available to providers, typically after the report was reviewed and verified.). This is the underlying object with id, value and extensions. The accessor "getIssued" gives direct access to the value 1053 */ 1054 public InstantType getIssuedElement() { 1055 if (this.issued == null) 1056 if (Configuration.errorOnAutoCreate()) 1057 throw new Error("Attempt to auto-create DiagnosticReport.issued"); 1058 else if (Configuration.doAutoCreate()) 1059 this.issued = new InstantType(); // bb 1060 return this.issued; 1061 } 1062 1063 public boolean hasIssuedElement() { 1064 return this.issued != null && !this.issued.isEmpty(); 1065 } 1066 1067 public boolean hasIssued() { 1068 return this.issued != null && !this.issued.isEmpty(); 1069 } 1070 1071 /** 1072 * @param value {@link #issued} (The date and time that this version of the report was made available to providers, typically after the report was reviewed and verified.). This is the underlying object with id, value and extensions. The accessor "getIssued" gives direct access to the value 1073 */ 1074 public DiagnosticReport setIssuedElement(InstantType value) { 1075 this.issued = value; 1076 return this; 1077 } 1078 1079 /** 1080 * @return The date and time that this version of the report was made available to providers, typically after the report was reviewed and verified. 1081 */ 1082 public Date getIssued() { 1083 return this.issued == null ? null : this.issued.getValue(); 1084 } 1085 1086 /** 1087 * @param value The date and time that this version of the report was made available to providers, typically after the report was reviewed and verified. 1088 */ 1089 public DiagnosticReport setIssued(Date value) { 1090 if (value == null) 1091 this.issued = null; 1092 else { 1093 if (this.issued == null) 1094 this.issued = new InstantType(); 1095 this.issued.setValue(value); 1096 } 1097 return this; 1098 } 1099 1100 /** 1101 * @return {@link #performer} (The diagnostic service that is responsible for issuing the report.) 1102 */ 1103 public List<Reference> getPerformer() { 1104 if (this.performer == null) 1105 this.performer = new ArrayList<Reference>(); 1106 return this.performer; 1107 } 1108 1109 /** 1110 * @return Returns a reference to <code>this</code> for easy method chaining 1111 */ 1112 public DiagnosticReport setPerformer(List<Reference> thePerformer) { 1113 this.performer = thePerformer; 1114 return this; 1115 } 1116 1117 public boolean hasPerformer() { 1118 if (this.performer == null) 1119 return false; 1120 for (Reference item : this.performer) 1121 if (!item.isEmpty()) 1122 return true; 1123 return false; 1124 } 1125 1126 public Reference addPerformer() { //3 1127 Reference t = new Reference(); 1128 if (this.performer == null) 1129 this.performer = new ArrayList<Reference>(); 1130 this.performer.add(t); 1131 return t; 1132 } 1133 1134 public DiagnosticReport addPerformer(Reference t) { //3 1135 if (t == null) 1136 return this; 1137 if (this.performer == null) 1138 this.performer = new ArrayList<Reference>(); 1139 this.performer.add(t); 1140 return this; 1141 } 1142 1143 /** 1144 * @return The first repetition of repeating field {@link #performer}, creating it if it does not already exist 1145 */ 1146 public Reference getPerformerFirstRep() { 1147 if (getPerformer().isEmpty()) { 1148 addPerformer(); 1149 } 1150 return getPerformer().get(0); 1151 } 1152 1153 /** 1154 * @deprecated Use Reference#setResource(IBaseResource) instead 1155 */ 1156 @Deprecated 1157 public List<Resource> getPerformerTarget() { 1158 if (this.performerTarget == null) 1159 this.performerTarget = new ArrayList<Resource>(); 1160 return this.performerTarget; 1161 } 1162 1163 /** 1164 * @return {@link #resultsInterpreter} (The practitioner or organization that is responsible for the report's conclusions and interpretations.) 1165 */ 1166 public List<Reference> getResultsInterpreter() { 1167 if (this.resultsInterpreter == null) 1168 this.resultsInterpreter = new ArrayList<Reference>(); 1169 return this.resultsInterpreter; 1170 } 1171 1172 /** 1173 * @return Returns a reference to <code>this</code> for easy method chaining 1174 */ 1175 public DiagnosticReport setResultsInterpreter(List<Reference> theResultsInterpreter) { 1176 this.resultsInterpreter = theResultsInterpreter; 1177 return this; 1178 } 1179 1180 public boolean hasResultsInterpreter() { 1181 if (this.resultsInterpreter == null) 1182 return false; 1183 for (Reference item : this.resultsInterpreter) 1184 if (!item.isEmpty()) 1185 return true; 1186 return false; 1187 } 1188 1189 public Reference addResultsInterpreter() { //3 1190 Reference t = new Reference(); 1191 if (this.resultsInterpreter == null) 1192 this.resultsInterpreter = new ArrayList<Reference>(); 1193 this.resultsInterpreter.add(t); 1194 return t; 1195 } 1196 1197 public DiagnosticReport addResultsInterpreter(Reference t) { //3 1198 if (t == null) 1199 return this; 1200 if (this.resultsInterpreter == null) 1201 this.resultsInterpreter = new ArrayList<Reference>(); 1202 this.resultsInterpreter.add(t); 1203 return this; 1204 } 1205 1206 /** 1207 * @return The first repetition of repeating field {@link #resultsInterpreter}, creating it if it does not already exist 1208 */ 1209 public Reference getResultsInterpreterFirstRep() { 1210 if (getResultsInterpreter().isEmpty()) { 1211 addResultsInterpreter(); 1212 } 1213 return getResultsInterpreter().get(0); 1214 } 1215 1216 /** 1217 * @deprecated Use Reference#setResource(IBaseResource) instead 1218 */ 1219 @Deprecated 1220 public List<Resource> getResultsInterpreterTarget() { 1221 if (this.resultsInterpreterTarget == null) 1222 this.resultsInterpreterTarget = new ArrayList<Resource>(); 1223 return this.resultsInterpreterTarget; 1224 } 1225 1226 /** 1227 * @return {@link #specimen} (Details about the specimens on which this diagnostic report is based.) 1228 */ 1229 public List<Reference> getSpecimen() { 1230 if (this.specimen == null) 1231 this.specimen = new ArrayList<Reference>(); 1232 return this.specimen; 1233 } 1234 1235 /** 1236 * @return Returns a reference to <code>this</code> for easy method chaining 1237 */ 1238 public DiagnosticReport setSpecimen(List<Reference> theSpecimen) { 1239 this.specimen = theSpecimen; 1240 return this; 1241 } 1242 1243 public boolean hasSpecimen() { 1244 if (this.specimen == null) 1245 return false; 1246 for (Reference item : this.specimen) 1247 if (!item.isEmpty()) 1248 return true; 1249 return false; 1250 } 1251 1252 public Reference addSpecimen() { //3 1253 Reference t = new Reference(); 1254 if (this.specimen == null) 1255 this.specimen = new ArrayList<Reference>(); 1256 this.specimen.add(t); 1257 return t; 1258 } 1259 1260 public DiagnosticReport addSpecimen(Reference t) { //3 1261 if (t == null) 1262 return this; 1263 if (this.specimen == null) 1264 this.specimen = new ArrayList<Reference>(); 1265 this.specimen.add(t); 1266 return this; 1267 } 1268 1269 /** 1270 * @return The first repetition of repeating field {@link #specimen}, creating it if it does not already exist 1271 */ 1272 public Reference getSpecimenFirstRep() { 1273 if (getSpecimen().isEmpty()) { 1274 addSpecimen(); 1275 } 1276 return getSpecimen().get(0); 1277 } 1278 1279 /** 1280 * @deprecated Use Reference#setResource(IBaseResource) instead 1281 */ 1282 @Deprecated 1283 public List<Specimen> getSpecimenTarget() { 1284 if (this.specimenTarget == null) 1285 this.specimenTarget = new ArrayList<Specimen>(); 1286 return this.specimenTarget; 1287 } 1288 1289 /** 1290 * @deprecated Use Reference#setResource(IBaseResource) instead 1291 */ 1292 @Deprecated 1293 public Specimen addSpecimenTarget() { 1294 Specimen r = new Specimen(); 1295 if (this.specimenTarget == null) 1296 this.specimenTarget = new ArrayList<Specimen>(); 1297 this.specimenTarget.add(r); 1298 return r; 1299 } 1300 1301 /** 1302 * @return {@link #result} (Observations that are part of this diagnostic report. Observations can be simple name/value pairs (e.g. "atomic" results), or they can be grouping observations that include references to other members of the group (e.g. "panels").) 1303 */ 1304 public List<Reference> getResult() { 1305 if (this.result == null) 1306 this.result = new ArrayList<Reference>(); 1307 return this.result; 1308 } 1309 1310 /** 1311 * @return Returns a reference to <code>this</code> for easy method chaining 1312 */ 1313 public DiagnosticReport setResult(List<Reference> theResult) { 1314 this.result = theResult; 1315 return this; 1316 } 1317 1318 public boolean hasResult() { 1319 if (this.result == null) 1320 return false; 1321 for (Reference item : this.result) 1322 if (!item.isEmpty()) 1323 return true; 1324 return false; 1325 } 1326 1327 public Reference addResult() { //3 1328 Reference t = new Reference(); 1329 if (this.result == null) 1330 this.result = new ArrayList<Reference>(); 1331 this.result.add(t); 1332 return t; 1333 } 1334 1335 public DiagnosticReport addResult(Reference t) { //3 1336 if (t == null) 1337 return this; 1338 if (this.result == null) 1339 this.result = new ArrayList<Reference>(); 1340 this.result.add(t); 1341 return this; 1342 } 1343 1344 /** 1345 * @return The first repetition of repeating field {@link #result}, creating it if it does not already exist 1346 */ 1347 public Reference getResultFirstRep() { 1348 if (getResult().isEmpty()) { 1349 addResult(); 1350 } 1351 return getResult().get(0); 1352 } 1353 1354 /** 1355 * @deprecated Use Reference#setResource(IBaseResource) instead 1356 */ 1357 @Deprecated 1358 public List<Observation> getResultTarget() { 1359 if (this.resultTarget == null) 1360 this.resultTarget = new ArrayList<Observation>(); 1361 return this.resultTarget; 1362 } 1363 1364 /** 1365 * @deprecated Use Reference#setResource(IBaseResource) instead 1366 */ 1367 @Deprecated 1368 public Observation addResultTarget() { 1369 Observation r = new Observation(); 1370 if (this.resultTarget == null) 1371 this.resultTarget = new ArrayList<Observation>(); 1372 this.resultTarget.add(r); 1373 return r; 1374 } 1375 1376 /** 1377 * @return {@link #imagingStudy} (One or more links to full details of any imaging performed during the diagnostic investigation. Typically, this is imaging performed by DICOM enabled modalities, but this is not required. A fully enabled PACS viewer can use this information to provide views of the source images.) 1378 */ 1379 public List<Reference> getImagingStudy() { 1380 if (this.imagingStudy == null) 1381 this.imagingStudy = new ArrayList<Reference>(); 1382 return this.imagingStudy; 1383 } 1384 1385 /** 1386 * @return Returns a reference to <code>this</code> for easy method chaining 1387 */ 1388 public DiagnosticReport setImagingStudy(List<Reference> theImagingStudy) { 1389 this.imagingStudy = theImagingStudy; 1390 return this; 1391 } 1392 1393 public boolean hasImagingStudy() { 1394 if (this.imagingStudy == null) 1395 return false; 1396 for (Reference item : this.imagingStudy) 1397 if (!item.isEmpty()) 1398 return true; 1399 return false; 1400 } 1401 1402 public Reference addImagingStudy() { //3 1403 Reference t = new Reference(); 1404 if (this.imagingStudy == null) 1405 this.imagingStudy = new ArrayList<Reference>(); 1406 this.imagingStudy.add(t); 1407 return t; 1408 } 1409 1410 public DiagnosticReport addImagingStudy(Reference t) { //3 1411 if (t == null) 1412 return this; 1413 if (this.imagingStudy == null) 1414 this.imagingStudy = new ArrayList<Reference>(); 1415 this.imagingStudy.add(t); 1416 return this; 1417 } 1418 1419 /** 1420 * @return The first repetition of repeating field {@link #imagingStudy}, creating it if it does not already exist 1421 */ 1422 public Reference getImagingStudyFirstRep() { 1423 if (getImagingStudy().isEmpty()) { 1424 addImagingStudy(); 1425 } 1426 return getImagingStudy().get(0); 1427 } 1428 1429 /** 1430 * @deprecated Use Reference#setResource(IBaseResource) instead 1431 */ 1432 @Deprecated 1433 public List<ImagingStudy> getImagingStudyTarget() { 1434 if (this.imagingStudyTarget == null) 1435 this.imagingStudyTarget = new ArrayList<ImagingStudy>(); 1436 return this.imagingStudyTarget; 1437 } 1438 1439 /** 1440 * @deprecated Use Reference#setResource(IBaseResource) instead 1441 */ 1442 @Deprecated 1443 public ImagingStudy addImagingStudyTarget() { 1444 ImagingStudy r = new ImagingStudy(); 1445 if (this.imagingStudyTarget == null) 1446 this.imagingStudyTarget = new ArrayList<ImagingStudy>(); 1447 this.imagingStudyTarget.add(r); 1448 return r; 1449 } 1450 1451 /** 1452 * @return {@link #media} (A list of key images associated with this report. The images are generally created during the diagnostic process, and may be directly of the patient, or of treated specimens (i.e. slides of interest).) 1453 */ 1454 public List<DiagnosticReportMediaComponent> getMedia() { 1455 if (this.media == null) 1456 this.media = new ArrayList<DiagnosticReportMediaComponent>(); 1457 return this.media; 1458 } 1459 1460 /** 1461 * @return Returns a reference to <code>this</code> for easy method chaining 1462 */ 1463 public DiagnosticReport setMedia(List<DiagnosticReportMediaComponent> theMedia) { 1464 this.media = theMedia; 1465 return this; 1466 } 1467 1468 public boolean hasMedia() { 1469 if (this.media == null) 1470 return false; 1471 for (DiagnosticReportMediaComponent item : this.media) 1472 if (!item.isEmpty()) 1473 return true; 1474 return false; 1475 } 1476 1477 public DiagnosticReportMediaComponent addMedia() { //3 1478 DiagnosticReportMediaComponent t = new DiagnosticReportMediaComponent(); 1479 if (this.media == null) 1480 this.media = new ArrayList<DiagnosticReportMediaComponent>(); 1481 this.media.add(t); 1482 return t; 1483 } 1484 1485 public DiagnosticReport addMedia(DiagnosticReportMediaComponent t) { //3 1486 if (t == null) 1487 return this; 1488 if (this.media == null) 1489 this.media = new ArrayList<DiagnosticReportMediaComponent>(); 1490 this.media.add(t); 1491 return this; 1492 } 1493 1494 /** 1495 * @return The first repetition of repeating field {@link #media}, creating it if it does not already exist 1496 */ 1497 public DiagnosticReportMediaComponent getMediaFirstRep() { 1498 if (getMedia().isEmpty()) { 1499 addMedia(); 1500 } 1501 return getMedia().get(0); 1502 } 1503 1504 /** 1505 * @return {@link #conclusion} (Concise and clinically contextualized impression / summary of the diagnostic report.). This is the underlying object with id, value and extensions. The accessor "getConclusion" gives direct access to the value 1506 */ 1507 public StringType getConclusionElement() { 1508 if (this.conclusion == null) 1509 if (Configuration.errorOnAutoCreate()) 1510 throw new Error("Attempt to auto-create DiagnosticReport.conclusion"); 1511 else if (Configuration.doAutoCreate()) 1512 this.conclusion = new StringType(); // bb 1513 return this.conclusion; 1514 } 1515 1516 public boolean hasConclusionElement() { 1517 return this.conclusion != null && !this.conclusion.isEmpty(); 1518 } 1519 1520 public boolean hasConclusion() { 1521 return this.conclusion != null && !this.conclusion.isEmpty(); 1522 } 1523 1524 /** 1525 * @param value {@link #conclusion} (Concise and clinically contextualized impression / summary of the diagnostic report.). This is the underlying object with id, value and extensions. The accessor "getConclusion" gives direct access to the value 1526 */ 1527 public DiagnosticReport setConclusionElement(StringType value) { 1528 this.conclusion = value; 1529 return this; 1530 } 1531 1532 /** 1533 * @return Concise and clinically contextualized impression / summary of the diagnostic report. 1534 */ 1535 public String getConclusion() { 1536 return this.conclusion == null ? null : this.conclusion.getValue(); 1537 } 1538 1539 /** 1540 * @param value Concise and clinically contextualized impression / summary of the diagnostic report. 1541 */ 1542 public DiagnosticReport setConclusion(String value) { 1543 if (Utilities.noString(value)) 1544 this.conclusion = null; 1545 else { 1546 if (this.conclusion == null) 1547 this.conclusion = new StringType(); 1548 this.conclusion.setValue(value); 1549 } 1550 return this; 1551 } 1552 1553 /** 1554 * @return {@link #codedDiagnosis} (Codes for the conclusion.) 1555 */ 1556 public List<CodeableConcept> getCodedDiagnosis() { 1557 if (this.codedDiagnosis == null) 1558 this.codedDiagnosis = new ArrayList<CodeableConcept>(); 1559 return this.codedDiagnosis; 1560 } 1561 1562 /** 1563 * @return Returns a reference to <code>this</code> for easy method chaining 1564 */ 1565 public DiagnosticReport setCodedDiagnosis(List<CodeableConcept> theCodedDiagnosis) { 1566 this.codedDiagnosis = theCodedDiagnosis; 1567 return this; 1568 } 1569 1570 public boolean hasCodedDiagnosis() { 1571 if (this.codedDiagnosis == null) 1572 return false; 1573 for (CodeableConcept item : this.codedDiagnosis) 1574 if (!item.isEmpty()) 1575 return true; 1576 return false; 1577 } 1578 1579 public CodeableConcept addCodedDiagnosis() { //3 1580 CodeableConcept t = new CodeableConcept(); 1581 if (this.codedDiagnosis == null) 1582 this.codedDiagnosis = new ArrayList<CodeableConcept>(); 1583 this.codedDiagnosis.add(t); 1584 return t; 1585 } 1586 1587 public DiagnosticReport addCodedDiagnosis(CodeableConcept t) { //3 1588 if (t == null) 1589 return this; 1590 if (this.codedDiagnosis == null) 1591 this.codedDiagnosis = new ArrayList<CodeableConcept>(); 1592 this.codedDiagnosis.add(t); 1593 return this; 1594 } 1595 1596 /** 1597 * @return The first repetition of repeating field {@link #codedDiagnosis}, creating it if it does not already exist 1598 */ 1599 public CodeableConcept getCodedDiagnosisFirstRep() { 1600 if (getCodedDiagnosis().isEmpty()) { 1601 addCodedDiagnosis(); 1602 } 1603 return getCodedDiagnosis().get(0); 1604 } 1605 1606 /** 1607 * @return {@link #presentedForm} (Rich text representation of the entire result as issued by the diagnostic service. Multiple formats are allowed but they SHALL be semantically equivalent.) 1608 */ 1609 public List<Attachment> getPresentedForm() { 1610 if (this.presentedForm == null) 1611 this.presentedForm = new ArrayList<Attachment>(); 1612 return this.presentedForm; 1613 } 1614 1615 /** 1616 * @return Returns a reference to <code>this</code> for easy method chaining 1617 */ 1618 public DiagnosticReport setPresentedForm(List<Attachment> thePresentedForm) { 1619 this.presentedForm = thePresentedForm; 1620 return this; 1621 } 1622 1623 public boolean hasPresentedForm() { 1624 if (this.presentedForm == null) 1625 return false; 1626 for (Attachment item : this.presentedForm) 1627 if (!item.isEmpty()) 1628 return true; 1629 return false; 1630 } 1631 1632 public Attachment addPresentedForm() { //3 1633 Attachment t = new Attachment(); 1634 if (this.presentedForm == null) 1635 this.presentedForm = new ArrayList<Attachment>(); 1636 this.presentedForm.add(t); 1637 return t; 1638 } 1639 1640 public DiagnosticReport addPresentedForm(Attachment t) { //3 1641 if (t == null) 1642 return this; 1643 if (this.presentedForm == null) 1644 this.presentedForm = new ArrayList<Attachment>(); 1645 this.presentedForm.add(t); 1646 return this; 1647 } 1648 1649 /** 1650 * @return The first repetition of repeating field {@link #presentedForm}, creating it if it does not already exist 1651 */ 1652 public Attachment getPresentedFormFirstRep() { 1653 if (getPresentedForm().isEmpty()) { 1654 addPresentedForm(); 1655 } 1656 return getPresentedForm().get(0); 1657 } 1658 1659 protected void listChildren(List<Property> children) { 1660 super.listChildren(children); 1661 children.add(new Property("identifier", "Identifier", "Identifiers assigned to this report by the performer or other systems.", 0, java.lang.Integer.MAX_VALUE, identifier)); 1662 children.add(new Property("basedOn", "Reference(CarePlan|ImmunizationRecommendation|MedicationRequest|NutritionOrder|ServiceRequest)", "Details concerning a service requested.", 0, java.lang.Integer.MAX_VALUE, basedOn)); 1663 children.add(new Property("status", "code", "The status of the diagnostic report.", 0, 1, status)); 1664 children.add(new Property("category", "CodeableConcept", "A code that classifies the clinical discipline, department or diagnostic service that created the report (e.g. cardiology, biochemistry, hematology, MRI). This is used for searching, sorting and display purposes.", 0, 1, category)); 1665 children.add(new Property("code", "CodeableConcept", "A code or name that describes this diagnostic report.", 0, 1, code)); 1666 children.add(new Property("subject", "Reference(Patient|Group|Device|Location)", "The subject of the report. Usually, but not always, this is a patient. However diagnostic services also perform analyses on specimens collected from a variety of other sources.", 0, 1, subject)); 1667 children.add(new Property("context", "Reference(Encounter|EpisodeOfCare)", "The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport per is about.", 0, 1, context)); 1668 children.add(new Property("effective[x]", "dateTime|Period", "The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective)); 1669 children.add(new Property("issued", "instant", "The date and time that this version of the report was made available to providers, typically after the report was reviewed and verified.", 0, 1, issued)); 1670 children.add(new Property("performer", "Reference(Practitioner|PractitionerRole|Organization|CareTeam)", "The diagnostic service that is responsible for issuing the report.", 0, java.lang.Integer.MAX_VALUE, performer)); 1671 children.add(new Property("resultsInterpreter", "Reference(Practitioner|PractitionerRole|Organization|CareTeam)", "The practitioner or organization that is responsible for the report's conclusions and interpretations.", 0, java.lang.Integer.MAX_VALUE, resultsInterpreter)); 1672 children.add(new Property("specimen", "Reference(Specimen)", "Details about the specimens on which this diagnostic report is based.", 0, java.lang.Integer.MAX_VALUE, specimen)); 1673 children.add(new Property("result", "Reference(Observation)", "Observations that are part of this diagnostic report. Observations can be simple name/value pairs (e.g. \"atomic\" results), or they can be grouping observations that include references to other members of the group (e.g. \"panels\").", 0, java.lang.Integer.MAX_VALUE, result)); 1674 children.add(new Property("imagingStudy", "Reference(ImagingStudy)", "One or more links to full details of any imaging performed during the diagnostic investigation. Typically, this is imaging performed by DICOM enabled modalities, but this is not required. A fully enabled PACS viewer can use this information to provide views of the source images.", 0, java.lang.Integer.MAX_VALUE, imagingStudy)); 1675 children.add(new Property("media", "", "A list of key images associated with this report. The images are generally created during the diagnostic process, and may be directly of the patient, or of treated specimens (i.e. slides of interest).", 0, java.lang.Integer.MAX_VALUE, media)); 1676 children.add(new Property("conclusion", "string", "Concise and clinically contextualized impression / summary of the diagnostic report.", 0, 1, conclusion)); 1677 children.add(new Property("codedDiagnosis", "CodeableConcept", "Codes for the conclusion.", 0, java.lang.Integer.MAX_VALUE, codedDiagnosis)); 1678 children.add(new Property("presentedForm", "Attachment", "Rich text representation of the entire result as issued by the diagnostic service. Multiple formats are allowed but they SHALL be semantically equivalent.", 0, java.lang.Integer.MAX_VALUE, presentedForm)); 1679 } 1680 1681 @Override 1682 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1683 switch (_hash) { 1684 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "Identifiers assigned to this report by the performer or other systems.", 0, java.lang.Integer.MAX_VALUE, identifier); 1685 case -332612366: /*basedOn*/ return new Property("basedOn", "Reference(CarePlan|ImmunizationRecommendation|MedicationRequest|NutritionOrder|ServiceRequest)", "Details concerning a service requested.", 0, java.lang.Integer.MAX_VALUE, basedOn); 1686 case -892481550: /*status*/ return new Property("status", "code", "The status of the diagnostic report.", 0, 1, status); 1687 case 50511102: /*category*/ return new Property("category", "CodeableConcept", "A code that classifies the clinical discipline, department or diagnostic service that created the report (e.g. cardiology, biochemistry, hematology, MRI). This is used for searching, sorting and display purposes.", 0, 1, category); 1688 case 3059181: /*code*/ return new Property("code", "CodeableConcept", "A code or name that describes this diagnostic report.", 0, 1, code); 1689 case -1867885268: /*subject*/ return new Property("subject", "Reference(Patient|Group|Device|Location)", "The subject of the report. Usually, but not always, this is a patient. However diagnostic services also perform analyses on specimens collected from a variety of other sources.", 0, 1, subject); 1690 case 951530927: /*context*/ return new Property("context", "Reference(Encounter|EpisodeOfCare)", "The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport per is about.", 0, 1, context); 1691 case 247104889: /*effective[x]*/ return new Property("effective[x]", "dateTime|Period", "The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective); 1692 case -1468651097: /*effective*/ return new Property("effective[x]", "dateTime|Period", "The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective); 1693 case -275306910: /*effectiveDateTime*/ return new Property("effective[x]", "dateTime|Period", "The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective); 1694 case -403934648: /*effectivePeriod*/ return new Property("effective[x]", "dateTime|Period", "The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself.", 0, 1, effective); 1695 case -1179159893: /*issued*/ return new Property("issued", "instant", "The date and time that this version of the report was made available to providers, typically after the report was reviewed and verified.", 0, 1, issued); 1696 case 481140686: /*performer*/ return new Property("performer", "Reference(Practitioner|PractitionerRole|Organization|CareTeam)", "The diagnostic service that is responsible for issuing the report.", 0, java.lang.Integer.MAX_VALUE, performer); 1697 case 2134944932: /*resultsInterpreter*/ return new Property("resultsInterpreter", "Reference(Practitioner|PractitionerRole|Organization|CareTeam)", "The practitioner or organization that is responsible for the report's conclusions and interpretations.", 0, java.lang.Integer.MAX_VALUE, resultsInterpreter); 1698 case -2132868344: /*specimen*/ return new Property("specimen", "Reference(Specimen)", "Details about the specimens on which this diagnostic report is based.", 0, java.lang.Integer.MAX_VALUE, specimen); 1699 case -934426595: /*result*/ return new Property("result", "Reference(Observation)", "Observations that are part of this diagnostic report. Observations can be simple name/value pairs (e.g. \"atomic\" results), or they can be grouping observations that include references to other members of the group (e.g. \"panels\").", 0, java.lang.Integer.MAX_VALUE, result); 1700 case -814900911: /*imagingStudy*/ return new Property("imagingStudy", "Reference(ImagingStudy)", "One or more links to full details of any imaging performed during the diagnostic investigation. Typically, this is imaging performed by DICOM enabled modalities, but this is not required. A fully enabled PACS viewer can use this information to provide views of the source images.", 0, java.lang.Integer.MAX_VALUE, imagingStudy); 1701 case 103772132: /*media*/ return new Property("media", "", "A list of key images associated with this report. The images are generally created during the diagnostic process, and may be directly of the patient, or of treated specimens (i.e. slides of interest).", 0, java.lang.Integer.MAX_VALUE, media); 1702 case -1731259873: /*conclusion*/ return new Property("conclusion", "string", "Concise and clinically contextualized impression / summary of the diagnostic report.", 0, 1, conclusion); 1703 case -1364269926: /*codedDiagnosis*/ return new Property("codedDiagnosis", "CodeableConcept", "Codes for the conclusion.", 0, java.lang.Integer.MAX_VALUE, codedDiagnosis); 1704 case 230090366: /*presentedForm*/ return new Property("presentedForm", "Attachment", "Rich text representation of the entire result as issued by the diagnostic service. Multiple formats are allowed but they SHALL be semantically equivalent.", 0, java.lang.Integer.MAX_VALUE, presentedForm); 1705 default: return super.getNamedProperty(_hash, _name, _checkValid); 1706 } 1707 1708 } 1709 1710 @Override 1711 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1712 switch (hash) { 1713 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 1714 case -332612366: /*basedOn*/ return this.basedOn == null ? new Base[0] : this.basedOn.toArray(new Base[this.basedOn.size()]); // Reference 1715 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<DiagnosticReportStatus> 1716 case 50511102: /*category*/ return this.category == null ? new Base[0] : new Base[] {this.category}; // CodeableConcept 1717 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 1718 case -1867885268: /*subject*/ return this.subject == null ? new Base[0] : new Base[] {this.subject}; // Reference 1719 case 951530927: /*context*/ return this.context == null ? new Base[0] : new Base[] {this.context}; // Reference 1720 case -1468651097: /*effective*/ return this.effective == null ? new Base[0] : new Base[] {this.effective}; // Type 1721 case -1179159893: /*issued*/ return this.issued == null ? new Base[0] : new Base[] {this.issued}; // InstantType 1722 case 481140686: /*performer*/ return this.performer == null ? new Base[0] : this.performer.toArray(new Base[this.performer.size()]); // Reference 1723 case 2134944932: /*resultsInterpreter*/ return this.resultsInterpreter == null ? new Base[0] : this.resultsInterpreter.toArray(new Base[this.resultsInterpreter.size()]); // Reference 1724 case -2132868344: /*specimen*/ return this.specimen == null ? new Base[0] : this.specimen.toArray(new Base[this.specimen.size()]); // Reference 1725 case -934426595: /*result*/ return this.result == null ? new Base[0] : this.result.toArray(new Base[this.result.size()]); // Reference 1726 case -814900911: /*imagingStudy*/ return this.imagingStudy == null ? new Base[0] : this.imagingStudy.toArray(new Base[this.imagingStudy.size()]); // Reference 1727 case 103772132: /*media*/ return this.media == null ? new Base[0] : this.media.toArray(new Base[this.media.size()]); // DiagnosticReportMediaComponent 1728 case -1731259873: /*conclusion*/ return this.conclusion == null ? new Base[0] : new Base[] {this.conclusion}; // StringType 1729 case -1364269926: /*codedDiagnosis*/ return this.codedDiagnosis == null ? new Base[0] : this.codedDiagnosis.toArray(new Base[this.codedDiagnosis.size()]); // CodeableConcept 1730 case 230090366: /*presentedForm*/ return this.presentedForm == null ? new Base[0] : this.presentedForm.toArray(new Base[this.presentedForm.size()]); // Attachment 1731 default: return super.getProperty(hash, name, checkValid); 1732 } 1733 1734 } 1735 1736 @Override 1737 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1738 switch (hash) { 1739 case -1618432855: // identifier 1740 this.getIdentifier().add(castToIdentifier(value)); // Identifier 1741 return value; 1742 case -332612366: // basedOn 1743 this.getBasedOn().add(castToReference(value)); // Reference 1744 return value; 1745 case -892481550: // status 1746 value = new DiagnosticReportStatusEnumFactory().fromType(castToCode(value)); 1747 this.status = (Enumeration) value; // Enumeration<DiagnosticReportStatus> 1748 return value; 1749 case 50511102: // category 1750 this.category = castToCodeableConcept(value); // CodeableConcept 1751 return value; 1752 case 3059181: // code 1753 this.code = castToCodeableConcept(value); // CodeableConcept 1754 return value; 1755 case -1867885268: // subject 1756 this.subject = castToReference(value); // Reference 1757 return value; 1758 case 951530927: // context 1759 this.context = castToReference(value); // Reference 1760 return value; 1761 case -1468651097: // effective 1762 this.effective = castToType(value); // Type 1763 return value; 1764 case -1179159893: // issued 1765 this.issued = castToInstant(value); // InstantType 1766 return value; 1767 case 481140686: // performer 1768 this.getPerformer().add(castToReference(value)); // Reference 1769 return value; 1770 case 2134944932: // resultsInterpreter 1771 this.getResultsInterpreter().add(castToReference(value)); // Reference 1772 return value; 1773 case -2132868344: // specimen 1774 this.getSpecimen().add(castToReference(value)); // Reference 1775 return value; 1776 case -934426595: // result 1777 this.getResult().add(castToReference(value)); // Reference 1778 return value; 1779 case -814900911: // imagingStudy 1780 this.getImagingStudy().add(castToReference(value)); // Reference 1781 return value; 1782 case 103772132: // media 1783 this.getMedia().add((DiagnosticReportMediaComponent) value); // DiagnosticReportMediaComponent 1784 return value; 1785 case -1731259873: // conclusion 1786 this.conclusion = castToString(value); // StringType 1787 return value; 1788 case -1364269926: // codedDiagnosis 1789 this.getCodedDiagnosis().add(castToCodeableConcept(value)); // CodeableConcept 1790 return value; 1791 case 230090366: // presentedForm 1792 this.getPresentedForm().add(castToAttachment(value)); // Attachment 1793 return value; 1794 default: return super.setProperty(hash, name, value); 1795 } 1796 1797 } 1798 1799 @Override 1800 public Base setProperty(String name, Base value) throws FHIRException { 1801 if (name.equals("identifier")) { 1802 this.getIdentifier().add(castToIdentifier(value)); 1803 } else if (name.equals("basedOn")) { 1804 this.getBasedOn().add(castToReference(value)); 1805 } else if (name.equals("status")) { 1806 value = new DiagnosticReportStatusEnumFactory().fromType(castToCode(value)); 1807 this.status = (Enumeration) value; // Enumeration<DiagnosticReportStatus> 1808 } else if (name.equals("category")) { 1809 this.category = castToCodeableConcept(value); // CodeableConcept 1810 } else if (name.equals("code")) { 1811 this.code = castToCodeableConcept(value); // CodeableConcept 1812 } else if (name.equals("subject")) { 1813 this.subject = castToReference(value); // Reference 1814 } else if (name.equals("context")) { 1815 this.context = castToReference(value); // Reference 1816 } else if (name.equals("effective[x]")) { 1817 this.effective = castToType(value); // Type 1818 } else if (name.equals("issued")) { 1819 this.issued = castToInstant(value); // InstantType 1820 } else if (name.equals("performer")) { 1821 this.getPerformer().add(castToReference(value)); 1822 } else if (name.equals("resultsInterpreter")) { 1823 this.getResultsInterpreter().add(castToReference(value)); 1824 } else if (name.equals("specimen")) { 1825 this.getSpecimen().add(castToReference(value)); 1826 } else if (name.equals("result")) { 1827 this.getResult().add(castToReference(value)); 1828 } else if (name.equals("imagingStudy")) { 1829 this.getImagingStudy().add(castToReference(value)); 1830 } else if (name.equals("media")) { 1831 this.getMedia().add((DiagnosticReportMediaComponent) value); 1832 } else if (name.equals("conclusion")) { 1833 this.conclusion = castToString(value); // StringType 1834 } else if (name.equals("codedDiagnosis")) { 1835 this.getCodedDiagnosis().add(castToCodeableConcept(value)); 1836 } else if (name.equals("presentedForm")) { 1837 this.getPresentedForm().add(castToAttachment(value)); 1838 } else 1839 return super.setProperty(name, value); 1840 return value; 1841 } 1842 1843 @Override 1844 public Base makeProperty(int hash, String name) throws FHIRException { 1845 switch (hash) { 1846 case -1618432855: return addIdentifier(); 1847 case -332612366: return addBasedOn(); 1848 case -892481550: return getStatusElement(); 1849 case 50511102: return getCategory(); 1850 case 3059181: return getCode(); 1851 case -1867885268: return getSubject(); 1852 case 951530927: return getContext(); 1853 case 247104889: return getEffective(); 1854 case -1468651097: return getEffective(); 1855 case -1179159893: return getIssuedElement(); 1856 case 481140686: return addPerformer(); 1857 case 2134944932: return addResultsInterpreter(); 1858 case -2132868344: return addSpecimen(); 1859 case -934426595: return addResult(); 1860 case -814900911: return addImagingStudy(); 1861 case 103772132: return addMedia(); 1862 case -1731259873: return getConclusionElement(); 1863 case -1364269926: return addCodedDiagnosis(); 1864 case 230090366: return addPresentedForm(); 1865 default: return super.makeProperty(hash, name); 1866 } 1867 1868 } 1869 1870 @Override 1871 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1872 switch (hash) { 1873 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 1874 case -332612366: /*basedOn*/ return new String[] {"Reference"}; 1875 case -892481550: /*status*/ return new String[] {"code"}; 1876 case 50511102: /*category*/ return new String[] {"CodeableConcept"}; 1877 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 1878 case -1867885268: /*subject*/ return new String[] {"Reference"}; 1879 case 951530927: /*context*/ return new String[] {"Reference"}; 1880 case -1468651097: /*effective*/ return new String[] {"dateTime", "Period"}; 1881 case -1179159893: /*issued*/ return new String[] {"instant"}; 1882 case 481140686: /*performer*/ return new String[] {"Reference"}; 1883 case 2134944932: /*resultsInterpreter*/ return new String[] {"Reference"}; 1884 case -2132868344: /*specimen*/ return new String[] {"Reference"}; 1885 case -934426595: /*result*/ return new String[] {"Reference"}; 1886 case -814900911: /*imagingStudy*/ return new String[] {"Reference"}; 1887 case 103772132: /*media*/ return new String[] {}; 1888 case -1731259873: /*conclusion*/ return new String[] {"string"}; 1889 case -1364269926: /*codedDiagnosis*/ return new String[] {"CodeableConcept"}; 1890 case 230090366: /*presentedForm*/ return new String[] {"Attachment"}; 1891 default: return super.getTypesForProperty(hash, name); 1892 } 1893 1894 } 1895 1896 @Override 1897 public Base addChild(String name) throws FHIRException { 1898 if (name.equals("identifier")) { 1899 return addIdentifier(); 1900 } 1901 else if (name.equals("basedOn")) { 1902 return addBasedOn(); 1903 } 1904 else if (name.equals("status")) { 1905 throw new FHIRException("Cannot call addChild on a primitive type DiagnosticReport.status"); 1906 } 1907 else if (name.equals("category")) { 1908 this.category = new CodeableConcept(); 1909 return this.category; 1910 } 1911 else if (name.equals("code")) { 1912 this.code = new CodeableConcept(); 1913 return this.code; 1914 } 1915 else if (name.equals("subject")) { 1916 this.subject = new Reference(); 1917 return this.subject; 1918 } 1919 else if (name.equals("context")) { 1920 this.context = new Reference(); 1921 return this.context; 1922 } 1923 else if (name.equals("effectiveDateTime")) { 1924 this.effective = new DateTimeType(); 1925 return this.effective; 1926 } 1927 else if (name.equals("effectivePeriod")) { 1928 this.effective = new Period(); 1929 return this.effective; 1930 } 1931 else if (name.equals("issued")) { 1932 throw new FHIRException("Cannot call addChild on a primitive type DiagnosticReport.issued"); 1933 } 1934 else if (name.equals("performer")) { 1935 return addPerformer(); 1936 } 1937 else if (name.equals("resultsInterpreter")) { 1938 return addResultsInterpreter(); 1939 } 1940 else if (name.equals("specimen")) { 1941 return addSpecimen(); 1942 } 1943 else if (name.equals("result")) { 1944 return addResult(); 1945 } 1946 else if (name.equals("imagingStudy")) { 1947 return addImagingStudy(); 1948 } 1949 else if (name.equals("media")) { 1950 return addMedia(); 1951 } 1952 else if (name.equals("conclusion")) { 1953 throw new FHIRException("Cannot call addChild on a primitive type DiagnosticReport.conclusion"); 1954 } 1955 else if (name.equals("codedDiagnosis")) { 1956 return addCodedDiagnosis(); 1957 } 1958 else if (name.equals("presentedForm")) { 1959 return addPresentedForm(); 1960 } 1961 else 1962 return super.addChild(name); 1963 } 1964 1965 public String fhirType() { 1966 return "DiagnosticReport"; 1967 1968 } 1969 1970 public DiagnosticReport copy() { 1971 DiagnosticReport dst = new DiagnosticReport(); 1972 copyValues(dst); 1973 if (identifier != null) { 1974 dst.identifier = new ArrayList<Identifier>(); 1975 for (Identifier i : identifier) 1976 dst.identifier.add(i.copy()); 1977 }; 1978 if (basedOn != null) { 1979 dst.basedOn = new ArrayList<Reference>(); 1980 for (Reference i : basedOn) 1981 dst.basedOn.add(i.copy()); 1982 }; 1983 dst.status = status == null ? null : status.copy(); 1984 dst.category = category == null ? null : category.copy(); 1985 dst.code = code == null ? null : code.copy(); 1986 dst.subject = subject == null ? null : subject.copy(); 1987 dst.context = context == null ? null : context.copy(); 1988 dst.effective = effective == null ? null : effective.copy(); 1989 dst.issued = issued == null ? null : issued.copy(); 1990 if (performer != null) { 1991 dst.performer = new ArrayList<Reference>(); 1992 for (Reference i : performer) 1993 dst.performer.add(i.copy()); 1994 }; 1995 if (resultsInterpreter != null) { 1996 dst.resultsInterpreter = new ArrayList<Reference>(); 1997 for (Reference i : resultsInterpreter) 1998 dst.resultsInterpreter.add(i.copy()); 1999 }; 2000 if (specimen != null) { 2001 dst.specimen = new ArrayList<Reference>(); 2002 for (Reference i : specimen) 2003 dst.specimen.add(i.copy()); 2004 }; 2005 if (result != null) { 2006 dst.result = new ArrayList<Reference>(); 2007 for (Reference i : result) 2008 dst.result.add(i.copy()); 2009 }; 2010 if (imagingStudy != null) { 2011 dst.imagingStudy = new ArrayList<Reference>(); 2012 for (Reference i : imagingStudy) 2013 dst.imagingStudy.add(i.copy()); 2014 }; 2015 if (media != null) { 2016 dst.media = new ArrayList<DiagnosticReportMediaComponent>(); 2017 for (DiagnosticReportMediaComponent i : media) 2018 dst.media.add(i.copy()); 2019 }; 2020 dst.conclusion = conclusion == null ? null : conclusion.copy(); 2021 if (codedDiagnosis != null) { 2022 dst.codedDiagnosis = new ArrayList<CodeableConcept>(); 2023 for (CodeableConcept i : codedDiagnosis) 2024 dst.codedDiagnosis.add(i.copy()); 2025 }; 2026 if (presentedForm != null) { 2027 dst.presentedForm = new ArrayList<Attachment>(); 2028 for (Attachment i : presentedForm) 2029 dst.presentedForm.add(i.copy()); 2030 }; 2031 return dst; 2032 } 2033 2034 protected DiagnosticReport typedCopy() { 2035 return copy(); 2036 } 2037 2038 @Override 2039 public boolean equalsDeep(Base other_) { 2040 if (!super.equalsDeep(other_)) 2041 return false; 2042 if (!(other_ instanceof DiagnosticReport)) 2043 return false; 2044 DiagnosticReport o = (DiagnosticReport) other_; 2045 return compareDeep(identifier, o.identifier, true) && compareDeep(basedOn, o.basedOn, true) && compareDeep(status, o.status, true) 2046 && compareDeep(category, o.category, true) && compareDeep(code, o.code, true) && compareDeep(subject, o.subject, true) 2047 && compareDeep(context, o.context, true) && compareDeep(effective, o.effective, true) && compareDeep(issued, o.issued, true) 2048 && compareDeep(performer, o.performer, true) && compareDeep(resultsInterpreter, o.resultsInterpreter, true) 2049 && compareDeep(specimen, o.specimen, true) && compareDeep(result, o.result, true) && compareDeep(imagingStudy, o.imagingStudy, true) 2050 && compareDeep(media, o.media, true) && compareDeep(conclusion, o.conclusion, true) && compareDeep(codedDiagnosis, o.codedDiagnosis, true) 2051 && compareDeep(presentedForm, o.presentedForm, true); 2052 } 2053 2054 @Override 2055 public boolean equalsShallow(Base other_) { 2056 if (!super.equalsShallow(other_)) 2057 return false; 2058 if (!(other_ instanceof DiagnosticReport)) 2059 return false; 2060 DiagnosticReport o = (DiagnosticReport) other_; 2061 return compareValues(status, o.status, true) && compareValues(issued, o.issued, true) && compareValues(conclusion, o.conclusion, true) 2062 ; 2063 } 2064 2065 public boolean isEmpty() { 2066 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, basedOn, status 2067 , category, code, subject, context, effective, issued, performer, resultsInterpreter 2068 , specimen, result, imagingStudy, media, conclusion, codedDiagnosis, presentedForm 2069 ); 2070 } 2071 2072 @Override 2073 public ResourceType getResourceType() { 2074 return ResourceType.DiagnosticReport; 2075 } 2076 2077 /** 2078 * Search parameter: <b>date</b> 2079 * <p> 2080 * Description: <b>The clinically relevant time of the report</b><br> 2081 * Type: <b>date</b><br> 2082 * Path: <b>DiagnosticReport.effective[x]</b><br> 2083 * </p> 2084 */ 2085 @SearchParamDefinition(name="date", path="DiagnosticReport.effective", description="The clinically relevant time of the report", type="date" ) 2086 public static final String SP_DATE = "date"; 2087 /** 2088 * <b>Fluent Client</b> search parameter constant for <b>date</b> 2089 * <p> 2090 * Description: <b>The clinically relevant time of the report</b><br> 2091 * Type: <b>date</b><br> 2092 * Path: <b>DiagnosticReport.effective[x]</b><br> 2093 * </p> 2094 */ 2095 public static final ca.uhn.fhir.rest.gclient.DateClientParam DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_DATE); 2096 2097 /** 2098 * Search parameter: <b>identifier</b> 2099 * <p> 2100 * Description: <b>An identifier for the report</b><br> 2101 * Type: <b>token</b><br> 2102 * Path: <b>DiagnosticReport.identifier</b><br> 2103 * </p> 2104 */ 2105 @SearchParamDefinition(name="identifier", path="DiagnosticReport.identifier", description="An identifier for the report", type="token" ) 2106 public static final String SP_IDENTIFIER = "identifier"; 2107 /** 2108 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 2109 * <p> 2110 * Description: <b>An identifier for the report</b><br> 2111 * Type: <b>token</b><br> 2112 * Path: <b>DiagnosticReport.identifier</b><br> 2113 * </p> 2114 */ 2115 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 2116 2117 /** 2118 * Search parameter: <b>performer</b> 2119 * <p> 2120 * Description: <b>Who is responsible for the report</b><br> 2121 * Type: <b>reference</b><br> 2122 * Path: <b>DiagnosticReport.performer</b><br> 2123 * </p> 2124 */ 2125 @SearchParamDefinition(name="performer", path="DiagnosticReport.performer", description="Who is responsible for the report", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Practitioner") }, target={CareTeam.class, Organization.class, Practitioner.class, PractitionerRole.class } ) 2126 public static final String SP_PERFORMER = "performer"; 2127 /** 2128 * <b>Fluent Client</b> search parameter constant for <b>performer</b> 2129 * <p> 2130 * Description: <b>Who is responsible for the report</b><br> 2131 * Type: <b>reference</b><br> 2132 * Path: <b>DiagnosticReport.performer</b><br> 2133 * </p> 2134 */ 2135 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PERFORMER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PERFORMER); 2136 2137/** 2138 * Constant for fluent queries to be used to add include statements. Specifies 2139 * the path value of "<b>DiagnosticReport:performer</b>". 2140 */ 2141 public static final ca.uhn.fhir.model.api.Include INCLUDE_PERFORMER = new ca.uhn.fhir.model.api.Include("DiagnosticReport:performer").toLocked(); 2142 2143 /** 2144 * Search parameter: <b>code</b> 2145 * <p> 2146 * Description: <b>The code for the report, as opposed to codes for the atomic results, which are the names on the observation resource referred to from the result</b><br> 2147 * Type: <b>token</b><br> 2148 * Path: <b>DiagnosticReport.code</b><br> 2149 * </p> 2150 */ 2151 @SearchParamDefinition(name="code", path="DiagnosticReport.code", description="The code for the report, as opposed to codes for the atomic results, which are the names on the observation resource referred to from the result", type="token" ) 2152 public static final String SP_CODE = "code"; 2153 /** 2154 * <b>Fluent Client</b> search parameter constant for <b>code</b> 2155 * <p> 2156 * Description: <b>The code for the report, as opposed to codes for the atomic results, which are the names on the observation resource referred to from the result</b><br> 2157 * Type: <b>token</b><br> 2158 * Path: <b>DiagnosticReport.code</b><br> 2159 * </p> 2160 */ 2161 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CODE); 2162 2163 /** 2164 * Search parameter: <b>subject</b> 2165 * <p> 2166 * Description: <b>The subject of the report</b><br> 2167 * Type: <b>reference</b><br> 2168 * Path: <b>DiagnosticReport.subject</b><br> 2169 * </p> 2170 */ 2171 @SearchParamDefinition(name="subject", path="DiagnosticReport.subject", description="The subject of the report", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Device"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Patient") }, target={Device.class, Group.class, Location.class, Patient.class } ) 2172 public static final String SP_SUBJECT = "subject"; 2173 /** 2174 * <b>Fluent Client</b> search parameter constant for <b>subject</b> 2175 * <p> 2176 * Description: <b>The subject of the report</b><br> 2177 * Type: <b>reference</b><br> 2178 * Path: <b>DiagnosticReport.subject</b><br> 2179 * </p> 2180 */ 2181 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SUBJECT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SUBJECT); 2182 2183/** 2184 * Constant for fluent queries to be used to add include statements. Specifies 2185 * the path value of "<b>DiagnosticReport:subject</b>". 2186 */ 2187 public static final ca.uhn.fhir.model.api.Include INCLUDE_SUBJECT = new ca.uhn.fhir.model.api.Include("DiagnosticReport:subject").toLocked(); 2188 2189 /** 2190 * Search parameter: <b>diagnosis</b> 2191 * <p> 2192 * Description: <b>A coded diagnosis on the report</b><br> 2193 * Type: <b>token</b><br> 2194 * Path: <b>DiagnosticReport.codedDiagnosis</b><br> 2195 * </p> 2196 */ 2197 @SearchParamDefinition(name="diagnosis", path="DiagnosticReport.codedDiagnosis", description="A coded diagnosis on the report", type="token" ) 2198 public static final String SP_DIAGNOSIS = "diagnosis"; 2199 /** 2200 * <b>Fluent Client</b> search parameter constant for <b>diagnosis</b> 2201 * <p> 2202 * Description: <b>A coded diagnosis on the report</b><br> 2203 * Type: <b>token</b><br> 2204 * Path: <b>DiagnosticReport.codedDiagnosis</b><br> 2205 * </p> 2206 */ 2207 public static final ca.uhn.fhir.rest.gclient.TokenClientParam DIAGNOSIS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_DIAGNOSIS); 2208 2209 /** 2210 * Search parameter: <b>media</b> 2211 * <p> 2212 * Description: <b>A reference to the image source.</b><br> 2213 * Type: <b>reference</b><br> 2214 * Path: <b>DiagnosticReport.media.link</b><br> 2215 * </p> 2216 */ 2217 @SearchParamDefinition(name="media", path="DiagnosticReport.media.link", description="A reference to the image source.", type="reference", target={Media.class } ) 2218 public static final String SP_MEDIA = "media"; 2219 /** 2220 * <b>Fluent Client</b> search parameter constant for <b>media</b> 2221 * <p> 2222 * Description: <b>A reference to the image source.</b><br> 2223 * Type: <b>reference</b><br> 2224 * Path: <b>DiagnosticReport.media.link</b><br> 2225 * </p> 2226 */ 2227 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam MEDIA = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_MEDIA); 2228 2229/** 2230 * Constant for fluent queries to be used to add include statements. Specifies 2231 * the path value of "<b>DiagnosticReport:media</b>". 2232 */ 2233 public static final ca.uhn.fhir.model.api.Include INCLUDE_MEDIA = new ca.uhn.fhir.model.api.Include("DiagnosticReport:media").toLocked(); 2234 2235 /** 2236 * Search parameter: <b>encounter</b> 2237 * <p> 2238 * Description: <b>The Encounter when the order was made</b><br> 2239 * Type: <b>reference</b><br> 2240 * Path: <b>DiagnosticReport.context</b><br> 2241 * </p> 2242 */ 2243 @SearchParamDefinition(name="encounter", path="DiagnosticReport.context", description="The Encounter when the order was made", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Encounter") }, target={Encounter.class } ) 2244 public static final String SP_ENCOUNTER = "encounter"; 2245 /** 2246 * <b>Fluent Client</b> search parameter constant for <b>encounter</b> 2247 * <p> 2248 * Description: <b>The Encounter when the order was made</b><br> 2249 * Type: <b>reference</b><br> 2250 * Path: <b>DiagnosticReport.context</b><br> 2251 * </p> 2252 */ 2253 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ENCOUNTER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ENCOUNTER); 2254 2255/** 2256 * Constant for fluent queries to be used to add include statements. Specifies 2257 * the path value of "<b>DiagnosticReport:encounter</b>". 2258 */ 2259 public static final ca.uhn.fhir.model.api.Include INCLUDE_ENCOUNTER = new ca.uhn.fhir.model.api.Include("DiagnosticReport:encounter").toLocked(); 2260 2261 /** 2262 * Search parameter: <b>result</b> 2263 * <p> 2264 * Description: <b>Link to an atomic result (observation resource)</b><br> 2265 * Type: <b>reference</b><br> 2266 * Path: <b>DiagnosticReport.result</b><br> 2267 * </p> 2268 */ 2269 @SearchParamDefinition(name="result", path="DiagnosticReport.result", description="Link to an atomic result (observation resource)", type="reference", target={Observation.class } ) 2270 public static final String SP_RESULT = "result"; 2271 /** 2272 * <b>Fluent Client</b> search parameter constant for <b>result</b> 2273 * <p> 2274 * Description: <b>Link to an atomic result (observation resource)</b><br> 2275 * Type: <b>reference</b><br> 2276 * Path: <b>DiagnosticReport.result</b><br> 2277 * </p> 2278 */ 2279 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam RESULT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_RESULT); 2280 2281/** 2282 * Constant for fluent queries to be used to add include statements. Specifies 2283 * the path value of "<b>DiagnosticReport:result</b>". 2284 */ 2285 public static final ca.uhn.fhir.model.api.Include INCLUDE_RESULT = new ca.uhn.fhir.model.api.Include("DiagnosticReport:result").toLocked(); 2286 2287 /** 2288 * Search parameter: <b>based-on</b> 2289 * <p> 2290 * Description: <b>Reference to the service request.</b><br> 2291 * Type: <b>reference</b><br> 2292 * Path: <b>DiagnosticReport.basedOn</b><br> 2293 * </p> 2294 */ 2295 @SearchParamDefinition(name="based-on", path="DiagnosticReport.basedOn", description="Reference to the service request.", type="reference", target={CarePlan.class, ImmunizationRecommendation.class, MedicationRequest.class, NutritionOrder.class, ServiceRequest.class } ) 2296 public static final String SP_BASED_ON = "based-on"; 2297 /** 2298 * <b>Fluent Client</b> search parameter constant for <b>based-on</b> 2299 * <p> 2300 * Description: <b>Reference to the service request.</b><br> 2301 * Type: <b>reference</b><br> 2302 * Path: <b>DiagnosticReport.basedOn</b><br> 2303 * </p> 2304 */ 2305 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam BASED_ON = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_BASED_ON); 2306 2307/** 2308 * Constant for fluent queries to be used to add include statements. Specifies 2309 * the path value of "<b>DiagnosticReport:based-on</b>". 2310 */ 2311 public static final ca.uhn.fhir.model.api.Include INCLUDE_BASED_ON = new ca.uhn.fhir.model.api.Include("DiagnosticReport:based-on").toLocked(); 2312 2313 /** 2314 * Search parameter: <b>patient</b> 2315 * <p> 2316 * Description: <b>The subject of the report if a patient</b><br> 2317 * Type: <b>reference</b><br> 2318 * Path: <b>DiagnosticReport.subject</b><br> 2319 * </p> 2320 */ 2321 @SearchParamDefinition(name="patient", path="DiagnosticReport.subject", description="The subject of the report if a patient", type="reference", target={Patient.class } ) 2322 public static final String SP_PATIENT = "patient"; 2323 /** 2324 * <b>Fluent Client</b> search parameter constant for <b>patient</b> 2325 * <p> 2326 * Description: <b>The subject of the report if a patient</b><br> 2327 * Type: <b>reference</b><br> 2328 * Path: <b>DiagnosticReport.subject</b><br> 2329 * </p> 2330 */ 2331 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT); 2332 2333/** 2334 * Constant for fluent queries to be used to add include statements. Specifies 2335 * the path value of "<b>DiagnosticReport:patient</b>". 2336 */ 2337 public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("DiagnosticReport:patient").toLocked(); 2338 2339 /** 2340 * Search parameter: <b>specimen</b> 2341 * <p> 2342 * Description: <b>The specimen details</b><br> 2343 * Type: <b>reference</b><br> 2344 * Path: <b>DiagnosticReport.specimen</b><br> 2345 * </p> 2346 */ 2347 @SearchParamDefinition(name="specimen", path="DiagnosticReport.specimen", description="The specimen details", type="reference", target={Specimen.class } ) 2348 public static final String SP_SPECIMEN = "specimen"; 2349 /** 2350 * <b>Fluent Client</b> search parameter constant for <b>specimen</b> 2351 * <p> 2352 * Description: <b>The specimen details</b><br> 2353 * Type: <b>reference</b><br> 2354 * Path: <b>DiagnosticReport.specimen</b><br> 2355 * </p> 2356 */ 2357 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SPECIMEN = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SPECIMEN); 2358 2359/** 2360 * Constant for fluent queries to be used to add include statements. Specifies 2361 * the path value of "<b>DiagnosticReport:specimen</b>". 2362 */ 2363 public static final ca.uhn.fhir.model.api.Include INCLUDE_SPECIMEN = new ca.uhn.fhir.model.api.Include("DiagnosticReport:specimen").toLocked(); 2364 2365 /** 2366 * Search parameter: <b>context</b> 2367 * <p> 2368 * Description: <b>Healthcare event (Episode of Care or Encounter) related to the report</b><br> 2369 * Type: <b>reference</b><br> 2370 * Path: <b>DiagnosticReport.context</b><br> 2371 * </p> 2372 */ 2373 @SearchParamDefinition(name="context", path="DiagnosticReport.context", description="Healthcare event (Episode of Care or Encounter) related to the report", type="reference", target={Encounter.class, EpisodeOfCare.class } ) 2374 public static final String SP_CONTEXT = "context"; 2375 /** 2376 * <b>Fluent Client</b> search parameter constant for <b>context</b> 2377 * <p> 2378 * Description: <b>Healthcare event (Episode of Care or Encounter) related to the report</b><br> 2379 * Type: <b>reference</b><br> 2380 * Path: <b>DiagnosticReport.context</b><br> 2381 * </p> 2382 */ 2383 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam CONTEXT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_CONTEXT); 2384 2385/** 2386 * Constant for fluent queries to be used to add include statements. Specifies 2387 * the path value of "<b>DiagnosticReport:context</b>". 2388 */ 2389 public static final ca.uhn.fhir.model.api.Include INCLUDE_CONTEXT = new ca.uhn.fhir.model.api.Include("DiagnosticReport:context").toLocked(); 2390 2391 /** 2392 * Search parameter: <b>issued</b> 2393 * <p> 2394 * Description: <b>When the report was issued</b><br> 2395 * Type: <b>date</b><br> 2396 * Path: <b>DiagnosticReport.issued</b><br> 2397 * </p> 2398 */ 2399 @SearchParamDefinition(name="issued", path="DiagnosticReport.issued", description="When the report was issued", type="date" ) 2400 public static final String SP_ISSUED = "issued"; 2401 /** 2402 * <b>Fluent Client</b> search parameter constant for <b>issued</b> 2403 * <p> 2404 * Description: <b>When the report was issued</b><br> 2405 * Type: <b>date</b><br> 2406 * Path: <b>DiagnosticReport.issued</b><br> 2407 * </p> 2408 */ 2409 public static final ca.uhn.fhir.rest.gclient.DateClientParam ISSUED = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_ISSUED); 2410 2411 /** 2412 * Search parameter: <b>category</b> 2413 * <p> 2414 * Description: <b>Which diagnostic discipline/department created the report</b><br> 2415 * Type: <b>token</b><br> 2416 * Path: <b>DiagnosticReport.category</b><br> 2417 * </p> 2418 */ 2419 @SearchParamDefinition(name="category", path="DiagnosticReport.category", description="Which diagnostic discipline/department created the report", type="token" ) 2420 public static final String SP_CATEGORY = "category"; 2421 /** 2422 * <b>Fluent Client</b> search parameter constant for <b>category</b> 2423 * <p> 2424 * Description: <b>Which diagnostic discipline/department created the report</b><br> 2425 * Type: <b>token</b><br> 2426 * Path: <b>DiagnosticReport.category</b><br> 2427 * </p> 2428 */ 2429 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CATEGORY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CATEGORY); 2430 2431 /** 2432 * Search parameter: <b>results-interpreter</b> 2433 * <p> 2434 * Description: <b>Who was the source of the report</b><br> 2435 * Type: <b>reference</b><br> 2436 * Path: <b>DiagnosticReport.resultsInterpreter</b><br> 2437 * </p> 2438 */ 2439 @SearchParamDefinition(name="results-interpreter", path="DiagnosticReport.resultsInterpreter", description="Who was the source of the report", type="reference", target={CareTeam.class, Organization.class, Practitioner.class, PractitionerRole.class } ) 2440 public static final String SP_RESULTS_INTERPRETER = "results-interpreter"; 2441 /** 2442 * <b>Fluent Client</b> search parameter constant for <b>results-interpreter</b> 2443 * <p> 2444 * Description: <b>Who was the source of the report</b><br> 2445 * Type: <b>reference</b><br> 2446 * Path: <b>DiagnosticReport.resultsInterpreter</b><br> 2447 * </p> 2448 */ 2449 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam RESULTS_INTERPRETER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_RESULTS_INTERPRETER); 2450 2451/** 2452 * Constant for fluent queries to be used to add include statements. Specifies 2453 * the path value of "<b>DiagnosticReport:results-interpreter</b>". 2454 */ 2455 public static final ca.uhn.fhir.model.api.Include INCLUDE_RESULTS_INTERPRETER = new ca.uhn.fhir.model.api.Include("DiagnosticReport:results-interpreter").toLocked(); 2456 2457 /** 2458 * Search parameter: <b>status</b> 2459 * <p> 2460 * Description: <b>The status of the report</b><br> 2461 * Type: <b>token</b><br> 2462 * Path: <b>DiagnosticReport.status</b><br> 2463 * </p> 2464 */ 2465 @SearchParamDefinition(name="status", path="DiagnosticReport.status", description="The status of the report", type="token" ) 2466 public static final String SP_STATUS = "status"; 2467 /** 2468 * <b>Fluent Client</b> search parameter constant for <b>status</b> 2469 * <p> 2470 * Description: <b>The status of the report</b><br> 2471 * Type: <b>token</b><br> 2472 * Path: <b>DiagnosticReport.status</b><br> 2473 * </p> 2474 */ 2475 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 2476 2477 2478} 2479