001package org.hl7.fhir.r5.model; 002 003 004/* 005 Copyright (c) 2011+, HL7, Inc. 006 All rights reserved. 007 008 Redistribution and use in source and binary forms, with or without modification, \ 009 are permitted provided that the following conditions are met: 010 011 * Redistributions of source code must retain the above copyright notice, this \ 012 list of conditions and the following disclaimer. 013 * Redistributions in binary form must reproduce the above copyright notice, \ 014 this list of conditions and the following disclaimer in the documentation \ 015 and/or other materials provided with the distribution. 016 * Neither the name of HL7 nor the names of its contributors may be used to 017 endorse or promote products derived from this software without specific 018 prior written permission. 019 020 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND \ 021 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \ 022 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \ 023 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \ 024 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT \ 025 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR \ 026 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \ 027 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) \ 028 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE \ 029 POSSIBILITY OF SUCH DAMAGE. 030 */ 031 032// Generated on Tue, Dec 13, 2022 17:53+1100 for FHIR vcurrent 033 034import java.util.ArrayList; 035import java.util.Date; 036import java.util.List; 037import org.hl7.fhir.utilities.Utilities; 038import org.hl7.fhir.r5.model.Enumerations.*; 039import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 040import org.hl7.fhir.exceptions.FHIRException; 041import org.hl7.fhir.instance.model.api.ICompositeType; 042import ca.uhn.fhir.model.api.annotation.ResourceDef; 043import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 044import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 045import ca.uhn.fhir.model.api.annotation.Child; 046import ca.uhn.fhir.model.api.annotation.ChildOrder; 047import ca.uhn.fhir.model.api.annotation.Description; 048import ca.uhn.fhir.model.api.annotation.Block; 049 050/** 051 * A Genomic Study is a set of analysis performed to analyze and generate genomic data. 052 */ 053@ResourceDef(name="GenomicStudy", profile="http://hl7.org/fhir/StructureDefinition/GenomicStudy") 054public class GenomicStudy extends DomainResource { 055 056 @Block() 057 public static class GenomicStudyAnalysisComponent extends BackboneElement implements IBaseBackboneElement { 058 /** 059 * Identifiers for the analysis event. 060 */ 061 @Child(name = "identifier", type = {Identifier.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 062 @Description(shortDefinition="Identifiers for the analysis event", formalDefinition="Identifiers for the analysis event." ) 063 protected List<Identifier> identifier; 064 065 /** 066 * Type of the methods used in the analysis, e.g., Fluorescence in situ hybridization (FISH), Karyotyping, or Microsatellite instability testing (MSI). 067 */ 068 @Child(name = "methodType", type = {CodeableConcept.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 069 @Description(shortDefinition="Type of the methods used in the analysis (e.g., FISH, Karyotyping, MSI)", formalDefinition="Type of the methods used in the analysis, e.g., Fluorescence in situ hybridization (FISH), Karyotyping, or Microsatellite instability testing (MSI)." ) 070 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/genomicstudy-methodtype") 071 protected List<CodeableConcept> methodType; 072 073 /** 074 * Type of the genomic changes studied in the analysis, e.g., DNA, RNA, or amino acid change. 075 */ 076 @Child(name = "changeType", type = {CodeableConcept.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 077 @Description(shortDefinition="Type of the genomic changes studied in the analysis (e.g., DNA, RNA, or AA change)", formalDefinition="Type of the genomic changes studied in the analysis, e.g., DNA, RNA, or amino acid change." ) 078 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/genomicstudy-changetype") 079 protected List<CodeableConcept> changeType; 080 081 /** 082 * The reference genome build that is used in this analysis. 083 */ 084 @Child(name = "genomeBuild", type = {CodeableConcept.class}, order=4, min=0, max=1, modifier=false, summary=false) 085 @Description(shortDefinition="Genome build that is used in this analysis", formalDefinition="The reference genome build that is used in this analysis." ) 086 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://loinc.org/vs/LL1040-6") 087 protected CodeableConcept genomeBuild; 088 089 /** 090 * The defined protocol that describes the analysis. 091 */ 092 @Child(name = "instantiatesCanonical", type = {CanonicalType.class}, order=5, min=0, max=1, modifier=false, summary=false) 093 @Description(shortDefinition="The defined protocol that describes the analysis", formalDefinition="The defined protocol that describes the analysis." ) 094 protected CanonicalType instantiatesCanonical; 095 096 /** 097 * The URL pointing to an externally maintained protocol that describes the analysis. 098 */ 099 @Child(name = "instantiatesUri", type = {UriType.class}, order=6, min=0, max=1, modifier=false, summary=false) 100 @Description(shortDefinition="The URL pointing to an externally maintained protocol that describes the analysis", formalDefinition="The URL pointing to an externally maintained protocol that describes the analysis." ) 101 protected UriType instantiatesUri; 102 103 /** 104 * Name of the analysis event (human friendly). 105 */ 106 @Child(name = "title", type = {StringType.class}, order=7, min=0, max=1, modifier=false, summary=false) 107 @Description(shortDefinition="Name of the analysis event (human friendly)", formalDefinition="Name of the analysis event (human friendly)." ) 108 protected StringType title; 109 110 /** 111 * The subject of the analysis event. 112 */ 113 @Child(name = "subject", type = {Patient.class, Group.class, Device.class, Location.class, Organization.class, Procedure.class, Practitioner.class, Medication.class, Substance.class, BiologicallyDerivedProduct.class, NutritionProduct.class}, order=8, min=0, max=1, modifier=false, summary=false) 114 @Description(shortDefinition="The subject of the analysis event", formalDefinition="The subject of the analysis event." ) 115 protected Reference subject; 116 117 /** 118 * The specimen used in the analysis event. 119 */ 120 @Child(name = "specimen", type = {Specimen.class}, order=9, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 121 @Description(shortDefinition="The specimen used in the analysis event", formalDefinition="The specimen used in the analysis event." ) 122 protected List<Reference> specimen; 123 124 /** 125 * The date of the analysis event. 126 */ 127 @Child(name = "date", type = {DateTimeType.class}, order=10, min=0, max=1, modifier=false, summary=false) 128 @Description(shortDefinition="The date of the analysis event", formalDefinition="The date of the analysis event." ) 129 protected DateTimeType date; 130 131 /** 132 * Any notes capture with the analysis event. 133 */ 134 @Child(name = "note", type = {Annotation.class}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 135 @Description(shortDefinition="Any notes capture with the analysis event", formalDefinition="Any notes capture with the analysis event." ) 136 protected List<Annotation> note; 137 138 /** 139 * The protocol that was performed for the analysis event. 140 */ 141 @Child(name = "protocolPerformed", type = {Procedure.class, Task.class}, order=12, min=0, max=1, modifier=false, summary=false) 142 @Description(shortDefinition="The protocol that was performed for the analysis event", formalDefinition="The protocol that was performed for the analysis event." ) 143 protected Reference protocolPerformed; 144 145 /** 146 * The genomic regions to be studied in the analysis (BED file). 147 */ 148 @Child(name = "regionsStudied", type = {DocumentReference.class, Observation.class}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 149 @Description(shortDefinition="The genomic regions to be studied in the analysis (BED file)", formalDefinition="The genomic regions to be studied in the analysis (BED file)." ) 150 protected List<Reference> regionsStudied; 151 152 /** 153 * Genomic regions actually called in the analysis event (BED file). 154 */ 155 @Child(name = "regionsCalled", type = {DocumentReference.class, Observation.class}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 156 @Description(shortDefinition="Genomic regions actually called in the analysis event (BED file)", formalDefinition="Genomic regions actually called in the analysis event (BED file)." ) 157 protected List<Reference> regionsCalled; 158 159 /** 160 * Inputs for the analysis event. 161 */ 162 @Child(name = "input", type = {}, order=15, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 163 @Description(shortDefinition="Inputs for the analysis event", formalDefinition="Inputs for the analysis event." ) 164 protected List<GenomicStudyAnalysisInputComponent> input; 165 166 /** 167 * Outputs for the analysis event. 168 */ 169 @Child(name = "output", type = {}, order=16, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 170 @Description(shortDefinition="Outputs for the analysis event", formalDefinition="Outputs for the analysis event." ) 171 protected List<GenomicStudyAnalysisOutputComponent> output; 172 173 /** 174 * Performer for the analysis event. 175 */ 176 @Child(name = "performer", type = {}, order=17, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 177 @Description(shortDefinition="Performer for the analysis event", formalDefinition="Performer for the analysis event." ) 178 protected List<GenomicStudyAnalysisPerformerComponent> performer; 179 180 /** 181 * Devices used for the analysis (e.g., instruments, software), with settings and parameters. 182 */ 183 @Child(name = "device", type = {}, order=18, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 184 @Description(shortDefinition="Devices used for the analysis (e.g., instruments, software), with settings and parameters", formalDefinition="Devices used for the analysis (e.g., instruments, software), with settings and parameters." ) 185 protected List<GenomicStudyAnalysisDeviceComponent> device; 186 187 private static final long serialVersionUID = 400268376L; 188 189 /** 190 * Constructor 191 */ 192 public GenomicStudyAnalysisComponent() { 193 super(); 194 } 195 196 /** 197 * @return {@link #identifier} (Identifiers for the analysis event.) 198 */ 199 public List<Identifier> getIdentifier() { 200 if (this.identifier == null) 201 this.identifier = new ArrayList<Identifier>(); 202 return this.identifier; 203 } 204 205 /** 206 * @return Returns a reference to <code>this</code> for easy method chaining 207 */ 208 public GenomicStudyAnalysisComponent setIdentifier(List<Identifier> theIdentifier) { 209 this.identifier = theIdentifier; 210 return this; 211 } 212 213 public boolean hasIdentifier() { 214 if (this.identifier == null) 215 return false; 216 for (Identifier item : this.identifier) 217 if (!item.isEmpty()) 218 return true; 219 return false; 220 } 221 222 public Identifier addIdentifier() { //3 223 Identifier t = new Identifier(); 224 if (this.identifier == null) 225 this.identifier = new ArrayList<Identifier>(); 226 this.identifier.add(t); 227 return t; 228 } 229 230 public GenomicStudyAnalysisComponent addIdentifier(Identifier t) { //3 231 if (t == null) 232 return this; 233 if (this.identifier == null) 234 this.identifier = new ArrayList<Identifier>(); 235 this.identifier.add(t); 236 return this; 237 } 238 239 /** 240 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist {3} 241 */ 242 public Identifier getIdentifierFirstRep() { 243 if (getIdentifier().isEmpty()) { 244 addIdentifier(); 245 } 246 return getIdentifier().get(0); 247 } 248 249 /** 250 * @return {@link #methodType} (Type of the methods used in the analysis, e.g., Fluorescence in situ hybridization (FISH), Karyotyping, or Microsatellite instability testing (MSI).) 251 */ 252 public List<CodeableConcept> getMethodType() { 253 if (this.methodType == null) 254 this.methodType = new ArrayList<CodeableConcept>(); 255 return this.methodType; 256 } 257 258 /** 259 * @return Returns a reference to <code>this</code> for easy method chaining 260 */ 261 public GenomicStudyAnalysisComponent setMethodType(List<CodeableConcept> theMethodType) { 262 this.methodType = theMethodType; 263 return this; 264 } 265 266 public boolean hasMethodType() { 267 if (this.methodType == null) 268 return false; 269 for (CodeableConcept item : this.methodType) 270 if (!item.isEmpty()) 271 return true; 272 return false; 273 } 274 275 public CodeableConcept addMethodType() { //3 276 CodeableConcept t = new CodeableConcept(); 277 if (this.methodType == null) 278 this.methodType = new ArrayList<CodeableConcept>(); 279 this.methodType.add(t); 280 return t; 281 } 282 283 public GenomicStudyAnalysisComponent addMethodType(CodeableConcept t) { //3 284 if (t == null) 285 return this; 286 if (this.methodType == null) 287 this.methodType = new ArrayList<CodeableConcept>(); 288 this.methodType.add(t); 289 return this; 290 } 291 292 /** 293 * @return The first repetition of repeating field {@link #methodType}, creating it if it does not already exist {3} 294 */ 295 public CodeableConcept getMethodTypeFirstRep() { 296 if (getMethodType().isEmpty()) { 297 addMethodType(); 298 } 299 return getMethodType().get(0); 300 } 301 302 /** 303 * @return {@link #changeType} (Type of the genomic changes studied in the analysis, e.g., DNA, RNA, or amino acid change.) 304 */ 305 public List<CodeableConcept> getChangeType() { 306 if (this.changeType == null) 307 this.changeType = new ArrayList<CodeableConcept>(); 308 return this.changeType; 309 } 310 311 /** 312 * @return Returns a reference to <code>this</code> for easy method chaining 313 */ 314 public GenomicStudyAnalysisComponent setChangeType(List<CodeableConcept> theChangeType) { 315 this.changeType = theChangeType; 316 return this; 317 } 318 319 public boolean hasChangeType() { 320 if (this.changeType == null) 321 return false; 322 for (CodeableConcept item : this.changeType) 323 if (!item.isEmpty()) 324 return true; 325 return false; 326 } 327 328 public CodeableConcept addChangeType() { //3 329 CodeableConcept t = new CodeableConcept(); 330 if (this.changeType == null) 331 this.changeType = new ArrayList<CodeableConcept>(); 332 this.changeType.add(t); 333 return t; 334 } 335 336 public GenomicStudyAnalysisComponent addChangeType(CodeableConcept t) { //3 337 if (t == null) 338 return this; 339 if (this.changeType == null) 340 this.changeType = new ArrayList<CodeableConcept>(); 341 this.changeType.add(t); 342 return this; 343 } 344 345 /** 346 * @return The first repetition of repeating field {@link #changeType}, creating it if it does not already exist {3} 347 */ 348 public CodeableConcept getChangeTypeFirstRep() { 349 if (getChangeType().isEmpty()) { 350 addChangeType(); 351 } 352 return getChangeType().get(0); 353 } 354 355 /** 356 * @return {@link #genomeBuild} (The reference genome build that is used in this analysis.) 357 */ 358 public CodeableConcept getGenomeBuild() { 359 if (this.genomeBuild == null) 360 if (Configuration.errorOnAutoCreate()) 361 throw new Error("Attempt to auto-create GenomicStudyAnalysisComponent.genomeBuild"); 362 else if (Configuration.doAutoCreate()) 363 this.genomeBuild = new CodeableConcept(); // cc 364 return this.genomeBuild; 365 } 366 367 public boolean hasGenomeBuild() { 368 return this.genomeBuild != null && !this.genomeBuild.isEmpty(); 369 } 370 371 /** 372 * @param value {@link #genomeBuild} (The reference genome build that is used in this analysis.) 373 */ 374 public GenomicStudyAnalysisComponent setGenomeBuild(CodeableConcept value) { 375 this.genomeBuild = value; 376 return this; 377 } 378 379 /** 380 * @return {@link #instantiatesCanonical} (The defined protocol that describes the analysis.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesCanonical" gives direct access to the value 381 */ 382 public CanonicalType getInstantiatesCanonicalElement() { 383 if (this.instantiatesCanonical == null) 384 if (Configuration.errorOnAutoCreate()) 385 throw new Error("Attempt to auto-create GenomicStudyAnalysisComponent.instantiatesCanonical"); 386 else if (Configuration.doAutoCreate()) 387 this.instantiatesCanonical = new CanonicalType(); // bb 388 return this.instantiatesCanonical; 389 } 390 391 public boolean hasInstantiatesCanonicalElement() { 392 return this.instantiatesCanonical != null && !this.instantiatesCanonical.isEmpty(); 393 } 394 395 public boolean hasInstantiatesCanonical() { 396 return this.instantiatesCanonical != null && !this.instantiatesCanonical.isEmpty(); 397 } 398 399 /** 400 * @param value {@link #instantiatesCanonical} (The defined protocol that describes the analysis.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesCanonical" gives direct access to the value 401 */ 402 public GenomicStudyAnalysisComponent setInstantiatesCanonicalElement(CanonicalType value) { 403 this.instantiatesCanonical = value; 404 return this; 405 } 406 407 /** 408 * @return The defined protocol that describes the analysis. 409 */ 410 public String getInstantiatesCanonical() { 411 return this.instantiatesCanonical == null ? null : this.instantiatesCanonical.getValue(); 412 } 413 414 /** 415 * @param value The defined protocol that describes the analysis. 416 */ 417 public GenomicStudyAnalysisComponent setInstantiatesCanonical(String value) { 418 if (Utilities.noString(value)) 419 this.instantiatesCanonical = null; 420 else { 421 if (this.instantiatesCanonical == null) 422 this.instantiatesCanonical = new CanonicalType(); 423 this.instantiatesCanonical.setValue(value); 424 } 425 return this; 426 } 427 428 /** 429 * @return {@link #instantiatesUri} (The URL pointing to an externally maintained protocol that describes the analysis.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesUri" gives direct access to the value 430 */ 431 public UriType getInstantiatesUriElement() { 432 if (this.instantiatesUri == null) 433 if (Configuration.errorOnAutoCreate()) 434 throw new Error("Attempt to auto-create GenomicStudyAnalysisComponent.instantiatesUri"); 435 else if (Configuration.doAutoCreate()) 436 this.instantiatesUri = new UriType(); // bb 437 return this.instantiatesUri; 438 } 439 440 public boolean hasInstantiatesUriElement() { 441 return this.instantiatesUri != null && !this.instantiatesUri.isEmpty(); 442 } 443 444 public boolean hasInstantiatesUri() { 445 return this.instantiatesUri != null && !this.instantiatesUri.isEmpty(); 446 } 447 448 /** 449 * @param value {@link #instantiatesUri} (The URL pointing to an externally maintained protocol that describes the analysis.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesUri" gives direct access to the value 450 */ 451 public GenomicStudyAnalysisComponent setInstantiatesUriElement(UriType value) { 452 this.instantiatesUri = value; 453 return this; 454 } 455 456 /** 457 * @return The URL pointing to an externally maintained protocol that describes the analysis. 458 */ 459 public String getInstantiatesUri() { 460 return this.instantiatesUri == null ? null : this.instantiatesUri.getValue(); 461 } 462 463 /** 464 * @param value The URL pointing to an externally maintained protocol that describes the analysis. 465 */ 466 public GenomicStudyAnalysisComponent setInstantiatesUri(String value) { 467 if (Utilities.noString(value)) 468 this.instantiatesUri = null; 469 else { 470 if (this.instantiatesUri == null) 471 this.instantiatesUri = new UriType(); 472 this.instantiatesUri.setValue(value); 473 } 474 return this; 475 } 476 477 /** 478 * @return {@link #title} (Name of the analysis event (human friendly).). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 479 */ 480 public StringType getTitleElement() { 481 if (this.title == null) 482 if (Configuration.errorOnAutoCreate()) 483 throw new Error("Attempt to auto-create GenomicStudyAnalysisComponent.title"); 484 else if (Configuration.doAutoCreate()) 485 this.title = new StringType(); // bb 486 return this.title; 487 } 488 489 public boolean hasTitleElement() { 490 return this.title != null && !this.title.isEmpty(); 491 } 492 493 public boolean hasTitle() { 494 return this.title != null && !this.title.isEmpty(); 495 } 496 497 /** 498 * @param value {@link #title} (Name of the analysis event (human friendly).). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 499 */ 500 public GenomicStudyAnalysisComponent setTitleElement(StringType value) { 501 this.title = value; 502 return this; 503 } 504 505 /** 506 * @return Name of the analysis event (human friendly). 507 */ 508 public String getTitle() { 509 return this.title == null ? null : this.title.getValue(); 510 } 511 512 /** 513 * @param value Name of the analysis event (human friendly). 514 */ 515 public GenomicStudyAnalysisComponent setTitle(String value) { 516 if (Utilities.noString(value)) 517 this.title = null; 518 else { 519 if (this.title == null) 520 this.title = new StringType(); 521 this.title.setValue(value); 522 } 523 return this; 524 } 525 526 /** 527 * @return {@link #subject} (The subject of the analysis event.) 528 */ 529 public Reference getSubject() { 530 if (this.subject == null) 531 if (Configuration.errorOnAutoCreate()) 532 throw new Error("Attempt to auto-create GenomicStudyAnalysisComponent.subject"); 533 else if (Configuration.doAutoCreate()) 534 this.subject = new Reference(); // cc 535 return this.subject; 536 } 537 538 public boolean hasSubject() { 539 return this.subject != null && !this.subject.isEmpty(); 540 } 541 542 /** 543 * @param value {@link #subject} (The subject of the analysis event.) 544 */ 545 public GenomicStudyAnalysisComponent setSubject(Reference value) { 546 this.subject = value; 547 return this; 548 } 549 550 /** 551 * @return {@link #specimen} (The specimen used in the analysis event.) 552 */ 553 public List<Reference> getSpecimen() { 554 if (this.specimen == null) 555 this.specimen = new ArrayList<Reference>(); 556 return this.specimen; 557 } 558 559 /** 560 * @return Returns a reference to <code>this</code> for easy method chaining 561 */ 562 public GenomicStudyAnalysisComponent setSpecimen(List<Reference> theSpecimen) { 563 this.specimen = theSpecimen; 564 return this; 565 } 566 567 public boolean hasSpecimen() { 568 if (this.specimen == null) 569 return false; 570 for (Reference item : this.specimen) 571 if (!item.isEmpty()) 572 return true; 573 return false; 574 } 575 576 public Reference addSpecimen() { //3 577 Reference t = new Reference(); 578 if (this.specimen == null) 579 this.specimen = new ArrayList<Reference>(); 580 this.specimen.add(t); 581 return t; 582 } 583 584 public GenomicStudyAnalysisComponent addSpecimen(Reference t) { //3 585 if (t == null) 586 return this; 587 if (this.specimen == null) 588 this.specimen = new ArrayList<Reference>(); 589 this.specimen.add(t); 590 return this; 591 } 592 593 /** 594 * @return The first repetition of repeating field {@link #specimen}, creating it if it does not already exist {3} 595 */ 596 public Reference getSpecimenFirstRep() { 597 if (getSpecimen().isEmpty()) { 598 addSpecimen(); 599 } 600 return getSpecimen().get(0); 601 } 602 603 /** 604 * @return {@link #date} (The date of the analysis event.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value 605 */ 606 public DateTimeType getDateElement() { 607 if (this.date == null) 608 if (Configuration.errorOnAutoCreate()) 609 throw new Error("Attempt to auto-create GenomicStudyAnalysisComponent.date"); 610 else if (Configuration.doAutoCreate()) 611 this.date = new DateTimeType(); // bb 612 return this.date; 613 } 614 615 public boolean hasDateElement() { 616 return this.date != null && !this.date.isEmpty(); 617 } 618 619 public boolean hasDate() { 620 return this.date != null && !this.date.isEmpty(); 621 } 622 623 /** 624 * @param value {@link #date} (The date of the analysis event.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value 625 */ 626 public GenomicStudyAnalysisComponent setDateElement(DateTimeType value) { 627 this.date = value; 628 return this; 629 } 630 631 /** 632 * @return The date of the analysis event. 633 */ 634 public Date getDate() { 635 return this.date == null ? null : this.date.getValue(); 636 } 637 638 /** 639 * @param value The date of the analysis event. 640 */ 641 public GenomicStudyAnalysisComponent setDate(Date value) { 642 if (value == null) 643 this.date = null; 644 else { 645 if (this.date == null) 646 this.date = new DateTimeType(); 647 this.date.setValue(value); 648 } 649 return this; 650 } 651 652 /** 653 * @return {@link #note} (Any notes capture with the analysis event.) 654 */ 655 public List<Annotation> getNote() { 656 if (this.note == null) 657 this.note = new ArrayList<Annotation>(); 658 return this.note; 659 } 660 661 /** 662 * @return Returns a reference to <code>this</code> for easy method chaining 663 */ 664 public GenomicStudyAnalysisComponent setNote(List<Annotation> theNote) { 665 this.note = theNote; 666 return this; 667 } 668 669 public boolean hasNote() { 670 if (this.note == null) 671 return false; 672 for (Annotation item : this.note) 673 if (!item.isEmpty()) 674 return true; 675 return false; 676 } 677 678 public Annotation addNote() { //3 679 Annotation t = new Annotation(); 680 if (this.note == null) 681 this.note = new ArrayList<Annotation>(); 682 this.note.add(t); 683 return t; 684 } 685 686 public GenomicStudyAnalysisComponent addNote(Annotation t) { //3 687 if (t == null) 688 return this; 689 if (this.note == null) 690 this.note = new ArrayList<Annotation>(); 691 this.note.add(t); 692 return this; 693 } 694 695 /** 696 * @return The first repetition of repeating field {@link #note}, creating it if it does not already exist {3} 697 */ 698 public Annotation getNoteFirstRep() { 699 if (getNote().isEmpty()) { 700 addNote(); 701 } 702 return getNote().get(0); 703 } 704 705 /** 706 * @return {@link #protocolPerformed} (The protocol that was performed for the analysis event.) 707 */ 708 public Reference getProtocolPerformed() { 709 if (this.protocolPerformed == null) 710 if (Configuration.errorOnAutoCreate()) 711 throw new Error("Attempt to auto-create GenomicStudyAnalysisComponent.protocolPerformed"); 712 else if (Configuration.doAutoCreate()) 713 this.protocolPerformed = new Reference(); // cc 714 return this.protocolPerformed; 715 } 716 717 public boolean hasProtocolPerformed() { 718 return this.protocolPerformed != null && !this.protocolPerformed.isEmpty(); 719 } 720 721 /** 722 * @param value {@link #protocolPerformed} (The protocol that was performed for the analysis event.) 723 */ 724 public GenomicStudyAnalysisComponent setProtocolPerformed(Reference value) { 725 this.protocolPerformed = value; 726 return this; 727 } 728 729 /** 730 * @return {@link #regionsStudied} (The genomic regions to be studied in the analysis (BED file).) 731 */ 732 public List<Reference> getRegionsStudied() { 733 if (this.regionsStudied == null) 734 this.regionsStudied = new ArrayList<Reference>(); 735 return this.regionsStudied; 736 } 737 738 /** 739 * @return Returns a reference to <code>this</code> for easy method chaining 740 */ 741 public GenomicStudyAnalysisComponent setRegionsStudied(List<Reference> theRegionsStudied) { 742 this.regionsStudied = theRegionsStudied; 743 return this; 744 } 745 746 public boolean hasRegionsStudied() { 747 if (this.regionsStudied == null) 748 return false; 749 for (Reference item : this.regionsStudied) 750 if (!item.isEmpty()) 751 return true; 752 return false; 753 } 754 755 public Reference addRegionsStudied() { //3 756 Reference t = new Reference(); 757 if (this.regionsStudied == null) 758 this.regionsStudied = new ArrayList<Reference>(); 759 this.regionsStudied.add(t); 760 return t; 761 } 762 763 public GenomicStudyAnalysisComponent addRegionsStudied(Reference t) { //3 764 if (t == null) 765 return this; 766 if (this.regionsStudied == null) 767 this.regionsStudied = new ArrayList<Reference>(); 768 this.regionsStudied.add(t); 769 return this; 770 } 771 772 /** 773 * @return The first repetition of repeating field {@link #regionsStudied}, creating it if it does not already exist {3} 774 */ 775 public Reference getRegionsStudiedFirstRep() { 776 if (getRegionsStudied().isEmpty()) { 777 addRegionsStudied(); 778 } 779 return getRegionsStudied().get(0); 780 } 781 782 /** 783 * @return {@link #regionsCalled} (Genomic regions actually called in the analysis event (BED file).) 784 */ 785 public List<Reference> getRegionsCalled() { 786 if (this.regionsCalled == null) 787 this.regionsCalled = new ArrayList<Reference>(); 788 return this.regionsCalled; 789 } 790 791 /** 792 * @return Returns a reference to <code>this</code> for easy method chaining 793 */ 794 public GenomicStudyAnalysisComponent setRegionsCalled(List<Reference> theRegionsCalled) { 795 this.regionsCalled = theRegionsCalled; 796 return this; 797 } 798 799 public boolean hasRegionsCalled() { 800 if (this.regionsCalled == null) 801 return false; 802 for (Reference item : this.regionsCalled) 803 if (!item.isEmpty()) 804 return true; 805 return false; 806 } 807 808 public Reference addRegionsCalled() { //3 809 Reference t = new Reference(); 810 if (this.regionsCalled == null) 811 this.regionsCalled = new ArrayList<Reference>(); 812 this.regionsCalled.add(t); 813 return t; 814 } 815 816 public GenomicStudyAnalysisComponent addRegionsCalled(Reference t) { //3 817 if (t == null) 818 return this; 819 if (this.regionsCalled == null) 820 this.regionsCalled = new ArrayList<Reference>(); 821 this.regionsCalled.add(t); 822 return this; 823 } 824 825 /** 826 * @return The first repetition of repeating field {@link #regionsCalled}, creating it if it does not already exist {3} 827 */ 828 public Reference getRegionsCalledFirstRep() { 829 if (getRegionsCalled().isEmpty()) { 830 addRegionsCalled(); 831 } 832 return getRegionsCalled().get(0); 833 } 834 835 /** 836 * @return {@link #input} (Inputs for the analysis event.) 837 */ 838 public List<GenomicStudyAnalysisInputComponent> getInput() { 839 if (this.input == null) 840 this.input = new ArrayList<GenomicStudyAnalysisInputComponent>(); 841 return this.input; 842 } 843 844 /** 845 * @return Returns a reference to <code>this</code> for easy method chaining 846 */ 847 public GenomicStudyAnalysisComponent setInput(List<GenomicStudyAnalysisInputComponent> theInput) { 848 this.input = theInput; 849 return this; 850 } 851 852 public boolean hasInput() { 853 if (this.input == null) 854 return false; 855 for (GenomicStudyAnalysisInputComponent item : this.input) 856 if (!item.isEmpty()) 857 return true; 858 return false; 859 } 860 861 public GenomicStudyAnalysisInputComponent addInput() { //3 862 GenomicStudyAnalysisInputComponent t = new GenomicStudyAnalysisInputComponent(); 863 if (this.input == null) 864 this.input = new ArrayList<GenomicStudyAnalysisInputComponent>(); 865 this.input.add(t); 866 return t; 867 } 868 869 public GenomicStudyAnalysisComponent addInput(GenomicStudyAnalysisInputComponent t) { //3 870 if (t == null) 871 return this; 872 if (this.input == null) 873 this.input = new ArrayList<GenomicStudyAnalysisInputComponent>(); 874 this.input.add(t); 875 return this; 876 } 877 878 /** 879 * @return The first repetition of repeating field {@link #input}, creating it if it does not already exist {3} 880 */ 881 public GenomicStudyAnalysisInputComponent getInputFirstRep() { 882 if (getInput().isEmpty()) { 883 addInput(); 884 } 885 return getInput().get(0); 886 } 887 888 /** 889 * @return {@link #output} (Outputs for the analysis event.) 890 */ 891 public List<GenomicStudyAnalysisOutputComponent> getOutput() { 892 if (this.output == null) 893 this.output = new ArrayList<GenomicStudyAnalysisOutputComponent>(); 894 return this.output; 895 } 896 897 /** 898 * @return Returns a reference to <code>this</code> for easy method chaining 899 */ 900 public GenomicStudyAnalysisComponent setOutput(List<GenomicStudyAnalysisOutputComponent> theOutput) { 901 this.output = theOutput; 902 return this; 903 } 904 905 public boolean hasOutput() { 906 if (this.output == null) 907 return false; 908 for (GenomicStudyAnalysisOutputComponent item : this.output) 909 if (!item.isEmpty()) 910 return true; 911 return false; 912 } 913 914 public GenomicStudyAnalysisOutputComponent addOutput() { //3 915 GenomicStudyAnalysisOutputComponent t = new GenomicStudyAnalysisOutputComponent(); 916 if (this.output == null) 917 this.output = new ArrayList<GenomicStudyAnalysisOutputComponent>(); 918 this.output.add(t); 919 return t; 920 } 921 922 public GenomicStudyAnalysisComponent addOutput(GenomicStudyAnalysisOutputComponent t) { //3 923 if (t == null) 924 return this; 925 if (this.output == null) 926 this.output = new ArrayList<GenomicStudyAnalysisOutputComponent>(); 927 this.output.add(t); 928 return this; 929 } 930 931 /** 932 * @return The first repetition of repeating field {@link #output}, creating it if it does not already exist {3} 933 */ 934 public GenomicStudyAnalysisOutputComponent getOutputFirstRep() { 935 if (getOutput().isEmpty()) { 936 addOutput(); 937 } 938 return getOutput().get(0); 939 } 940 941 /** 942 * @return {@link #performer} (Performer for the analysis event.) 943 */ 944 public List<GenomicStudyAnalysisPerformerComponent> getPerformer() { 945 if (this.performer == null) 946 this.performer = new ArrayList<GenomicStudyAnalysisPerformerComponent>(); 947 return this.performer; 948 } 949 950 /** 951 * @return Returns a reference to <code>this</code> for easy method chaining 952 */ 953 public GenomicStudyAnalysisComponent setPerformer(List<GenomicStudyAnalysisPerformerComponent> thePerformer) { 954 this.performer = thePerformer; 955 return this; 956 } 957 958 public boolean hasPerformer() { 959 if (this.performer == null) 960 return false; 961 for (GenomicStudyAnalysisPerformerComponent item : this.performer) 962 if (!item.isEmpty()) 963 return true; 964 return false; 965 } 966 967 public GenomicStudyAnalysisPerformerComponent addPerformer() { //3 968 GenomicStudyAnalysisPerformerComponent t = new GenomicStudyAnalysisPerformerComponent(); 969 if (this.performer == null) 970 this.performer = new ArrayList<GenomicStudyAnalysisPerformerComponent>(); 971 this.performer.add(t); 972 return t; 973 } 974 975 public GenomicStudyAnalysisComponent addPerformer(GenomicStudyAnalysisPerformerComponent t) { //3 976 if (t == null) 977 return this; 978 if (this.performer == null) 979 this.performer = new ArrayList<GenomicStudyAnalysisPerformerComponent>(); 980 this.performer.add(t); 981 return this; 982 } 983 984 /** 985 * @return The first repetition of repeating field {@link #performer}, creating it if it does not already exist {3} 986 */ 987 public GenomicStudyAnalysisPerformerComponent getPerformerFirstRep() { 988 if (getPerformer().isEmpty()) { 989 addPerformer(); 990 } 991 return getPerformer().get(0); 992 } 993 994 /** 995 * @return {@link #device} (Devices used for the analysis (e.g., instruments, software), with settings and parameters.) 996 */ 997 public List<GenomicStudyAnalysisDeviceComponent> getDevice() { 998 if (this.device == null) 999 this.device = new ArrayList<GenomicStudyAnalysisDeviceComponent>(); 1000 return this.device; 1001 } 1002 1003 /** 1004 * @return Returns a reference to <code>this</code> for easy method chaining 1005 */ 1006 public GenomicStudyAnalysisComponent setDevice(List<GenomicStudyAnalysisDeviceComponent> theDevice) { 1007 this.device = theDevice; 1008 return this; 1009 } 1010 1011 public boolean hasDevice() { 1012 if (this.device == null) 1013 return false; 1014 for (GenomicStudyAnalysisDeviceComponent item : this.device) 1015 if (!item.isEmpty()) 1016 return true; 1017 return false; 1018 } 1019 1020 public GenomicStudyAnalysisDeviceComponent addDevice() { //3 1021 GenomicStudyAnalysisDeviceComponent t = new GenomicStudyAnalysisDeviceComponent(); 1022 if (this.device == null) 1023 this.device = new ArrayList<GenomicStudyAnalysisDeviceComponent>(); 1024 this.device.add(t); 1025 return t; 1026 } 1027 1028 public GenomicStudyAnalysisComponent addDevice(GenomicStudyAnalysisDeviceComponent t) { //3 1029 if (t == null) 1030 return this; 1031 if (this.device == null) 1032 this.device = new ArrayList<GenomicStudyAnalysisDeviceComponent>(); 1033 this.device.add(t); 1034 return this; 1035 } 1036 1037 /** 1038 * @return The first repetition of repeating field {@link #device}, creating it if it does not already exist {3} 1039 */ 1040 public GenomicStudyAnalysisDeviceComponent getDeviceFirstRep() { 1041 if (getDevice().isEmpty()) { 1042 addDevice(); 1043 } 1044 return getDevice().get(0); 1045 } 1046 1047 protected void listChildren(List<Property> children) { 1048 super.listChildren(children); 1049 children.add(new Property("identifier", "Identifier", "Identifiers for the analysis event.", 0, java.lang.Integer.MAX_VALUE, identifier)); 1050 children.add(new Property("methodType", "CodeableConcept", "Type of the methods used in the analysis, e.g., Fluorescence in situ hybridization (FISH), Karyotyping, or Microsatellite instability testing (MSI).", 0, java.lang.Integer.MAX_VALUE, methodType)); 1051 children.add(new Property("changeType", "CodeableConcept", "Type of the genomic changes studied in the analysis, e.g., DNA, RNA, or amino acid change.", 0, java.lang.Integer.MAX_VALUE, changeType)); 1052 children.add(new Property("genomeBuild", "CodeableConcept", "The reference genome build that is used in this analysis.", 0, 1, genomeBuild)); 1053 children.add(new Property("instantiatesCanonical", "canonical(PlanDefinition|ActivityDefinition)", "The defined protocol that describes the analysis.", 0, 1, instantiatesCanonical)); 1054 children.add(new Property("instantiatesUri", "uri", "The URL pointing to an externally maintained protocol that describes the analysis.", 0, 1, instantiatesUri)); 1055 children.add(new Property("title", "string", "Name of the analysis event (human friendly).", 0, 1, title)); 1056 children.add(new Property("subject", "Reference(Patient|Group|Device|Location|Organization|Procedure|Practitioner|Medication|Substance|BiologicallyDerivedProduct|NutritionProduct)", "The subject of the analysis event.", 0, 1, subject)); 1057 children.add(new Property("specimen", "Reference(Specimen)", "The specimen used in the analysis event.", 0, java.lang.Integer.MAX_VALUE, specimen)); 1058 children.add(new Property("date", "dateTime", "The date of the analysis event.", 0, 1, date)); 1059 children.add(new Property("note", "Annotation", "Any notes capture with the analysis event.", 0, java.lang.Integer.MAX_VALUE, note)); 1060 children.add(new Property("protocolPerformed", "Reference(Procedure|Task)", "The protocol that was performed for the analysis event.", 0, 1, protocolPerformed)); 1061 children.add(new Property("regionsStudied", "Reference(DocumentReference|Observation)", "The genomic regions to be studied in the analysis (BED file).", 0, java.lang.Integer.MAX_VALUE, regionsStudied)); 1062 children.add(new Property("regionsCalled", "Reference(DocumentReference|Observation)", "Genomic regions actually called in the analysis event (BED file).", 0, java.lang.Integer.MAX_VALUE, regionsCalled)); 1063 children.add(new Property("input", "", "Inputs for the analysis event.", 0, java.lang.Integer.MAX_VALUE, input)); 1064 children.add(new Property("output", "", "Outputs for the analysis event.", 0, java.lang.Integer.MAX_VALUE, output)); 1065 children.add(new Property("performer", "", "Performer for the analysis event.", 0, java.lang.Integer.MAX_VALUE, performer)); 1066 children.add(new Property("device", "", "Devices used for the analysis (e.g., instruments, software), with settings and parameters.", 0, java.lang.Integer.MAX_VALUE, device)); 1067 } 1068 1069 @Override 1070 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1071 switch (_hash) { 1072 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "Identifiers for the analysis event.", 0, java.lang.Integer.MAX_VALUE, identifier); 1073 case -722961477: /*methodType*/ return new Property("methodType", "CodeableConcept", "Type of the methods used in the analysis, e.g., Fluorescence in situ hybridization (FISH), Karyotyping, or Microsatellite instability testing (MSI).", 0, java.lang.Integer.MAX_VALUE, methodType); 1074 case -2131902710: /*changeType*/ return new Property("changeType", "CodeableConcept", "Type of the genomic changes studied in the analysis, e.g., DNA, RNA, or amino acid change.", 0, java.lang.Integer.MAX_VALUE, changeType); 1075 case 1061239735: /*genomeBuild*/ return new Property("genomeBuild", "CodeableConcept", "The reference genome build that is used in this analysis.", 0, 1, genomeBuild); 1076 case 8911915: /*instantiatesCanonical*/ return new Property("instantiatesCanonical", "canonical(PlanDefinition|ActivityDefinition)", "The defined protocol that describes the analysis.", 0, 1, instantiatesCanonical); 1077 case -1926393373: /*instantiatesUri*/ return new Property("instantiatesUri", "uri", "The URL pointing to an externally maintained protocol that describes the analysis.", 0, 1, instantiatesUri); 1078 case 110371416: /*title*/ return new Property("title", "string", "Name of the analysis event (human friendly).", 0, 1, title); 1079 case -1867885268: /*subject*/ return new Property("subject", "Reference(Patient|Group|Device|Location|Organization|Procedure|Practitioner|Medication|Substance|BiologicallyDerivedProduct|NutritionProduct)", "The subject of the analysis event.", 0, 1, subject); 1080 case -2132868344: /*specimen*/ return new Property("specimen", "Reference(Specimen)", "The specimen used in the analysis event.", 0, java.lang.Integer.MAX_VALUE, specimen); 1081 case 3076014: /*date*/ return new Property("date", "dateTime", "The date of the analysis event.", 0, 1, date); 1082 case 3387378: /*note*/ return new Property("note", "Annotation", "Any notes capture with the analysis event.", 0, java.lang.Integer.MAX_VALUE, note); 1083 case -1565516792: /*protocolPerformed*/ return new Property("protocolPerformed", "Reference(Procedure|Task)", "The protocol that was performed for the analysis event.", 0, 1, protocolPerformed); 1084 case 391791385: /*regionsStudied*/ return new Property("regionsStudied", "Reference(DocumentReference|Observation)", "The genomic regions to be studied in the analysis (BED file).", 0, java.lang.Integer.MAX_VALUE, regionsStudied); 1085 case -2125803428: /*regionsCalled*/ return new Property("regionsCalled", "Reference(DocumentReference|Observation)", "Genomic regions actually called in the analysis event (BED file).", 0, java.lang.Integer.MAX_VALUE, regionsCalled); 1086 case 100358090: /*input*/ return new Property("input", "", "Inputs for the analysis event.", 0, java.lang.Integer.MAX_VALUE, input); 1087 case -1005512447: /*output*/ return new Property("output", "", "Outputs for the analysis event.", 0, java.lang.Integer.MAX_VALUE, output); 1088 case 481140686: /*performer*/ return new Property("performer", "", "Performer for the analysis event.", 0, java.lang.Integer.MAX_VALUE, performer); 1089 case -1335157162: /*device*/ return new Property("device", "", "Devices used for the analysis (e.g., instruments, software), with settings and parameters.", 0, java.lang.Integer.MAX_VALUE, device); 1090 default: return super.getNamedProperty(_hash, _name, _checkValid); 1091 } 1092 1093 } 1094 1095 @Override 1096 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1097 switch (hash) { 1098 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 1099 case -722961477: /*methodType*/ return this.methodType == null ? new Base[0] : this.methodType.toArray(new Base[this.methodType.size()]); // CodeableConcept 1100 case -2131902710: /*changeType*/ return this.changeType == null ? new Base[0] : this.changeType.toArray(new Base[this.changeType.size()]); // CodeableConcept 1101 case 1061239735: /*genomeBuild*/ return this.genomeBuild == null ? new Base[0] : new Base[] {this.genomeBuild}; // CodeableConcept 1102 case 8911915: /*instantiatesCanonical*/ return this.instantiatesCanonical == null ? new Base[0] : new Base[] {this.instantiatesCanonical}; // CanonicalType 1103 case -1926393373: /*instantiatesUri*/ return this.instantiatesUri == null ? new Base[0] : new Base[] {this.instantiatesUri}; // UriType 1104 case 110371416: /*title*/ return this.title == null ? new Base[0] : new Base[] {this.title}; // StringType 1105 case -1867885268: /*subject*/ return this.subject == null ? new Base[0] : new Base[] {this.subject}; // Reference 1106 case -2132868344: /*specimen*/ return this.specimen == null ? new Base[0] : this.specimen.toArray(new Base[this.specimen.size()]); // Reference 1107 case 3076014: /*date*/ return this.date == null ? new Base[0] : new Base[] {this.date}; // DateTimeType 1108 case 3387378: /*note*/ return this.note == null ? new Base[0] : this.note.toArray(new Base[this.note.size()]); // Annotation 1109 case -1565516792: /*protocolPerformed*/ return this.protocolPerformed == null ? new Base[0] : new Base[] {this.protocolPerformed}; // Reference 1110 case 391791385: /*regionsStudied*/ return this.regionsStudied == null ? new Base[0] : this.regionsStudied.toArray(new Base[this.regionsStudied.size()]); // Reference 1111 case -2125803428: /*regionsCalled*/ return this.regionsCalled == null ? new Base[0] : this.regionsCalled.toArray(new Base[this.regionsCalled.size()]); // Reference 1112 case 100358090: /*input*/ return this.input == null ? new Base[0] : this.input.toArray(new Base[this.input.size()]); // GenomicStudyAnalysisInputComponent 1113 case -1005512447: /*output*/ return this.output == null ? new Base[0] : this.output.toArray(new Base[this.output.size()]); // GenomicStudyAnalysisOutputComponent 1114 case 481140686: /*performer*/ return this.performer == null ? new Base[0] : this.performer.toArray(new Base[this.performer.size()]); // GenomicStudyAnalysisPerformerComponent 1115 case -1335157162: /*device*/ return this.device == null ? new Base[0] : this.device.toArray(new Base[this.device.size()]); // GenomicStudyAnalysisDeviceComponent 1116 default: return super.getProperty(hash, name, checkValid); 1117 } 1118 1119 } 1120 1121 @Override 1122 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1123 switch (hash) { 1124 case -1618432855: // identifier 1125 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); // Identifier 1126 return value; 1127 case -722961477: // methodType 1128 this.getMethodType().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 1129 return value; 1130 case -2131902710: // changeType 1131 this.getChangeType().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 1132 return value; 1133 case 1061239735: // genomeBuild 1134 this.genomeBuild = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1135 return value; 1136 case 8911915: // instantiatesCanonical 1137 this.instantiatesCanonical = TypeConvertor.castToCanonical(value); // CanonicalType 1138 return value; 1139 case -1926393373: // instantiatesUri 1140 this.instantiatesUri = TypeConvertor.castToUri(value); // UriType 1141 return value; 1142 case 110371416: // title 1143 this.title = TypeConvertor.castToString(value); // StringType 1144 return value; 1145 case -1867885268: // subject 1146 this.subject = TypeConvertor.castToReference(value); // Reference 1147 return value; 1148 case -2132868344: // specimen 1149 this.getSpecimen().add(TypeConvertor.castToReference(value)); // Reference 1150 return value; 1151 case 3076014: // date 1152 this.date = TypeConvertor.castToDateTime(value); // DateTimeType 1153 return value; 1154 case 3387378: // note 1155 this.getNote().add(TypeConvertor.castToAnnotation(value)); // Annotation 1156 return value; 1157 case -1565516792: // protocolPerformed 1158 this.protocolPerformed = TypeConvertor.castToReference(value); // Reference 1159 return value; 1160 case 391791385: // regionsStudied 1161 this.getRegionsStudied().add(TypeConvertor.castToReference(value)); // Reference 1162 return value; 1163 case -2125803428: // regionsCalled 1164 this.getRegionsCalled().add(TypeConvertor.castToReference(value)); // Reference 1165 return value; 1166 case 100358090: // input 1167 this.getInput().add((GenomicStudyAnalysisInputComponent) value); // GenomicStudyAnalysisInputComponent 1168 return value; 1169 case -1005512447: // output 1170 this.getOutput().add((GenomicStudyAnalysisOutputComponent) value); // GenomicStudyAnalysisOutputComponent 1171 return value; 1172 case 481140686: // performer 1173 this.getPerformer().add((GenomicStudyAnalysisPerformerComponent) value); // GenomicStudyAnalysisPerformerComponent 1174 return value; 1175 case -1335157162: // device 1176 this.getDevice().add((GenomicStudyAnalysisDeviceComponent) value); // GenomicStudyAnalysisDeviceComponent 1177 return value; 1178 default: return super.setProperty(hash, name, value); 1179 } 1180 1181 } 1182 1183 @Override 1184 public Base setProperty(String name, Base value) throws FHIRException { 1185 if (name.equals("identifier")) { 1186 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); 1187 } else if (name.equals("methodType")) { 1188 this.getMethodType().add(TypeConvertor.castToCodeableConcept(value)); 1189 } else if (name.equals("changeType")) { 1190 this.getChangeType().add(TypeConvertor.castToCodeableConcept(value)); 1191 } else if (name.equals("genomeBuild")) { 1192 this.genomeBuild = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1193 } else if (name.equals("instantiatesCanonical")) { 1194 this.instantiatesCanonical = TypeConvertor.castToCanonical(value); // CanonicalType 1195 } else if (name.equals("instantiatesUri")) { 1196 this.instantiatesUri = TypeConvertor.castToUri(value); // UriType 1197 } else if (name.equals("title")) { 1198 this.title = TypeConvertor.castToString(value); // StringType 1199 } else if (name.equals("subject")) { 1200 this.subject = TypeConvertor.castToReference(value); // Reference 1201 } else if (name.equals("specimen")) { 1202 this.getSpecimen().add(TypeConvertor.castToReference(value)); 1203 } else if (name.equals("date")) { 1204 this.date = TypeConvertor.castToDateTime(value); // DateTimeType 1205 } else if (name.equals("note")) { 1206 this.getNote().add(TypeConvertor.castToAnnotation(value)); 1207 } else if (name.equals("protocolPerformed")) { 1208 this.protocolPerformed = TypeConvertor.castToReference(value); // Reference 1209 } else if (name.equals("regionsStudied")) { 1210 this.getRegionsStudied().add(TypeConvertor.castToReference(value)); 1211 } else if (name.equals("regionsCalled")) { 1212 this.getRegionsCalled().add(TypeConvertor.castToReference(value)); 1213 } else if (name.equals("input")) { 1214 this.getInput().add((GenomicStudyAnalysisInputComponent) value); 1215 } else if (name.equals("output")) { 1216 this.getOutput().add((GenomicStudyAnalysisOutputComponent) value); 1217 } else if (name.equals("performer")) { 1218 this.getPerformer().add((GenomicStudyAnalysisPerformerComponent) value); 1219 } else if (name.equals("device")) { 1220 this.getDevice().add((GenomicStudyAnalysisDeviceComponent) value); 1221 } else 1222 return super.setProperty(name, value); 1223 return value; 1224 } 1225 1226 @Override 1227 public Base makeProperty(int hash, String name) throws FHIRException { 1228 switch (hash) { 1229 case -1618432855: return addIdentifier(); 1230 case -722961477: return addMethodType(); 1231 case -2131902710: return addChangeType(); 1232 case 1061239735: return getGenomeBuild(); 1233 case 8911915: return getInstantiatesCanonicalElement(); 1234 case -1926393373: return getInstantiatesUriElement(); 1235 case 110371416: return getTitleElement(); 1236 case -1867885268: return getSubject(); 1237 case -2132868344: return addSpecimen(); 1238 case 3076014: return getDateElement(); 1239 case 3387378: return addNote(); 1240 case -1565516792: return getProtocolPerformed(); 1241 case 391791385: return addRegionsStudied(); 1242 case -2125803428: return addRegionsCalled(); 1243 case 100358090: return addInput(); 1244 case -1005512447: return addOutput(); 1245 case 481140686: return addPerformer(); 1246 case -1335157162: return addDevice(); 1247 default: return super.makeProperty(hash, name); 1248 } 1249 1250 } 1251 1252 @Override 1253 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1254 switch (hash) { 1255 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 1256 case -722961477: /*methodType*/ return new String[] {"CodeableConcept"}; 1257 case -2131902710: /*changeType*/ return new String[] {"CodeableConcept"}; 1258 case 1061239735: /*genomeBuild*/ return new String[] {"CodeableConcept"}; 1259 case 8911915: /*instantiatesCanonical*/ return new String[] {"canonical"}; 1260 case -1926393373: /*instantiatesUri*/ return new String[] {"uri"}; 1261 case 110371416: /*title*/ return new String[] {"string"}; 1262 case -1867885268: /*subject*/ return new String[] {"Reference"}; 1263 case -2132868344: /*specimen*/ return new String[] {"Reference"}; 1264 case 3076014: /*date*/ return new String[] {"dateTime"}; 1265 case 3387378: /*note*/ return new String[] {"Annotation"}; 1266 case -1565516792: /*protocolPerformed*/ return new String[] {"Reference"}; 1267 case 391791385: /*regionsStudied*/ return new String[] {"Reference"}; 1268 case -2125803428: /*regionsCalled*/ return new String[] {"Reference"}; 1269 case 100358090: /*input*/ return new String[] {}; 1270 case -1005512447: /*output*/ return new String[] {}; 1271 case 481140686: /*performer*/ return new String[] {}; 1272 case -1335157162: /*device*/ return new String[] {}; 1273 default: return super.getTypesForProperty(hash, name); 1274 } 1275 1276 } 1277 1278 @Override 1279 public Base addChild(String name) throws FHIRException { 1280 if (name.equals("identifier")) { 1281 return addIdentifier(); 1282 } 1283 else if (name.equals("methodType")) { 1284 return addMethodType(); 1285 } 1286 else if (name.equals("changeType")) { 1287 return addChangeType(); 1288 } 1289 else if (name.equals("genomeBuild")) { 1290 this.genomeBuild = new CodeableConcept(); 1291 return this.genomeBuild; 1292 } 1293 else if (name.equals("instantiatesCanonical")) { 1294 throw new FHIRException("Cannot call addChild on a primitive type GenomicStudy.analysis.instantiatesCanonical"); 1295 } 1296 else if (name.equals("instantiatesUri")) { 1297 throw new FHIRException("Cannot call addChild on a primitive type GenomicStudy.analysis.instantiatesUri"); 1298 } 1299 else if (name.equals("title")) { 1300 throw new FHIRException("Cannot call addChild on a primitive type GenomicStudy.analysis.title"); 1301 } 1302 else if (name.equals("subject")) { 1303 this.subject = new Reference(); 1304 return this.subject; 1305 } 1306 else if (name.equals("specimen")) { 1307 return addSpecimen(); 1308 } 1309 else if (name.equals("date")) { 1310 throw new FHIRException("Cannot call addChild on a primitive type GenomicStudy.analysis.date"); 1311 } 1312 else if (name.equals("note")) { 1313 return addNote(); 1314 } 1315 else if (name.equals("protocolPerformed")) { 1316 this.protocolPerformed = new Reference(); 1317 return this.protocolPerformed; 1318 } 1319 else if (name.equals("regionsStudied")) { 1320 return addRegionsStudied(); 1321 } 1322 else if (name.equals("regionsCalled")) { 1323 return addRegionsCalled(); 1324 } 1325 else if (name.equals("input")) { 1326 return addInput(); 1327 } 1328 else if (name.equals("output")) { 1329 return addOutput(); 1330 } 1331 else if (name.equals("performer")) { 1332 return addPerformer(); 1333 } 1334 else if (name.equals("device")) { 1335 return addDevice(); 1336 } 1337 else 1338 return super.addChild(name); 1339 } 1340 1341 public GenomicStudyAnalysisComponent copy() { 1342 GenomicStudyAnalysisComponent dst = new GenomicStudyAnalysisComponent(); 1343 copyValues(dst); 1344 return dst; 1345 } 1346 1347 public void copyValues(GenomicStudyAnalysisComponent dst) { 1348 super.copyValues(dst); 1349 if (identifier != null) { 1350 dst.identifier = new ArrayList<Identifier>(); 1351 for (Identifier i : identifier) 1352 dst.identifier.add(i.copy()); 1353 }; 1354 if (methodType != null) { 1355 dst.methodType = new ArrayList<CodeableConcept>(); 1356 for (CodeableConcept i : methodType) 1357 dst.methodType.add(i.copy()); 1358 }; 1359 if (changeType != null) { 1360 dst.changeType = new ArrayList<CodeableConcept>(); 1361 for (CodeableConcept i : changeType) 1362 dst.changeType.add(i.copy()); 1363 }; 1364 dst.genomeBuild = genomeBuild == null ? null : genomeBuild.copy(); 1365 dst.instantiatesCanonical = instantiatesCanonical == null ? null : instantiatesCanonical.copy(); 1366 dst.instantiatesUri = instantiatesUri == null ? null : instantiatesUri.copy(); 1367 dst.title = title == null ? null : title.copy(); 1368 dst.subject = subject == null ? null : subject.copy(); 1369 if (specimen != null) { 1370 dst.specimen = new ArrayList<Reference>(); 1371 for (Reference i : specimen) 1372 dst.specimen.add(i.copy()); 1373 }; 1374 dst.date = date == null ? null : date.copy(); 1375 if (note != null) { 1376 dst.note = new ArrayList<Annotation>(); 1377 for (Annotation i : note) 1378 dst.note.add(i.copy()); 1379 }; 1380 dst.protocolPerformed = protocolPerformed == null ? null : protocolPerformed.copy(); 1381 if (regionsStudied != null) { 1382 dst.regionsStudied = new ArrayList<Reference>(); 1383 for (Reference i : regionsStudied) 1384 dst.regionsStudied.add(i.copy()); 1385 }; 1386 if (regionsCalled != null) { 1387 dst.regionsCalled = new ArrayList<Reference>(); 1388 for (Reference i : regionsCalled) 1389 dst.regionsCalled.add(i.copy()); 1390 }; 1391 if (input != null) { 1392 dst.input = new ArrayList<GenomicStudyAnalysisInputComponent>(); 1393 for (GenomicStudyAnalysisInputComponent i : input) 1394 dst.input.add(i.copy()); 1395 }; 1396 if (output != null) { 1397 dst.output = new ArrayList<GenomicStudyAnalysisOutputComponent>(); 1398 for (GenomicStudyAnalysisOutputComponent i : output) 1399 dst.output.add(i.copy()); 1400 }; 1401 if (performer != null) { 1402 dst.performer = new ArrayList<GenomicStudyAnalysisPerformerComponent>(); 1403 for (GenomicStudyAnalysisPerformerComponent i : performer) 1404 dst.performer.add(i.copy()); 1405 }; 1406 if (device != null) { 1407 dst.device = new ArrayList<GenomicStudyAnalysisDeviceComponent>(); 1408 for (GenomicStudyAnalysisDeviceComponent i : device) 1409 dst.device.add(i.copy()); 1410 }; 1411 } 1412 1413 @Override 1414 public boolean equalsDeep(Base other_) { 1415 if (!super.equalsDeep(other_)) 1416 return false; 1417 if (!(other_ instanceof GenomicStudyAnalysisComponent)) 1418 return false; 1419 GenomicStudyAnalysisComponent o = (GenomicStudyAnalysisComponent) other_; 1420 return compareDeep(identifier, o.identifier, true) && compareDeep(methodType, o.methodType, true) 1421 && compareDeep(changeType, o.changeType, true) && compareDeep(genomeBuild, o.genomeBuild, true) 1422 && compareDeep(instantiatesCanonical, o.instantiatesCanonical, true) && compareDeep(instantiatesUri, o.instantiatesUri, true) 1423 && compareDeep(title, o.title, true) && compareDeep(subject, o.subject, true) && compareDeep(specimen, o.specimen, true) 1424 && compareDeep(date, o.date, true) && compareDeep(note, o.note, true) && compareDeep(protocolPerformed, o.protocolPerformed, true) 1425 && compareDeep(regionsStudied, o.regionsStudied, true) && compareDeep(regionsCalled, o.regionsCalled, true) 1426 && compareDeep(input, o.input, true) && compareDeep(output, o.output, true) && compareDeep(performer, o.performer, true) 1427 && compareDeep(device, o.device, true); 1428 } 1429 1430 @Override 1431 public boolean equalsShallow(Base other_) { 1432 if (!super.equalsShallow(other_)) 1433 return false; 1434 if (!(other_ instanceof GenomicStudyAnalysisComponent)) 1435 return false; 1436 GenomicStudyAnalysisComponent o = (GenomicStudyAnalysisComponent) other_; 1437 return compareValues(instantiatesCanonical, o.instantiatesCanonical, true) && compareValues(instantiatesUri, o.instantiatesUri, true) 1438 && compareValues(title, o.title, true) && compareValues(date, o.date, true); 1439 } 1440 1441 public boolean isEmpty() { 1442 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, methodType, changeType 1443 , genomeBuild, instantiatesCanonical, instantiatesUri, title, subject, specimen 1444 , date, note, protocolPerformed, regionsStudied, regionsCalled, input, output 1445 , performer, device); 1446 } 1447 1448 public String fhirType() { 1449 return "GenomicStudy.analysis"; 1450 1451 } 1452 1453 } 1454 1455 @Block() 1456 public static class GenomicStudyAnalysisInputComponent extends BackboneElement implements IBaseBackboneElement { 1457 /** 1458 * File containing input data. 1459 */ 1460 @Child(name = "file", type = {DocumentReference.class}, order=1, min=0, max=1, modifier=false, summary=false) 1461 @Description(shortDefinition="File containing input data", formalDefinition="File containing input data." ) 1462 protected Reference file; 1463 1464 /** 1465 * Type of input data, e.g., BAM, CRAM, or FASTA. 1466 */ 1467 @Child(name = "type", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 1468 @Description(shortDefinition="Type of input data (e.g., BAM, CRAM, or FASTA)", formalDefinition="Type of input data, e.g., BAM, CRAM, or FASTA." ) 1469 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/genomicstudy-dataformat") 1470 protected CodeableConcept type; 1471 1472 /** 1473 * The analysis event or other GenomicStudy that generated this input file. 1474 */ 1475 @Child(name = "generatedBy", type = {Identifier.class, GenomicStudy.class}, order=3, min=0, max=1, modifier=false, summary=false) 1476 @Description(shortDefinition="The analysis event or other GenomicStudy that generated this input file", formalDefinition="The analysis event or other GenomicStudy that generated this input file." ) 1477 protected DataType generatedBy; 1478 1479 private static final long serialVersionUID = -650883036L; 1480 1481 /** 1482 * Constructor 1483 */ 1484 public GenomicStudyAnalysisInputComponent() { 1485 super(); 1486 } 1487 1488 /** 1489 * @return {@link #file} (File containing input data.) 1490 */ 1491 public Reference getFile() { 1492 if (this.file == null) 1493 if (Configuration.errorOnAutoCreate()) 1494 throw new Error("Attempt to auto-create GenomicStudyAnalysisInputComponent.file"); 1495 else if (Configuration.doAutoCreate()) 1496 this.file = new Reference(); // cc 1497 return this.file; 1498 } 1499 1500 public boolean hasFile() { 1501 return this.file != null && !this.file.isEmpty(); 1502 } 1503 1504 /** 1505 * @param value {@link #file} (File containing input data.) 1506 */ 1507 public GenomicStudyAnalysisInputComponent setFile(Reference value) { 1508 this.file = value; 1509 return this; 1510 } 1511 1512 /** 1513 * @return {@link #type} (Type of input data, e.g., BAM, CRAM, or FASTA.) 1514 */ 1515 public CodeableConcept getType() { 1516 if (this.type == null) 1517 if (Configuration.errorOnAutoCreate()) 1518 throw new Error("Attempt to auto-create GenomicStudyAnalysisInputComponent.type"); 1519 else if (Configuration.doAutoCreate()) 1520 this.type = new CodeableConcept(); // cc 1521 return this.type; 1522 } 1523 1524 public boolean hasType() { 1525 return this.type != null && !this.type.isEmpty(); 1526 } 1527 1528 /** 1529 * @param value {@link #type} (Type of input data, e.g., BAM, CRAM, or FASTA.) 1530 */ 1531 public GenomicStudyAnalysisInputComponent setType(CodeableConcept value) { 1532 this.type = value; 1533 return this; 1534 } 1535 1536 /** 1537 * @return {@link #generatedBy} (The analysis event or other GenomicStudy that generated this input file.) 1538 */ 1539 public DataType getGeneratedBy() { 1540 return this.generatedBy; 1541 } 1542 1543 /** 1544 * @return {@link #generatedBy} (The analysis event or other GenomicStudy that generated this input file.) 1545 */ 1546 public Identifier getGeneratedByIdentifier() throws FHIRException { 1547 if (this.generatedBy == null) 1548 this.generatedBy = new Identifier(); 1549 if (!(this.generatedBy instanceof Identifier)) 1550 throw new FHIRException("Type mismatch: the type Identifier was expected, but "+this.generatedBy.getClass().getName()+" was encountered"); 1551 return (Identifier) this.generatedBy; 1552 } 1553 1554 public boolean hasGeneratedByIdentifier() { 1555 return this != null && this.generatedBy instanceof Identifier; 1556 } 1557 1558 /** 1559 * @return {@link #generatedBy} (The analysis event or other GenomicStudy that generated this input file.) 1560 */ 1561 public Reference getGeneratedByReference() throws FHIRException { 1562 if (this.generatedBy == null) 1563 this.generatedBy = new Reference(); 1564 if (!(this.generatedBy instanceof Reference)) 1565 throw new FHIRException("Type mismatch: the type Reference was expected, but "+this.generatedBy.getClass().getName()+" was encountered"); 1566 return (Reference) this.generatedBy; 1567 } 1568 1569 public boolean hasGeneratedByReference() { 1570 return this != null && this.generatedBy instanceof Reference; 1571 } 1572 1573 public boolean hasGeneratedBy() { 1574 return this.generatedBy != null && !this.generatedBy.isEmpty(); 1575 } 1576 1577 /** 1578 * @param value {@link #generatedBy} (The analysis event or other GenomicStudy that generated this input file.) 1579 */ 1580 public GenomicStudyAnalysisInputComponent setGeneratedBy(DataType value) { 1581 if (value != null && !(value instanceof Identifier || value instanceof Reference)) 1582 throw new Error("Not the right type for GenomicStudy.analysis.input.generatedBy[x]: "+value.fhirType()); 1583 this.generatedBy = value; 1584 return this; 1585 } 1586 1587 protected void listChildren(List<Property> children) { 1588 super.listChildren(children); 1589 children.add(new Property("file", "Reference(DocumentReference)", "File containing input data.", 0, 1, file)); 1590 children.add(new Property("type", "CodeableConcept", "Type of input data, e.g., BAM, CRAM, or FASTA.", 0, 1, type)); 1591 children.add(new Property("generatedBy[x]", "Identifier|Reference(GenomicStudy)", "The analysis event or other GenomicStudy that generated this input file.", 0, 1, generatedBy)); 1592 } 1593 1594 @Override 1595 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1596 switch (_hash) { 1597 case 3143036: /*file*/ return new Property("file", "Reference(DocumentReference)", "File containing input data.", 0, 1, file); 1598 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Type of input data, e.g., BAM, CRAM, or FASTA.", 0, 1, type); 1599 case -1669563270: /*generatedBy[x]*/ return new Property("generatedBy[x]", "Identifier|Reference(GenomicStudy)", "The analysis event or other GenomicStudy that generated this input file.", 0, 1, generatedBy); 1600 case 886733382: /*generatedBy*/ return new Property("generatedBy[x]", "Identifier|Reference(GenomicStudy)", "The analysis event or other GenomicStudy that generated this input file.", 0, 1, generatedBy); 1601 case 913138575: /*generatedByIdentifier*/ return new Property("generatedBy[x]", "Identifier", "The analysis event or other GenomicStudy that generated this input file.", 0, 1, generatedBy); 1602 case -1397681243: /*generatedByReference*/ return new Property("generatedBy[x]", "Reference(GenomicStudy)", "The analysis event or other GenomicStudy that generated this input file.", 0, 1, generatedBy); 1603 default: return super.getNamedProperty(_hash, _name, _checkValid); 1604 } 1605 1606 } 1607 1608 @Override 1609 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1610 switch (hash) { 1611 case 3143036: /*file*/ return this.file == null ? new Base[0] : new Base[] {this.file}; // Reference 1612 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 1613 case 886733382: /*generatedBy*/ return this.generatedBy == null ? new Base[0] : new Base[] {this.generatedBy}; // DataType 1614 default: return super.getProperty(hash, name, checkValid); 1615 } 1616 1617 } 1618 1619 @Override 1620 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1621 switch (hash) { 1622 case 3143036: // file 1623 this.file = TypeConvertor.castToReference(value); // Reference 1624 return value; 1625 case 3575610: // type 1626 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1627 return value; 1628 case 886733382: // generatedBy 1629 this.generatedBy = TypeConvertor.castToType(value); // DataType 1630 return value; 1631 default: return super.setProperty(hash, name, value); 1632 } 1633 1634 } 1635 1636 @Override 1637 public Base setProperty(String name, Base value) throws FHIRException { 1638 if (name.equals("file")) { 1639 this.file = TypeConvertor.castToReference(value); // Reference 1640 } else if (name.equals("type")) { 1641 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1642 } else if (name.equals("generatedBy[x]")) { 1643 this.generatedBy = TypeConvertor.castToType(value); // DataType 1644 } else 1645 return super.setProperty(name, value); 1646 return value; 1647 } 1648 1649 @Override 1650 public Base makeProperty(int hash, String name) throws FHIRException { 1651 switch (hash) { 1652 case 3143036: return getFile(); 1653 case 3575610: return getType(); 1654 case -1669563270: return getGeneratedBy(); 1655 case 886733382: return getGeneratedBy(); 1656 default: return super.makeProperty(hash, name); 1657 } 1658 1659 } 1660 1661 @Override 1662 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1663 switch (hash) { 1664 case 3143036: /*file*/ return new String[] {"Reference"}; 1665 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 1666 case 886733382: /*generatedBy*/ return new String[] {"Identifier", "Reference"}; 1667 default: return super.getTypesForProperty(hash, name); 1668 } 1669 1670 } 1671 1672 @Override 1673 public Base addChild(String name) throws FHIRException { 1674 if (name.equals("file")) { 1675 this.file = new Reference(); 1676 return this.file; 1677 } 1678 else if (name.equals("type")) { 1679 this.type = new CodeableConcept(); 1680 return this.type; 1681 } 1682 else if (name.equals("generatedByIdentifier")) { 1683 this.generatedBy = new Identifier(); 1684 return this.generatedBy; 1685 } 1686 else if (name.equals("generatedByReference")) { 1687 this.generatedBy = new Reference(); 1688 return this.generatedBy; 1689 } 1690 else 1691 return super.addChild(name); 1692 } 1693 1694 public GenomicStudyAnalysisInputComponent copy() { 1695 GenomicStudyAnalysisInputComponent dst = new GenomicStudyAnalysisInputComponent(); 1696 copyValues(dst); 1697 return dst; 1698 } 1699 1700 public void copyValues(GenomicStudyAnalysisInputComponent dst) { 1701 super.copyValues(dst); 1702 dst.file = file == null ? null : file.copy(); 1703 dst.type = type == null ? null : type.copy(); 1704 dst.generatedBy = generatedBy == null ? null : generatedBy.copy(); 1705 } 1706 1707 @Override 1708 public boolean equalsDeep(Base other_) { 1709 if (!super.equalsDeep(other_)) 1710 return false; 1711 if (!(other_ instanceof GenomicStudyAnalysisInputComponent)) 1712 return false; 1713 GenomicStudyAnalysisInputComponent o = (GenomicStudyAnalysisInputComponent) other_; 1714 return compareDeep(file, o.file, true) && compareDeep(type, o.type, true) && compareDeep(generatedBy, o.generatedBy, true) 1715 ; 1716 } 1717 1718 @Override 1719 public boolean equalsShallow(Base other_) { 1720 if (!super.equalsShallow(other_)) 1721 return false; 1722 if (!(other_ instanceof GenomicStudyAnalysisInputComponent)) 1723 return false; 1724 GenomicStudyAnalysisInputComponent o = (GenomicStudyAnalysisInputComponent) other_; 1725 return true; 1726 } 1727 1728 public boolean isEmpty() { 1729 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(file, type, generatedBy 1730 ); 1731 } 1732 1733 public String fhirType() { 1734 return "GenomicStudy.analysis.input"; 1735 1736 } 1737 1738 } 1739 1740 @Block() 1741 public static class GenomicStudyAnalysisOutputComponent extends BackboneElement implements IBaseBackboneElement { 1742 /** 1743 * File containing output data. 1744 */ 1745 @Child(name = "file", type = {DocumentReference.class}, order=1, min=0, max=1, modifier=false, summary=false) 1746 @Description(shortDefinition="File containing output data", formalDefinition="File containing output data." ) 1747 protected Reference file; 1748 1749 /** 1750 * Type of output data, e.g., VCF, MAF, or BAM. 1751 */ 1752 @Child(name = "type", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 1753 @Description(shortDefinition="Type of output data (e.g., VCF, MAF, or BAM)", formalDefinition="Type of output data, e.g., VCF, MAF, or BAM." ) 1754 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/genomicstudy-dataformat") 1755 protected CodeableConcept type; 1756 1757 private static final long serialVersionUID = -2075265800L; 1758 1759 /** 1760 * Constructor 1761 */ 1762 public GenomicStudyAnalysisOutputComponent() { 1763 super(); 1764 } 1765 1766 /** 1767 * @return {@link #file} (File containing output data.) 1768 */ 1769 public Reference getFile() { 1770 if (this.file == null) 1771 if (Configuration.errorOnAutoCreate()) 1772 throw new Error("Attempt to auto-create GenomicStudyAnalysisOutputComponent.file"); 1773 else if (Configuration.doAutoCreate()) 1774 this.file = new Reference(); // cc 1775 return this.file; 1776 } 1777 1778 public boolean hasFile() { 1779 return this.file != null && !this.file.isEmpty(); 1780 } 1781 1782 /** 1783 * @param value {@link #file} (File containing output data.) 1784 */ 1785 public GenomicStudyAnalysisOutputComponent setFile(Reference value) { 1786 this.file = value; 1787 return this; 1788 } 1789 1790 /** 1791 * @return {@link #type} (Type of output data, e.g., VCF, MAF, or BAM.) 1792 */ 1793 public CodeableConcept getType() { 1794 if (this.type == null) 1795 if (Configuration.errorOnAutoCreate()) 1796 throw new Error("Attempt to auto-create GenomicStudyAnalysisOutputComponent.type"); 1797 else if (Configuration.doAutoCreate()) 1798 this.type = new CodeableConcept(); // cc 1799 return this.type; 1800 } 1801 1802 public boolean hasType() { 1803 return this.type != null && !this.type.isEmpty(); 1804 } 1805 1806 /** 1807 * @param value {@link #type} (Type of output data, e.g., VCF, MAF, or BAM.) 1808 */ 1809 public GenomicStudyAnalysisOutputComponent setType(CodeableConcept value) { 1810 this.type = value; 1811 return this; 1812 } 1813 1814 protected void listChildren(List<Property> children) { 1815 super.listChildren(children); 1816 children.add(new Property("file", "Reference(DocumentReference)", "File containing output data.", 0, 1, file)); 1817 children.add(new Property("type", "CodeableConcept", "Type of output data, e.g., VCF, MAF, or BAM.", 0, 1, type)); 1818 } 1819 1820 @Override 1821 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1822 switch (_hash) { 1823 case 3143036: /*file*/ return new Property("file", "Reference(DocumentReference)", "File containing output data.", 0, 1, file); 1824 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Type of output data, e.g., VCF, MAF, or BAM.", 0, 1, type); 1825 default: return super.getNamedProperty(_hash, _name, _checkValid); 1826 } 1827 1828 } 1829 1830 @Override 1831 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1832 switch (hash) { 1833 case 3143036: /*file*/ return this.file == null ? new Base[0] : new Base[] {this.file}; // Reference 1834 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 1835 default: return super.getProperty(hash, name, checkValid); 1836 } 1837 1838 } 1839 1840 @Override 1841 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1842 switch (hash) { 1843 case 3143036: // file 1844 this.file = TypeConvertor.castToReference(value); // Reference 1845 return value; 1846 case 3575610: // type 1847 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1848 return value; 1849 default: return super.setProperty(hash, name, value); 1850 } 1851 1852 } 1853 1854 @Override 1855 public Base setProperty(String name, Base value) throws FHIRException { 1856 if (name.equals("file")) { 1857 this.file = TypeConvertor.castToReference(value); // Reference 1858 } else if (name.equals("type")) { 1859 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1860 } else 1861 return super.setProperty(name, value); 1862 return value; 1863 } 1864 1865 @Override 1866 public Base makeProperty(int hash, String name) throws FHIRException { 1867 switch (hash) { 1868 case 3143036: return getFile(); 1869 case 3575610: return getType(); 1870 default: return super.makeProperty(hash, name); 1871 } 1872 1873 } 1874 1875 @Override 1876 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1877 switch (hash) { 1878 case 3143036: /*file*/ return new String[] {"Reference"}; 1879 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 1880 default: return super.getTypesForProperty(hash, name); 1881 } 1882 1883 } 1884 1885 @Override 1886 public Base addChild(String name) throws FHIRException { 1887 if (name.equals("file")) { 1888 this.file = new Reference(); 1889 return this.file; 1890 } 1891 else if (name.equals("type")) { 1892 this.type = new CodeableConcept(); 1893 return this.type; 1894 } 1895 else 1896 return super.addChild(name); 1897 } 1898 1899 public GenomicStudyAnalysisOutputComponent copy() { 1900 GenomicStudyAnalysisOutputComponent dst = new GenomicStudyAnalysisOutputComponent(); 1901 copyValues(dst); 1902 return dst; 1903 } 1904 1905 public void copyValues(GenomicStudyAnalysisOutputComponent dst) { 1906 super.copyValues(dst); 1907 dst.file = file == null ? null : file.copy(); 1908 dst.type = type == null ? null : type.copy(); 1909 } 1910 1911 @Override 1912 public boolean equalsDeep(Base other_) { 1913 if (!super.equalsDeep(other_)) 1914 return false; 1915 if (!(other_ instanceof GenomicStudyAnalysisOutputComponent)) 1916 return false; 1917 GenomicStudyAnalysisOutputComponent o = (GenomicStudyAnalysisOutputComponent) other_; 1918 return compareDeep(file, o.file, true) && compareDeep(type, o.type, true); 1919 } 1920 1921 @Override 1922 public boolean equalsShallow(Base other_) { 1923 if (!super.equalsShallow(other_)) 1924 return false; 1925 if (!(other_ instanceof GenomicStudyAnalysisOutputComponent)) 1926 return false; 1927 GenomicStudyAnalysisOutputComponent o = (GenomicStudyAnalysisOutputComponent) other_; 1928 return true; 1929 } 1930 1931 public boolean isEmpty() { 1932 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(file, type); 1933 } 1934 1935 public String fhirType() { 1936 return "GenomicStudy.analysis.output"; 1937 1938 } 1939 1940 } 1941 1942 @Block() 1943 public static class GenomicStudyAnalysisPerformerComponent extends BackboneElement implements IBaseBackboneElement { 1944 /** 1945 * The organization, healthcare professional, or others who participated in performing this analysis. 1946 */ 1947 @Child(name = "actor", type = {Practitioner.class, PractitionerRole.class, Organization.class, Device.class}, order=1, min=0, max=1, modifier=false, summary=false) 1948 @Description(shortDefinition="The organization, healthcare professional, or others who participated in performing this analysis", formalDefinition="The organization, healthcare professional, or others who participated in performing this analysis." ) 1949 protected Reference actor; 1950 1951 /** 1952 * Role of the actor for this analysis. 1953 */ 1954 @Child(name = "role", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 1955 @Description(shortDefinition="Role of the actor for this analysis", formalDefinition="Role of the actor for this analysis." ) 1956 protected CodeableConcept role; 1957 1958 private static final long serialVersionUID = 827444743L; 1959 1960 /** 1961 * Constructor 1962 */ 1963 public GenomicStudyAnalysisPerformerComponent() { 1964 super(); 1965 } 1966 1967 /** 1968 * @return {@link #actor} (The organization, healthcare professional, or others who participated in performing this analysis.) 1969 */ 1970 public Reference getActor() { 1971 if (this.actor == null) 1972 if (Configuration.errorOnAutoCreate()) 1973 throw new Error("Attempt to auto-create GenomicStudyAnalysisPerformerComponent.actor"); 1974 else if (Configuration.doAutoCreate()) 1975 this.actor = new Reference(); // cc 1976 return this.actor; 1977 } 1978 1979 public boolean hasActor() { 1980 return this.actor != null && !this.actor.isEmpty(); 1981 } 1982 1983 /** 1984 * @param value {@link #actor} (The organization, healthcare professional, or others who participated in performing this analysis.) 1985 */ 1986 public GenomicStudyAnalysisPerformerComponent setActor(Reference value) { 1987 this.actor = value; 1988 return this; 1989 } 1990 1991 /** 1992 * @return {@link #role} (Role of the actor for this analysis.) 1993 */ 1994 public CodeableConcept getRole() { 1995 if (this.role == null) 1996 if (Configuration.errorOnAutoCreate()) 1997 throw new Error("Attempt to auto-create GenomicStudyAnalysisPerformerComponent.role"); 1998 else if (Configuration.doAutoCreate()) 1999 this.role = new CodeableConcept(); // cc 2000 return this.role; 2001 } 2002 2003 public boolean hasRole() { 2004 return this.role != null && !this.role.isEmpty(); 2005 } 2006 2007 /** 2008 * @param value {@link #role} (Role of the actor for this analysis.) 2009 */ 2010 public GenomicStudyAnalysisPerformerComponent setRole(CodeableConcept value) { 2011 this.role = value; 2012 return this; 2013 } 2014 2015 protected void listChildren(List<Property> children) { 2016 super.listChildren(children); 2017 children.add(new Property("actor", "Reference(Practitioner|PractitionerRole|Organization|Device)", "The organization, healthcare professional, or others who participated in performing this analysis.", 0, 1, actor)); 2018 children.add(new Property("role", "CodeableConcept", "Role of the actor for this analysis.", 0, 1, role)); 2019 } 2020 2021 @Override 2022 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2023 switch (_hash) { 2024 case 92645877: /*actor*/ return new Property("actor", "Reference(Practitioner|PractitionerRole|Organization|Device)", "The organization, healthcare professional, or others who participated in performing this analysis.", 0, 1, actor); 2025 case 3506294: /*role*/ return new Property("role", "CodeableConcept", "Role of the actor for this analysis.", 0, 1, role); 2026 default: return super.getNamedProperty(_hash, _name, _checkValid); 2027 } 2028 2029 } 2030 2031 @Override 2032 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2033 switch (hash) { 2034 case 92645877: /*actor*/ return this.actor == null ? new Base[0] : new Base[] {this.actor}; // Reference 2035 case 3506294: /*role*/ return this.role == null ? new Base[0] : new Base[] {this.role}; // CodeableConcept 2036 default: return super.getProperty(hash, name, checkValid); 2037 } 2038 2039 } 2040 2041 @Override 2042 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2043 switch (hash) { 2044 case 92645877: // actor 2045 this.actor = TypeConvertor.castToReference(value); // Reference 2046 return value; 2047 case 3506294: // role 2048 this.role = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2049 return value; 2050 default: return super.setProperty(hash, name, value); 2051 } 2052 2053 } 2054 2055 @Override 2056 public Base setProperty(String name, Base value) throws FHIRException { 2057 if (name.equals("actor")) { 2058 this.actor = TypeConvertor.castToReference(value); // Reference 2059 } else if (name.equals("role")) { 2060 this.role = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2061 } else 2062 return super.setProperty(name, value); 2063 return value; 2064 } 2065 2066 @Override 2067 public Base makeProperty(int hash, String name) throws FHIRException { 2068 switch (hash) { 2069 case 92645877: return getActor(); 2070 case 3506294: return getRole(); 2071 default: return super.makeProperty(hash, name); 2072 } 2073 2074 } 2075 2076 @Override 2077 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2078 switch (hash) { 2079 case 92645877: /*actor*/ return new String[] {"Reference"}; 2080 case 3506294: /*role*/ return new String[] {"CodeableConcept"}; 2081 default: return super.getTypesForProperty(hash, name); 2082 } 2083 2084 } 2085 2086 @Override 2087 public Base addChild(String name) throws FHIRException { 2088 if (name.equals("actor")) { 2089 this.actor = new Reference(); 2090 return this.actor; 2091 } 2092 else if (name.equals("role")) { 2093 this.role = new CodeableConcept(); 2094 return this.role; 2095 } 2096 else 2097 return super.addChild(name); 2098 } 2099 2100 public GenomicStudyAnalysisPerformerComponent copy() { 2101 GenomicStudyAnalysisPerformerComponent dst = new GenomicStudyAnalysisPerformerComponent(); 2102 copyValues(dst); 2103 return dst; 2104 } 2105 2106 public void copyValues(GenomicStudyAnalysisPerformerComponent dst) { 2107 super.copyValues(dst); 2108 dst.actor = actor == null ? null : actor.copy(); 2109 dst.role = role == null ? null : role.copy(); 2110 } 2111 2112 @Override 2113 public boolean equalsDeep(Base other_) { 2114 if (!super.equalsDeep(other_)) 2115 return false; 2116 if (!(other_ instanceof GenomicStudyAnalysisPerformerComponent)) 2117 return false; 2118 GenomicStudyAnalysisPerformerComponent o = (GenomicStudyAnalysisPerformerComponent) other_; 2119 return compareDeep(actor, o.actor, true) && compareDeep(role, o.role, true); 2120 } 2121 2122 @Override 2123 public boolean equalsShallow(Base other_) { 2124 if (!super.equalsShallow(other_)) 2125 return false; 2126 if (!(other_ instanceof GenomicStudyAnalysisPerformerComponent)) 2127 return false; 2128 GenomicStudyAnalysisPerformerComponent o = (GenomicStudyAnalysisPerformerComponent) other_; 2129 return true; 2130 } 2131 2132 public boolean isEmpty() { 2133 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(actor, role); 2134 } 2135 2136 public String fhirType() { 2137 return "GenomicStudy.analysis.performer"; 2138 2139 } 2140 2141 } 2142 2143 @Block() 2144 public static class GenomicStudyAnalysisDeviceComponent extends BackboneElement implements IBaseBackboneElement { 2145 /** 2146 * Device used for the analysis. 2147 */ 2148 @Child(name = "device", type = {Device.class}, order=1, min=0, max=1, modifier=false, summary=false) 2149 @Description(shortDefinition="Device used for the analysis", formalDefinition="Device used for the analysis." ) 2150 protected Reference device; 2151 2152 /** 2153 * Specific function for the device used for the analysis. 2154 */ 2155 @Child(name = "function", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 2156 @Description(shortDefinition="Specific function for the device used for the analysis", formalDefinition="Specific function for the device used for the analysis." ) 2157 protected CodeableConcept function; 2158 2159 private static final long serialVersionUID = 1643933108L; 2160 2161 /** 2162 * Constructor 2163 */ 2164 public GenomicStudyAnalysisDeviceComponent() { 2165 super(); 2166 } 2167 2168 /** 2169 * @return {@link #device} (Device used for the analysis.) 2170 */ 2171 public Reference getDevice() { 2172 if (this.device == null) 2173 if (Configuration.errorOnAutoCreate()) 2174 throw new Error("Attempt to auto-create GenomicStudyAnalysisDeviceComponent.device"); 2175 else if (Configuration.doAutoCreate()) 2176 this.device = new Reference(); // cc 2177 return this.device; 2178 } 2179 2180 public boolean hasDevice() { 2181 return this.device != null && !this.device.isEmpty(); 2182 } 2183 2184 /** 2185 * @param value {@link #device} (Device used for the analysis.) 2186 */ 2187 public GenomicStudyAnalysisDeviceComponent setDevice(Reference value) { 2188 this.device = value; 2189 return this; 2190 } 2191 2192 /** 2193 * @return {@link #function} (Specific function for the device used for the analysis.) 2194 */ 2195 public CodeableConcept getFunction() { 2196 if (this.function == null) 2197 if (Configuration.errorOnAutoCreate()) 2198 throw new Error("Attempt to auto-create GenomicStudyAnalysisDeviceComponent.function"); 2199 else if (Configuration.doAutoCreate()) 2200 this.function = new CodeableConcept(); // cc 2201 return this.function; 2202 } 2203 2204 public boolean hasFunction() { 2205 return this.function != null && !this.function.isEmpty(); 2206 } 2207 2208 /** 2209 * @param value {@link #function} (Specific function for the device used for the analysis.) 2210 */ 2211 public GenomicStudyAnalysisDeviceComponent setFunction(CodeableConcept value) { 2212 this.function = value; 2213 return this; 2214 } 2215 2216 protected void listChildren(List<Property> children) { 2217 super.listChildren(children); 2218 children.add(new Property("device", "Reference(Device)", "Device used for the analysis.", 0, 1, device)); 2219 children.add(new Property("function", "CodeableConcept", "Specific function for the device used for the analysis.", 0, 1, function)); 2220 } 2221 2222 @Override 2223 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2224 switch (_hash) { 2225 case -1335157162: /*device*/ return new Property("device", "Reference(Device)", "Device used for the analysis.", 0, 1, device); 2226 case 1380938712: /*function*/ return new Property("function", "CodeableConcept", "Specific function for the device used for the analysis.", 0, 1, function); 2227 default: return super.getNamedProperty(_hash, _name, _checkValid); 2228 } 2229 2230 } 2231 2232 @Override 2233 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2234 switch (hash) { 2235 case -1335157162: /*device*/ return this.device == null ? new Base[0] : new Base[] {this.device}; // Reference 2236 case 1380938712: /*function*/ return this.function == null ? new Base[0] : new Base[] {this.function}; // CodeableConcept 2237 default: return super.getProperty(hash, name, checkValid); 2238 } 2239 2240 } 2241 2242 @Override 2243 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2244 switch (hash) { 2245 case -1335157162: // device 2246 this.device = TypeConvertor.castToReference(value); // Reference 2247 return value; 2248 case 1380938712: // function 2249 this.function = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2250 return value; 2251 default: return super.setProperty(hash, name, value); 2252 } 2253 2254 } 2255 2256 @Override 2257 public Base setProperty(String name, Base value) throws FHIRException { 2258 if (name.equals("device")) { 2259 this.device = TypeConvertor.castToReference(value); // Reference 2260 } else if (name.equals("function")) { 2261 this.function = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2262 } else 2263 return super.setProperty(name, value); 2264 return value; 2265 } 2266 2267 @Override 2268 public Base makeProperty(int hash, String name) throws FHIRException { 2269 switch (hash) { 2270 case -1335157162: return getDevice(); 2271 case 1380938712: return getFunction(); 2272 default: return super.makeProperty(hash, name); 2273 } 2274 2275 } 2276 2277 @Override 2278 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2279 switch (hash) { 2280 case -1335157162: /*device*/ return new String[] {"Reference"}; 2281 case 1380938712: /*function*/ return new String[] {"CodeableConcept"}; 2282 default: return super.getTypesForProperty(hash, name); 2283 } 2284 2285 } 2286 2287 @Override 2288 public Base addChild(String name) throws FHIRException { 2289 if (name.equals("device")) { 2290 this.device = new Reference(); 2291 return this.device; 2292 } 2293 else if (name.equals("function")) { 2294 this.function = new CodeableConcept(); 2295 return this.function; 2296 } 2297 else 2298 return super.addChild(name); 2299 } 2300 2301 public GenomicStudyAnalysisDeviceComponent copy() { 2302 GenomicStudyAnalysisDeviceComponent dst = new GenomicStudyAnalysisDeviceComponent(); 2303 copyValues(dst); 2304 return dst; 2305 } 2306 2307 public void copyValues(GenomicStudyAnalysisDeviceComponent dst) { 2308 super.copyValues(dst); 2309 dst.device = device == null ? null : device.copy(); 2310 dst.function = function == null ? null : function.copy(); 2311 } 2312 2313 @Override 2314 public boolean equalsDeep(Base other_) { 2315 if (!super.equalsDeep(other_)) 2316 return false; 2317 if (!(other_ instanceof GenomicStudyAnalysisDeviceComponent)) 2318 return false; 2319 GenomicStudyAnalysisDeviceComponent o = (GenomicStudyAnalysisDeviceComponent) other_; 2320 return compareDeep(device, o.device, true) && compareDeep(function, o.function, true); 2321 } 2322 2323 @Override 2324 public boolean equalsShallow(Base other_) { 2325 if (!super.equalsShallow(other_)) 2326 return false; 2327 if (!(other_ instanceof GenomicStudyAnalysisDeviceComponent)) 2328 return false; 2329 GenomicStudyAnalysisDeviceComponent o = (GenomicStudyAnalysisDeviceComponent) other_; 2330 return true; 2331 } 2332 2333 public boolean isEmpty() { 2334 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(device, function); 2335 } 2336 2337 public String fhirType() { 2338 return "GenomicStudy.analysis.device"; 2339 2340 } 2341 2342 } 2343 2344 /** 2345 * Identifiers for this genomic study. 2346 */ 2347 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2348 @Description(shortDefinition="Identifiers for this genomic study", formalDefinition="Identifiers for this genomic study." ) 2349 protected List<Identifier> identifier; 2350 2351 /** 2352 * The status of the genomic study. 2353 */ 2354 @Child(name = "status", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=true, summary=true) 2355 @Description(shortDefinition="The status of the genomic study", formalDefinition="The status of the genomic study." ) 2356 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/genomicstudy-status") 2357 protected CodeableConcept status; 2358 2359 /** 2360 * The type of the study, e.g., Familial variant segregation, Functional variation detection, or Gene expression profiling. 2361 */ 2362 @Child(name = "type", type = {CodeableConcept.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2363 @Description(shortDefinition="The type of the study (e.g., Familial variant segregation, Functional variation detection, or Gene expression profiling)", formalDefinition="The type of the study, e.g., Familial variant segregation, Functional variation detection, or Gene expression profiling." ) 2364 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/genomicstudy-type") 2365 protected List<CodeableConcept> type; 2366 2367 /** 2368 * The primary subject of the genomic study. 2369 */ 2370 @Child(name = "subject", type = {Patient.class, Group.class, Device.class, Location.class, Organization.class, Procedure.class, Practitioner.class, Medication.class, Substance.class, BiologicallyDerivedProduct.class, NutritionProduct.class}, order=3, min=1, max=1, modifier=false, summary=true) 2371 @Description(shortDefinition="The primary subject of the genomic study", formalDefinition="The primary subject of the genomic study." ) 2372 protected Reference subject; 2373 2374 /** 2375 * The healthcare event with which this genomics study is associated. 2376 */ 2377 @Child(name = "encounter", type = {Encounter.class}, order=4, min=0, max=1, modifier=false, summary=false) 2378 @Description(shortDefinition="The healthcare event with which this genomics study is associated", formalDefinition="The healthcare event with which this genomics study is associated." ) 2379 protected Reference encounter; 2380 2381 /** 2382 * When the genomic study was started. 2383 */ 2384 @Child(name = "startDate", type = {DateTimeType.class}, order=5, min=0, max=1, modifier=false, summary=false) 2385 @Description(shortDefinition="When the genomic study was started", formalDefinition="When the genomic study was started." ) 2386 protected DateTimeType startDate; 2387 2388 /** 2389 * Event resources that the genomic study is based on. 2390 */ 2391 @Child(name = "basedOn", type = {ServiceRequest.class, Task.class}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2392 @Description(shortDefinition="Event resources that the genomic study is based on", formalDefinition="Event resources that the genomic study is based on." ) 2393 protected List<Reference> basedOn; 2394 2395 /** 2396 * Healthcare professional who requested or referred the genomic study. 2397 */ 2398 @Child(name = "referrer", type = {Practitioner.class, PractitionerRole.class}, order=7, min=0, max=1, modifier=false, summary=false) 2399 @Description(shortDefinition="Healthcare professional who requested or referred the genomic study", formalDefinition="Healthcare professional who requested or referred the genomic study." ) 2400 protected Reference referrer; 2401 2402 /** 2403 * Healthcare professionals who interpreted the genomic study. 2404 */ 2405 @Child(name = "interpreter", type = {Practitioner.class, PractitionerRole.class}, order=8, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2406 @Description(shortDefinition="Healthcare professionals who interpreted the genomic study", formalDefinition="Healthcare professionals who interpreted the genomic study." ) 2407 protected List<Reference> interpreter; 2408 2409 /** 2410 * Why the genomic study was performed. 2411 */ 2412 @Child(name = "reason", type = {CodeableReference.class}, order=9, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2413 @Description(shortDefinition="Why the genomic study was performed", formalDefinition="Why the genomic study was performed." ) 2414 protected List<CodeableReference> reason; 2415 2416 /** 2417 * The defined protocol that describes the study. 2418 */ 2419 @Child(name = "instantiatesCanonical", type = {CanonicalType.class}, order=10, min=0, max=1, modifier=false, summary=false) 2420 @Description(shortDefinition="The defined protocol that describes the study", formalDefinition="The defined protocol that describes the study." ) 2421 protected CanonicalType instantiatesCanonical; 2422 2423 /** 2424 * The URL pointing to an externally maintained protocol that describes the study. 2425 */ 2426 @Child(name = "instantiatesUri", type = {UriType.class}, order=11, min=0, max=1, modifier=false, summary=false) 2427 @Description(shortDefinition="The URL pointing to an externally maintained protocol that describes the study", formalDefinition="The URL pointing to an externally maintained protocol that describes the study." ) 2428 protected UriType instantiatesUri; 2429 2430 /** 2431 * Comments related to the genomic study. 2432 */ 2433 @Child(name = "note", type = {Annotation.class}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2434 @Description(shortDefinition="Comments related to the genomic study", formalDefinition="Comments related to the genomic study." ) 2435 protected List<Annotation> note; 2436 2437 /** 2438 * Description of the genomic study. 2439 */ 2440 @Child(name = "description", type = {StringType.class}, order=13, min=0, max=1, modifier=false, summary=false) 2441 @Description(shortDefinition="Description of the genomic study", formalDefinition="Description of the genomic study." ) 2442 protected StringType description; 2443 2444 /** 2445 * The details about a specific analysis that was performed in this GenomicStudy. 2446 */ 2447 @Child(name = "analysis", type = {}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2448 @Description(shortDefinition="Genomic Analysis Event", formalDefinition="The details about a specific analysis that was performed in this GenomicStudy." ) 2449 protected List<GenomicStudyAnalysisComponent> analysis; 2450 2451 private static final long serialVersionUID = -345111606L; 2452 2453 /** 2454 * Constructor 2455 */ 2456 public GenomicStudy() { 2457 super(); 2458 } 2459 2460 /** 2461 * Constructor 2462 */ 2463 public GenomicStudy(CodeableConcept status, Reference subject) { 2464 super(); 2465 this.setStatus(status); 2466 this.setSubject(subject); 2467 } 2468 2469 /** 2470 * @return {@link #identifier} (Identifiers for this genomic study.) 2471 */ 2472 public List<Identifier> getIdentifier() { 2473 if (this.identifier == null) 2474 this.identifier = new ArrayList<Identifier>(); 2475 return this.identifier; 2476 } 2477 2478 /** 2479 * @return Returns a reference to <code>this</code> for easy method chaining 2480 */ 2481 public GenomicStudy setIdentifier(List<Identifier> theIdentifier) { 2482 this.identifier = theIdentifier; 2483 return this; 2484 } 2485 2486 public boolean hasIdentifier() { 2487 if (this.identifier == null) 2488 return false; 2489 for (Identifier item : this.identifier) 2490 if (!item.isEmpty()) 2491 return true; 2492 return false; 2493 } 2494 2495 public Identifier addIdentifier() { //3 2496 Identifier t = new Identifier(); 2497 if (this.identifier == null) 2498 this.identifier = new ArrayList<Identifier>(); 2499 this.identifier.add(t); 2500 return t; 2501 } 2502 2503 public GenomicStudy addIdentifier(Identifier t) { //3 2504 if (t == null) 2505 return this; 2506 if (this.identifier == null) 2507 this.identifier = new ArrayList<Identifier>(); 2508 this.identifier.add(t); 2509 return this; 2510 } 2511 2512 /** 2513 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist {3} 2514 */ 2515 public Identifier getIdentifierFirstRep() { 2516 if (getIdentifier().isEmpty()) { 2517 addIdentifier(); 2518 } 2519 return getIdentifier().get(0); 2520 } 2521 2522 /** 2523 * @return {@link #status} (The status of the genomic study.) 2524 */ 2525 public CodeableConcept getStatus() { 2526 if (this.status == null) 2527 if (Configuration.errorOnAutoCreate()) 2528 throw new Error("Attempt to auto-create GenomicStudy.status"); 2529 else if (Configuration.doAutoCreate()) 2530 this.status = new CodeableConcept(); // cc 2531 return this.status; 2532 } 2533 2534 public boolean hasStatus() { 2535 return this.status != null && !this.status.isEmpty(); 2536 } 2537 2538 /** 2539 * @param value {@link #status} (The status of the genomic study.) 2540 */ 2541 public GenomicStudy setStatus(CodeableConcept value) { 2542 this.status = value; 2543 return this; 2544 } 2545 2546 /** 2547 * @return {@link #type} (The type of the study, e.g., Familial variant segregation, Functional variation detection, or Gene expression profiling.) 2548 */ 2549 public List<CodeableConcept> getType() { 2550 if (this.type == null) 2551 this.type = new ArrayList<CodeableConcept>(); 2552 return this.type; 2553 } 2554 2555 /** 2556 * @return Returns a reference to <code>this</code> for easy method chaining 2557 */ 2558 public GenomicStudy setType(List<CodeableConcept> theType) { 2559 this.type = theType; 2560 return this; 2561 } 2562 2563 public boolean hasType() { 2564 if (this.type == null) 2565 return false; 2566 for (CodeableConcept item : this.type) 2567 if (!item.isEmpty()) 2568 return true; 2569 return false; 2570 } 2571 2572 public CodeableConcept addType() { //3 2573 CodeableConcept t = new CodeableConcept(); 2574 if (this.type == null) 2575 this.type = new ArrayList<CodeableConcept>(); 2576 this.type.add(t); 2577 return t; 2578 } 2579 2580 public GenomicStudy addType(CodeableConcept t) { //3 2581 if (t == null) 2582 return this; 2583 if (this.type == null) 2584 this.type = new ArrayList<CodeableConcept>(); 2585 this.type.add(t); 2586 return this; 2587 } 2588 2589 /** 2590 * @return The first repetition of repeating field {@link #type}, creating it if it does not already exist {3} 2591 */ 2592 public CodeableConcept getTypeFirstRep() { 2593 if (getType().isEmpty()) { 2594 addType(); 2595 } 2596 return getType().get(0); 2597 } 2598 2599 /** 2600 * @return {@link #subject} (The primary subject of the genomic study.) 2601 */ 2602 public Reference getSubject() { 2603 if (this.subject == null) 2604 if (Configuration.errorOnAutoCreate()) 2605 throw new Error("Attempt to auto-create GenomicStudy.subject"); 2606 else if (Configuration.doAutoCreate()) 2607 this.subject = new Reference(); // cc 2608 return this.subject; 2609 } 2610 2611 public boolean hasSubject() { 2612 return this.subject != null && !this.subject.isEmpty(); 2613 } 2614 2615 /** 2616 * @param value {@link #subject} (The primary subject of the genomic study.) 2617 */ 2618 public GenomicStudy setSubject(Reference value) { 2619 this.subject = value; 2620 return this; 2621 } 2622 2623 /** 2624 * @return {@link #encounter} (The healthcare event with which this genomics study is associated.) 2625 */ 2626 public Reference getEncounter() { 2627 if (this.encounter == null) 2628 if (Configuration.errorOnAutoCreate()) 2629 throw new Error("Attempt to auto-create GenomicStudy.encounter"); 2630 else if (Configuration.doAutoCreate()) 2631 this.encounter = new Reference(); // cc 2632 return this.encounter; 2633 } 2634 2635 public boolean hasEncounter() { 2636 return this.encounter != null && !this.encounter.isEmpty(); 2637 } 2638 2639 /** 2640 * @param value {@link #encounter} (The healthcare event with which this genomics study is associated.) 2641 */ 2642 public GenomicStudy setEncounter(Reference value) { 2643 this.encounter = value; 2644 return this; 2645 } 2646 2647 /** 2648 * @return {@link #startDate} (When the genomic study was started.). This is the underlying object with id, value and extensions. The accessor "getStartDate" gives direct access to the value 2649 */ 2650 public DateTimeType getStartDateElement() { 2651 if (this.startDate == null) 2652 if (Configuration.errorOnAutoCreate()) 2653 throw new Error("Attempt to auto-create GenomicStudy.startDate"); 2654 else if (Configuration.doAutoCreate()) 2655 this.startDate = new DateTimeType(); // bb 2656 return this.startDate; 2657 } 2658 2659 public boolean hasStartDateElement() { 2660 return this.startDate != null && !this.startDate.isEmpty(); 2661 } 2662 2663 public boolean hasStartDate() { 2664 return this.startDate != null && !this.startDate.isEmpty(); 2665 } 2666 2667 /** 2668 * @param value {@link #startDate} (When the genomic study was started.). This is the underlying object with id, value and extensions. The accessor "getStartDate" gives direct access to the value 2669 */ 2670 public GenomicStudy setStartDateElement(DateTimeType value) { 2671 this.startDate = value; 2672 return this; 2673 } 2674 2675 /** 2676 * @return When the genomic study was started. 2677 */ 2678 public Date getStartDate() { 2679 return this.startDate == null ? null : this.startDate.getValue(); 2680 } 2681 2682 /** 2683 * @param value When the genomic study was started. 2684 */ 2685 public GenomicStudy setStartDate(Date value) { 2686 if (value == null) 2687 this.startDate = null; 2688 else { 2689 if (this.startDate == null) 2690 this.startDate = new DateTimeType(); 2691 this.startDate.setValue(value); 2692 } 2693 return this; 2694 } 2695 2696 /** 2697 * @return {@link #basedOn} (Event resources that the genomic study is based on.) 2698 */ 2699 public List<Reference> getBasedOn() { 2700 if (this.basedOn == null) 2701 this.basedOn = new ArrayList<Reference>(); 2702 return this.basedOn; 2703 } 2704 2705 /** 2706 * @return Returns a reference to <code>this</code> for easy method chaining 2707 */ 2708 public GenomicStudy setBasedOn(List<Reference> theBasedOn) { 2709 this.basedOn = theBasedOn; 2710 return this; 2711 } 2712 2713 public boolean hasBasedOn() { 2714 if (this.basedOn == null) 2715 return false; 2716 for (Reference item : this.basedOn) 2717 if (!item.isEmpty()) 2718 return true; 2719 return false; 2720 } 2721 2722 public Reference addBasedOn() { //3 2723 Reference t = new Reference(); 2724 if (this.basedOn == null) 2725 this.basedOn = new ArrayList<Reference>(); 2726 this.basedOn.add(t); 2727 return t; 2728 } 2729 2730 public GenomicStudy addBasedOn(Reference t) { //3 2731 if (t == null) 2732 return this; 2733 if (this.basedOn == null) 2734 this.basedOn = new ArrayList<Reference>(); 2735 this.basedOn.add(t); 2736 return this; 2737 } 2738 2739 /** 2740 * @return The first repetition of repeating field {@link #basedOn}, creating it if it does not already exist {3} 2741 */ 2742 public Reference getBasedOnFirstRep() { 2743 if (getBasedOn().isEmpty()) { 2744 addBasedOn(); 2745 } 2746 return getBasedOn().get(0); 2747 } 2748 2749 /** 2750 * @return {@link #referrer} (Healthcare professional who requested or referred the genomic study.) 2751 */ 2752 public Reference getReferrer() { 2753 if (this.referrer == null) 2754 if (Configuration.errorOnAutoCreate()) 2755 throw new Error("Attempt to auto-create GenomicStudy.referrer"); 2756 else if (Configuration.doAutoCreate()) 2757 this.referrer = new Reference(); // cc 2758 return this.referrer; 2759 } 2760 2761 public boolean hasReferrer() { 2762 return this.referrer != null && !this.referrer.isEmpty(); 2763 } 2764 2765 /** 2766 * @param value {@link #referrer} (Healthcare professional who requested or referred the genomic study.) 2767 */ 2768 public GenomicStudy setReferrer(Reference value) { 2769 this.referrer = value; 2770 return this; 2771 } 2772 2773 /** 2774 * @return {@link #interpreter} (Healthcare professionals who interpreted the genomic study.) 2775 */ 2776 public List<Reference> getInterpreter() { 2777 if (this.interpreter == null) 2778 this.interpreter = new ArrayList<Reference>(); 2779 return this.interpreter; 2780 } 2781 2782 /** 2783 * @return Returns a reference to <code>this</code> for easy method chaining 2784 */ 2785 public GenomicStudy setInterpreter(List<Reference> theInterpreter) { 2786 this.interpreter = theInterpreter; 2787 return this; 2788 } 2789 2790 public boolean hasInterpreter() { 2791 if (this.interpreter == null) 2792 return false; 2793 for (Reference item : this.interpreter) 2794 if (!item.isEmpty()) 2795 return true; 2796 return false; 2797 } 2798 2799 public Reference addInterpreter() { //3 2800 Reference t = new Reference(); 2801 if (this.interpreter == null) 2802 this.interpreter = new ArrayList<Reference>(); 2803 this.interpreter.add(t); 2804 return t; 2805 } 2806 2807 public GenomicStudy addInterpreter(Reference t) { //3 2808 if (t == null) 2809 return this; 2810 if (this.interpreter == null) 2811 this.interpreter = new ArrayList<Reference>(); 2812 this.interpreter.add(t); 2813 return this; 2814 } 2815 2816 /** 2817 * @return The first repetition of repeating field {@link #interpreter}, creating it if it does not already exist {3} 2818 */ 2819 public Reference getInterpreterFirstRep() { 2820 if (getInterpreter().isEmpty()) { 2821 addInterpreter(); 2822 } 2823 return getInterpreter().get(0); 2824 } 2825 2826 /** 2827 * @return {@link #reason} (Why the genomic study was performed.) 2828 */ 2829 public List<CodeableReference> getReason() { 2830 if (this.reason == null) 2831 this.reason = new ArrayList<CodeableReference>(); 2832 return this.reason; 2833 } 2834 2835 /** 2836 * @return Returns a reference to <code>this</code> for easy method chaining 2837 */ 2838 public GenomicStudy setReason(List<CodeableReference> theReason) { 2839 this.reason = theReason; 2840 return this; 2841 } 2842 2843 public boolean hasReason() { 2844 if (this.reason == null) 2845 return false; 2846 for (CodeableReference item : this.reason) 2847 if (!item.isEmpty()) 2848 return true; 2849 return false; 2850 } 2851 2852 public CodeableReference addReason() { //3 2853 CodeableReference t = new CodeableReference(); 2854 if (this.reason == null) 2855 this.reason = new ArrayList<CodeableReference>(); 2856 this.reason.add(t); 2857 return t; 2858 } 2859 2860 public GenomicStudy addReason(CodeableReference t) { //3 2861 if (t == null) 2862 return this; 2863 if (this.reason == null) 2864 this.reason = new ArrayList<CodeableReference>(); 2865 this.reason.add(t); 2866 return this; 2867 } 2868 2869 /** 2870 * @return The first repetition of repeating field {@link #reason}, creating it if it does not already exist {3} 2871 */ 2872 public CodeableReference getReasonFirstRep() { 2873 if (getReason().isEmpty()) { 2874 addReason(); 2875 } 2876 return getReason().get(0); 2877 } 2878 2879 /** 2880 * @return {@link #instantiatesCanonical} (The defined protocol that describes the study.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesCanonical" gives direct access to the value 2881 */ 2882 public CanonicalType getInstantiatesCanonicalElement() { 2883 if (this.instantiatesCanonical == null) 2884 if (Configuration.errorOnAutoCreate()) 2885 throw new Error("Attempt to auto-create GenomicStudy.instantiatesCanonical"); 2886 else if (Configuration.doAutoCreate()) 2887 this.instantiatesCanonical = new CanonicalType(); // bb 2888 return this.instantiatesCanonical; 2889 } 2890 2891 public boolean hasInstantiatesCanonicalElement() { 2892 return this.instantiatesCanonical != null && !this.instantiatesCanonical.isEmpty(); 2893 } 2894 2895 public boolean hasInstantiatesCanonical() { 2896 return this.instantiatesCanonical != null && !this.instantiatesCanonical.isEmpty(); 2897 } 2898 2899 /** 2900 * @param value {@link #instantiatesCanonical} (The defined protocol that describes the study.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesCanonical" gives direct access to the value 2901 */ 2902 public GenomicStudy setInstantiatesCanonicalElement(CanonicalType value) { 2903 this.instantiatesCanonical = value; 2904 return this; 2905 } 2906 2907 /** 2908 * @return The defined protocol that describes the study. 2909 */ 2910 public String getInstantiatesCanonical() { 2911 return this.instantiatesCanonical == null ? null : this.instantiatesCanonical.getValue(); 2912 } 2913 2914 /** 2915 * @param value The defined protocol that describes the study. 2916 */ 2917 public GenomicStudy setInstantiatesCanonical(String value) { 2918 if (Utilities.noString(value)) 2919 this.instantiatesCanonical = null; 2920 else { 2921 if (this.instantiatesCanonical == null) 2922 this.instantiatesCanonical = new CanonicalType(); 2923 this.instantiatesCanonical.setValue(value); 2924 } 2925 return this; 2926 } 2927 2928 /** 2929 * @return {@link #instantiatesUri} (The URL pointing to an externally maintained protocol that describes the study.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesUri" gives direct access to the value 2930 */ 2931 public UriType getInstantiatesUriElement() { 2932 if (this.instantiatesUri == null) 2933 if (Configuration.errorOnAutoCreate()) 2934 throw new Error("Attempt to auto-create GenomicStudy.instantiatesUri"); 2935 else if (Configuration.doAutoCreate()) 2936 this.instantiatesUri = new UriType(); // bb 2937 return this.instantiatesUri; 2938 } 2939 2940 public boolean hasInstantiatesUriElement() { 2941 return this.instantiatesUri != null && !this.instantiatesUri.isEmpty(); 2942 } 2943 2944 public boolean hasInstantiatesUri() { 2945 return this.instantiatesUri != null && !this.instantiatesUri.isEmpty(); 2946 } 2947 2948 /** 2949 * @param value {@link #instantiatesUri} (The URL pointing to an externally maintained protocol that describes the study.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesUri" gives direct access to the value 2950 */ 2951 public GenomicStudy setInstantiatesUriElement(UriType value) { 2952 this.instantiatesUri = value; 2953 return this; 2954 } 2955 2956 /** 2957 * @return The URL pointing to an externally maintained protocol that describes the study. 2958 */ 2959 public String getInstantiatesUri() { 2960 return this.instantiatesUri == null ? null : this.instantiatesUri.getValue(); 2961 } 2962 2963 /** 2964 * @param value The URL pointing to an externally maintained protocol that describes the study. 2965 */ 2966 public GenomicStudy setInstantiatesUri(String value) { 2967 if (Utilities.noString(value)) 2968 this.instantiatesUri = null; 2969 else { 2970 if (this.instantiatesUri == null) 2971 this.instantiatesUri = new UriType(); 2972 this.instantiatesUri.setValue(value); 2973 } 2974 return this; 2975 } 2976 2977 /** 2978 * @return {@link #note} (Comments related to the genomic study.) 2979 */ 2980 public List<Annotation> getNote() { 2981 if (this.note == null) 2982 this.note = new ArrayList<Annotation>(); 2983 return this.note; 2984 } 2985 2986 /** 2987 * @return Returns a reference to <code>this</code> for easy method chaining 2988 */ 2989 public GenomicStudy setNote(List<Annotation> theNote) { 2990 this.note = theNote; 2991 return this; 2992 } 2993 2994 public boolean hasNote() { 2995 if (this.note == null) 2996 return false; 2997 for (Annotation item : this.note) 2998 if (!item.isEmpty()) 2999 return true; 3000 return false; 3001 } 3002 3003 public Annotation addNote() { //3 3004 Annotation t = new Annotation(); 3005 if (this.note == null) 3006 this.note = new ArrayList<Annotation>(); 3007 this.note.add(t); 3008 return t; 3009 } 3010 3011 public GenomicStudy addNote(Annotation t) { //3 3012 if (t == null) 3013 return this; 3014 if (this.note == null) 3015 this.note = new ArrayList<Annotation>(); 3016 this.note.add(t); 3017 return this; 3018 } 3019 3020 /** 3021 * @return The first repetition of repeating field {@link #note}, creating it if it does not already exist {3} 3022 */ 3023 public Annotation getNoteFirstRep() { 3024 if (getNote().isEmpty()) { 3025 addNote(); 3026 } 3027 return getNote().get(0); 3028 } 3029 3030 /** 3031 * @return {@link #description} (Description of the genomic study.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 3032 */ 3033 public StringType getDescriptionElement() { 3034 if (this.description == null) 3035 if (Configuration.errorOnAutoCreate()) 3036 throw new Error("Attempt to auto-create GenomicStudy.description"); 3037 else if (Configuration.doAutoCreate()) 3038 this.description = new StringType(); // bb 3039 return this.description; 3040 } 3041 3042 public boolean hasDescriptionElement() { 3043 return this.description != null && !this.description.isEmpty(); 3044 } 3045 3046 public boolean hasDescription() { 3047 return this.description != null && !this.description.isEmpty(); 3048 } 3049 3050 /** 3051 * @param value {@link #description} (Description of the genomic study.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 3052 */ 3053 public GenomicStudy setDescriptionElement(StringType value) { 3054 this.description = value; 3055 return this; 3056 } 3057 3058 /** 3059 * @return Description of the genomic study. 3060 */ 3061 public String getDescription() { 3062 return this.description == null ? null : this.description.getValue(); 3063 } 3064 3065 /** 3066 * @param value Description of the genomic study. 3067 */ 3068 public GenomicStudy setDescription(String value) { 3069 if (Utilities.noString(value)) 3070 this.description = null; 3071 else { 3072 if (this.description == null) 3073 this.description = new StringType(); 3074 this.description.setValue(value); 3075 } 3076 return this; 3077 } 3078 3079 /** 3080 * @return {@link #analysis} (The details about a specific analysis that was performed in this GenomicStudy.) 3081 */ 3082 public List<GenomicStudyAnalysisComponent> getAnalysis() { 3083 if (this.analysis == null) 3084 this.analysis = new ArrayList<GenomicStudyAnalysisComponent>(); 3085 return this.analysis; 3086 } 3087 3088 /** 3089 * @return Returns a reference to <code>this</code> for easy method chaining 3090 */ 3091 public GenomicStudy setAnalysis(List<GenomicStudyAnalysisComponent> theAnalysis) { 3092 this.analysis = theAnalysis; 3093 return this; 3094 } 3095 3096 public boolean hasAnalysis() { 3097 if (this.analysis == null) 3098 return false; 3099 for (GenomicStudyAnalysisComponent item : this.analysis) 3100 if (!item.isEmpty()) 3101 return true; 3102 return false; 3103 } 3104 3105 public GenomicStudyAnalysisComponent addAnalysis() { //3 3106 GenomicStudyAnalysisComponent t = new GenomicStudyAnalysisComponent(); 3107 if (this.analysis == null) 3108 this.analysis = new ArrayList<GenomicStudyAnalysisComponent>(); 3109 this.analysis.add(t); 3110 return t; 3111 } 3112 3113 public GenomicStudy addAnalysis(GenomicStudyAnalysisComponent t) { //3 3114 if (t == null) 3115 return this; 3116 if (this.analysis == null) 3117 this.analysis = new ArrayList<GenomicStudyAnalysisComponent>(); 3118 this.analysis.add(t); 3119 return this; 3120 } 3121 3122 /** 3123 * @return The first repetition of repeating field {@link #analysis}, creating it if it does not already exist {3} 3124 */ 3125 public GenomicStudyAnalysisComponent getAnalysisFirstRep() { 3126 if (getAnalysis().isEmpty()) { 3127 addAnalysis(); 3128 } 3129 return getAnalysis().get(0); 3130 } 3131 3132 protected void listChildren(List<Property> children) { 3133 super.listChildren(children); 3134 children.add(new Property("identifier", "Identifier", "Identifiers for this genomic study.", 0, java.lang.Integer.MAX_VALUE, identifier)); 3135 children.add(new Property("status", "CodeableConcept", "The status of the genomic study.", 0, 1, status)); 3136 children.add(new Property("type", "CodeableConcept", "The type of the study, e.g., Familial variant segregation, Functional variation detection, or Gene expression profiling.", 0, java.lang.Integer.MAX_VALUE, type)); 3137 children.add(new Property("subject", "Reference(Patient|Group|Device|Location|Organization|Procedure|Practitioner|Medication|Substance|BiologicallyDerivedProduct|NutritionProduct)", "The primary subject of the genomic study.", 0, 1, subject)); 3138 children.add(new Property("encounter", "Reference(Encounter)", "The healthcare event with which this genomics study is associated.", 0, 1, encounter)); 3139 children.add(new Property("startDate", "dateTime", "When the genomic study was started.", 0, 1, startDate)); 3140 children.add(new Property("basedOn", "Reference(ServiceRequest|Task)", "Event resources that the genomic study is based on.", 0, java.lang.Integer.MAX_VALUE, basedOn)); 3141 children.add(new Property("referrer", "Reference(Practitioner|PractitionerRole)", "Healthcare professional who requested or referred the genomic study.", 0, 1, referrer)); 3142 children.add(new Property("interpreter", "Reference(Practitioner|PractitionerRole)", "Healthcare professionals who interpreted the genomic study.", 0, java.lang.Integer.MAX_VALUE, interpreter)); 3143 children.add(new Property("reason", "CodeableReference(Condition|Observation)", "Why the genomic study was performed.", 0, java.lang.Integer.MAX_VALUE, reason)); 3144 children.add(new Property("instantiatesCanonical", "canonical(PlanDefinition)", "The defined protocol that describes the study.", 0, 1, instantiatesCanonical)); 3145 children.add(new Property("instantiatesUri", "uri", "The URL pointing to an externally maintained protocol that describes the study.", 0, 1, instantiatesUri)); 3146 children.add(new Property("note", "Annotation", "Comments related to the genomic study.", 0, java.lang.Integer.MAX_VALUE, note)); 3147 children.add(new Property("description", "string", "Description of the genomic study.", 0, 1, description)); 3148 children.add(new Property("analysis", "", "The details about a specific analysis that was performed in this GenomicStudy.", 0, java.lang.Integer.MAX_VALUE, analysis)); 3149 } 3150 3151 @Override 3152 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 3153 switch (_hash) { 3154 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "Identifiers for this genomic study.", 0, java.lang.Integer.MAX_VALUE, identifier); 3155 case -892481550: /*status*/ return new Property("status", "CodeableConcept", "The status of the genomic study.", 0, 1, status); 3156 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The type of the study, e.g., Familial variant segregation, Functional variation detection, or Gene expression profiling.", 0, java.lang.Integer.MAX_VALUE, type); 3157 case -1867885268: /*subject*/ return new Property("subject", "Reference(Patient|Group|Device|Location|Organization|Procedure|Practitioner|Medication|Substance|BiologicallyDerivedProduct|NutritionProduct)", "The primary subject of the genomic study.", 0, 1, subject); 3158 case 1524132147: /*encounter*/ return new Property("encounter", "Reference(Encounter)", "The healthcare event with which this genomics study is associated.", 0, 1, encounter); 3159 case -2129778896: /*startDate*/ return new Property("startDate", "dateTime", "When the genomic study was started.", 0, 1, startDate); 3160 case -332612366: /*basedOn*/ return new Property("basedOn", "Reference(ServiceRequest|Task)", "Event resources that the genomic study is based on.", 0, java.lang.Integer.MAX_VALUE, basedOn); 3161 case -722568161: /*referrer*/ return new Property("referrer", "Reference(Practitioner|PractitionerRole)", "Healthcare professional who requested or referred the genomic study.", 0, 1, referrer); 3162 case -2008009094: /*interpreter*/ return new Property("interpreter", "Reference(Practitioner|PractitionerRole)", "Healthcare professionals who interpreted the genomic study.", 0, java.lang.Integer.MAX_VALUE, interpreter); 3163 case -934964668: /*reason*/ return new Property("reason", "CodeableReference(Condition|Observation)", "Why the genomic study was performed.", 0, java.lang.Integer.MAX_VALUE, reason); 3164 case 8911915: /*instantiatesCanonical*/ return new Property("instantiatesCanonical", "canonical(PlanDefinition)", "The defined protocol that describes the study.", 0, 1, instantiatesCanonical); 3165 case -1926393373: /*instantiatesUri*/ return new Property("instantiatesUri", "uri", "The URL pointing to an externally maintained protocol that describes the study.", 0, 1, instantiatesUri); 3166 case 3387378: /*note*/ return new Property("note", "Annotation", "Comments related to the genomic study.", 0, java.lang.Integer.MAX_VALUE, note); 3167 case -1724546052: /*description*/ return new Property("description", "string", "Description of the genomic study.", 0, 1, description); 3168 case -1024445732: /*analysis*/ return new Property("analysis", "", "The details about a specific analysis that was performed in this GenomicStudy.", 0, java.lang.Integer.MAX_VALUE, analysis); 3169 default: return super.getNamedProperty(_hash, _name, _checkValid); 3170 } 3171 3172 } 3173 3174 @Override 3175 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 3176 switch (hash) { 3177 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 3178 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // CodeableConcept 3179 case 3575610: /*type*/ return this.type == null ? new Base[0] : this.type.toArray(new Base[this.type.size()]); // CodeableConcept 3180 case -1867885268: /*subject*/ return this.subject == null ? new Base[0] : new Base[] {this.subject}; // Reference 3181 case 1524132147: /*encounter*/ return this.encounter == null ? new Base[0] : new Base[] {this.encounter}; // Reference 3182 case -2129778896: /*startDate*/ return this.startDate == null ? new Base[0] : new Base[] {this.startDate}; // DateTimeType 3183 case -332612366: /*basedOn*/ return this.basedOn == null ? new Base[0] : this.basedOn.toArray(new Base[this.basedOn.size()]); // Reference 3184 case -722568161: /*referrer*/ return this.referrer == null ? new Base[0] : new Base[] {this.referrer}; // Reference 3185 case -2008009094: /*interpreter*/ return this.interpreter == null ? new Base[0] : this.interpreter.toArray(new Base[this.interpreter.size()]); // Reference 3186 case -934964668: /*reason*/ return this.reason == null ? new Base[0] : this.reason.toArray(new Base[this.reason.size()]); // CodeableReference 3187 case 8911915: /*instantiatesCanonical*/ return this.instantiatesCanonical == null ? new Base[0] : new Base[] {this.instantiatesCanonical}; // CanonicalType 3188 case -1926393373: /*instantiatesUri*/ return this.instantiatesUri == null ? new Base[0] : new Base[] {this.instantiatesUri}; // UriType 3189 case 3387378: /*note*/ return this.note == null ? new Base[0] : this.note.toArray(new Base[this.note.size()]); // Annotation 3190 case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType 3191 case -1024445732: /*analysis*/ return this.analysis == null ? new Base[0] : this.analysis.toArray(new Base[this.analysis.size()]); // GenomicStudyAnalysisComponent 3192 default: return super.getProperty(hash, name, checkValid); 3193 } 3194 3195 } 3196 3197 @Override 3198 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3199 switch (hash) { 3200 case -1618432855: // identifier 3201 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); // Identifier 3202 return value; 3203 case -892481550: // status 3204 this.status = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3205 return value; 3206 case 3575610: // type 3207 this.getType().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 3208 return value; 3209 case -1867885268: // subject 3210 this.subject = TypeConvertor.castToReference(value); // Reference 3211 return value; 3212 case 1524132147: // encounter 3213 this.encounter = TypeConvertor.castToReference(value); // Reference 3214 return value; 3215 case -2129778896: // startDate 3216 this.startDate = TypeConvertor.castToDateTime(value); // DateTimeType 3217 return value; 3218 case -332612366: // basedOn 3219 this.getBasedOn().add(TypeConvertor.castToReference(value)); // Reference 3220 return value; 3221 case -722568161: // referrer 3222 this.referrer = TypeConvertor.castToReference(value); // Reference 3223 return value; 3224 case -2008009094: // interpreter 3225 this.getInterpreter().add(TypeConvertor.castToReference(value)); // Reference 3226 return value; 3227 case -934964668: // reason 3228 this.getReason().add(TypeConvertor.castToCodeableReference(value)); // CodeableReference 3229 return value; 3230 case 8911915: // instantiatesCanonical 3231 this.instantiatesCanonical = TypeConvertor.castToCanonical(value); // CanonicalType 3232 return value; 3233 case -1926393373: // instantiatesUri 3234 this.instantiatesUri = TypeConvertor.castToUri(value); // UriType 3235 return value; 3236 case 3387378: // note 3237 this.getNote().add(TypeConvertor.castToAnnotation(value)); // Annotation 3238 return value; 3239 case -1724546052: // description 3240 this.description = TypeConvertor.castToString(value); // StringType 3241 return value; 3242 case -1024445732: // analysis 3243 this.getAnalysis().add((GenomicStudyAnalysisComponent) value); // GenomicStudyAnalysisComponent 3244 return value; 3245 default: return super.setProperty(hash, name, value); 3246 } 3247 3248 } 3249 3250 @Override 3251 public Base setProperty(String name, Base value) throws FHIRException { 3252 if (name.equals("identifier")) { 3253 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); 3254 } else if (name.equals("status")) { 3255 this.status = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3256 } else if (name.equals("type")) { 3257 this.getType().add(TypeConvertor.castToCodeableConcept(value)); 3258 } else if (name.equals("subject")) { 3259 this.subject = TypeConvertor.castToReference(value); // Reference 3260 } else if (name.equals("encounter")) { 3261 this.encounter = TypeConvertor.castToReference(value); // Reference 3262 } else if (name.equals("startDate")) { 3263 this.startDate = TypeConvertor.castToDateTime(value); // DateTimeType 3264 } else if (name.equals("basedOn")) { 3265 this.getBasedOn().add(TypeConvertor.castToReference(value)); 3266 } else if (name.equals("referrer")) { 3267 this.referrer = TypeConvertor.castToReference(value); // Reference 3268 } else if (name.equals("interpreter")) { 3269 this.getInterpreter().add(TypeConvertor.castToReference(value)); 3270 } else if (name.equals("reason")) { 3271 this.getReason().add(TypeConvertor.castToCodeableReference(value)); 3272 } else if (name.equals("instantiatesCanonical")) { 3273 this.instantiatesCanonical = TypeConvertor.castToCanonical(value); // CanonicalType 3274 } else if (name.equals("instantiatesUri")) { 3275 this.instantiatesUri = TypeConvertor.castToUri(value); // UriType 3276 } else if (name.equals("note")) { 3277 this.getNote().add(TypeConvertor.castToAnnotation(value)); 3278 } else if (name.equals("description")) { 3279 this.description = TypeConvertor.castToString(value); // StringType 3280 } else if (name.equals("analysis")) { 3281 this.getAnalysis().add((GenomicStudyAnalysisComponent) value); 3282 } else 3283 return super.setProperty(name, value); 3284 return value; 3285 } 3286 3287 @Override 3288 public Base makeProperty(int hash, String name) throws FHIRException { 3289 switch (hash) { 3290 case -1618432855: return addIdentifier(); 3291 case -892481550: return getStatus(); 3292 case 3575610: return addType(); 3293 case -1867885268: return getSubject(); 3294 case 1524132147: return getEncounter(); 3295 case -2129778896: return getStartDateElement(); 3296 case -332612366: return addBasedOn(); 3297 case -722568161: return getReferrer(); 3298 case -2008009094: return addInterpreter(); 3299 case -934964668: return addReason(); 3300 case 8911915: return getInstantiatesCanonicalElement(); 3301 case -1926393373: return getInstantiatesUriElement(); 3302 case 3387378: return addNote(); 3303 case -1724546052: return getDescriptionElement(); 3304 case -1024445732: return addAnalysis(); 3305 default: return super.makeProperty(hash, name); 3306 } 3307 3308 } 3309 3310 @Override 3311 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 3312 switch (hash) { 3313 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 3314 case -892481550: /*status*/ return new String[] {"CodeableConcept"}; 3315 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 3316 case -1867885268: /*subject*/ return new String[] {"Reference"}; 3317 case 1524132147: /*encounter*/ return new String[] {"Reference"}; 3318 case -2129778896: /*startDate*/ return new String[] {"dateTime"}; 3319 case -332612366: /*basedOn*/ return new String[] {"Reference"}; 3320 case -722568161: /*referrer*/ return new String[] {"Reference"}; 3321 case -2008009094: /*interpreter*/ return new String[] {"Reference"}; 3322 case -934964668: /*reason*/ return new String[] {"CodeableReference"}; 3323 case 8911915: /*instantiatesCanonical*/ return new String[] {"canonical"}; 3324 case -1926393373: /*instantiatesUri*/ return new String[] {"uri"}; 3325 case 3387378: /*note*/ return new String[] {"Annotation"}; 3326 case -1724546052: /*description*/ return new String[] {"string"}; 3327 case -1024445732: /*analysis*/ return new String[] {}; 3328 default: return super.getTypesForProperty(hash, name); 3329 } 3330 3331 } 3332 3333 @Override 3334 public Base addChild(String name) throws FHIRException { 3335 if (name.equals("identifier")) { 3336 return addIdentifier(); 3337 } 3338 else if (name.equals("status")) { 3339 this.status = new CodeableConcept(); 3340 return this.status; 3341 } 3342 else if (name.equals("type")) { 3343 return addType(); 3344 } 3345 else if (name.equals("subject")) { 3346 this.subject = new Reference(); 3347 return this.subject; 3348 } 3349 else if (name.equals("encounter")) { 3350 this.encounter = new Reference(); 3351 return this.encounter; 3352 } 3353 else if (name.equals("startDate")) { 3354 throw new FHIRException("Cannot call addChild on a primitive type GenomicStudy.startDate"); 3355 } 3356 else if (name.equals("basedOn")) { 3357 return addBasedOn(); 3358 } 3359 else if (name.equals("referrer")) { 3360 this.referrer = new Reference(); 3361 return this.referrer; 3362 } 3363 else if (name.equals("interpreter")) { 3364 return addInterpreter(); 3365 } 3366 else if (name.equals("reason")) { 3367 return addReason(); 3368 } 3369 else if (name.equals("instantiatesCanonical")) { 3370 throw new FHIRException("Cannot call addChild on a primitive type GenomicStudy.instantiatesCanonical"); 3371 } 3372 else if (name.equals("instantiatesUri")) { 3373 throw new FHIRException("Cannot call addChild on a primitive type GenomicStudy.instantiatesUri"); 3374 } 3375 else if (name.equals("note")) { 3376 return addNote(); 3377 } 3378 else if (name.equals("description")) { 3379 throw new FHIRException("Cannot call addChild on a primitive type GenomicStudy.description"); 3380 } 3381 else if (name.equals("analysis")) { 3382 return addAnalysis(); 3383 } 3384 else 3385 return super.addChild(name); 3386 } 3387 3388 public String fhirType() { 3389 return "GenomicStudy"; 3390 3391 } 3392 3393 public GenomicStudy copy() { 3394 GenomicStudy dst = new GenomicStudy(); 3395 copyValues(dst); 3396 return dst; 3397 } 3398 3399 public void copyValues(GenomicStudy dst) { 3400 super.copyValues(dst); 3401 if (identifier != null) { 3402 dst.identifier = new ArrayList<Identifier>(); 3403 for (Identifier i : identifier) 3404 dst.identifier.add(i.copy()); 3405 }; 3406 dst.status = status == null ? null : status.copy(); 3407 if (type != null) { 3408 dst.type = new ArrayList<CodeableConcept>(); 3409 for (CodeableConcept i : type) 3410 dst.type.add(i.copy()); 3411 }; 3412 dst.subject = subject == null ? null : subject.copy(); 3413 dst.encounter = encounter == null ? null : encounter.copy(); 3414 dst.startDate = startDate == null ? null : startDate.copy(); 3415 if (basedOn != null) { 3416 dst.basedOn = new ArrayList<Reference>(); 3417 for (Reference i : basedOn) 3418 dst.basedOn.add(i.copy()); 3419 }; 3420 dst.referrer = referrer == null ? null : referrer.copy(); 3421 if (interpreter != null) { 3422 dst.interpreter = new ArrayList<Reference>(); 3423 for (Reference i : interpreter) 3424 dst.interpreter.add(i.copy()); 3425 }; 3426 if (reason != null) { 3427 dst.reason = new ArrayList<CodeableReference>(); 3428 for (CodeableReference i : reason) 3429 dst.reason.add(i.copy()); 3430 }; 3431 dst.instantiatesCanonical = instantiatesCanonical == null ? null : instantiatesCanonical.copy(); 3432 dst.instantiatesUri = instantiatesUri == null ? null : instantiatesUri.copy(); 3433 if (note != null) { 3434 dst.note = new ArrayList<Annotation>(); 3435 for (Annotation i : note) 3436 dst.note.add(i.copy()); 3437 }; 3438 dst.description = description == null ? null : description.copy(); 3439 if (analysis != null) { 3440 dst.analysis = new ArrayList<GenomicStudyAnalysisComponent>(); 3441 for (GenomicStudyAnalysisComponent i : analysis) 3442 dst.analysis.add(i.copy()); 3443 }; 3444 } 3445 3446 protected GenomicStudy typedCopy() { 3447 return copy(); 3448 } 3449 3450 @Override 3451 public boolean equalsDeep(Base other_) { 3452 if (!super.equalsDeep(other_)) 3453 return false; 3454 if (!(other_ instanceof GenomicStudy)) 3455 return false; 3456 GenomicStudy o = (GenomicStudy) other_; 3457 return compareDeep(identifier, o.identifier, true) && compareDeep(status, o.status, true) && compareDeep(type, o.type, true) 3458 && compareDeep(subject, o.subject, true) && compareDeep(encounter, o.encounter, true) && compareDeep(startDate, o.startDate, true) 3459 && compareDeep(basedOn, o.basedOn, true) && compareDeep(referrer, o.referrer, true) && compareDeep(interpreter, o.interpreter, true) 3460 && compareDeep(reason, o.reason, true) && compareDeep(instantiatesCanonical, o.instantiatesCanonical, true) 3461 && compareDeep(instantiatesUri, o.instantiatesUri, true) && compareDeep(note, o.note, true) && compareDeep(description, o.description, true) 3462 && compareDeep(analysis, o.analysis, true); 3463 } 3464 3465 @Override 3466 public boolean equalsShallow(Base other_) { 3467 if (!super.equalsShallow(other_)) 3468 return false; 3469 if (!(other_ instanceof GenomicStudy)) 3470 return false; 3471 GenomicStudy o = (GenomicStudy) other_; 3472 return compareValues(startDate, o.startDate, true) && compareValues(instantiatesCanonical, o.instantiatesCanonical, true) 3473 && compareValues(instantiatesUri, o.instantiatesUri, true) && compareValues(description, o.description, true) 3474 ; 3475 } 3476 3477 public boolean isEmpty() { 3478 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, status, type 3479 , subject, encounter, startDate, basedOn, referrer, interpreter, reason, instantiatesCanonical 3480 , instantiatesUri, note, description, analysis); 3481 } 3482 3483 @Override 3484 public ResourceType getResourceType() { 3485 return ResourceType.GenomicStudy; 3486 } 3487 3488 /** 3489 * Search parameter: <b>analysis-patient</b> 3490 * <p> 3491 * Description: <b>Who the analysis is about</b><br> 3492 * Type: <b>reference</b><br> 3493 * Path: <b>GenomicStudy.analysis.subject.where(resolve() is Patient)</b><br> 3494 * </p> 3495 */ 3496 @SearchParamDefinition(name="analysis-patient", path="GenomicStudy.analysis.subject.where(resolve() is Patient)", description="Who the analysis is about", type="reference", target={BiologicallyDerivedProduct.class, Device.class, Group.class, Location.class, Medication.class, NutritionProduct.class, Organization.class, Patient.class, Practitioner.class, Procedure.class, Substance.class } ) 3497 public static final String SP_ANALYSIS_PATIENT = "analysis-patient"; 3498 /** 3499 * <b>Fluent Client</b> search parameter constant for <b>analysis-patient</b> 3500 * <p> 3501 * Description: <b>Who the analysis is about</b><br> 3502 * Type: <b>reference</b><br> 3503 * Path: <b>GenomicStudy.analysis.subject.where(resolve() is Patient)</b><br> 3504 * </p> 3505 */ 3506 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ANALYSIS_PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ANALYSIS_PATIENT); 3507 3508/** 3509 * Constant for fluent queries to be used to add include statements. Specifies 3510 * the path value of "<b>GenomicStudy:analysis-patient</b>". 3511 */ 3512 public static final ca.uhn.fhir.model.api.Include INCLUDE_ANALYSIS_PATIENT = new ca.uhn.fhir.model.api.Include("GenomicStudy:analysis-patient").toLocked(); 3513 3514 /** 3515 * Search parameter: <b>analysis-subject</b> 3516 * <p> 3517 * Description: <b>Who the analysis is about</b><br> 3518 * Type: <b>reference</b><br> 3519 * Path: <b>GenomicStudy.analysis.subject</b><br> 3520 * </p> 3521 */ 3522 @SearchParamDefinition(name="analysis-subject", path="GenomicStudy.analysis.subject", description="Who the analysis is about", type="reference", target={BiologicallyDerivedProduct.class, Device.class, Group.class, Location.class, Medication.class, NutritionProduct.class, Organization.class, Patient.class, Practitioner.class, Procedure.class, Substance.class } ) 3523 public static final String SP_ANALYSIS_SUBJECT = "analysis-subject"; 3524 /** 3525 * <b>Fluent Client</b> search parameter constant for <b>analysis-subject</b> 3526 * <p> 3527 * Description: <b>Who the analysis is about</b><br> 3528 * Type: <b>reference</b><br> 3529 * Path: <b>GenomicStudy.analysis.subject</b><br> 3530 * </p> 3531 */ 3532 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ANALYSIS_SUBJECT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ANALYSIS_SUBJECT); 3533 3534/** 3535 * Constant for fluent queries to be used to add include statements. Specifies 3536 * the path value of "<b>GenomicStudy:analysis-subject</b>". 3537 */ 3538 public static final ca.uhn.fhir.model.api.Include INCLUDE_ANALYSIS_SUBJECT = new ca.uhn.fhir.model.api.Include("GenomicStudy:analysis-subject").toLocked(); 3539 3540 /** 3541 * Search parameter: <b>identifier</b> 3542 * <p> 3543 * Description: <b>Identifiers for the Study</b><br> 3544 * Type: <b>token</b><br> 3545 * Path: <b>GenomicStudy.identifier</b><br> 3546 * </p> 3547 */ 3548 @SearchParamDefinition(name="identifier", path="GenomicStudy.identifier", description="Identifiers for the Study", type="token" ) 3549 public static final String SP_IDENTIFIER = "identifier"; 3550 /** 3551 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 3552 * <p> 3553 * Description: <b>Identifiers for the Study</b><br> 3554 * Type: <b>token</b><br> 3555 * Path: <b>GenomicStudy.identifier</b><br> 3556 * </p> 3557 */ 3558 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 3559 3560 /** 3561 * Search parameter: <b>patient</b> 3562 * <p> 3563 * Description: <b>Who the study is about</b><br> 3564 * Type: <b>reference</b><br> 3565 * Path: <b>GenomicStudy.subject.where(resolve() is Patient)</b><br> 3566 * </p> 3567 */ 3568 @SearchParamDefinition(name="patient", path="GenomicStudy.subject.where(resolve() is Patient)", description="Who the study is about", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Patient") }, target={BiologicallyDerivedProduct.class, Device.class, Group.class, Location.class, Medication.class, NutritionProduct.class, Organization.class, Patient.class, Practitioner.class, Procedure.class, Substance.class } ) 3569 public static final String SP_PATIENT = "patient"; 3570 /** 3571 * <b>Fluent Client</b> search parameter constant for <b>patient</b> 3572 * <p> 3573 * Description: <b>Who the study is about</b><br> 3574 * Type: <b>reference</b><br> 3575 * Path: <b>GenomicStudy.subject.where(resolve() is Patient)</b><br> 3576 * </p> 3577 */ 3578 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT); 3579 3580/** 3581 * Constant for fluent queries to be used to add include statements. Specifies 3582 * the path value of "<b>GenomicStudy:patient</b>". 3583 */ 3584 public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("GenomicStudy:patient").toLocked(); 3585 3586 /** 3587 * Search parameter: <b>status</b> 3588 * <p> 3589 * Description: <b>The status of the study</b><br> 3590 * Type: <b>token</b><br> 3591 * Path: <b>GenomicStudy.status</b><br> 3592 * </p> 3593 */ 3594 @SearchParamDefinition(name="status", path="GenomicStudy.status", description="The status of the study", type="token" ) 3595 public static final String SP_STATUS = "status"; 3596 /** 3597 * <b>Fluent Client</b> search parameter constant for <b>status</b> 3598 * <p> 3599 * Description: <b>The status of the study</b><br> 3600 * Type: <b>token</b><br> 3601 * Path: <b>GenomicStudy.status</b><br> 3602 * </p> 3603 */ 3604 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 3605 3606 /** 3607 * Search parameter: <b>subject</b> 3608 * <p> 3609 * Description: <b>Who the study is about</b><br> 3610 * Type: <b>reference</b><br> 3611 * Path: <b>GenomicStudy.subject</b><br> 3612 * </p> 3613 */ 3614 @SearchParamDefinition(name="subject", path="GenomicStudy.subject", description="Who the study is about", type="reference", target={BiologicallyDerivedProduct.class, Device.class, Group.class, Location.class, Medication.class, NutritionProduct.class, Organization.class, Patient.class, Practitioner.class, Procedure.class, Substance.class } ) 3615 public static final String SP_SUBJECT = "subject"; 3616 /** 3617 * <b>Fluent Client</b> search parameter constant for <b>subject</b> 3618 * <p> 3619 * Description: <b>Who the study is about</b><br> 3620 * Type: <b>reference</b><br> 3621 * Path: <b>GenomicStudy.subject</b><br> 3622 * </p> 3623 */ 3624 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SUBJECT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SUBJECT); 3625 3626/** 3627 * Constant for fluent queries to be used to add include statements. Specifies 3628 * the path value of "<b>GenomicStudy:subject</b>". 3629 */ 3630 public static final ca.uhn.fhir.model.api.Include INCLUDE_SUBJECT = new ca.uhn.fhir.model.api.Include("GenomicStudy:subject").toLocked(); 3631 3632 3633} 3634