001package org.hl7.fhir.dstu2.model; 002 003 004 005 006/* 007 Copyright (c) 2011+, HL7, Inc. 008 All rights reserved. 009 010 Redistribution and use in source and binary forms, with or without modification, 011 are permitted provided that the following conditions are met: 012 013 * Redistributions of source code must retain the above copyright notice, this 014 list of conditions and the following disclaimer. 015 * Redistributions in binary form must reproduce the above copyright notice, 016 this list of conditions and the following disclaimer in the documentation 017 and/or other materials provided with the distribution. 018 * Neither the name of HL7 nor the names of its contributors may be used to 019 endorse or promote products derived from this software without specific 020 prior written permission. 021 022 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 023 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 024 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 025 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 026 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 027 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 028 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 029 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 030 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 031 POSSIBILITY OF SUCH DAMAGE. 032 033*/ 034 035// Generated on Wed, Jul 13, 2016 05:32+1000 for FHIR v1.0.2 036import java.util.ArrayList; 037import java.util.Date; 038import java.util.List; 039 040import ca.uhn.fhir.model.api.annotation.Block; 041import ca.uhn.fhir.model.api.annotation.Child; 042import ca.uhn.fhir.model.api.annotation.Description; 043import ca.uhn.fhir.model.api.annotation.ResourceDef; 044import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 045import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 046import org.hl7.fhir.exceptions.FHIRException; 047import org.hl7.fhir.utilities.Utilities; 048/** 049 * Representation of the content produced in a DICOM imaging study. A study comprises a set of series, each of which includes a set of Service-Object Pair Instances (SOP Instances - images or other data) acquired or produced in a common context. A series is of only one modality (e.g. X-ray, CT, MR, ultrasound), but a study may have multiple series of different modalities. 050 */ 051@ResourceDef(name="ImagingStudy", profile="http://hl7.org/fhir/Profile/ImagingStudy") 052public class ImagingStudy extends DomainResource { 053 054 public enum InstanceAvailability { 055 /** 056 * null 057 */ 058 ONLINE, 059 /** 060 * null 061 */ 062 OFFLINE, 063 /** 064 * null 065 */ 066 NEARLINE, 067 /** 068 * null 069 */ 070 UNAVAILABLE, 071 /** 072 * added to help the parsers 073 */ 074 NULL; 075 public static InstanceAvailability fromCode(String codeString) throws FHIRException { 076 if (codeString == null || "".equals(codeString)) 077 return null; 078 if ("ONLINE".equals(codeString)) 079 return ONLINE; 080 if ("OFFLINE".equals(codeString)) 081 return OFFLINE; 082 if ("NEARLINE".equals(codeString)) 083 return NEARLINE; 084 if ("UNAVAILABLE".equals(codeString)) 085 return UNAVAILABLE; 086 throw new FHIRException("Unknown InstanceAvailability code '"+codeString+"'"); 087 } 088 public String toCode() { 089 switch (this) { 090 case ONLINE: return "ONLINE"; 091 case OFFLINE: return "OFFLINE"; 092 case NEARLINE: return "NEARLINE"; 093 case UNAVAILABLE: return "UNAVAILABLE"; 094 case NULL: return null; 095 default: return "?"; 096 } 097 } 098 public String getSystem() { 099 switch (this) { 100 case ONLINE: return "http://nema.org/dicom/dicm"; 101 case OFFLINE: return "http://nema.org/dicom/dicm"; 102 case NEARLINE: return "http://nema.org/dicom/dicm"; 103 case UNAVAILABLE: return "http://nema.org/dicom/dicm"; 104 case NULL: return null; 105 default: return "?"; 106 } 107 } 108 public String getDefinition() { 109 switch (this) { 110 case ONLINE: return ""; 111 case OFFLINE: return ""; 112 case NEARLINE: return ""; 113 case UNAVAILABLE: return ""; 114 case NULL: return null; 115 default: return "?"; 116 } 117 } 118 public String getDisplay() { 119 switch (this) { 120 case ONLINE: return "ONLINE"; 121 case OFFLINE: return "OFFLINE"; 122 case NEARLINE: return "NEARLINE"; 123 case UNAVAILABLE: return "UNAVAILABLE"; 124 case NULL: return null; 125 default: return "?"; 126 } 127 } 128 } 129 130 public static class InstanceAvailabilityEnumFactory implements EnumFactory<InstanceAvailability> { 131 public InstanceAvailability fromCode(String codeString) throws IllegalArgumentException { 132 if (codeString == null || "".equals(codeString)) 133 if (codeString == null || "".equals(codeString)) 134 return null; 135 if ("ONLINE".equals(codeString)) 136 return InstanceAvailability.ONLINE; 137 if ("OFFLINE".equals(codeString)) 138 return InstanceAvailability.OFFLINE; 139 if ("NEARLINE".equals(codeString)) 140 return InstanceAvailability.NEARLINE; 141 if ("UNAVAILABLE".equals(codeString)) 142 return InstanceAvailability.UNAVAILABLE; 143 throw new IllegalArgumentException("Unknown InstanceAvailability code '"+codeString+"'"); 144 } 145 public Enumeration<InstanceAvailability> fromType(Base code) throws FHIRException { 146 if (code == null || code.isEmpty()) 147 return null; 148 String codeString = ((PrimitiveType) code).asStringValue(); 149 if (codeString == null || "".equals(codeString)) 150 return null; 151 if ("ONLINE".equals(codeString)) 152 return new Enumeration<InstanceAvailability>(this, InstanceAvailability.ONLINE); 153 if ("OFFLINE".equals(codeString)) 154 return new Enumeration<InstanceAvailability>(this, InstanceAvailability.OFFLINE); 155 if ("NEARLINE".equals(codeString)) 156 return new Enumeration<InstanceAvailability>(this, InstanceAvailability.NEARLINE); 157 if ("UNAVAILABLE".equals(codeString)) 158 return new Enumeration<InstanceAvailability>(this, InstanceAvailability.UNAVAILABLE); 159 throw new FHIRException("Unknown InstanceAvailability code '"+codeString+"'"); 160 } 161 public String toCode(InstanceAvailability code) { 162 if (code == InstanceAvailability.ONLINE) 163 return "ONLINE"; 164 if (code == InstanceAvailability.OFFLINE) 165 return "OFFLINE"; 166 if (code == InstanceAvailability.NEARLINE) 167 return "NEARLINE"; 168 if (code == InstanceAvailability.UNAVAILABLE) 169 return "UNAVAILABLE"; 170 return "?"; 171 } 172 } 173 174 @Block() 175 public static class ImagingStudySeriesComponent extends BackboneElement implements IBaseBackboneElement { 176 /** 177 * The Numeric identifier of this series in the study. 178 */ 179 @Child(name = "number", type = {UnsignedIntType.class}, order=1, min=0, max=1, modifier=false, summary=true) 180 @Description(shortDefinition="Numeric identifier of this series", formalDefinition="The Numeric identifier of this series in the study." ) 181 protected UnsignedIntType number; 182 183 /** 184 * The modality of this series sequence. 185 */ 186 @Child(name = "modality", type = {Coding.class}, order=2, min=1, max=1, modifier=false, summary=true) 187 @Description(shortDefinition="The modality of the instances in the series", formalDefinition="The modality of this series sequence." ) 188 protected Coding modality; 189 190 /** 191 * Formal identifier for this series. 192 */ 193 @Child(name = "uid", type = {OidType.class}, order=3, min=1, max=1, modifier=false, summary=true) 194 @Description(shortDefinition="Formal identifier for this series", formalDefinition="Formal identifier for this series." ) 195 protected OidType uid; 196 197 /** 198 * A description of the series. 199 */ 200 @Child(name = "description", type = {StringType.class}, order=4, min=0, max=1, modifier=false, summary=true) 201 @Description(shortDefinition="A description of the series", formalDefinition="A description of the series." ) 202 protected StringType description; 203 204 /** 205 * Number of SOP Instances in Series. 206 */ 207 @Child(name = "numberOfInstances", type = {UnsignedIntType.class}, order=5, min=1, max=1, modifier=false, summary=true) 208 @Description(shortDefinition="Number of Series Related Instances", formalDefinition="Number of SOP Instances in Series." ) 209 protected UnsignedIntType numberOfInstances; 210 211 /** 212 * Availability of series (online, offline or nearline). 213 */ 214 @Child(name = "availability", type = {CodeType.class}, order=6, min=0, max=1, modifier=false, summary=true) 215 @Description(shortDefinition="ONLINE | OFFLINE | NEARLINE | UNAVAILABLE", formalDefinition="Availability of series (online, offline or nearline)." ) 216 protected Enumeration<InstanceAvailability> availability; 217 218 /** 219 * URI/URL specifying the location of the referenced series using WADO-RS. 220 */ 221 @Child(name = "url", type = {UriType.class}, order=7, min=0, max=1, modifier=false, summary=true) 222 @Description(shortDefinition="Location of the referenced instance(s)", formalDefinition="URI/URL specifying the location of the referenced series using WADO-RS." ) 223 protected UriType url; 224 225 /** 226 * Body part examined. See DICOM Part 16 Annex L for the mapping from DICOM to Snomed CT. 227 */ 228 @Child(name = "bodySite", type = {Coding.class}, order=8, min=0, max=1, modifier=false, summary=true) 229 @Description(shortDefinition="Body part examined", formalDefinition="Body part examined. See DICOM Part 16 Annex L for the mapping from DICOM to Snomed CT." ) 230 protected Coding bodySite; 231 232 /** 233 * Laterality if body site is paired anatomic structure and laterality is not pre-coordinated in body site code. 234 */ 235 @Child(name = "laterality", type = {Coding.class}, order=9, min=0, max=1, modifier=false, summary=true) 236 @Description(shortDefinition="Body part laterality", formalDefinition="Laterality if body site is paired anatomic structure and laterality is not pre-coordinated in body site code." ) 237 protected Coding laterality; 238 239 /** 240 * The date and time the series was started. 241 */ 242 @Child(name = "started", type = {DateTimeType.class}, order=10, min=0, max=1, modifier=false, summary=true) 243 @Description(shortDefinition="When the series started", formalDefinition="The date and time the series was started." ) 244 protected DateTimeType started; 245 246 /** 247 * A single SOP Instance within the series, e.g. an image, or presentation state. 248 */ 249 @Child(name = "instance", type = {}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 250 @Description(shortDefinition="A single SOP instance from the series", formalDefinition="A single SOP Instance within the series, e.g. an image, or presentation state." ) 251 protected List<ImagingStudySeriesInstanceComponent> instance; 252 253 private static final long serialVersionUID = -1798366943L; 254 255 /* 256 * Constructor 257 */ 258 public ImagingStudySeriesComponent() { 259 super(); 260 } 261 262 /* 263 * Constructor 264 */ 265 public ImagingStudySeriesComponent(Coding modality, OidType uid, UnsignedIntType numberOfInstances) { 266 super(); 267 this.modality = modality; 268 this.uid = uid; 269 this.numberOfInstances = numberOfInstances; 270 } 271 272 /** 273 * @return {@link #number} (The Numeric identifier of this series in the study.). This is the underlying object with id, value and extensions. The accessor "getNumber" gives direct access to the value 274 */ 275 public UnsignedIntType getNumberElement() { 276 if (this.number == null) 277 if (Configuration.errorOnAutoCreate()) 278 throw new Error("Attempt to auto-create ImagingStudySeriesComponent.number"); 279 else if (Configuration.doAutoCreate()) 280 this.number = new UnsignedIntType(); // bb 281 return this.number; 282 } 283 284 public boolean hasNumberElement() { 285 return this.number != null && !this.number.isEmpty(); 286 } 287 288 public boolean hasNumber() { 289 return this.number != null && !this.number.isEmpty(); 290 } 291 292 /** 293 * @param value {@link #number} (The Numeric identifier of this series in the study.). This is the underlying object with id, value and extensions. The accessor "getNumber" gives direct access to the value 294 */ 295 public ImagingStudySeriesComponent setNumberElement(UnsignedIntType value) { 296 this.number = value; 297 return this; 298 } 299 300 /** 301 * @return The Numeric identifier of this series in the study. 302 */ 303 public int getNumber() { 304 return this.number == null || this.number.isEmpty() ? 0 : this.number.getValue(); 305 } 306 307 /** 308 * @param value The Numeric identifier of this series in the study. 309 */ 310 public ImagingStudySeriesComponent setNumber(int value) { 311 if (this.number == null) 312 this.number = new UnsignedIntType(); 313 this.number.setValue(value); 314 return this; 315 } 316 317 /** 318 * @return {@link #modality} (The modality of this series sequence.) 319 */ 320 public Coding getModality() { 321 if (this.modality == null) 322 if (Configuration.errorOnAutoCreate()) 323 throw new Error("Attempt to auto-create ImagingStudySeriesComponent.modality"); 324 else if (Configuration.doAutoCreate()) 325 this.modality = new Coding(); // cc 326 return this.modality; 327 } 328 329 public boolean hasModality() { 330 return this.modality != null && !this.modality.isEmpty(); 331 } 332 333 /** 334 * @param value {@link #modality} (The modality of this series sequence.) 335 */ 336 public ImagingStudySeriesComponent setModality(Coding value) { 337 this.modality = value; 338 return this; 339 } 340 341 /** 342 * @return {@link #uid} (Formal identifier for this series.). This is the underlying object with id, value and extensions. The accessor "getUid" gives direct access to the value 343 */ 344 public OidType getUidElement() { 345 if (this.uid == null) 346 if (Configuration.errorOnAutoCreate()) 347 throw new Error("Attempt to auto-create ImagingStudySeriesComponent.uid"); 348 else if (Configuration.doAutoCreate()) 349 this.uid = new OidType(); // bb 350 return this.uid; 351 } 352 353 public boolean hasUidElement() { 354 return this.uid != null && !this.uid.isEmpty(); 355 } 356 357 public boolean hasUid() { 358 return this.uid != null && !this.uid.isEmpty(); 359 } 360 361 /** 362 * @param value {@link #uid} (Formal identifier for this series.). This is the underlying object with id, value and extensions. The accessor "getUid" gives direct access to the value 363 */ 364 public ImagingStudySeriesComponent setUidElement(OidType value) { 365 this.uid = value; 366 return this; 367 } 368 369 /** 370 * @return Formal identifier for this series. 371 */ 372 public String getUid() { 373 return this.uid == null ? null : this.uid.getValue(); 374 } 375 376 /** 377 * @param value Formal identifier for this series. 378 */ 379 public ImagingStudySeriesComponent setUid(String value) { 380 if (this.uid == null) 381 this.uid = new OidType(); 382 this.uid.setValue(value); 383 return this; 384 } 385 386 /** 387 * @return {@link #description} (A description of the series.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 388 */ 389 public StringType getDescriptionElement() { 390 if (this.description == null) 391 if (Configuration.errorOnAutoCreate()) 392 throw new Error("Attempt to auto-create ImagingStudySeriesComponent.description"); 393 else if (Configuration.doAutoCreate()) 394 this.description = new StringType(); // bb 395 return this.description; 396 } 397 398 public boolean hasDescriptionElement() { 399 return this.description != null && !this.description.isEmpty(); 400 } 401 402 public boolean hasDescription() { 403 return this.description != null && !this.description.isEmpty(); 404 } 405 406 /** 407 * @param value {@link #description} (A description of the series.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 408 */ 409 public ImagingStudySeriesComponent setDescriptionElement(StringType value) { 410 this.description = value; 411 return this; 412 } 413 414 /** 415 * @return A description of the series. 416 */ 417 public String getDescription() { 418 return this.description == null ? null : this.description.getValue(); 419 } 420 421 /** 422 * @param value A description of the series. 423 */ 424 public ImagingStudySeriesComponent setDescription(String value) { 425 if (Utilities.noString(value)) 426 this.description = null; 427 else { 428 if (this.description == null) 429 this.description = new StringType(); 430 this.description.setValue(value); 431 } 432 return this; 433 } 434 435 /** 436 * @return {@link #numberOfInstances} (Number of SOP Instances in Series.). This is the underlying object with id, value and extensions. The accessor "getNumberOfInstances" gives direct access to the value 437 */ 438 public UnsignedIntType getNumberOfInstancesElement() { 439 if (this.numberOfInstances == null) 440 if (Configuration.errorOnAutoCreate()) 441 throw new Error("Attempt to auto-create ImagingStudySeriesComponent.numberOfInstances"); 442 else if (Configuration.doAutoCreate()) 443 this.numberOfInstances = new UnsignedIntType(); // bb 444 return this.numberOfInstances; 445 } 446 447 public boolean hasNumberOfInstancesElement() { 448 return this.numberOfInstances != null && !this.numberOfInstances.isEmpty(); 449 } 450 451 public boolean hasNumberOfInstances() { 452 return this.numberOfInstances != null && !this.numberOfInstances.isEmpty(); 453 } 454 455 /** 456 * @param value {@link #numberOfInstances} (Number of SOP Instances in Series.). This is the underlying object with id, value and extensions. The accessor "getNumberOfInstances" gives direct access to the value 457 */ 458 public ImagingStudySeriesComponent setNumberOfInstancesElement(UnsignedIntType value) { 459 this.numberOfInstances = value; 460 return this; 461 } 462 463 /** 464 * @return Number of SOP Instances in Series. 465 */ 466 public int getNumberOfInstances() { 467 return this.numberOfInstances == null || this.numberOfInstances.isEmpty() ? 0 : this.numberOfInstances.getValue(); 468 } 469 470 /** 471 * @param value Number of SOP Instances in Series. 472 */ 473 public ImagingStudySeriesComponent setNumberOfInstances(int value) { 474 if (this.numberOfInstances == null) 475 this.numberOfInstances = new UnsignedIntType(); 476 this.numberOfInstances.setValue(value); 477 return this; 478 } 479 480 /** 481 * @return {@link #availability} (Availability of series (online, offline or nearline).). This is the underlying object with id, value and extensions. The accessor "getAvailability" gives direct access to the value 482 */ 483 public Enumeration<InstanceAvailability> getAvailabilityElement() { 484 if (this.availability == null) 485 if (Configuration.errorOnAutoCreate()) 486 throw new Error("Attempt to auto-create ImagingStudySeriesComponent.availability"); 487 else if (Configuration.doAutoCreate()) 488 this.availability = new Enumeration<InstanceAvailability>(new InstanceAvailabilityEnumFactory()); // bb 489 return this.availability; 490 } 491 492 public boolean hasAvailabilityElement() { 493 return this.availability != null && !this.availability.isEmpty(); 494 } 495 496 public boolean hasAvailability() { 497 return this.availability != null && !this.availability.isEmpty(); 498 } 499 500 /** 501 * @param value {@link #availability} (Availability of series (online, offline or nearline).). This is the underlying object with id, value and extensions. The accessor "getAvailability" gives direct access to the value 502 */ 503 public ImagingStudySeriesComponent setAvailabilityElement(Enumeration<InstanceAvailability> value) { 504 this.availability = value; 505 return this; 506 } 507 508 /** 509 * @return Availability of series (online, offline or nearline). 510 */ 511 public InstanceAvailability getAvailability() { 512 return this.availability == null ? null : this.availability.getValue(); 513 } 514 515 /** 516 * @param value Availability of series (online, offline or nearline). 517 */ 518 public ImagingStudySeriesComponent setAvailability(InstanceAvailability value) { 519 if (value == null) 520 this.availability = null; 521 else { 522 if (this.availability == null) 523 this.availability = new Enumeration<InstanceAvailability>(new InstanceAvailabilityEnumFactory()); 524 this.availability.setValue(value); 525 } 526 return this; 527 } 528 529 /** 530 * @return {@link #url} (URI/URL specifying the location of the referenced series using WADO-RS.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 531 */ 532 public UriType getUrlElement() { 533 if (this.url == null) 534 if (Configuration.errorOnAutoCreate()) 535 throw new Error("Attempt to auto-create ImagingStudySeriesComponent.url"); 536 else if (Configuration.doAutoCreate()) 537 this.url = new UriType(); // bb 538 return this.url; 539 } 540 541 public boolean hasUrlElement() { 542 return this.url != null && !this.url.isEmpty(); 543 } 544 545 public boolean hasUrl() { 546 return this.url != null && !this.url.isEmpty(); 547 } 548 549 /** 550 * @param value {@link #url} (URI/URL specifying the location of the referenced series using WADO-RS.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 551 */ 552 public ImagingStudySeriesComponent setUrlElement(UriType value) { 553 this.url = value; 554 return this; 555 } 556 557 /** 558 * @return URI/URL specifying the location of the referenced series using WADO-RS. 559 */ 560 public String getUrl() { 561 return this.url == null ? null : this.url.getValue(); 562 } 563 564 /** 565 * @param value URI/URL specifying the location of the referenced series using WADO-RS. 566 */ 567 public ImagingStudySeriesComponent setUrl(String value) { 568 if (Utilities.noString(value)) 569 this.url = null; 570 else { 571 if (this.url == null) 572 this.url = new UriType(); 573 this.url.setValue(value); 574 } 575 return this; 576 } 577 578 /** 579 * @return {@link #bodySite} (Body part examined. See DICOM Part 16 Annex L for the mapping from DICOM to Snomed CT.) 580 */ 581 public Coding getBodySite() { 582 if (this.bodySite == null) 583 if (Configuration.errorOnAutoCreate()) 584 throw new Error("Attempt to auto-create ImagingStudySeriesComponent.bodySite"); 585 else if (Configuration.doAutoCreate()) 586 this.bodySite = new Coding(); // cc 587 return this.bodySite; 588 } 589 590 public boolean hasBodySite() { 591 return this.bodySite != null && !this.bodySite.isEmpty(); 592 } 593 594 /** 595 * @param value {@link #bodySite} (Body part examined. See DICOM Part 16 Annex L for the mapping from DICOM to Snomed CT.) 596 */ 597 public ImagingStudySeriesComponent setBodySite(Coding value) { 598 this.bodySite = value; 599 return this; 600 } 601 602 /** 603 * @return {@link #laterality} (Laterality if body site is paired anatomic structure and laterality is not pre-coordinated in body site code.) 604 */ 605 public Coding getLaterality() { 606 if (this.laterality == null) 607 if (Configuration.errorOnAutoCreate()) 608 throw new Error("Attempt to auto-create ImagingStudySeriesComponent.laterality"); 609 else if (Configuration.doAutoCreate()) 610 this.laterality = new Coding(); // cc 611 return this.laterality; 612 } 613 614 public boolean hasLaterality() { 615 return this.laterality != null && !this.laterality.isEmpty(); 616 } 617 618 /** 619 * @param value {@link #laterality} (Laterality if body site is paired anatomic structure and laterality is not pre-coordinated in body site code.) 620 */ 621 public ImagingStudySeriesComponent setLaterality(Coding value) { 622 this.laterality = value; 623 return this; 624 } 625 626 /** 627 * @return {@link #started} (The date and time the series was started.). This is the underlying object with id, value and extensions. The accessor "getStarted" gives direct access to the value 628 */ 629 public DateTimeType getStartedElement() { 630 if (this.started == null) 631 if (Configuration.errorOnAutoCreate()) 632 throw new Error("Attempt to auto-create ImagingStudySeriesComponent.started"); 633 else if (Configuration.doAutoCreate()) 634 this.started = new DateTimeType(); // bb 635 return this.started; 636 } 637 638 public boolean hasStartedElement() { 639 return this.started != null && !this.started.isEmpty(); 640 } 641 642 public boolean hasStarted() { 643 return this.started != null && !this.started.isEmpty(); 644 } 645 646 /** 647 * @param value {@link #started} (The date and time the series was started.). This is the underlying object with id, value and extensions. The accessor "getStarted" gives direct access to the value 648 */ 649 public ImagingStudySeriesComponent setStartedElement(DateTimeType value) { 650 this.started = value; 651 return this; 652 } 653 654 /** 655 * @return The date and time the series was started. 656 */ 657 public Date getStarted() { 658 return this.started == null ? null : this.started.getValue(); 659 } 660 661 /** 662 * @param value The date and time the series was started. 663 */ 664 public ImagingStudySeriesComponent setStarted(Date value) { 665 if (value == null) 666 this.started = null; 667 else { 668 if (this.started == null) 669 this.started = new DateTimeType(); 670 this.started.setValue(value); 671 } 672 return this; 673 } 674 675 /** 676 * @return {@link #instance} (A single SOP Instance within the series, e.g. an image, or presentation state.) 677 */ 678 public List<ImagingStudySeriesInstanceComponent> getInstance() { 679 if (this.instance == null) 680 this.instance = new ArrayList<ImagingStudySeriesInstanceComponent>(); 681 return this.instance; 682 } 683 684 public boolean hasInstance() { 685 if (this.instance == null) 686 return false; 687 for (ImagingStudySeriesInstanceComponent item : this.instance) 688 if (!item.isEmpty()) 689 return true; 690 return false; 691 } 692 693 /** 694 * @return {@link #instance} (A single SOP Instance within the series, e.g. an image, or presentation state.) 695 */ 696 // syntactic sugar 697 public ImagingStudySeriesInstanceComponent addInstance() { //3 698 ImagingStudySeriesInstanceComponent t = new ImagingStudySeriesInstanceComponent(); 699 if (this.instance == null) 700 this.instance = new ArrayList<ImagingStudySeriesInstanceComponent>(); 701 this.instance.add(t); 702 return t; 703 } 704 705 // syntactic sugar 706 public ImagingStudySeriesComponent addInstance(ImagingStudySeriesInstanceComponent t) { //3 707 if (t == null) 708 return this; 709 if (this.instance == null) 710 this.instance = new ArrayList<ImagingStudySeriesInstanceComponent>(); 711 this.instance.add(t); 712 return this; 713 } 714 715 protected void listChildren(List<Property> childrenList) { 716 super.listChildren(childrenList); 717 childrenList.add(new Property("number", "unsignedInt", "The Numeric identifier of this series in the study.", 0, java.lang.Integer.MAX_VALUE, number)); 718 childrenList.add(new Property("modality", "Coding", "The modality of this series sequence.", 0, java.lang.Integer.MAX_VALUE, modality)); 719 childrenList.add(new Property("uid", "oid", "Formal identifier for this series.", 0, java.lang.Integer.MAX_VALUE, uid)); 720 childrenList.add(new Property("description", "string", "A description of the series.", 0, java.lang.Integer.MAX_VALUE, description)); 721 childrenList.add(new Property("numberOfInstances", "unsignedInt", "Number of SOP Instances in Series.", 0, java.lang.Integer.MAX_VALUE, numberOfInstances)); 722 childrenList.add(new Property("availability", "code", "Availability of series (online, offline or nearline).", 0, java.lang.Integer.MAX_VALUE, availability)); 723 childrenList.add(new Property("url", "uri", "URI/URL specifying the location of the referenced series using WADO-RS.", 0, java.lang.Integer.MAX_VALUE, url)); 724 childrenList.add(new Property("bodySite", "Coding", "Body part examined. See DICOM Part 16 Annex L for the mapping from DICOM to Snomed CT.", 0, java.lang.Integer.MAX_VALUE, bodySite)); 725 childrenList.add(new Property("laterality", "Coding", "Laterality if body site is paired anatomic structure and laterality is not pre-coordinated in body site code.", 0, java.lang.Integer.MAX_VALUE, laterality)); 726 childrenList.add(new Property("started", "dateTime", "The date and time the series was started.", 0, java.lang.Integer.MAX_VALUE, started)); 727 childrenList.add(new Property("instance", "", "A single SOP Instance within the series, e.g. an image, or presentation state.", 0, java.lang.Integer.MAX_VALUE, instance)); 728 } 729 730 @Override 731 public void setProperty(String name, Base value) throws FHIRException { 732 if (name.equals("number")) 733 this.number = castToUnsignedInt(value); // UnsignedIntType 734 else if (name.equals("modality")) 735 this.modality = castToCoding(value); // Coding 736 else if (name.equals("uid")) 737 this.uid = castToOid(value); // OidType 738 else if (name.equals("description")) 739 this.description = castToString(value); // StringType 740 else if (name.equals("numberOfInstances")) 741 this.numberOfInstances = castToUnsignedInt(value); // UnsignedIntType 742 else if (name.equals("availability")) 743 this.availability = new InstanceAvailabilityEnumFactory().fromType(value); // Enumeration<InstanceAvailability> 744 else if (name.equals("url")) 745 this.url = castToUri(value); // UriType 746 else if (name.equals("bodySite")) 747 this.bodySite = castToCoding(value); // Coding 748 else if (name.equals("laterality")) 749 this.laterality = castToCoding(value); // Coding 750 else if (name.equals("started")) 751 this.started = castToDateTime(value); // DateTimeType 752 else if (name.equals("instance")) 753 this.getInstance().add((ImagingStudySeriesInstanceComponent) value); 754 else 755 super.setProperty(name, value); 756 } 757 758 @Override 759 public Base addChild(String name) throws FHIRException { 760 if (name.equals("number")) { 761 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.number"); 762 } 763 else if (name.equals("modality")) { 764 this.modality = new Coding(); 765 return this.modality; 766 } 767 else if (name.equals("uid")) { 768 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.uid"); 769 } 770 else if (name.equals("description")) { 771 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.description"); 772 } 773 else if (name.equals("numberOfInstances")) { 774 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.numberOfInstances"); 775 } 776 else if (name.equals("availability")) { 777 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.availability"); 778 } 779 else if (name.equals("url")) { 780 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.url"); 781 } 782 else if (name.equals("bodySite")) { 783 this.bodySite = new Coding(); 784 return this.bodySite; 785 } 786 else if (name.equals("laterality")) { 787 this.laterality = new Coding(); 788 return this.laterality; 789 } 790 else if (name.equals("started")) { 791 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.started"); 792 } 793 else if (name.equals("instance")) { 794 return addInstance(); 795 } 796 else 797 return super.addChild(name); 798 } 799 800 public ImagingStudySeriesComponent copy() { 801 ImagingStudySeriesComponent dst = new ImagingStudySeriesComponent(); 802 copyValues(dst); 803 dst.number = number == null ? null : number.copy(); 804 dst.modality = modality == null ? null : modality.copy(); 805 dst.uid = uid == null ? null : uid.copy(); 806 dst.description = description == null ? null : description.copy(); 807 dst.numberOfInstances = numberOfInstances == null ? null : numberOfInstances.copy(); 808 dst.availability = availability == null ? null : availability.copy(); 809 dst.url = url == null ? null : url.copy(); 810 dst.bodySite = bodySite == null ? null : bodySite.copy(); 811 dst.laterality = laterality == null ? null : laterality.copy(); 812 dst.started = started == null ? null : started.copy(); 813 if (instance != null) { 814 dst.instance = new ArrayList<ImagingStudySeriesInstanceComponent>(); 815 for (ImagingStudySeriesInstanceComponent i : instance) 816 dst.instance.add(i.copy()); 817 }; 818 return dst; 819 } 820 821 @Override 822 public boolean equalsDeep(Base other) { 823 if (!super.equalsDeep(other)) 824 return false; 825 if (!(other instanceof ImagingStudySeriesComponent)) 826 return false; 827 ImagingStudySeriesComponent o = (ImagingStudySeriesComponent) other; 828 return compareDeep(number, o.number, true) && compareDeep(modality, o.modality, true) && compareDeep(uid, o.uid, true) 829 && compareDeep(description, o.description, true) && compareDeep(numberOfInstances, o.numberOfInstances, true) 830 && compareDeep(availability, o.availability, true) && compareDeep(url, o.url, true) && compareDeep(bodySite, o.bodySite, true) 831 && compareDeep(laterality, o.laterality, true) && compareDeep(started, o.started, true) && compareDeep(instance, o.instance, true) 832 ; 833 } 834 835 @Override 836 public boolean equalsShallow(Base other) { 837 if (!super.equalsShallow(other)) 838 return false; 839 if (!(other instanceof ImagingStudySeriesComponent)) 840 return false; 841 ImagingStudySeriesComponent o = (ImagingStudySeriesComponent) other; 842 return compareValues(number, o.number, true) && compareValues(uid, o.uid, true) && compareValues(description, o.description, true) 843 && compareValues(numberOfInstances, o.numberOfInstances, true) && compareValues(availability, o.availability, true) 844 && compareValues(url, o.url, true) && compareValues(started, o.started, true); 845 } 846 847 public boolean isEmpty() { 848 return super.isEmpty() && (number == null || number.isEmpty()) && (modality == null || modality.isEmpty()) 849 && (uid == null || uid.isEmpty()) && (description == null || description.isEmpty()) && (numberOfInstances == null || numberOfInstances.isEmpty()) 850 && (availability == null || availability.isEmpty()) && (url == null || url.isEmpty()) && (bodySite == null || bodySite.isEmpty()) 851 && (laterality == null || laterality.isEmpty()) && (started == null || started.isEmpty()) 852 && (instance == null || instance.isEmpty()); 853 } 854 855 public String fhirType() { 856 return "ImagingStudy.series"; 857 858 } 859 860 } 861 862 @Block() 863 public static class ImagingStudySeriesInstanceComponent extends BackboneElement implements IBaseBackboneElement { 864 /** 865 * The number of instance in the series. 866 */ 867 @Child(name = "number", type = {UnsignedIntType.class}, order=1, min=0, max=1, modifier=false, summary=true) 868 @Description(shortDefinition="The number of this instance in the series", formalDefinition="The number of instance in the series." ) 869 protected UnsignedIntType number; 870 871 /** 872 * Formal identifier for this image or other content. 873 */ 874 @Child(name = "uid", type = {OidType.class}, order=2, min=1, max=1, modifier=false, summary=true) 875 @Description(shortDefinition="Formal identifier for this instance", formalDefinition="Formal identifier for this image or other content." ) 876 protected OidType uid; 877 878 /** 879 * DICOM instance type. 880 */ 881 @Child(name = "sopClass", type = {OidType.class}, order=3, min=1, max=1, modifier=false, summary=true) 882 @Description(shortDefinition="DICOM class type", formalDefinition="DICOM instance type." ) 883 protected OidType sopClass; 884 885 /** 886 * A human-friendly SOP Class name. 887 */ 888 @Child(name = "type", type = {StringType.class}, order=4, min=0, max=1, modifier=false, summary=true) 889 @Description(shortDefinition="Type of instance (image etc.)", formalDefinition="A human-friendly SOP Class name." ) 890 protected StringType type; 891 892 /** 893 * The description of the instance. 894 */ 895 @Child(name = "title", type = {StringType.class}, order=5, min=0, max=1, modifier=false, summary=true) 896 @Description(shortDefinition="Description of instance", formalDefinition="The description of the instance." ) 897 protected StringType title; 898 899 /** 900 * Content of the instance or a rendering thereof (e.g. a JPEG of an image, or an XML of a structured report). May be represented for example by inline encoding; by a URL reference to a WADO-RS service that makes the instance available; or to a FHIR Resource (e.g. Media, Document, etc.). Multiple content attachments may be used for alternate representations of the instance. 901 */ 902 @Child(name = "content", type = {Attachment.class}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 903 @Description(shortDefinition="Content of the instance", formalDefinition="Content of the instance or a rendering thereof (e.g. a JPEG of an image, or an XML of a structured report). May be represented for example by inline encoding; by a URL reference to a WADO-RS service that makes the instance available; or to a FHIR Resource (e.g. Media, Document, etc.). Multiple content attachments may be used for alternate representations of the instance." ) 904 protected List<Attachment> content; 905 906 private static final long serialVersionUID = -1450403705L; 907 908 /* 909 * Constructor 910 */ 911 public ImagingStudySeriesInstanceComponent() { 912 super(); 913 } 914 915 /* 916 * Constructor 917 */ 918 public ImagingStudySeriesInstanceComponent(OidType uid, OidType sopClass) { 919 super(); 920 this.uid = uid; 921 this.sopClass = sopClass; 922 } 923 924 /** 925 * @return {@link #number} (The number of instance in the series.). This is the underlying object with id, value and extensions. The accessor "getNumber" gives direct access to the value 926 */ 927 public UnsignedIntType getNumberElement() { 928 if (this.number == null) 929 if (Configuration.errorOnAutoCreate()) 930 throw new Error("Attempt to auto-create ImagingStudySeriesInstanceComponent.number"); 931 else if (Configuration.doAutoCreate()) 932 this.number = new UnsignedIntType(); // bb 933 return this.number; 934 } 935 936 public boolean hasNumberElement() { 937 return this.number != null && !this.number.isEmpty(); 938 } 939 940 public boolean hasNumber() { 941 return this.number != null && !this.number.isEmpty(); 942 } 943 944 /** 945 * @param value {@link #number} (The number of instance in the series.). This is the underlying object with id, value and extensions. The accessor "getNumber" gives direct access to the value 946 */ 947 public ImagingStudySeriesInstanceComponent setNumberElement(UnsignedIntType value) { 948 this.number = value; 949 return this; 950 } 951 952 /** 953 * @return The number of instance in the series. 954 */ 955 public int getNumber() { 956 return this.number == null || this.number.isEmpty() ? 0 : this.number.getValue(); 957 } 958 959 /** 960 * @param value The number of instance in the series. 961 */ 962 public ImagingStudySeriesInstanceComponent setNumber(int value) { 963 if (this.number == null) 964 this.number = new UnsignedIntType(); 965 this.number.setValue(value); 966 return this; 967 } 968 969 /** 970 * @return {@link #uid} (Formal identifier for this image or other content.). This is the underlying object with id, value and extensions. The accessor "getUid" gives direct access to the value 971 */ 972 public OidType getUidElement() { 973 if (this.uid == null) 974 if (Configuration.errorOnAutoCreate()) 975 throw new Error("Attempt to auto-create ImagingStudySeriesInstanceComponent.uid"); 976 else if (Configuration.doAutoCreate()) 977 this.uid = new OidType(); // bb 978 return this.uid; 979 } 980 981 public boolean hasUidElement() { 982 return this.uid != null && !this.uid.isEmpty(); 983 } 984 985 public boolean hasUid() { 986 return this.uid != null && !this.uid.isEmpty(); 987 } 988 989 /** 990 * @param value {@link #uid} (Formal identifier for this image or other content.). This is the underlying object with id, value and extensions. The accessor "getUid" gives direct access to the value 991 */ 992 public ImagingStudySeriesInstanceComponent setUidElement(OidType value) { 993 this.uid = value; 994 return this; 995 } 996 997 /** 998 * @return Formal identifier for this image or other content. 999 */ 1000 public String getUid() { 1001 return this.uid == null ? null : this.uid.getValue(); 1002 } 1003 1004 /** 1005 * @param value Formal identifier for this image or other content. 1006 */ 1007 public ImagingStudySeriesInstanceComponent setUid(String value) { 1008 if (this.uid == null) 1009 this.uid = new OidType(); 1010 this.uid.setValue(value); 1011 return this; 1012 } 1013 1014 /** 1015 * @return {@link #sopClass} (DICOM instance type.). This is the underlying object with id, value and extensions. The accessor "getSopClass" gives direct access to the value 1016 */ 1017 public OidType getSopClassElement() { 1018 if (this.sopClass == null) 1019 if (Configuration.errorOnAutoCreate()) 1020 throw new Error("Attempt to auto-create ImagingStudySeriesInstanceComponent.sopClass"); 1021 else if (Configuration.doAutoCreate()) 1022 this.sopClass = new OidType(); // bb 1023 return this.sopClass; 1024 } 1025 1026 public boolean hasSopClassElement() { 1027 return this.sopClass != null && !this.sopClass.isEmpty(); 1028 } 1029 1030 public boolean hasSopClass() { 1031 return this.sopClass != null && !this.sopClass.isEmpty(); 1032 } 1033 1034 /** 1035 * @param value {@link #sopClass} (DICOM instance type.). This is the underlying object with id, value and extensions. The accessor "getSopClass" gives direct access to the value 1036 */ 1037 public ImagingStudySeriesInstanceComponent setSopClassElement(OidType value) { 1038 this.sopClass = value; 1039 return this; 1040 } 1041 1042 /** 1043 * @return DICOM instance type. 1044 */ 1045 public String getSopClass() { 1046 return this.sopClass == null ? null : this.sopClass.getValue(); 1047 } 1048 1049 /** 1050 * @param value DICOM instance type. 1051 */ 1052 public ImagingStudySeriesInstanceComponent setSopClass(String value) { 1053 if (this.sopClass == null) 1054 this.sopClass = new OidType(); 1055 this.sopClass.setValue(value); 1056 return this; 1057 } 1058 1059 /** 1060 * @return {@link #type} (A human-friendly SOP Class name.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value 1061 */ 1062 public StringType getTypeElement() { 1063 if (this.type == null) 1064 if (Configuration.errorOnAutoCreate()) 1065 throw new Error("Attempt to auto-create ImagingStudySeriesInstanceComponent.type"); 1066 else if (Configuration.doAutoCreate()) 1067 this.type = new StringType(); // bb 1068 return this.type; 1069 } 1070 1071 public boolean hasTypeElement() { 1072 return this.type != null && !this.type.isEmpty(); 1073 } 1074 1075 public boolean hasType() { 1076 return this.type != null && !this.type.isEmpty(); 1077 } 1078 1079 /** 1080 * @param value {@link #type} (A human-friendly SOP Class name.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value 1081 */ 1082 public ImagingStudySeriesInstanceComponent setTypeElement(StringType value) { 1083 this.type = value; 1084 return this; 1085 } 1086 1087 /** 1088 * @return A human-friendly SOP Class name. 1089 */ 1090 public String getType() { 1091 return this.type == null ? null : this.type.getValue(); 1092 } 1093 1094 /** 1095 * @param value A human-friendly SOP Class name. 1096 */ 1097 public ImagingStudySeriesInstanceComponent setType(String value) { 1098 if (Utilities.noString(value)) 1099 this.type = null; 1100 else { 1101 if (this.type == null) 1102 this.type = new StringType(); 1103 this.type.setValue(value); 1104 } 1105 return this; 1106 } 1107 1108 /** 1109 * @return {@link #title} (The description of the instance.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 1110 */ 1111 public StringType getTitleElement() { 1112 if (this.title == null) 1113 if (Configuration.errorOnAutoCreate()) 1114 throw new Error("Attempt to auto-create ImagingStudySeriesInstanceComponent.title"); 1115 else if (Configuration.doAutoCreate()) 1116 this.title = new StringType(); // bb 1117 return this.title; 1118 } 1119 1120 public boolean hasTitleElement() { 1121 return this.title != null && !this.title.isEmpty(); 1122 } 1123 1124 public boolean hasTitle() { 1125 return this.title != null && !this.title.isEmpty(); 1126 } 1127 1128 /** 1129 * @param value {@link #title} (The description of the instance.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 1130 */ 1131 public ImagingStudySeriesInstanceComponent setTitleElement(StringType value) { 1132 this.title = value; 1133 return this; 1134 } 1135 1136 /** 1137 * @return The description of the instance. 1138 */ 1139 public String getTitle() { 1140 return this.title == null ? null : this.title.getValue(); 1141 } 1142 1143 /** 1144 * @param value The description of the instance. 1145 */ 1146 public ImagingStudySeriesInstanceComponent setTitle(String value) { 1147 if (Utilities.noString(value)) 1148 this.title = null; 1149 else { 1150 if (this.title == null) 1151 this.title = new StringType(); 1152 this.title.setValue(value); 1153 } 1154 return this; 1155 } 1156 1157 /** 1158 * @return {@link #content} (Content of the instance or a rendering thereof (e.g. a JPEG of an image, or an XML of a structured report). May be represented for example by inline encoding; by a URL reference to a WADO-RS service that makes the instance available; or to a FHIR Resource (e.g. Media, Document, etc.). Multiple content attachments may be used for alternate representations of the instance.) 1159 */ 1160 public List<Attachment> getContent() { 1161 if (this.content == null) 1162 this.content = new ArrayList<Attachment>(); 1163 return this.content; 1164 } 1165 1166 public boolean hasContent() { 1167 if (this.content == null) 1168 return false; 1169 for (Attachment item : this.content) 1170 if (!item.isEmpty()) 1171 return true; 1172 return false; 1173 } 1174 1175 /** 1176 * @return {@link #content} (Content of the instance or a rendering thereof (e.g. a JPEG of an image, or an XML of a structured report). May be represented for example by inline encoding; by a URL reference to a WADO-RS service that makes the instance available; or to a FHIR Resource (e.g. Media, Document, etc.). Multiple content attachments may be used for alternate representations of the instance.) 1177 */ 1178 // syntactic sugar 1179 public Attachment addContent() { //3 1180 Attachment t = new Attachment(); 1181 if (this.content == null) 1182 this.content = new ArrayList<Attachment>(); 1183 this.content.add(t); 1184 return t; 1185 } 1186 1187 // syntactic sugar 1188 public ImagingStudySeriesInstanceComponent addContent(Attachment t) { //3 1189 if (t == null) 1190 return this; 1191 if (this.content == null) 1192 this.content = new ArrayList<Attachment>(); 1193 this.content.add(t); 1194 return this; 1195 } 1196 1197 protected void listChildren(List<Property> childrenList) { 1198 super.listChildren(childrenList); 1199 childrenList.add(new Property("number", "unsignedInt", "The number of instance in the series.", 0, java.lang.Integer.MAX_VALUE, number)); 1200 childrenList.add(new Property("uid", "oid", "Formal identifier for this image or other content.", 0, java.lang.Integer.MAX_VALUE, uid)); 1201 childrenList.add(new Property("sopClass", "oid", "DICOM instance type.", 0, java.lang.Integer.MAX_VALUE, sopClass)); 1202 childrenList.add(new Property("type", "string", "A human-friendly SOP Class name.", 0, java.lang.Integer.MAX_VALUE, type)); 1203 childrenList.add(new Property("title", "string", "The description of the instance.", 0, java.lang.Integer.MAX_VALUE, title)); 1204 childrenList.add(new Property("content", "Attachment", "Content of the instance or a rendering thereof (e.g. a JPEG of an image, or an XML of a structured report). May be represented for example by inline encoding; by a URL reference to a WADO-RS service that makes the instance available; or to a FHIR Resource (e.g. Media, Document, etc.). Multiple content attachments may be used for alternate representations of the instance.", 0, java.lang.Integer.MAX_VALUE, content)); 1205 } 1206 1207 @Override 1208 public void setProperty(String name, Base value) throws FHIRException { 1209 if (name.equals("number")) 1210 this.number = castToUnsignedInt(value); // UnsignedIntType 1211 else if (name.equals("uid")) 1212 this.uid = castToOid(value); // OidType 1213 else if (name.equals("sopClass")) 1214 this.sopClass = castToOid(value); // OidType 1215 else if (name.equals("type")) 1216 this.type = castToString(value); // StringType 1217 else if (name.equals("title")) 1218 this.title = castToString(value); // StringType 1219 else if (name.equals("content")) 1220 this.getContent().add(castToAttachment(value)); 1221 else 1222 super.setProperty(name, value); 1223 } 1224 1225 @Override 1226 public Base addChild(String name) throws FHIRException { 1227 if (name.equals("number")) { 1228 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.number"); 1229 } 1230 else if (name.equals("uid")) { 1231 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.uid"); 1232 } 1233 else if (name.equals("sopClass")) { 1234 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.sopClass"); 1235 } 1236 else if (name.equals("type")) { 1237 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.type"); 1238 } 1239 else if (name.equals("title")) { 1240 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.title"); 1241 } 1242 else if (name.equals("content")) { 1243 return addContent(); 1244 } 1245 else 1246 return super.addChild(name); 1247 } 1248 1249 public ImagingStudySeriesInstanceComponent copy() { 1250 ImagingStudySeriesInstanceComponent dst = new ImagingStudySeriesInstanceComponent(); 1251 copyValues(dst); 1252 dst.number = number == null ? null : number.copy(); 1253 dst.uid = uid == null ? null : uid.copy(); 1254 dst.sopClass = sopClass == null ? null : sopClass.copy(); 1255 dst.type = type == null ? null : type.copy(); 1256 dst.title = title == null ? null : title.copy(); 1257 if (content != null) { 1258 dst.content = new ArrayList<Attachment>(); 1259 for (Attachment i : content) 1260 dst.content.add(i.copy()); 1261 }; 1262 return dst; 1263 } 1264 1265 @Override 1266 public boolean equalsDeep(Base other) { 1267 if (!super.equalsDeep(other)) 1268 return false; 1269 if (!(other instanceof ImagingStudySeriesInstanceComponent)) 1270 return false; 1271 ImagingStudySeriesInstanceComponent o = (ImagingStudySeriesInstanceComponent) other; 1272 return compareDeep(number, o.number, true) && compareDeep(uid, o.uid, true) && compareDeep(sopClass, o.sopClass, true) 1273 && compareDeep(type, o.type, true) && compareDeep(title, o.title, true) && compareDeep(content, o.content, true) 1274 ; 1275 } 1276 1277 @Override 1278 public boolean equalsShallow(Base other) { 1279 if (!super.equalsShallow(other)) 1280 return false; 1281 if (!(other instanceof ImagingStudySeriesInstanceComponent)) 1282 return false; 1283 ImagingStudySeriesInstanceComponent o = (ImagingStudySeriesInstanceComponent) other; 1284 return compareValues(number, o.number, true) && compareValues(uid, o.uid, true) && compareValues(sopClass, o.sopClass, true) 1285 && compareValues(type, o.type, true) && compareValues(title, o.title, true); 1286 } 1287 1288 public boolean isEmpty() { 1289 return super.isEmpty() && (number == null || number.isEmpty()) && (uid == null || uid.isEmpty()) 1290 && (sopClass == null || sopClass.isEmpty()) && (type == null || type.isEmpty()) && (title == null || title.isEmpty()) 1291 && (content == null || content.isEmpty()); 1292 } 1293 1294 public String fhirType() { 1295 return "ImagingStudy.series.instance"; 1296 1297 } 1298 1299 } 1300 1301 /** 1302 * Date and Time the study started. 1303 */ 1304 @Child(name = "started", type = {DateTimeType.class}, order=0, min=0, max=1, modifier=false, summary=true) 1305 @Description(shortDefinition="When the study was started", formalDefinition="Date and Time the study started." ) 1306 protected DateTimeType started; 1307 1308 /** 1309 * The patient imaged in the study. 1310 */ 1311 @Child(name = "patient", type = {Patient.class}, order=1, min=1, max=1, modifier=false, summary=true) 1312 @Description(shortDefinition="Who the images are of", formalDefinition="The patient imaged in the study." ) 1313 protected Reference patient; 1314 1315 /** 1316 * The actual object that is the target of the reference (The patient imaged in the study.) 1317 */ 1318 protected Patient patientTarget; 1319 1320 /** 1321 * Formal identifier for the study. 1322 */ 1323 @Child(name = "uid", type = {OidType.class}, order=2, min=1, max=1, modifier=false, summary=true) 1324 @Description(shortDefinition="Formal identifier for the study", formalDefinition="Formal identifier for the study." ) 1325 protected OidType uid; 1326 1327 /** 1328 * Accession Number is an identifier related to some aspect of imaging workflow and data management. Usage may vary across different institutions. See for instance [IHE Radiology Technical Framework Volume 1 Appendix A](http://www.ihe.net/uploadedFiles/Documents/Radiology/IHE_RAD_TF_Rev13.0_Vol1_FT_2014-07-30.pdf). 1329 */ 1330 @Child(name = "accession", type = {Identifier.class}, order=3, min=0, max=1, modifier=false, summary=true) 1331 @Description(shortDefinition="Related workflow identifier (\"Accession Number\")", formalDefinition="Accession Number is an identifier related to some aspect of imaging workflow and data management. Usage may vary across different institutions. See for instance [IHE Radiology Technical Framework Volume 1 Appendix A](http://www.ihe.net/uploadedFiles/Documents/Radiology/IHE_RAD_TF_Rev13.0_Vol1_FT_2014-07-30.pdf)." ) 1332 protected Identifier accession; 1333 1334 /** 1335 * Other identifiers for the study. 1336 */ 1337 @Child(name = "identifier", type = {Identifier.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1338 @Description(shortDefinition="Other identifiers for the study", formalDefinition="Other identifiers for the study." ) 1339 protected List<Identifier> identifier; 1340 1341 /** 1342 * A list of the diagnostic orders that resulted in this imaging study being performed. 1343 */ 1344 @Child(name = "order", type = {DiagnosticOrder.class}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1345 @Description(shortDefinition="Order(s) that caused this study to be performed", formalDefinition="A list of the diagnostic orders that resulted in this imaging study being performed." ) 1346 protected List<Reference> order; 1347 /** 1348 * The actual objects that are the target of the reference (A list of the diagnostic orders that resulted in this imaging study being performed.) 1349 */ 1350 protected List<DiagnosticOrder> orderTarget; 1351 1352 1353 /** 1354 * A list of all the Series.ImageModality values that are actual acquisition modalities, i.e. those in the DICOM Context Group 29 (value set OID 1.2.840.10008.6.1.19). 1355 */ 1356 @Child(name = "modalityList", type = {Coding.class}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1357 @Description(shortDefinition="All series modality if actual acquisition modalities", formalDefinition="A list of all the Series.ImageModality values that are actual acquisition modalities, i.e. those in the DICOM Context Group 29 (value set OID 1.2.840.10008.6.1.19)." ) 1358 protected List<Coding> modalityList; 1359 1360 /** 1361 * The requesting/referring physician. 1362 */ 1363 @Child(name = "referrer", type = {Practitioner.class}, order=7, min=0, max=1, modifier=false, summary=true) 1364 @Description(shortDefinition="Referring physician (0008,0090)", formalDefinition="The requesting/referring physician." ) 1365 protected Reference referrer; 1366 1367 /** 1368 * The actual object that is the target of the reference (The requesting/referring physician.) 1369 */ 1370 protected Practitioner referrerTarget; 1371 1372 /** 1373 * Availability of study (online, offline or nearline). 1374 */ 1375 @Child(name = "availability", type = {CodeType.class}, order=8, min=0, max=1, modifier=false, summary=true) 1376 @Description(shortDefinition="ONLINE | OFFLINE | NEARLINE | UNAVAILABLE (0008,0056)", formalDefinition="Availability of study (online, offline or nearline)." ) 1377 protected Enumeration<InstanceAvailability> availability; 1378 1379 /** 1380 * WADO-RS resource where Study is available. 1381 */ 1382 @Child(name = "url", type = {UriType.class}, order=9, min=0, max=1, modifier=false, summary=true) 1383 @Description(shortDefinition="Retrieve URI", formalDefinition="WADO-RS resource where Study is available." ) 1384 protected UriType url; 1385 1386 /** 1387 * Number of Series in Study. 1388 */ 1389 @Child(name = "numberOfSeries", type = {UnsignedIntType.class}, order=10, min=1, max=1, modifier=false, summary=true) 1390 @Description(shortDefinition="Number of Study Related Series", formalDefinition="Number of Series in Study." ) 1391 protected UnsignedIntType numberOfSeries; 1392 1393 /** 1394 * Number of SOP Instances in Study. 1395 */ 1396 @Child(name = "numberOfInstances", type = {UnsignedIntType.class}, order=11, min=1, max=1, modifier=false, summary=true) 1397 @Description(shortDefinition="Number of Study Related Instances", formalDefinition="Number of SOP Instances in Study." ) 1398 protected UnsignedIntType numberOfInstances; 1399 1400 /** 1401 * Type of procedure performed. 1402 */ 1403 @Child(name = "procedure", type = {Procedure.class}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1404 @Description(shortDefinition="Type of procedure performed", formalDefinition="Type of procedure performed." ) 1405 protected List<Reference> procedure; 1406 /** 1407 * The actual objects that are the target of the reference (Type of procedure performed.) 1408 */ 1409 protected List<Procedure> procedureTarget; 1410 1411 1412 /** 1413 * Who read the study and interpreted the images or other content. 1414 */ 1415 @Child(name = "interpreter", type = {Practitioner.class}, order=13, min=0, max=1, modifier=false, summary=true) 1416 @Description(shortDefinition="Who interpreted images", formalDefinition="Who read the study and interpreted the images or other content." ) 1417 protected Reference interpreter; 1418 1419 /** 1420 * The actual object that is the target of the reference (Who read the study and interpreted the images or other content.) 1421 */ 1422 protected Practitioner interpreterTarget; 1423 1424 /** 1425 * Institution-generated description or classification of the Study performed. 1426 */ 1427 @Child(name = "description", type = {StringType.class}, order=14, min=0, max=1, modifier=false, summary=true) 1428 @Description(shortDefinition="Institution-generated description", formalDefinition="Institution-generated description or classification of the Study performed." ) 1429 protected StringType description; 1430 1431 /** 1432 * Each study has one or more series of images or other content. 1433 */ 1434 @Child(name = "series", type = {}, order=15, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1435 @Description(shortDefinition="Each study has one or more series of instances", formalDefinition="Each study has one or more series of images or other content." ) 1436 protected List<ImagingStudySeriesComponent> series; 1437 1438 private static final long serialVersionUID = 1895046380L; 1439 1440 /* 1441 * Constructor 1442 */ 1443 public ImagingStudy() { 1444 super(); 1445 } 1446 1447 /* 1448 * Constructor 1449 */ 1450 public ImagingStudy(Reference patient, OidType uid, UnsignedIntType numberOfSeries, UnsignedIntType numberOfInstances) { 1451 super(); 1452 this.patient = patient; 1453 this.uid = uid; 1454 this.numberOfSeries = numberOfSeries; 1455 this.numberOfInstances = numberOfInstances; 1456 } 1457 1458 /** 1459 * @return {@link #started} (Date and Time the study started.). This is the underlying object with id, value and extensions. The accessor "getStarted" gives direct access to the value 1460 */ 1461 public DateTimeType getStartedElement() { 1462 if (this.started == null) 1463 if (Configuration.errorOnAutoCreate()) 1464 throw new Error("Attempt to auto-create ImagingStudy.started"); 1465 else if (Configuration.doAutoCreate()) 1466 this.started = new DateTimeType(); // bb 1467 return this.started; 1468 } 1469 1470 public boolean hasStartedElement() { 1471 return this.started != null && !this.started.isEmpty(); 1472 } 1473 1474 public boolean hasStarted() { 1475 return this.started != null && !this.started.isEmpty(); 1476 } 1477 1478 /** 1479 * @param value {@link #started} (Date and Time the study started.). This is the underlying object with id, value and extensions. The accessor "getStarted" gives direct access to the value 1480 */ 1481 public ImagingStudy setStartedElement(DateTimeType value) { 1482 this.started = value; 1483 return this; 1484 } 1485 1486 /** 1487 * @return Date and Time the study started. 1488 */ 1489 public Date getStarted() { 1490 return this.started == null ? null : this.started.getValue(); 1491 } 1492 1493 /** 1494 * @param value Date and Time the study started. 1495 */ 1496 public ImagingStudy setStarted(Date value) { 1497 if (value == null) 1498 this.started = null; 1499 else { 1500 if (this.started == null) 1501 this.started = new DateTimeType(); 1502 this.started.setValue(value); 1503 } 1504 return this; 1505 } 1506 1507 /** 1508 * @return {@link #patient} (The patient imaged in the study.) 1509 */ 1510 public Reference getPatient() { 1511 if (this.patient == null) 1512 if (Configuration.errorOnAutoCreate()) 1513 throw new Error("Attempt to auto-create ImagingStudy.patient"); 1514 else if (Configuration.doAutoCreate()) 1515 this.patient = new Reference(); // cc 1516 return this.patient; 1517 } 1518 1519 public boolean hasPatient() { 1520 return this.patient != null && !this.patient.isEmpty(); 1521 } 1522 1523 /** 1524 * @param value {@link #patient} (The patient imaged in the study.) 1525 */ 1526 public ImagingStudy setPatient(Reference value) { 1527 this.patient = value; 1528 return this; 1529 } 1530 1531 /** 1532 * @return {@link #patient} 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 patient imaged in the study.) 1533 */ 1534 public Patient getPatientTarget() { 1535 if (this.patientTarget == null) 1536 if (Configuration.errorOnAutoCreate()) 1537 throw new Error("Attempt to auto-create ImagingStudy.patient"); 1538 else if (Configuration.doAutoCreate()) 1539 this.patientTarget = new Patient(); // aa 1540 return this.patientTarget; 1541 } 1542 1543 /** 1544 * @param value {@link #patient} 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 patient imaged in the study.) 1545 */ 1546 public ImagingStudy setPatientTarget(Patient value) { 1547 this.patientTarget = value; 1548 return this; 1549 } 1550 1551 /** 1552 * @return {@link #uid} (Formal identifier for the study.). This is the underlying object with id, value and extensions. The accessor "getUid" gives direct access to the value 1553 */ 1554 public OidType getUidElement() { 1555 if (this.uid == null) 1556 if (Configuration.errorOnAutoCreate()) 1557 throw new Error("Attempt to auto-create ImagingStudy.uid"); 1558 else if (Configuration.doAutoCreate()) 1559 this.uid = new OidType(); // bb 1560 return this.uid; 1561 } 1562 1563 public boolean hasUidElement() { 1564 return this.uid != null && !this.uid.isEmpty(); 1565 } 1566 1567 public boolean hasUid() { 1568 return this.uid != null && !this.uid.isEmpty(); 1569 } 1570 1571 /** 1572 * @param value {@link #uid} (Formal identifier for the study.). This is the underlying object with id, value and extensions. The accessor "getUid" gives direct access to the value 1573 */ 1574 public ImagingStudy setUidElement(OidType value) { 1575 this.uid = value; 1576 return this; 1577 } 1578 1579 /** 1580 * @return Formal identifier for the study. 1581 */ 1582 public String getUid() { 1583 return this.uid == null ? null : this.uid.getValue(); 1584 } 1585 1586 /** 1587 * @param value Formal identifier for the study. 1588 */ 1589 public ImagingStudy setUid(String value) { 1590 if (this.uid == null) 1591 this.uid = new OidType(); 1592 this.uid.setValue(value); 1593 return this; 1594 } 1595 1596 /** 1597 * @return {@link #accession} (Accession Number is an identifier related to some aspect of imaging workflow and data management. Usage may vary across different institutions. See for instance [IHE Radiology Technical Framework Volume 1 Appendix A](http://www.ihe.net/uploadedFiles/Documents/Radiology/IHE_RAD_TF_Rev13.0_Vol1_FT_2014-07-30.pdf).) 1598 */ 1599 public Identifier getAccession() { 1600 if (this.accession == null) 1601 if (Configuration.errorOnAutoCreate()) 1602 throw new Error("Attempt to auto-create ImagingStudy.accession"); 1603 else if (Configuration.doAutoCreate()) 1604 this.accession = new Identifier(); // cc 1605 return this.accession; 1606 } 1607 1608 public boolean hasAccession() { 1609 return this.accession != null && !this.accession.isEmpty(); 1610 } 1611 1612 /** 1613 * @param value {@link #accession} (Accession Number is an identifier related to some aspect of imaging workflow and data management. Usage may vary across different institutions. See for instance [IHE Radiology Technical Framework Volume 1 Appendix A](http://www.ihe.net/uploadedFiles/Documents/Radiology/IHE_RAD_TF_Rev13.0_Vol1_FT_2014-07-30.pdf).) 1614 */ 1615 public ImagingStudy setAccession(Identifier value) { 1616 this.accession = value; 1617 return this; 1618 } 1619 1620 /** 1621 * @return {@link #identifier} (Other identifiers for the study.) 1622 */ 1623 public List<Identifier> getIdentifier() { 1624 if (this.identifier == null) 1625 this.identifier = new ArrayList<Identifier>(); 1626 return this.identifier; 1627 } 1628 1629 public boolean hasIdentifier() { 1630 if (this.identifier == null) 1631 return false; 1632 for (Identifier item : this.identifier) 1633 if (!item.isEmpty()) 1634 return true; 1635 return false; 1636 } 1637 1638 /** 1639 * @return {@link #identifier} (Other identifiers for the study.) 1640 */ 1641 // syntactic sugar 1642 public Identifier addIdentifier() { //3 1643 Identifier t = new Identifier(); 1644 if (this.identifier == null) 1645 this.identifier = new ArrayList<Identifier>(); 1646 this.identifier.add(t); 1647 return t; 1648 } 1649 1650 // syntactic sugar 1651 public ImagingStudy addIdentifier(Identifier t) { //3 1652 if (t == null) 1653 return this; 1654 if (this.identifier == null) 1655 this.identifier = new ArrayList<Identifier>(); 1656 this.identifier.add(t); 1657 return this; 1658 } 1659 1660 /** 1661 * @return {@link #order} (A list of the diagnostic orders that resulted in this imaging study being performed.) 1662 */ 1663 public List<Reference> getOrder() { 1664 if (this.order == null) 1665 this.order = new ArrayList<Reference>(); 1666 return this.order; 1667 } 1668 1669 public boolean hasOrder() { 1670 if (this.order == null) 1671 return false; 1672 for (Reference item : this.order) 1673 if (!item.isEmpty()) 1674 return true; 1675 return false; 1676 } 1677 1678 /** 1679 * @return {@link #order} (A list of the diagnostic orders that resulted in this imaging study being performed.) 1680 */ 1681 // syntactic sugar 1682 public Reference addOrder() { //3 1683 Reference t = new Reference(); 1684 if (this.order == null) 1685 this.order = new ArrayList<Reference>(); 1686 this.order.add(t); 1687 return t; 1688 } 1689 1690 // syntactic sugar 1691 public ImagingStudy addOrder(Reference t) { //3 1692 if (t == null) 1693 return this; 1694 if (this.order == null) 1695 this.order = new ArrayList<Reference>(); 1696 this.order.add(t); 1697 return this; 1698 } 1699 1700 /** 1701 * @return {@link #order} (The actual objects that are the target of the reference. The reference library doesn't populate this, but you can use this to hold the resources if you resolvethemt. A list of the diagnostic orders that resulted in this imaging study being performed.) 1702 */ 1703 public List<DiagnosticOrder> getOrderTarget() { 1704 if (this.orderTarget == null) 1705 this.orderTarget = new ArrayList<DiagnosticOrder>(); 1706 return this.orderTarget; 1707 } 1708 1709 // syntactic sugar 1710 /** 1711 * @return {@link #order} (Add an actual object that is the target of the reference. The reference library doesn't use these, but you can use this to hold the resources if you resolvethemt. A list of the diagnostic orders that resulted in this imaging study being performed.) 1712 */ 1713 public DiagnosticOrder addOrderTarget() { 1714 DiagnosticOrder r = new DiagnosticOrder(); 1715 if (this.orderTarget == null) 1716 this.orderTarget = new ArrayList<DiagnosticOrder>(); 1717 this.orderTarget.add(r); 1718 return r; 1719 } 1720 1721 /** 1722 * @return {@link #modalityList} (A list of all the Series.ImageModality values that are actual acquisition modalities, i.e. those in the DICOM Context Group 29 (value set OID 1.2.840.10008.6.1.19).) 1723 */ 1724 public List<Coding> getModalityList() { 1725 if (this.modalityList == null) 1726 this.modalityList = new ArrayList<Coding>(); 1727 return this.modalityList; 1728 } 1729 1730 public boolean hasModalityList() { 1731 if (this.modalityList == null) 1732 return false; 1733 for (Coding item : this.modalityList) 1734 if (!item.isEmpty()) 1735 return true; 1736 return false; 1737 } 1738 1739 /** 1740 * @return {@link #modalityList} (A list of all the Series.ImageModality values that are actual acquisition modalities, i.e. those in the DICOM Context Group 29 (value set OID 1.2.840.10008.6.1.19).) 1741 */ 1742 // syntactic sugar 1743 public Coding addModalityList() { //3 1744 Coding t = new Coding(); 1745 if (this.modalityList == null) 1746 this.modalityList = new ArrayList<Coding>(); 1747 this.modalityList.add(t); 1748 return t; 1749 } 1750 1751 // syntactic sugar 1752 public ImagingStudy addModalityList(Coding t) { //3 1753 if (t == null) 1754 return this; 1755 if (this.modalityList == null) 1756 this.modalityList = new ArrayList<Coding>(); 1757 this.modalityList.add(t); 1758 return this; 1759 } 1760 1761 /** 1762 * @return {@link #referrer} (The requesting/referring physician.) 1763 */ 1764 public Reference getReferrer() { 1765 if (this.referrer == null) 1766 if (Configuration.errorOnAutoCreate()) 1767 throw new Error("Attempt to auto-create ImagingStudy.referrer"); 1768 else if (Configuration.doAutoCreate()) 1769 this.referrer = new Reference(); // cc 1770 return this.referrer; 1771 } 1772 1773 public boolean hasReferrer() { 1774 return this.referrer != null && !this.referrer.isEmpty(); 1775 } 1776 1777 /** 1778 * @param value {@link #referrer} (The requesting/referring physician.) 1779 */ 1780 public ImagingStudy setReferrer(Reference value) { 1781 this.referrer = value; 1782 return this; 1783 } 1784 1785 /** 1786 * @return {@link #referrer} 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 requesting/referring physician.) 1787 */ 1788 public Practitioner getReferrerTarget() { 1789 if (this.referrerTarget == null) 1790 if (Configuration.errorOnAutoCreate()) 1791 throw new Error("Attempt to auto-create ImagingStudy.referrer"); 1792 else if (Configuration.doAutoCreate()) 1793 this.referrerTarget = new Practitioner(); // aa 1794 return this.referrerTarget; 1795 } 1796 1797 /** 1798 * @param value {@link #referrer} 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 requesting/referring physician.) 1799 */ 1800 public ImagingStudy setReferrerTarget(Practitioner value) { 1801 this.referrerTarget = value; 1802 return this; 1803 } 1804 1805 /** 1806 * @return {@link #availability} (Availability of study (online, offline or nearline).). This is the underlying object with id, value and extensions. The accessor "getAvailability" gives direct access to the value 1807 */ 1808 public Enumeration<InstanceAvailability> getAvailabilityElement() { 1809 if (this.availability == null) 1810 if (Configuration.errorOnAutoCreate()) 1811 throw new Error("Attempt to auto-create ImagingStudy.availability"); 1812 else if (Configuration.doAutoCreate()) 1813 this.availability = new Enumeration<InstanceAvailability>(new InstanceAvailabilityEnumFactory()); // bb 1814 return this.availability; 1815 } 1816 1817 public boolean hasAvailabilityElement() { 1818 return this.availability != null && !this.availability.isEmpty(); 1819 } 1820 1821 public boolean hasAvailability() { 1822 return this.availability != null && !this.availability.isEmpty(); 1823 } 1824 1825 /** 1826 * @param value {@link #availability} (Availability of study (online, offline or nearline).). This is the underlying object with id, value and extensions. The accessor "getAvailability" gives direct access to the value 1827 */ 1828 public ImagingStudy setAvailabilityElement(Enumeration<InstanceAvailability> value) { 1829 this.availability = value; 1830 return this; 1831 } 1832 1833 /** 1834 * @return Availability of study (online, offline or nearline). 1835 */ 1836 public InstanceAvailability getAvailability() { 1837 return this.availability == null ? null : this.availability.getValue(); 1838 } 1839 1840 /** 1841 * @param value Availability of study (online, offline or nearline). 1842 */ 1843 public ImagingStudy setAvailability(InstanceAvailability value) { 1844 if (value == null) 1845 this.availability = null; 1846 else { 1847 if (this.availability == null) 1848 this.availability = new Enumeration<InstanceAvailability>(new InstanceAvailabilityEnumFactory()); 1849 this.availability.setValue(value); 1850 } 1851 return this; 1852 } 1853 1854 /** 1855 * @return {@link #url} (WADO-RS resource where Study is available.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 1856 */ 1857 public UriType getUrlElement() { 1858 if (this.url == null) 1859 if (Configuration.errorOnAutoCreate()) 1860 throw new Error("Attempt to auto-create ImagingStudy.url"); 1861 else if (Configuration.doAutoCreate()) 1862 this.url = new UriType(); // bb 1863 return this.url; 1864 } 1865 1866 public boolean hasUrlElement() { 1867 return this.url != null && !this.url.isEmpty(); 1868 } 1869 1870 public boolean hasUrl() { 1871 return this.url != null && !this.url.isEmpty(); 1872 } 1873 1874 /** 1875 * @param value {@link #url} (WADO-RS resource where Study is available.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 1876 */ 1877 public ImagingStudy setUrlElement(UriType value) { 1878 this.url = value; 1879 return this; 1880 } 1881 1882 /** 1883 * @return WADO-RS resource where Study is available. 1884 */ 1885 public String getUrl() { 1886 return this.url == null ? null : this.url.getValue(); 1887 } 1888 1889 /** 1890 * @param value WADO-RS resource where Study is available. 1891 */ 1892 public ImagingStudy setUrl(String value) { 1893 if (Utilities.noString(value)) 1894 this.url = null; 1895 else { 1896 if (this.url == null) 1897 this.url = new UriType(); 1898 this.url.setValue(value); 1899 } 1900 return this; 1901 } 1902 1903 /** 1904 * @return {@link #numberOfSeries} (Number of Series in Study.). This is the underlying object with id, value and extensions. The accessor "getNumberOfSeries" gives direct access to the value 1905 */ 1906 public UnsignedIntType getNumberOfSeriesElement() { 1907 if (this.numberOfSeries == null) 1908 if (Configuration.errorOnAutoCreate()) 1909 throw new Error("Attempt to auto-create ImagingStudy.numberOfSeries"); 1910 else if (Configuration.doAutoCreate()) 1911 this.numberOfSeries = new UnsignedIntType(); // bb 1912 return this.numberOfSeries; 1913 } 1914 1915 public boolean hasNumberOfSeriesElement() { 1916 return this.numberOfSeries != null && !this.numberOfSeries.isEmpty(); 1917 } 1918 1919 public boolean hasNumberOfSeries() { 1920 return this.numberOfSeries != null && !this.numberOfSeries.isEmpty(); 1921 } 1922 1923 /** 1924 * @param value {@link #numberOfSeries} (Number of Series in Study.). This is the underlying object with id, value and extensions. The accessor "getNumberOfSeries" gives direct access to the value 1925 */ 1926 public ImagingStudy setNumberOfSeriesElement(UnsignedIntType value) { 1927 this.numberOfSeries = value; 1928 return this; 1929 } 1930 1931 /** 1932 * @return Number of Series in Study. 1933 */ 1934 public int getNumberOfSeries() { 1935 return this.numberOfSeries == null || this.numberOfSeries.isEmpty() ? 0 : this.numberOfSeries.getValue(); 1936 } 1937 1938 /** 1939 * @param value Number of Series in Study. 1940 */ 1941 public ImagingStudy setNumberOfSeries(int value) { 1942 if (this.numberOfSeries == null) 1943 this.numberOfSeries = new UnsignedIntType(); 1944 this.numberOfSeries.setValue(value); 1945 return this; 1946 } 1947 1948 /** 1949 * @return {@link #numberOfInstances} (Number of SOP Instances in Study.). This is the underlying object with id, value and extensions. The accessor "getNumberOfInstances" gives direct access to the value 1950 */ 1951 public UnsignedIntType getNumberOfInstancesElement() { 1952 if (this.numberOfInstances == null) 1953 if (Configuration.errorOnAutoCreate()) 1954 throw new Error("Attempt to auto-create ImagingStudy.numberOfInstances"); 1955 else if (Configuration.doAutoCreate()) 1956 this.numberOfInstances = new UnsignedIntType(); // bb 1957 return this.numberOfInstances; 1958 } 1959 1960 public boolean hasNumberOfInstancesElement() { 1961 return this.numberOfInstances != null && !this.numberOfInstances.isEmpty(); 1962 } 1963 1964 public boolean hasNumberOfInstances() { 1965 return this.numberOfInstances != null && !this.numberOfInstances.isEmpty(); 1966 } 1967 1968 /** 1969 * @param value {@link #numberOfInstances} (Number of SOP Instances in Study.). This is the underlying object with id, value and extensions. The accessor "getNumberOfInstances" gives direct access to the value 1970 */ 1971 public ImagingStudy setNumberOfInstancesElement(UnsignedIntType value) { 1972 this.numberOfInstances = value; 1973 return this; 1974 } 1975 1976 /** 1977 * @return Number of SOP Instances in Study. 1978 */ 1979 public int getNumberOfInstances() { 1980 return this.numberOfInstances == null || this.numberOfInstances.isEmpty() ? 0 : this.numberOfInstances.getValue(); 1981 } 1982 1983 /** 1984 * @param value Number of SOP Instances in Study. 1985 */ 1986 public ImagingStudy setNumberOfInstances(int value) { 1987 if (this.numberOfInstances == null) 1988 this.numberOfInstances = new UnsignedIntType(); 1989 this.numberOfInstances.setValue(value); 1990 return this; 1991 } 1992 1993 /** 1994 * @return {@link #procedure} (Type of procedure performed.) 1995 */ 1996 public List<Reference> getProcedure() { 1997 if (this.procedure == null) 1998 this.procedure = new ArrayList<Reference>(); 1999 return this.procedure; 2000 } 2001 2002 public boolean hasProcedure() { 2003 if (this.procedure == null) 2004 return false; 2005 for (Reference item : this.procedure) 2006 if (!item.isEmpty()) 2007 return true; 2008 return false; 2009 } 2010 2011 /** 2012 * @return {@link #procedure} (Type of procedure performed.) 2013 */ 2014 // syntactic sugar 2015 public Reference addProcedure() { //3 2016 Reference t = new Reference(); 2017 if (this.procedure == null) 2018 this.procedure = new ArrayList<Reference>(); 2019 this.procedure.add(t); 2020 return t; 2021 } 2022 2023 // syntactic sugar 2024 public ImagingStudy addProcedure(Reference t) { //3 2025 if (t == null) 2026 return this; 2027 if (this.procedure == null) 2028 this.procedure = new ArrayList<Reference>(); 2029 this.procedure.add(t); 2030 return this; 2031 } 2032 2033 /** 2034 * @return {@link #procedure} (The actual objects that are the target of the reference. The reference library doesn't populate this, but you can use this to hold the resources if you resolvethemt. Type of procedure performed.) 2035 */ 2036 public List<Procedure> getProcedureTarget() { 2037 if (this.procedureTarget == null) 2038 this.procedureTarget = new ArrayList<Procedure>(); 2039 return this.procedureTarget; 2040 } 2041 2042 // syntactic sugar 2043 /** 2044 * @return {@link #procedure} (Add an actual object that is the target of the reference. The reference library doesn't use these, but you can use this to hold the resources if you resolvethemt. Type of procedure performed.) 2045 */ 2046 public Procedure addProcedureTarget() { 2047 Procedure r = new Procedure(); 2048 if (this.procedureTarget == null) 2049 this.procedureTarget = new ArrayList<Procedure>(); 2050 this.procedureTarget.add(r); 2051 return r; 2052 } 2053 2054 /** 2055 * @return {@link #interpreter} (Who read the study and interpreted the images or other content.) 2056 */ 2057 public Reference getInterpreter() { 2058 if (this.interpreter == null) 2059 if (Configuration.errorOnAutoCreate()) 2060 throw new Error("Attempt to auto-create ImagingStudy.interpreter"); 2061 else if (Configuration.doAutoCreate()) 2062 this.interpreter = new Reference(); // cc 2063 return this.interpreter; 2064 } 2065 2066 public boolean hasInterpreter() { 2067 return this.interpreter != null && !this.interpreter.isEmpty(); 2068 } 2069 2070 /** 2071 * @param value {@link #interpreter} (Who read the study and interpreted the images or other content.) 2072 */ 2073 public ImagingStudy setInterpreter(Reference value) { 2074 this.interpreter = value; 2075 return this; 2076 } 2077 2078 /** 2079 * @return {@link #interpreter} 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. (Who read the study and interpreted the images or other content.) 2080 */ 2081 public Practitioner getInterpreterTarget() { 2082 if (this.interpreterTarget == null) 2083 if (Configuration.errorOnAutoCreate()) 2084 throw new Error("Attempt to auto-create ImagingStudy.interpreter"); 2085 else if (Configuration.doAutoCreate()) 2086 this.interpreterTarget = new Practitioner(); // aa 2087 return this.interpreterTarget; 2088 } 2089 2090 /** 2091 * @param value {@link #interpreter} 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. (Who read the study and interpreted the images or other content.) 2092 */ 2093 public ImagingStudy setInterpreterTarget(Practitioner value) { 2094 this.interpreterTarget = value; 2095 return this; 2096 } 2097 2098 /** 2099 * @return {@link #description} (Institution-generated description or classification of the Study performed.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 2100 */ 2101 public StringType getDescriptionElement() { 2102 if (this.description == null) 2103 if (Configuration.errorOnAutoCreate()) 2104 throw new Error("Attempt to auto-create ImagingStudy.description"); 2105 else if (Configuration.doAutoCreate()) 2106 this.description = new StringType(); // bb 2107 return this.description; 2108 } 2109 2110 public boolean hasDescriptionElement() { 2111 return this.description != null && !this.description.isEmpty(); 2112 } 2113 2114 public boolean hasDescription() { 2115 return this.description != null && !this.description.isEmpty(); 2116 } 2117 2118 /** 2119 * @param value {@link #description} (Institution-generated description or classification of the Study performed.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 2120 */ 2121 public ImagingStudy setDescriptionElement(StringType value) { 2122 this.description = value; 2123 return this; 2124 } 2125 2126 /** 2127 * @return Institution-generated description or classification of the Study performed. 2128 */ 2129 public String getDescription() { 2130 return this.description == null ? null : this.description.getValue(); 2131 } 2132 2133 /** 2134 * @param value Institution-generated description or classification of the Study performed. 2135 */ 2136 public ImagingStudy setDescription(String value) { 2137 if (Utilities.noString(value)) 2138 this.description = null; 2139 else { 2140 if (this.description == null) 2141 this.description = new StringType(); 2142 this.description.setValue(value); 2143 } 2144 return this; 2145 } 2146 2147 /** 2148 * @return {@link #series} (Each study has one or more series of images or other content.) 2149 */ 2150 public List<ImagingStudySeriesComponent> getSeries() { 2151 if (this.series == null) 2152 this.series = new ArrayList<ImagingStudySeriesComponent>(); 2153 return this.series; 2154 } 2155 2156 public boolean hasSeries() { 2157 if (this.series == null) 2158 return false; 2159 for (ImagingStudySeriesComponent item : this.series) 2160 if (!item.isEmpty()) 2161 return true; 2162 return false; 2163 } 2164 2165 /** 2166 * @return {@link #series} (Each study has one or more series of images or other content.) 2167 */ 2168 // syntactic sugar 2169 public ImagingStudySeriesComponent addSeries() { //3 2170 ImagingStudySeriesComponent t = new ImagingStudySeriesComponent(); 2171 if (this.series == null) 2172 this.series = new ArrayList<ImagingStudySeriesComponent>(); 2173 this.series.add(t); 2174 return t; 2175 } 2176 2177 // syntactic sugar 2178 public ImagingStudy addSeries(ImagingStudySeriesComponent t) { //3 2179 if (t == null) 2180 return this; 2181 if (this.series == null) 2182 this.series = new ArrayList<ImagingStudySeriesComponent>(); 2183 this.series.add(t); 2184 return this; 2185 } 2186 2187 protected void listChildren(List<Property> childrenList) { 2188 super.listChildren(childrenList); 2189 childrenList.add(new Property("started", "dateTime", "Date and Time the study started.", 0, java.lang.Integer.MAX_VALUE, started)); 2190 childrenList.add(new Property("patient", "Reference(Patient)", "The patient imaged in the study.", 0, java.lang.Integer.MAX_VALUE, patient)); 2191 childrenList.add(new Property("uid", "oid", "Formal identifier for the study.", 0, java.lang.Integer.MAX_VALUE, uid)); 2192 childrenList.add(new Property("accession", "Identifier", "Accession Number is an identifier related to some aspect of imaging workflow and data management. Usage may vary across different institutions. See for instance [IHE Radiology Technical Framework Volume 1 Appendix A](http://www.ihe.net/uploadedFiles/Documents/Radiology/IHE_RAD_TF_Rev13.0_Vol1_FT_2014-07-30.pdf).", 0, java.lang.Integer.MAX_VALUE, accession)); 2193 childrenList.add(new Property("identifier", "Identifier", "Other identifiers for the study.", 0, java.lang.Integer.MAX_VALUE, identifier)); 2194 childrenList.add(new Property("order", "Reference(DiagnosticOrder)", "A list of the diagnostic orders that resulted in this imaging study being performed.", 0, java.lang.Integer.MAX_VALUE, order)); 2195 childrenList.add(new Property("modalityList", "Coding", "A list of all the Series.ImageModality values that are actual acquisition modalities, i.e. those in the DICOM Context Group 29 (value set OID 1.2.840.10008.6.1.19).", 0, java.lang.Integer.MAX_VALUE, modalityList)); 2196 childrenList.add(new Property("referrer", "Reference(Practitioner)", "The requesting/referring physician.", 0, java.lang.Integer.MAX_VALUE, referrer)); 2197 childrenList.add(new Property("availability", "code", "Availability of study (online, offline or nearline).", 0, java.lang.Integer.MAX_VALUE, availability)); 2198 childrenList.add(new Property("url", "uri", "WADO-RS resource where Study is available.", 0, java.lang.Integer.MAX_VALUE, url)); 2199 childrenList.add(new Property("numberOfSeries", "unsignedInt", "Number of Series in Study.", 0, java.lang.Integer.MAX_VALUE, numberOfSeries)); 2200 childrenList.add(new Property("numberOfInstances", "unsignedInt", "Number of SOP Instances in Study.", 0, java.lang.Integer.MAX_VALUE, numberOfInstances)); 2201 childrenList.add(new Property("procedure", "Reference(Procedure)", "Type of procedure performed.", 0, java.lang.Integer.MAX_VALUE, procedure)); 2202 childrenList.add(new Property("interpreter", "Reference(Practitioner)", "Who read the study and interpreted the images or other content.", 0, java.lang.Integer.MAX_VALUE, interpreter)); 2203 childrenList.add(new Property("description", "string", "Institution-generated description or classification of the Study performed.", 0, java.lang.Integer.MAX_VALUE, description)); 2204 childrenList.add(new Property("series", "", "Each study has one or more series of images or other content.", 0, java.lang.Integer.MAX_VALUE, series)); 2205 } 2206 2207 @Override 2208 public void setProperty(String name, Base value) throws FHIRException { 2209 if (name.equals("started")) 2210 this.started = castToDateTime(value); // DateTimeType 2211 else if (name.equals("patient")) 2212 this.patient = castToReference(value); // Reference 2213 else if (name.equals("uid")) 2214 this.uid = castToOid(value); // OidType 2215 else if (name.equals("accession")) 2216 this.accession = castToIdentifier(value); // Identifier 2217 else if (name.equals("identifier")) 2218 this.getIdentifier().add(castToIdentifier(value)); 2219 else if (name.equals("order")) 2220 this.getOrder().add(castToReference(value)); 2221 else if (name.equals("modalityList")) 2222 this.getModalityList().add(castToCoding(value)); 2223 else if (name.equals("referrer")) 2224 this.referrer = castToReference(value); // Reference 2225 else if (name.equals("availability")) 2226 this.availability = new InstanceAvailabilityEnumFactory().fromType(value); // Enumeration<InstanceAvailability> 2227 else if (name.equals("url")) 2228 this.url = castToUri(value); // UriType 2229 else if (name.equals("numberOfSeries")) 2230 this.numberOfSeries = castToUnsignedInt(value); // UnsignedIntType 2231 else if (name.equals("numberOfInstances")) 2232 this.numberOfInstances = castToUnsignedInt(value); // UnsignedIntType 2233 else if (name.equals("procedure")) 2234 this.getProcedure().add(castToReference(value)); 2235 else if (name.equals("interpreter")) 2236 this.interpreter = castToReference(value); // Reference 2237 else if (name.equals("description")) 2238 this.description = castToString(value); // StringType 2239 else if (name.equals("series")) 2240 this.getSeries().add((ImagingStudySeriesComponent) value); 2241 else 2242 super.setProperty(name, value); 2243 } 2244 2245 @Override 2246 public Base addChild(String name) throws FHIRException { 2247 if (name.equals("started")) { 2248 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.started"); 2249 } 2250 else if (name.equals("patient")) { 2251 this.patient = new Reference(); 2252 return this.patient; 2253 } 2254 else if (name.equals("uid")) { 2255 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.uid"); 2256 } 2257 else if (name.equals("accession")) { 2258 this.accession = new Identifier(); 2259 return this.accession; 2260 } 2261 else if (name.equals("identifier")) { 2262 return addIdentifier(); 2263 } 2264 else if (name.equals("order")) { 2265 return addOrder(); 2266 } 2267 else if (name.equals("modalityList")) { 2268 return addModalityList(); 2269 } 2270 else if (name.equals("referrer")) { 2271 this.referrer = new Reference(); 2272 return this.referrer; 2273 } 2274 else if (name.equals("availability")) { 2275 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.availability"); 2276 } 2277 else if (name.equals("url")) { 2278 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.url"); 2279 } 2280 else if (name.equals("numberOfSeries")) { 2281 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.numberOfSeries"); 2282 } 2283 else if (name.equals("numberOfInstances")) { 2284 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.numberOfInstances"); 2285 } 2286 else if (name.equals("procedure")) { 2287 return addProcedure(); 2288 } 2289 else if (name.equals("interpreter")) { 2290 this.interpreter = new Reference(); 2291 return this.interpreter; 2292 } 2293 else if (name.equals("description")) { 2294 throw new FHIRException("Cannot call addChild on a primitive type ImagingStudy.description"); 2295 } 2296 else if (name.equals("series")) { 2297 return addSeries(); 2298 } 2299 else 2300 return super.addChild(name); 2301 } 2302 2303 public String fhirType() { 2304 return "ImagingStudy"; 2305 2306 } 2307 2308 public ImagingStudy copy() { 2309 ImagingStudy dst = new ImagingStudy(); 2310 copyValues(dst); 2311 dst.started = started == null ? null : started.copy(); 2312 dst.patient = patient == null ? null : patient.copy(); 2313 dst.uid = uid == null ? null : uid.copy(); 2314 dst.accession = accession == null ? null : accession.copy(); 2315 if (identifier != null) { 2316 dst.identifier = new ArrayList<Identifier>(); 2317 for (Identifier i : identifier) 2318 dst.identifier.add(i.copy()); 2319 }; 2320 if (order != null) { 2321 dst.order = new ArrayList<Reference>(); 2322 for (Reference i : order) 2323 dst.order.add(i.copy()); 2324 }; 2325 if (modalityList != null) { 2326 dst.modalityList = new ArrayList<Coding>(); 2327 for (Coding i : modalityList) 2328 dst.modalityList.add(i.copy()); 2329 }; 2330 dst.referrer = referrer == null ? null : referrer.copy(); 2331 dst.availability = availability == null ? null : availability.copy(); 2332 dst.url = url == null ? null : url.copy(); 2333 dst.numberOfSeries = numberOfSeries == null ? null : numberOfSeries.copy(); 2334 dst.numberOfInstances = numberOfInstances == null ? null : numberOfInstances.copy(); 2335 if (procedure != null) { 2336 dst.procedure = new ArrayList<Reference>(); 2337 for (Reference i : procedure) 2338 dst.procedure.add(i.copy()); 2339 }; 2340 dst.interpreter = interpreter == null ? null : interpreter.copy(); 2341 dst.description = description == null ? null : description.copy(); 2342 if (series != null) { 2343 dst.series = new ArrayList<ImagingStudySeriesComponent>(); 2344 for (ImagingStudySeriesComponent i : series) 2345 dst.series.add(i.copy()); 2346 }; 2347 return dst; 2348 } 2349 2350 protected ImagingStudy typedCopy() { 2351 return copy(); 2352 } 2353 2354 @Override 2355 public boolean equalsDeep(Base other) { 2356 if (!super.equalsDeep(other)) 2357 return false; 2358 if (!(other instanceof ImagingStudy)) 2359 return false; 2360 ImagingStudy o = (ImagingStudy) other; 2361 return compareDeep(started, o.started, true) && compareDeep(patient, o.patient, true) && compareDeep(uid, o.uid, true) 2362 && compareDeep(accession, o.accession, true) && compareDeep(identifier, o.identifier, true) && compareDeep(order, o.order, true) 2363 && compareDeep(modalityList, o.modalityList, true) && compareDeep(referrer, o.referrer, true) && compareDeep(availability, o.availability, true) 2364 && compareDeep(url, o.url, true) && compareDeep(numberOfSeries, o.numberOfSeries, true) && compareDeep(numberOfInstances, o.numberOfInstances, true) 2365 && compareDeep(procedure, o.procedure, true) && compareDeep(interpreter, o.interpreter, true) && compareDeep(description, o.description, true) 2366 && compareDeep(series, o.series, true); 2367 } 2368 2369 @Override 2370 public boolean equalsShallow(Base other) { 2371 if (!super.equalsShallow(other)) 2372 return false; 2373 if (!(other instanceof ImagingStudy)) 2374 return false; 2375 ImagingStudy o = (ImagingStudy) other; 2376 return compareValues(started, o.started, true) && compareValues(uid, o.uid, true) && compareValues(availability, o.availability, true) 2377 && compareValues(url, o.url, true) && compareValues(numberOfSeries, o.numberOfSeries, true) && compareValues(numberOfInstances, o.numberOfInstances, true) 2378 && compareValues(description, o.description, true); 2379 } 2380 2381 public boolean isEmpty() { 2382 return super.isEmpty() && (started == null || started.isEmpty()) && (patient == null || patient.isEmpty()) 2383 && (uid == null || uid.isEmpty()) && (accession == null || accession.isEmpty()) && (identifier == null || identifier.isEmpty()) 2384 && (order == null || order.isEmpty()) && (modalityList == null || modalityList.isEmpty()) 2385 && (referrer == null || referrer.isEmpty()) && (availability == null || availability.isEmpty()) 2386 && (url == null || url.isEmpty()) && (numberOfSeries == null || numberOfSeries.isEmpty()) 2387 && (numberOfInstances == null || numberOfInstances.isEmpty()) && (procedure == null || procedure.isEmpty()) 2388 && (interpreter == null || interpreter.isEmpty()) && (description == null || description.isEmpty()) 2389 && (series == null || series.isEmpty()); 2390 } 2391 2392 @Override 2393 public ResourceType getResourceType() { 2394 return ResourceType.ImagingStudy; 2395 } 2396 2397 @SearchParamDefinition(name="uid", path="ImagingStudy.series.instance.uid", description="The instance unique identifier", type="uri" ) 2398 public static final String SP_UID = "uid"; 2399 @SearchParamDefinition(name="study", path="ImagingStudy.uid", description="The study identifier for the image", type="uri" ) 2400 public static final String SP_STUDY = "study"; 2401 @SearchParamDefinition(name="dicom-class", path="ImagingStudy.series.instance.sopClass", description="The type of the instance", type="uri" ) 2402 public static final String SP_DICOMCLASS = "dicom-class"; 2403 @SearchParamDefinition(name="modality", path="ImagingStudy.series.modality", description="The modality of the series", type="token" ) 2404 public static final String SP_MODALITY = "modality"; 2405 @SearchParamDefinition(name="bodysite", path="ImagingStudy.series.bodySite", description="The body site studied", type="token" ) 2406 public static final String SP_BODYSITE = "bodysite"; 2407 @SearchParamDefinition(name="patient", path="ImagingStudy.patient", description="Who the study is about", type="reference" ) 2408 public static final String SP_PATIENT = "patient"; 2409 @SearchParamDefinition(name="series", path="ImagingStudy.series.uid", description="The identifier of the series of images", type="uri" ) 2410 public static final String SP_SERIES = "series"; 2411 @SearchParamDefinition(name="started", path="ImagingStudy.started", description="When the study was started", type="date" ) 2412 public static final String SP_STARTED = "started"; 2413 @SearchParamDefinition(name="accession", path="ImagingStudy.accession", description="The accession identifier for the study", type="token" ) 2414 public static final String SP_ACCESSION = "accession"; 2415 @SearchParamDefinition(name="order", path="ImagingStudy.order", description="The order for the image", type="reference" ) 2416 public static final String SP_ORDER = "order"; 2417 2418}