001package org.hl7.fhir.r4.model; 002 003 004 005/* 006 Copyright (c) 2011+, HL7, Inc. 007 All rights reserved. 008 009 Redistribution and use in source and binary forms, with or without modification, 010 are permitted provided that the following conditions are met: 011 012 * Redistributions of source code must retain the above copyright notice, this 013 list of conditions and the following disclaimer. 014 * Redistributions in binary form must reproduce the above copyright notice, 015 this list of conditions and the following disclaimer in the documentation 016 and/or other materials provided with the distribution. 017 * Neither the name of HL7 nor the names of its contributors may be used to 018 endorse or promote products derived from this software without specific 019 prior written permission. 020 021 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 022 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 023 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 024 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 025 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 026 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 027 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 028 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 029 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 030 POSSIBILITY OF SUCH DAMAGE. 031 032*/ 033 034 035// Generated on Tue, May 12, 2020 07:26+1000 for FHIR v4.0.1 036 037import java.util.*; 038 039import org.hl7.fhir.utilities.Utilities; 040import org.hl7.fhir.r4.model.Enumerations.*; 041import ca.uhn.fhir.model.api.annotation.ResourceDef; 042import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 043import ca.uhn.fhir.model.api.annotation.Child; 044import ca.uhn.fhir.model.api.annotation.ChildOrder; 045import ca.uhn.fhir.model.api.annotation.Description; 046import ca.uhn.fhir.model.api.annotation.Block; 047import org.hl7.fhir.instance.model.api.*; 048import org.hl7.fhir.exceptions.FHIRException; 049/** 050 * A person who is directly or indirectly involved in the provisioning of healthcare. 051 */ 052@ResourceDef(name="Practitioner", profile="http://hl7.org/fhir/StructureDefinition/Practitioner") 053public class Practitioner extends DomainResource { 054 055 @Block() 056 public static class PractitionerQualificationComponent extends BackboneElement implements IBaseBackboneElement { 057 /** 058 * An identifier that applies to this person's qualification in this role. 059 */ 060 @Child(name = "identifier", type = {Identifier.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 061 @Description(shortDefinition="An identifier for this qualification for the practitioner", formalDefinition="An identifier that applies to this person's qualification in this role." ) 062 protected List<Identifier> identifier; 063 064 /** 065 * Coded representation of the qualification. 066 */ 067 @Child(name = "code", type = {CodeableConcept.class}, order=2, min=1, max=1, modifier=false, summary=false) 068 @Description(shortDefinition="Coded representation of the qualification", formalDefinition="Coded representation of the qualification." ) 069 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://terminology.hl7.org/ValueSet/v2-2.7-0360") 070 protected CodeableConcept code; 071 072 /** 073 * Period during which the qualification is valid. 074 */ 075 @Child(name = "period", type = {Period.class}, order=3, min=0, max=1, modifier=false, summary=false) 076 @Description(shortDefinition="Period during which the qualification is valid", formalDefinition="Period during which the qualification is valid." ) 077 protected Period period; 078 079 /** 080 * Organization that regulates and issues the qualification. 081 */ 082 @Child(name = "issuer", type = {Organization.class}, order=4, min=0, max=1, modifier=false, summary=false) 083 @Description(shortDefinition="Organization that regulates and issues the qualification", formalDefinition="Organization that regulates and issues the qualification." ) 084 protected Reference issuer; 085 086 /** 087 * The actual object that is the target of the reference (Organization that regulates and issues the qualification.) 088 */ 089 protected Organization issuerTarget; 090 091 private static final long serialVersionUID = 1095219071L; 092 093 /** 094 * Constructor 095 */ 096 public PractitionerQualificationComponent() { 097 super(); 098 } 099 100 /** 101 * Constructor 102 */ 103 public PractitionerQualificationComponent(CodeableConcept code) { 104 super(); 105 this.code = code; 106 } 107 108 /** 109 * @return {@link #identifier} (An identifier that applies to this person's qualification in this role.) 110 */ 111 public List<Identifier> getIdentifier() { 112 if (this.identifier == null) 113 this.identifier = new ArrayList<Identifier>(); 114 return this.identifier; 115 } 116 117 /** 118 * @return Returns a reference to <code>this</code> for easy method chaining 119 */ 120 public PractitionerQualificationComponent setIdentifier(List<Identifier> theIdentifier) { 121 this.identifier = theIdentifier; 122 return this; 123 } 124 125 public boolean hasIdentifier() { 126 if (this.identifier == null) 127 return false; 128 for (Identifier item : this.identifier) 129 if (!item.isEmpty()) 130 return true; 131 return false; 132 } 133 134 public Identifier addIdentifier() { //3 135 Identifier t = new Identifier(); 136 if (this.identifier == null) 137 this.identifier = new ArrayList<Identifier>(); 138 this.identifier.add(t); 139 return t; 140 } 141 142 public PractitionerQualificationComponent addIdentifier(Identifier t) { //3 143 if (t == null) 144 return this; 145 if (this.identifier == null) 146 this.identifier = new ArrayList<Identifier>(); 147 this.identifier.add(t); 148 return this; 149 } 150 151 /** 152 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist 153 */ 154 public Identifier getIdentifierFirstRep() { 155 if (getIdentifier().isEmpty()) { 156 addIdentifier(); 157 } 158 return getIdentifier().get(0); 159 } 160 161 /** 162 * @return {@link #code} (Coded representation of the qualification.) 163 */ 164 public CodeableConcept getCode() { 165 if (this.code == null) 166 if (Configuration.errorOnAutoCreate()) 167 throw new Error("Attempt to auto-create PractitionerQualificationComponent.code"); 168 else if (Configuration.doAutoCreate()) 169 this.code = new CodeableConcept(); // cc 170 return this.code; 171 } 172 173 public boolean hasCode() { 174 return this.code != null && !this.code.isEmpty(); 175 } 176 177 /** 178 * @param value {@link #code} (Coded representation of the qualification.) 179 */ 180 public PractitionerQualificationComponent setCode(CodeableConcept value) { 181 this.code = value; 182 return this; 183 } 184 185 /** 186 * @return {@link #period} (Period during which the qualification is valid.) 187 */ 188 public Period getPeriod() { 189 if (this.period == null) 190 if (Configuration.errorOnAutoCreate()) 191 throw new Error("Attempt to auto-create PractitionerQualificationComponent.period"); 192 else if (Configuration.doAutoCreate()) 193 this.period = new Period(); // cc 194 return this.period; 195 } 196 197 public boolean hasPeriod() { 198 return this.period != null && !this.period.isEmpty(); 199 } 200 201 /** 202 * @param value {@link #period} (Period during which the qualification is valid.) 203 */ 204 public PractitionerQualificationComponent setPeriod(Period value) { 205 this.period = value; 206 return this; 207 } 208 209 /** 210 * @return {@link #issuer} (Organization that regulates and issues the qualification.) 211 */ 212 public Reference getIssuer() { 213 if (this.issuer == null) 214 if (Configuration.errorOnAutoCreate()) 215 throw new Error("Attempt to auto-create PractitionerQualificationComponent.issuer"); 216 else if (Configuration.doAutoCreate()) 217 this.issuer = new Reference(); // cc 218 return this.issuer; 219 } 220 221 public boolean hasIssuer() { 222 return this.issuer != null && !this.issuer.isEmpty(); 223 } 224 225 /** 226 * @param value {@link #issuer} (Organization that regulates and issues the qualification.) 227 */ 228 public PractitionerQualificationComponent setIssuer(Reference value) { 229 this.issuer = value; 230 return this; 231 } 232 233 /** 234 * @return {@link #issuer} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (Organization that regulates and issues the qualification.) 235 */ 236 public Organization getIssuerTarget() { 237 if (this.issuerTarget == null) 238 if (Configuration.errorOnAutoCreate()) 239 throw new Error("Attempt to auto-create PractitionerQualificationComponent.issuer"); 240 else if (Configuration.doAutoCreate()) 241 this.issuerTarget = new Organization(); // aa 242 return this.issuerTarget; 243 } 244 245 /** 246 * @param value {@link #issuer} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (Organization that regulates and issues the qualification.) 247 */ 248 public PractitionerQualificationComponent setIssuerTarget(Organization value) { 249 this.issuerTarget = value; 250 return this; 251 } 252 253 protected void listChildren(List<Property> children) { 254 super.listChildren(children); 255 children.add(new Property("identifier", "Identifier", "An identifier that applies to this person's qualification in this role.", 0, java.lang.Integer.MAX_VALUE, identifier)); 256 children.add(new Property("code", "CodeableConcept", "Coded representation of the qualification.", 0, 1, code)); 257 children.add(new Property("period", "Period", "Period during which the qualification is valid.", 0, 1, period)); 258 children.add(new Property("issuer", "Reference(Organization)", "Organization that regulates and issues the qualification.", 0, 1, issuer)); 259 } 260 261 @Override 262 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 263 switch (_hash) { 264 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "An identifier that applies to this person's qualification in this role.", 0, java.lang.Integer.MAX_VALUE, identifier); 265 case 3059181: /*code*/ return new Property("code", "CodeableConcept", "Coded representation of the qualification.", 0, 1, code); 266 case -991726143: /*period*/ return new Property("period", "Period", "Period during which the qualification is valid.", 0, 1, period); 267 case -1179159879: /*issuer*/ return new Property("issuer", "Reference(Organization)", "Organization that regulates and issues the qualification.", 0, 1, issuer); 268 default: return super.getNamedProperty(_hash, _name, _checkValid); 269 } 270 271 } 272 273 @Override 274 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 275 switch (hash) { 276 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 277 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 278 case -991726143: /*period*/ return this.period == null ? new Base[0] : new Base[] {this.period}; // Period 279 case -1179159879: /*issuer*/ return this.issuer == null ? new Base[0] : new Base[] {this.issuer}; // Reference 280 default: return super.getProperty(hash, name, checkValid); 281 } 282 283 } 284 285 @Override 286 public Base setProperty(int hash, String name, Base value) throws FHIRException { 287 switch (hash) { 288 case -1618432855: // identifier 289 this.getIdentifier().add(castToIdentifier(value)); // Identifier 290 return value; 291 case 3059181: // code 292 this.code = castToCodeableConcept(value); // CodeableConcept 293 return value; 294 case -991726143: // period 295 this.period = castToPeriod(value); // Period 296 return value; 297 case -1179159879: // issuer 298 this.issuer = castToReference(value); // Reference 299 return value; 300 default: return super.setProperty(hash, name, value); 301 } 302 303 } 304 305 @Override 306 public Base setProperty(String name, Base value) throws FHIRException { 307 if (name.equals("identifier")) { 308 this.getIdentifier().add(castToIdentifier(value)); 309 } else if (name.equals("code")) { 310 this.code = castToCodeableConcept(value); // CodeableConcept 311 } else if (name.equals("period")) { 312 this.period = castToPeriod(value); // Period 313 } else if (name.equals("issuer")) { 314 this.issuer = castToReference(value); // Reference 315 } else 316 return super.setProperty(name, value); 317 return value; 318 } 319 320 @Override 321 public Base makeProperty(int hash, String name) throws FHIRException { 322 switch (hash) { 323 case -1618432855: return addIdentifier(); 324 case 3059181: return getCode(); 325 case -991726143: return getPeriod(); 326 case -1179159879: return getIssuer(); 327 default: return super.makeProperty(hash, name); 328 } 329 330 } 331 332 @Override 333 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 334 switch (hash) { 335 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 336 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 337 case -991726143: /*period*/ return new String[] {"Period"}; 338 case -1179159879: /*issuer*/ return new String[] {"Reference"}; 339 default: return super.getTypesForProperty(hash, name); 340 } 341 342 } 343 344 @Override 345 public Base addChild(String name) throws FHIRException { 346 if (name.equals("identifier")) { 347 return addIdentifier(); 348 } 349 else if (name.equals("code")) { 350 this.code = new CodeableConcept(); 351 return this.code; 352 } 353 else if (name.equals("period")) { 354 this.period = new Period(); 355 return this.period; 356 } 357 else if (name.equals("issuer")) { 358 this.issuer = new Reference(); 359 return this.issuer; 360 } 361 else 362 return super.addChild(name); 363 } 364 365 public PractitionerQualificationComponent copy() { 366 PractitionerQualificationComponent dst = new PractitionerQualificationComponent(); 367 copyValues(dst); 368 return dst; 369 } 370 371 public void copyValues(PractitionerQualificationComponent dst) { 372 super.copyValues(dst); 373 if (identifier != null) { 374 dst.identifier = new ArrayList<Identifier>(); 375 for (Identifier i : identifier) 376 dst.identifier.add(i.copy()); 377 }; 378 dst.code = code == null ? null : code.copy(); 379 dst.period = period == null ? null : period.copy(); 380 dst.issuer = issuer == null ? null : issuer.copy(); 381 } 382 383 @Override 384 public boolean equalsDeep(Base other_) { 385 if (!super.equalsDeep(other_)) 386 return false; 387 if (!(other_ instanceof PractitionerQualificationComponent)) 388 return false; 389 PractitionerQualificationComponent o = (PractitionerQualificationComponent) other_; 390 return compareDeep(identifier, o.identifier, true) && compareDeep(code, o.code, true) && compareDeep(period, o.period, true) 391 && compareDeep(issuer, o.issuer, true); 392 } 393 394 @Override 395 public boolean equalsShallow(Base other_) { 396 if (!super.equalsShallow(other_)) 397 return false; 398 if (!(other_ instanceof PractitionerQualificationComponent)) 399 return false; 400 PractitionerQualificationComponent o = (PractitionerQualificationComponent) other_; 401 return true; 402 } 403 404 public boolean isEmpty() { 405 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, code, period 406 , issuer); 407 } 408 409 public String fhirType() { 410 return "Practitioner.qualification"; 411 412 } 413 414 } 415 416 /** 417 * An identifier that applies to this person in this role. 418 */ 419 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 420 @Description(shortDefinition="An identifier for the person as this agent", formalDefinition="An identifier that applies to this person in this role." ) 421 protected List<Identifier> identifier; 422 423 /** 424 * Whether this practitioner's record is in active use. 425 */ 426 @Child(name = "active", type = {BooleanType.class}, order=1, min=0, max=1, modifier=false, summary=true) 427 @Description(shortDefinition="Whether this practitioner's record is in active use", formalDefinition="Whether this practitioner's record is in active use." ) 428 protected BooleanType active; 429 430 /** 431 * The name(s) associated with the practitioner. 432 */ 433 @Child(name = "name", type = {HumanName.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 434 @Description(shortDefinition="The name(s) associated with the practitioner", formalDefinition="The name(s) associated with the practitioner." ) 435 protected List<HumanName> name; 436 437 /** 438 * A contact detail for the practitioner, e.g. a telephone number or an email address. 439 */ 440 @Child(name = "telecom", type = {ContactPoint.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 441 @Description(shortDefinition="A contact detail for the practitioner (that apply to all roles)", formalDefinition="A contact detail for the practitioner, e.g. a telephone number or an email address." ) 442 protected List<ContactPoint> telecom; 443 444 /** 445 * Address(es) of the practitioner that are not role specific (typically home address). 446Work addresses are not typically entered in this property as they are usually role dependent. 447 */ 448 @Child(name = "address", type = {Address.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 449 @Description(shortDefinition="Address(es) of the practitioner that are not role specific (typically home address)", formalDefinition="Address(es) of the practitioner that are not role specific (typically home address). \rWork addresses are not typically entered in this property as they are usually role dependent." ) 450 protected List<Address> address; 451 452 /** 453 * Administrative Gender - the gender that the person is considered to have for administration and record keeping purposes. 454 */ 455 @Child(name = "gender", type = {CodeType.class}, order=5, min=0, max=1, modifier=false, summary=true) 456 @Description(shortDefinition="male | female | other | unknown", formalDefinition="Administrative Gender - the gender that the person is considered to have for administration and record keeping purposes." ) 457 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/administrative-gender") 458 protected Enumeration<AdministrativeGender> gender; 459 460 /** 461 * The date of birth for the practitioner. 462 */ 463 @Child(name = "birthDate", type = {DateType.class}, order=6, min=0, max=1, modifier=false, summary=true) 464 @Description(shortDefinition="The date on which the practitioner was born", formalDefinition="The date of birth for the practitioner." ) 465 protected DateType birthDate; 466 467 /** 468 * Image of the person. 469 */ 470 @Child(name = "photo", type = {Attachment.class}, order=7, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 471 @Description(shortDefinition="Image of the person", formalDefinition="Image of the person." ) 472 protected List<Attachment> photo; 473 474 /** 475 * The official certifications, training, and licenses that authorize or otherwise pertain to the provision of care by the practitioner. For example, a medical license issued by a medical board authorizing the practitioner to practice medicine within a certian locality. 476 */ 477 @Child(name = "qualification", type = {}, order=8, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 478 @Description(shortDefinition="Certification, licenses, or training pertaining to the provision of care", formalDefinition="The official certifications, training, and licenses that authorize or otherwise pertain to the provision of care by the practitioner. For example, a medical license issued by a medical board authorizing the practitioner to practice medicine within a certian locality." ) 479 protected List<PractitionerQualificationComponent> qualification; 480 481 /** 482 * A language the practitioner can use in patient communication. 483 */ 484 @Child(name = "communication", type = {CodeableConcept.class}, order=9, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 485 @Description(shortDefinition="A language the practitioner can use in patient communication", formalDefinition="A language the practitioner can use in patient communication." ) 486 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/languages") 487 protected List<CodeableConcept> communication; 488 489 private static final long serialVersionUID = 2128349259L; 490 491 /** 492 * Constructor 493 */ 494 public Practitioner() { 495 super(); 496 } 497 498 /** 499 * @return {@link #identifier} (An identifier that applies to this person in this role.) 500 */ 501 public List<Identifier> getIdentifier() { 502 if (this.identifier == null) 503 this.identifier = new ArrayList<Identifier>(); 504 return this.identifier; 505 } 506 507 /** 508 * @return Returns a reference to <code>this</code> for easy method chaining 509 */ 510 public Practitioner setIdentifier(List<Identifier> theIdentifier) { 511 this.identifier = theIdentifier; 512 return this; 513 } 514 515 public boolean hasIdentifier() { 516 if (this.identifier == null) 517 return false; 518 for (Identifier item : this.identifier) 519 if (!item.isEmpty()) 520 return true; 521 return false; 522 } 523 524 public Identifier addIdentifier() { //3 525 Identifier t = new Identifier(); 526 if (this.identifier == null) 527 this.identifier = new ArrayList<Identifier>(); 528 this.identifier.add(t); 529 return t; 530 } 531 532 public Practitioner addIdentifier(Identifier t) { //3 533 if (t == null) 534 return this; 535 if (this.identifier == null) 536 this.identifier = new ArrayList<Identifier>(); 537 this.identifier.add(t); 538 return this; 539 } 540 541 /** 542 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist 543 */ 544 public Identifier getIdentifierFirstRep() { 545 if (getIdentifier().isEmpty()) { 546 addIdentifier(); 547 } 548 return getIdentifier().get(0); 549 } 550 551 /** 552 * @return {@link #active} (Whether this practitioner's record is in active use.). This is the underlying object with id, value and extensions. The accessor "getActive" gives direct access to the value 553 */ 554 public BooleanType getActiveElement() { 555 if (this.active == null) 556 if (Configuration.errorOnAutoCreate()) 557 throw new Error("Attempt to auto-create Practitioner.active"); 558 else if (Configuration.doAutoCreate()) 559 this.active = new BooleanType(); // bb 560 return this.active; 561 } 562 563 public boolean hasActiveElement() { 564 return this.active != null && !this.active.isEmpty(); 565 } 566 567 public boolean hasActive() { 568 return this.active != null && !this.active.isEmpty(); 569 } 570 571 /** 572 * @param value {@link #active} (Whether this practitioner's record is in active use.). This is the underlying object with id, value and extensions. The accessor "getActive" gives direct access to the value 573 */ 574 public Practitioner setActiveElement(BooleanType value) { 575 this.active = value; 576 return this; 577 } 578 579 /** 580 * @return Whether this practitioner's record is in active use. 581 */ 582 public boolean getActive() { 583 return this.active == null || this.active.isEmpty() ? false : this.active.getValue(); 584 } 585 586 /** 587 * @param value Whether this practitioner's record is in active use. 588 */ 589 public Practitioner setActive(boolean value) { 590 if (this.active == null) 591 this.active = new BooleanType(); 592 this.active.setValue(value); 593 return this; 594 } 595 596 /** 597 * @return {@link #name} (The name(s) associated with the practitioner.) 598 */ 599 public List<HumanName> getName() { 600 if (this.name == null) 601 this.name = new ArrayList<HumanName>(); 602 return this.name; 603 } 604 605 /** 606 * @return Returns a reference to <code>this</code> for easy method chaining 607 */ 608 public Practitioner setName(List<HumanName> theName) { 609 this.name = theName; 610 return this; 611 } 612 613 public boolean hasName() { 614 if (this.name == null) 615 return false; 616 for (HumanName item : this.name) 617 if (!item.isEmpty()) 618 return true; 619 return false; 620 } 621 622 public HumanName addName() { //3 623 HumanName t = new HumanName(); 624 if (this.name == null) 625 this.name = new ArrayList<HumanName>(); 626 this.name.add(t); 627 return t; 628 } 629 630 public Practitioner addName(HumanName t) { //3 631 if (t == null) 632 return this; 633 if (this.name == null) 634 this.name = new ArrayList<HumanName>(); 635 this.name.add(t); 636 return this; 637 } 638 639 /** 640 * @return The first repetition of repeating field {@link #name}, creating it if it does not already exist 641 */ 642 public HumanName getNameFirstRep() { 643 if (getName().isEmpty()) { 644 addName(); 645 } 646 return getName().get(0); 647 } 648 649 /** 650 * @return {@link #telecom} (A contact detail for the practitioner, e.g. a telephone number or an email address.) 651 */ 652 public List<ContactPoint> getTelecom() { 653 if (this.telecom == null) 654 this.telecom = new ArrayList<ContactPoint>(); 655 return this.telecom; 656 } 657 658 /** 659 * @return Returns a reference to <code>this</code> for easy method chaining 660 */ 661 public Practitioner setTelecom(List<ContactPoint> theTelecom) { 662 this.telecom = theTelecom; 663 return this; 664 } 665 666 public boolean hasTelecom() { 667 if (this.telecom == null) 668 return false; 669 for (ContactPoint item : this.telecom) 670 if (!item.isEmpty()) 671 return true; 672 return false; 673 } 674 675 public ContactPoint addTelecom() { //3 676 ContactPoint t = new ContactPoint(); 677 if (this.telecom == null) 678 this.telecom = new ArrayList<ContactPoint>(); 679 this.telecom.add(t); 680 return t; 681 } 682 683 public Practitioner addTelecom(ContactPoint t) { //3 684 if (t == null) 685 return this; 686 if (this.telecom == null) 687 this.telecom = new ArrayList<ContactPoint>(); 688 this.telecom.add(t); 689 return this; 690 } 691 692 /** 693 * @return The first repetition of repeating field {@link #telecom}, creating it if it does not already exist 694 */ 695 public ContactPoint getTelecomFirstRep() { 696 if (getTelecom().isEmpty()) { 697 addTelecom(); 698 } 699 return getTelecom().get(0); 700 } 701 702 /** 703 * @return {@link #address} (Address(es) of the practitioner that are not role specific (typically home address). 704Work addresses are not typically entered in this property as they are usually role dependent.) 705 */ 706 public List<Address> getAddress() { 707 if (this.address == null) 708 this.address = new ArrayList<Address>(); 709 return this.address; 710 } 711 712 /** 713 * @return Returns a reference to <code>this</code> for easy method chaining 714 */ 715 public Practitioner setAddress(List<Address> theAddress) { 716 this.address = theAddress; 717 return this; 718 } 719 720 public boolean hasAddress() { 721 if (this.address == null) 722 return false; 723 for (Address item : this.address) 724 if (!item.isEmpty()) 725 return true; 726 return false; 727 } 728 729 public Address addAddress() { //3 730 Address t = new Address(); 731 if (this.address == null) 732 this.address = new ArrayList<Address>(); 733 this.address.add(t); 734 return t; 735 } 736 737 public Practitioner addAddress(Address t) { //3 738 if (t == null) 739 return this; 740 if (this.address == null) 741 this.address = new ArrayList<Address>(); 742 this.address.add(t); 743 return this; 744 } 745 746 /** 747 * @return The first repetition of repeating field {@link #address}, creating it if it does not already exist 748 */ 749 public Address getAddressFirstRep() { 750 if (getAddress().isEmpty()) { 751 addAddress(); 752 } 753 return getAddress().get(0); 754 } 755 756 /** 757 * @return {@link #gender} (Administrative Gender - the gender that the person is considered to have for administration and record keeping purposes.). This is the underlying object with id, value and extensions. The accessor "getGender" gives direct access to the value 758 */ 759 public Enumeration<AdministrativeGender> getGenderElement() { 760 if (this.gender == null) 761 if (Configuration.errorOnAutoCreate()) 762 throw new Error("Attempt to auto-create Practitioner.gender"); 763 else if (Configuration.doAutoCreate()) 764 this.gender = new Enumeration<AdministrativeGender>(new AdministrativeGenderEnumFactory()); // bb 765 return this.gender; 766 } 767 768 public boolean hasGenderElement() { 769 return this.gender != null && !this.gender.isEmpty(); 770 } 771 772 public boolean hasGender() { 773 return this.gender != null && !this.gender.isEmpty(); 774 } 775 776 /** 777 * @param value {@link #gender} (Administrative Gender - the gender that the person is considered to have for administration and record keeping purposes.). This is the underlying object with id, value and extensions. The accessor "getGender" gives direct access to the value 778 */ 779 public Practitioner setGenderElement(Enumeration<AdministrativeGender> value) { 780 this.gender = value; 781 return this; 782 } 783 784 /** 785 * @return Administrative Gender - the gender that the person is considered to have for administration and record keeping purposes. 786 */ 787 public AdministrativeGender getGender() { 788 return this.gender == null ? null : this.gender.getValue(); 789 } 790 791 /** 792 * @param value Administrative Gender - the gender that the person is considered to have for administration and record keeping purposes. 793 */ 794 public Practitioner setGender(AdministrativeGender value) { 795 if (value == null) 796 this.gender = null; 797 else { 798 if (this.gender == null) 799 this.gender = new Enumeration<AdministrativeGender>(new AdministrativeGenderEnumFactory()); 800 this.gender.setValue(value); 801 } 802 return this; 803 } 804 805 /** 806 * @return {@link #birthDate} (The date of birth for the practitioner.). This is the underlying object with id, value and extensions. The accessor "getBirthDate" gives direct access to the value 807 */ 808 public DateType getBirthDateElement() { 809 if (this.birthDate == null) 810 if (Configuration.errorOnAutoCreate()) 811 throw new Error("Attempt to auto-create Practitioner.birthDate"); 812 else if (Configuration.doAutoCreate()) 813 this.birthDate = new DateType(); // bb 814 return this.birthDate; 815 } 816 817 public boolean hasBirthDateElement() { 818 return this.birthDate != null && !this.birthDate.isEmpty(); 819 } 820 821 public boolean hasBirthDate() { 822 return this.birthDate != null && !this.birthDate.isEmpty(); 823 } 824 825 /** 826 * @param value {@link #birthDate} (The date of birth for the practitioner.). This is the underlying object with id, value and extensions. The accessor "getBirthDate" gives direct access to the value 827 */ 828 public Practitioner setBirthDateElement(DateType value) { 829 this.birthDate = value; 830 return this; 831 } 832 833 /** 834 * @return The date of birth for the practitioner. 835 */ 836 public Date getBirthDate() { 837 return this.birthDate == null ? null : this.birthDate.getValue(); 838 } 839 840 /** 841 * @param value The date of birth for the practitioner. 842 */ 843 public Practitioner setBirthDate(Date value) { 844 if (value == null) 845 this.birthDate = null; 846 else { 847 if (this.birthDate == null) 848 this.birthDate = new DateType(); 849 this.birthDate.setValue(value); 850 } 851 return this; 852 } 853 854 /** 855 * @return {@link #photo} (Image of the person.) 856 */ 857 public List<Attachment> getPhoto() { 858 if (this.photo == null) 859 this.photo = new ArrayList<Attachment>(); 860 return this.photo; 861 } 862 863 /** 864 * @return Returns a reference to <code>this</code> for easy method chaining 865 */ 866 public Practitioner setPhoto(List<Attachment> thePhoto) { 867 this.photo = thePhoto; 868 return this; 869 } 870 871 public boolean hasPhoto() { 872 if (this.photo == null) 873 return false; 874 for (Attachment item : this.photo) 875 if (!item.isEmpty()) 876 return true; 877 return false; 878 } 879 880 public Attachment addPhoto() { //3 881 Attachment t = new Attachment(); 882 if (this.photo == null) 883 this.photo = new ArrayList<Attachment>(); 884 this.photo.add(t); 885 return t; 886 } 887 888 public Practitioner addPhoto(Attachment t) { //3 889 if (t == null) 890 return this; 891 if (this.photo == null) 892 this.photo = new ArrayList<Attachment>(); 893 this.photo.add(t); 894 return this; 895 } 896 897 /** 898 * @return The first repetition of repeating field {@link #photo}, creating it if it does not already exist 899 */ 900 public Attachment getPhotoFirstRep() { 901 if (getPhoto().isEmpty()) { 902 addPhoto(); 903 } 904 return getPhoto().get(0); 905 } 906 907 /** 908 * @return {@link #qualification} (The official certifications, training, and licenses that authorize or otherwise pertain to the provision of care by the practitioner. For example, a medical license issued by a medical board authorizing the practitioner to practice medicine within a certian locality.) 909 */ 910 public List<PractitionerQualificationComponent> getQualification() { 911 if (this.qualification == null) 912 this.qualification = new ArrayList<PractitionerQualificationComponent>(); 913 return this.qualification; 914 } 915 916 /** 917 * @return Returns a reference to <code>this</code> for easy method chaining 918 */ 919 public Practitioner setQualification(List<PractitionerQualificationComponent> theQualification) { 920 this.qualification = theQualification; 921 return this; 922 } 923 924 public boolean hasQualification() { 925 if (this.qualification == null) 926 return false; 927 for (PractitionerQualificationComponent item : this.qualification) 928 if (!item.isEmpty()) 929 return true; 930 return false; 931 } 932 933 public PractitionerQualificationComponent addQualification() { //3 934 PractitionerQualificationComponent t = new PractitionerQualificationComponent(); 935 if (this.qualification == null) 936 this.qualification = new ArrayList<PractitionerQualificationComponent>(); 937 this.qualification.add(t); 938 return t; 939 } 940 941 public Practitioner addQualification(PractitionerQualificationComponent t) { //3 942 if (t == null) 943 return this; 944 if (this.qualification == null) 945 this.qualification = new ArrayList<PractitionerQualificationComponent>(); 946 this.qualification.add(t); 947 return this; 948 } 949 950 /** 951 * @return The first repetition of repeating field {@link #qualification}, creating it if it does not already exist 952 */ 953 public PractitionerQualificationComponent getQualificationFirstRep() { 954 if (getQualification().isEmpty()) { 955 addQualification(); 956 } 957 return getQualification().get(0); 958 } 959 960 /** 961 * @return {@link #communication} (A language the practitioner can use in patient communication.) 962 */ 963 public List<CodeableConcept> getCommunication() { 964 if (this.communication == null) 965 this.communication = new ArrayList<CodeableConcept>(); 966 return this.communication; 967 } 968 969 /** 970 * @return Returns a reference to <code>this</code> for easy method chaining 971 */ 972 public Practitioner setCommunication(List<CodeableConcept> theCommunication) { 973 this.communication = theCommunication; 974 return this; 975 } 976 977 public boolean hasCommunication() { 978 if (this.communication == null) 979 return false; 980 for (CodeableConcept item : this.communication) 981 if (!item.isEmpty()) 982 return true; 983 return false; 984 } 985 986 public CodeableConcept addCommunication() { //3 987 CodeableConcept t = new CodeableConcept(); 988 if (this.communication == null) 989 this.communication = new ArrayList<CodeableConcept>(); 990 this.communication.add(t); 991 return t; 992 } 993 994 public Practitioner addCommunication(CodeableConcept t) { //3 995 if (t == null) 996 return this; 997 if (this.communication == null) 998 this.communication = new ArrayList<CodeableConcept>(); 999 this.communication.add(t); 1000 return this; 1001 } 1002 1003 /** 1004 * @return The first repetition of repeating field {@link #communication}, creating it if it does not already exist 1005 */ 1006 public CodeableConcept getCommunicationFirstRep() { 1007 if (getCommunication().isEmpty()) { 1008 addCommunication(); 1009 } 1010 return getCommunication().get(0); 1011 } 1012 1013 protected void listChildren(List<Property> children) { 1014 super.listChildren(children); 1015 children.add(new Property("identifier", "Identifier", "An identifier that applies to this person in this role.", 0, java.lang.Integer.MAX_VALUE, identifier)); 1016 children.add(new Property("active", "boolean", "Whether this practitioner's record is in active use.", 0, 1, active)); 1017 children.add(new Property("name", "HumanName", "The name(s) associated with the practitioner.", 0, java.lang.Integer.MAX_VALUE, name)); 1018 children.add(new Property("telecom", "ContactPoint", "A contact detail for the practitioner, e.g. a telephone number or an email address.", 0, java.lang.Integer.MAX_VALUE, telecom)); 1019 children.add(new Property("address", "Address", "Address(es) of the practitioner that are not role specific (typically home address). \rWork addresses are not typically entered in this property as they are usually role dependent.", 0, java.lang.Integer.MAX_VALUE, address)); 1020 children.add(new Property("gender", "code", "Administrative Gender - the gender that the person is considered to have for administration and record keeping purposes.", 0, 1, gender)); 1021 children.add(new Property("birthDate", "date", "The date of birth for the practitioner.", 0, 1, birthDate)); 1022 children.add(new Property("photo", "Attachment", "Image of the person.", 0, java.lang.Integer.MAX_VALUE, photo)); 1023 children.add(new Property("qualification", "", "The official certifications, training, and licenses that authorize or otherwise pertain to the provision of care by the practitioner. For example, a medical license issued by a medical board authorizing the practitioner to practice medicine within a certian locality.", 0, java.lang.Integer.MAX_VALUE, qualification)); 1024 children.add(new Property("communication", "CodeableConcept", "A language the practitioner can use in patient communication.", 0, java.lang.Integer.MAX_VALUE, communication)); 1025 } 1026 1027 @Override 1028 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1029 switch (_hash) { 1030 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "An identifier that applies to this person in this role.", 0, java.lang.Integer.MAX_VALUE, identifier); 1031 case -1422950650: /*active*/ return new Property("active", "boolean", "Whether this practitioner's record is in active use.", 0, 1, active); 1032 case 3373707: /*name*/ return new Property("name", "HumanName", "The name(s) associated with the practitioner.", 0, java.lang.Integer.MAX_VALUE, name); 1033 case -1429363305: /*telecom*/ return new Property("telecom", "ContactPoint", "A contact detail for the practitioner, e.g. a telephone number or an email address.", 0, java.lang.Integer.MAX_VALUE, telecom); 1034 case -1147692044: /*address*/ return new Property("address", "Address", "Address(es) of the practitioner that are not role specific (typically home address). \rWork addresses are not typically entered in this property as they are usually role dependent.", 0, java.lang.Integer.MAX_VALUE, address); 1035 case -1249512767: /*gender*/ return new Property("gender", "code", "Administrative Gender - the gender that the person is considered to have for administration and record keeping purposes.", 0, 1, gender); 1036 case -1210031859: /*birthDate*/ return new Property("birthDate", "date", "The date of birth for the practitioner.", 0, 1, birthDate); 1037 case 106642994: /*photo*/ return new Property("photo", "Attachment", "Image of the person.", 0, java.lang.Integer.MAX_VALUE, photo); 1038 case -631333393: /*qualification*/ return new Property("qualification", "", "The official certifications, training, and licenses that authorize or otherwise pertain to the provision of care by the practitioner. For example, a medical license issued by a medical board authorizing the practitioner to practice medicine within a certian locality.", 0, java.lang.Integer.MAX_VALUE, qualification); 1039 case -1035284522: /*communication*/ return new Property("communication", "CodeableConcept", "A language the practitioner can use in patient communication.", 0, java.lang.Integer.MAX_VALUE, communication); 1040 default: return super.getNamedProperty(_hash, _name, _checkValid); 1041 } 1042 1043 } 1044 1045 @Override 1046 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1047 switch (hash) { 1048 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 1049 case -1422950650: /*active*/ return this.active == null ? new Base[0] : new Base[] {this.active}; // BooleanType 1050 case 3373707: /*name*/ return this.name == null ? new Base[0] : this.name.toArray(new Base[this.name.size()]); // HumanName 1051 case -1429363305: /*telecom*/ return this.telecom == null ? new Base[0] : this.telecom.toArray(new Base[this.telecom.size()]); // ContactPoint 1052 case -1147692044: /*address*/ return this.address == null ? new Base[0] : this.address.toArray(new Base[this.address.size()]); // Address 1053 case -1249512767: /*gender*/ return this.gender == null ? new Base[0] : new Base[] {this.gender}; // Enumeration<AdministrativeGender> 1054 case -1210031859: /*birthDate*/ return this.birthDate == null ? new Base[0] : new Base[] {this.birthDate}; // DateType 1055 case 106642994: /*photo*/ return this.photo == null ? new Base[0] : this.photo.toArray(new Base[this.photo.size()]); // Attachment 1056 case -631333393: /*qualification*/ return this.qualification == null ? new Base[0] : this.qualification.toArray(new Base[this.qualification.size()]); // PractitionerQualificationComponent 1057 case -1035284522: /*communication*/ return this.communication == null ? new Base[0] : this.communication.toArray(new Base[this.communication.size()]); // CodeableConcept 1058 default: return super.getProperty(hash, name, checkValid); 1059 } 1060 1061 } 1062 1063 @Override 1064 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1065 switch (hash) { 1066 case -1618432855: // identifier 1067 this.getIdentifier().add(castToIdentifier(value)); // Identifier 1068 return value; 1069 case -1422950650: // active 1070 this.active = castToBoolean(value); // BooleanType 1071 return value; 1072 case 3373707: // name 1073 this.getName().add(castToHumanName(value)); // HumanName 1074 return value; 1075 case -1429363305: // telecom 1076 this.getTelecom().add(castToContactPoint(value)); // ContactPoint 1077 return value; 1078 case -1147692044: // address 1079 this.getAddress().add(castToAddress(value)); // Address 1080 return value; 1081 case -1249512767: // gender 1082 value = new AdministrativeGenderEnumFactory().fromType(castToCode(value)); 1083 this.gender = (Enumeration) value; // Enumeration<AdministrativeGender> 1084 return value; 1085 case -1210031859: // birthDate 1086 this.birthDate = castToDate(value); // DateType 1087 return value; 1088 case 106642994: // photo 1089 this.getPhoto().add(castToAttachment(value)); // Attachment 1090 return value; 1091 case -631333393: // qualification 1092 this.getQualification().add((PractitionerQualificationComponent) value); // PractitionerQualificationComponent 1093 return value; 1094 case -1035284522: // communication 1095 this.getCommunication().add(castToCodeableConcept(value)); // CodeableConcept 1096 return value; 1097 default: return super.setProperty(hash, name, value); 1098 } 1099 1100 } 1101 1102 @Override 1103 public Base setProperty(String name, Base value) throws FHIRException { 1104 if (name.equals("identifier")) { 1105 this.getIdentifier().add(castToIdentifier(value)); 1106 } else if (name.equals("active")) { 1107 this.active = castToBoolean(value); // BooleanType 1108 } else if (name.equals("name")) { 1109 this.getName().add(castToHumanName(value)); 1110 } else if (name.equals("telecom")) { 1111 this.getTelecom().add(castToContactPoint(value)); 1112 } else if (name.equals("address")) { 1113 this.getAddress().add(castToAddress(value)); 1114 } else if (name.equals("gender")) { 1115 value = new AdministrativeGenderEnumFactory().fromType(castToCode(value)); 1116 this.gender = (Enumeration) value; // Enumeration<AdministrativeGender> 1117 } else if (name.equals("birthDate")) { 1118 this.birthDate = castToDate(value); // DateType 1119 } else if (name.equals("photo")) { 1120 this.getPhoto().add(castToAttachment(value)); 1121 } else if (name.equals("qualification")) { 1122 this.getQualification().add((PractitionerQualificationComponent) value); 1123 } else if (name.equals("communication")) { 1124 this.getCommunication().add(castToCodeableConcept(value)); 1125 } else 1126 return super.setProperty(name, value); 1127 return value; 1128 } 1129 1130 @Override 1131 public Base makeProperty(int hash, String name) throws FHIRException { 1132 switch (hash) { 1133 case -1618432855: return addIdentifier(); 1134 case -1422950650: return getActiveElement(); 1135 case 3373707: return addName(); 1136 case -1429363305: return addTelecom(); 1137 case -1147692044: return addAddress(); 1138 case -1249512767: return getGenderElement(); 1139 case -1210031859: return getBirthDateElement(); 1140 case 106642994: return addPhoto(); 1141 case -631333393: return addQualification(); 1142 case -1035284522: return addCommunication(); 1143 default: return super.makeProperty(hash, name); 1144 } 1145 1146 } 1147 1148 @Override 1149 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1150 switch (hash) { 1151 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 1152 case -1422950650: /*active*/ return new String[] {"boolean"}; 1153 case 3373707: /*name*/ return new String[] {"HumanName"}; 1154 case -1429363305: /*telecom*/ return new String[] {"ContactPoint"}; 1155 case -1147692044: /*address*/ return new String[] {"Address"}; 1156 case -1249512767: /*gender*/ return new String[] {"code"}; 1157 case -1210031859: /*birthDate*/ return new String[] {"date"}; 1158 case 106642994: /*photo*/ return new String[] {"Attachment"}; 1159 case -631333393: /*qualification*/ return new String[] {}; 1160 case -1035284522: /*communication*/ return new String[] {"CodeableConcept"}; 1161 default: return super.getTypesForProperty(hash, name); 1162 } 1163 1164 } 1165 1166 @Override 1167 public Base addChild(String name) throws FHIRException { 1168 if (name.equals("identifier")) { 1169 return addIdentifier(); 1170 } 1171 else if (name.equals("active")) { 1172 throw new FHIRException("Cannot call addChild on a primitive type Practitioner.active"); 1173 } 1174 else if (name.equals("name")) { 1175 return addName(); 1176 } 1177 else if (name.equals("telecom")) { 1178 return addTelecom(); 1179 } 1180 else if (name.equals("address")) { 1181 return addAddress(); 1182 } 1183 else if (name.equals("gender")) { 1184 throw new FHIRException("Cannot call addChild on a primitive type Practitioner.gender"); 1185 } 1186 else if (name.equals("birthDate")) { 1187 throw new FHIRException("Cannot call addChild on a primitive type Practitioner.birthDate"); 1188 } 1189 else if (name.equals("photo")) { 1190 return addPhoto(); 1191 } 1192 else if (name.equals("qualification")) { 1193 return addQualification(); 1194 } 1195 else if (name.equals("communication")) { 1196 return addCommunication(); 1197 } 1198 else 1199 return super.addChild(name); 1200 } 1201 1202 public String fhirType() { 1203 return "Practitioner"; 1204 1205 } 1206 1207 public Practitioner copy() { 1208 Practitioner dst = new Practitioner(); 1209 copyValues(dst); 1210 return dst; 1211 } 1212 1213 public void copyValues(Practitioner dst) { 1214 super.copyValues(dst); 1215 if (identifier != null) { 1216 dst.identifier = new ArrayList<Identifier>(); 1217 for (Identifier i : identifier) 1218 dst.identifier.add(i.copy()); 1219 }; 1220 dst.active = active == null ? null : active.copy(); 1221 if (name != null) { 1222 dst.name = new ArrayList<HumanName>(); 1223 for (HumanName i : name) 1224 dst.name.add(i.copy()); 1225 }; 1226 if (telecom != null) { 1227 dst.telecom = new ArrayList<ContactPoint>(); 1228 for (ContactPoint i : telecom) 1229 dst.telecom.add(i.copy()); 1230 }; 1231 if (address != null) { 1232 dst.address = new ArrayList<Address>(); 1233 for (Address i : address) 1234 dst.address.add(i.copy()); 1235 }; 1236 dst.gender = gender == null ? null : gender.copy(); 1237 dst.birthDate = birthDate == null ? null : birthDate.copy(); 1238 if (photo != null) { 1239 dst.photo = new ArrayList<Attachment>(); 1240 for (Attachment i : photo) 1241 dst.photo.add(i.copy()); 1242 }; 1243 if (qualification != null) { 1244 dst.qualification = new ArrayList<PractitionerQualificationComponent>(); 1245 for (PractitionerQualificationComponent i : qualification) 1246 dst.qualification.add(i.copy()); 1247 }; 1248 if (communication != null) { 1249 dst.communication = new ArrayList<CodeableConcept>(); 1250 for (CodeableConcept i : communication) 1251 dst.communication.add(i.copy()); 1252 }; 1253 } 1254 1255 protected Practitioner typedCopy() { 1256 return copy(); 1257 } 1258 1259 @Override 1260 public boolean equalsDeep(Base other_) { 1261 if (!super.equalsDeep(other_)) 1262 return false; 1263 if (!(other_ instanceof Practitioner)) 1264 return false; 1265 Practitioner o = (Practitioner) other_; 1266 return compareDeep(identifier, o.identifier, true) && compareDeep(active, o.active, true) && compareDeep(name, o.name, true) 1267 && compareDeep(telecom, o.telecom, true) && compareDeep(address, o.address, true) && compareDeep(gender, o.gender, true) 1268 && compareDeep(birthDate, o.birthDate, true) && compareDeep(photo, o.photo, true) && compareDeep(qualification, o.qualification, true) 1269 && compareDeep(communication, o.communication, true); 1270 } 1271 1272 @Override 1273 public boolean equalsShallow(Base other_) { 1274 if (!super.equalsShallow(other_)) 1275 return false; 1276 if (!(other_ instanceof Practitioner)) 1277 return false; 1278 Practitioner o = (Practitioner) other_; 1279 return compareValues(active, o.active, true) && compareValues(gender, o.gender, true) && compareValues(birthDate, o.birthDate, true) 1280 ; 1281 } 1282 1283 public boolean isEmpty() { 1284 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, active, name 1285 , telecom, address, gender, birthDate, photo, qualification, communication); 1286 } 1287 1288 @Override 1289 public ResourceType getResourceType() { 1290 return ResourceType.Practitioner; 1291 } 1292 1293 /** 1294 * Search parameter: <b>identifier</b> 1295 * <p> 1296 * Description: <b>A practitioner's Identifier</b><br> 1297 * Type: <b>token</b><br> 1298 * Path: <b>Practitioner.identifier</b><br> 1299 * </p> 1300 */ 1301 @SearchParamDefinition(name="identifier", path="Practitioner.identifier", description="A practitioner's Identifier", type="token" ) 1302 public static final String SP_IDENTIFIER = "identifier"; 1303 /** 1304 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 1305 * <p> 1306 * Description: <b>A practitioner's Identifier</b><br> 1307 * Type: <b>token</b><br> 1308 * Path: <b>Practitioner.identifier</b><br> 1309 * </p> 1310 */ 1311 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 1312 1313 /** 1314 * Search parameter: <b>given</b> 1315 * <p> 1316 * Description: <b>A portion of the given name</b><br> 1317 * Type: <b>string</b><br> 1318 * Path: <b>Practitioner.name.given</b><br> 1319 * </p> 1320 */ 1321 @SearchParamDefinition(name="given", path="Practitioner.name.given", description="A portion of the given name", type="string" ) 1322 public static final String SP_GIVEN = "given"; 1323 /** 1324 * <b>Fluent Client</b> search parameter constant for <b>given</b> 1325 * <p> 1326 * Description: <b>A portion of the given name</b><br> 1327 * Type: <b>string</b><br> 1328 * Path: <b>Practitioner.name.given</b><br> 1329 * </p> 1330 */ 1331 public static final ca.uhn.fhir.rest.gclient.StringClientParam GIVEN = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_GIVEN); 1332 1333 /** 1334 * Search parameter: <b>address</b> 1335 * <p> 1336 * Description: <b>A server defined search that may match any of the string fields in the Address, including line, city, district, state, country, postalCode, and/or text</b><br> 1337 * Type: <b>string</b><br> 1338 * Path: <b>Practitioner.address</b><br> 1339 * </p> 1340 */ 1341 @SearchParamDefinition(name="address", path="Practitioner.address", description="A server defined search that may match any of the string fields in the Address, including line, city, district, state, country, postalCode, and/or text", type="string" ) 1342 public static final String SP_ADDRESS = "address"; 1343 /** 1344 * <b>Fluent Client</b> search parameter constant for <b>address</b> 1345 * <p> 1346 * Description: <b>A server defined search that may match any of the string fields in the Address, including line, city, district, state, country, postalCode, and/or text</b><br> 1347 * Type: <b>string</b><br> 1348 * Path: <b>Practitioner.address</b><br> 1349 * </p> 1350 */ 1351 public static final ca.uhn.fhir.rest.gclient.StringClientParam ADDRESS = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ADDRESS); 1352 1353 /** 1354 * Search parameter: <b>address-state</b> 1355 * <p> 1356 * Description: <b>A state specified in an address</b><br> 1357 * Type: <b>string</b><br> 1358 * Path: <b>Practitioner.address.state</b><br> 1359 * </p> 1360 */ 1361 @SearchParamDefinition(name="address-state", path="Practitioner.address.state", description="A state specified in an address", type="string" ) 1362 public static final String SP_ADDRESS_STATE = "address-state"; 1363 /** 1364 * <b>Fluent Client</b> search parameter constant for <b>address-state</b> 1365 * <p> 1366 * Description: <b>A state specified in an address</b><br> 1367 * Type: <b>string</b><br> 1368 * Path: <b>Practitioner.address.state</b><br> 1369 * </p> 1370 */ 1371 public static final ca.uhn.fhir.rest.gclient.StringClientParam ADDRESS_STATE = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ADDRESS_STATE); 1372 1373 /** 1374 * Search parameter: <b>gender</b> 1375 * <p> 1376 * Description: <b>Gender of the practitioner</b><br> 1377 * Type: <b>token</b><br> 1378 * Path: <b>Practitioner.gender</b><br> 1379 * </p> 1380 */ 1381 @SearchParamDefinition(name="gender", path="Practitioner.gender", description="Gender of the practitioner", type="token" ) 1382 public static final String SP_GENDER = "gender"; 1383 /** 1384 * <b>Fluent Client</b> search parameter constant for <b>gender</b> 1385 * <p> 1386 * Description: <b>Gender of the practitioner</b><br> 1387 * Type: <b>token</b><br> 1388 * Path: <b>Practitioner.gender</b><br> 1389 * </p> 1390 */ 1391 public static final ca.uhn.fhir.rest.gclient.TokenClientParam GENDER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_GENDER); 1392 1393 /** 1394 * Search parameter: <b>active</b> 1395 * <p> 1396 * Description: <b>Whether the practitioner record is active</b><br> 1397 * Type: <b>token</b><br> 1398 * Path: <b>Practitioner.active</b><br> 1399 * </p> 1400 */ 1401 @SearchParamDefinition(name="active", path="Practitioner.active", description="Whether the practitioner record is active", type="token" ) 1402 public static final String SP_ACTIVE = "active"; 1403 /** 1404 * <b>Fluent Client</b> search parameter constant for <b>active</b> 1405 * <p> 1406 * Description: <b>Whether the practitioner record is active</b><br> 1407 * Type: <b>token</b><br> 1408 * Path: <b>Practitioner.active</b><br> 1409 * </p> 1410 */ 1411 public static final ca.uhn.fhir.rest.gclient.TokenClientParam ACTIVE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_ACTIVE); 1412 1413 /** 1414 * Search parameter: <b>address-postalcode</b> 1415 * <p> 1416 * Description: <b>A postalCode specified in an address</b><br> 1417 * Type: <b>string</b><br> 1418 * Path: <b>Practitioner.address.postalCode</b><br> 1419 * </p> 1420 */ 1421 @SearchParamDefinition(name="address-postalcode", path="Practitioner.address.postalCode", description="A postalCode specified in an address", type="string" ) 1422 public static final String SP_ADDRESS_POSTALCODE = "address-postalcode"; 1423 /** 1424 * <b>Fluent Client</b> search parameter constant for <b>address-postalcode</b> 1425 * <p> 1426 * Description: <b>A postalCode specified in an address</b><br> 1427 * Type: <b>string</b><br> 1428 * Path: <b>Practitioner.address.postalCode</b><br> 1429 * </p> 1430 */ 1431 public static final ca.uhn.fhir.rest.gclient.StringClientParam ADDRESS_POSTALCODE = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ADDRESS_POSTALCODE); 1432 1433 /** 1434 * Search parameter: <b>address-country</b> 1435 * <p> 1436 * Description: <b>A country specified in an address</b><br> 1437 * Type: <b>string</b><br> 1438 * Path: <b>Practitioner.address.country</b><br> 1439 * </p> 1440 */ 1441 @SearchParamDefinition(name="address-country", path="Practitioner.address.country", description="A country specified in an address", type="string" ) 1442 public static final String SP_ADDRESS_COUNTRY = "address-country"; 1443 /** 1444 * <b>Fluent Client</b> search parameter constant for <b>address-country</b> 1445 * <p> 1446 * Description: <b>A country specified in an address</b><br> 1447 * Type: <b>string</b><br> 1448 * Path: <b>Practitioner.address.country</b><br> 1449 * </p> 1450 */ 1451 public static final ca.uhn.fhir.rest.gclient.StringClientParam ADDRESS_COUNTRY = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ADDRESS_COUNTRY); 1452 1453 /** 1454 * Search parameter: <b>phonetic</b> 1455 * <p> 1456 * Description: <b>A portion of either family or given name using some kind of phonetic matching algorithm</b><br> 1457 * Type: <b>string</b><br> 1458 * Path: <b>Practitioner.name</b><br> 1459 * </p> 1460 */ 1461 @SearchParamDefinition(name="phonetic", path="Practitioner.name", description="A portion of either family or given name using some kind of phonetic matching algorithm", type="string" ) 1462 public static final String SP_PHONETIC = "phonetic"; 1463 /** 1464 * <b>Fluent Client</b> search parameter constant for <b>phonetic</b> 1465 * <p> 1466 * Description: <b>A portion of either family or given name using some kind of phonetic matching algorithm</b><br> 1467 * Type: <b>string</b><br> 1468 * Path: <b>Practitioner.name</b><br> 1469 * </p> 1470 */ 1471 public static final ca.uhn.fhir.rest.gclient.StringClientParam PHONETIC = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_PHONETIC); 1472 1473 /** 1474 * Search parameter: <b>phone</b> 1475 * <p> 1476 * Description: <b>A value in a phone contact</b><br> 1477 * Type: <b>token</b><br> 1478 * Path: <b>Practitioner.telecom(system=phone)</b><br> 1479 * </p> 1480 */ 1481 @SearchParamDefinition(name="phone", path="Practitioner.telecom.where(system='phone')", description="A value in a phone contact", type="token" ) 1482 public static final String SP_PHONE = "phone"; 1483 /** 1484 * <b>Fluent Client</b> search parameter constant for <b>phone</b> 1485 * <p> 1486 * Description: <b>A value in a phone contact</b><br> 1487 * Type: <b>token</b><br> 1488 * Path: <b>Practitioner.telecom(system=phone)</b><br> 1489 * </p> 1490 */ 1491 public static final ca.uhn.fhir.rest.gclient.TokenClientParam PHONE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_PHONE); 1492 1493 /** 1494 * Search parameter: <b>name</b> 1495 * <p> 1496 * Description: <b>A server defined search that may match any of the string fields in the HumanName, including family, give, prefix, suffix, suffix, and/or text</b><br> 1497 * Type: <b>string</b><br> 1498 * Path: <b>Practitioner.name</b><br> 1499 * </p> 1500 */ 1501 @SearchParamDefinition(name="name", path="Practitioner.name", description="A server defined search that may match any of the string fields in the HumanName, including family, give, prefix, suffix, suffix, and/or text", type="string" ) 1502 public static final String SP_NAME = "name"; 1503 /** 1504 * <b>Fluent Client</b> search parameter constant for <b>name</b> 1505 * <p> 1506 * Description: <b>A server defined search that may match any of the string fields in the HumanName, including family, give, prefix, suffix, suffix, and/or text</b><br> 1507 * Type: <b>string</b><br> 1508 * Path: <b>Practitioner.name</b><br> 1509 * </p> 1510 */ 1511 public static final ca.uhn.fhir.rest.gclient.StringClientParam NAME = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_NAME); 1512 1513 /** 1514 * Search parameter: <b>address-use</b> 1515 * <p> 1516 * Description: <b>A use code specified in an address</b><br> 1517 * Type: <b>token</b><br> 1518 * Path: <b>Practitioner.address.use</b><br> 1519 * </p> 1520 */ 1521 @SearchParamDefinition(name="address-use", path="Practitioner.address.use", description="A use code specified in an address", type="token" ) 1522 public static final String SP_ADDRESS_USE = "address-use"; 1523 /** 1524 * <b>Fluent Client</b> search parameter constant for <b>address-use</b> 1525 * <p> 1526 * Description: <b>A use code specified in an address</b><br> 1527 * Type: <b>token</b><br> 1528 * Path: <b>Practitioner.address.use</b><br> 1529 * </p> 1530 */ 1531 public static final ca.uhn.fhir.rest.gclient.TokenClientParam ADDRESS_USE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_ADDRESS_USE); 1532 1533 /** 1534 * Search parameter: <b>telecom</b> 1535 * <p> 1536 * Description: <b>The value in any kind of contact</b><br> 1537 * Type: <b>token</b><br> 1538 * Path: <b>Practitioner.telecom</b><br> 1539 * </p> 1540 */ 1541 @SearchParamDefinition(name="telecom", path="Practitioner.telecom", description="The value in any kind of contact", type="token" ) 1542 public static final String SP_TELECOM = "telecom"; 1543 /** 1544 * <b>Fluent Client</b> search parameter constant for <b>telecom</b> 1545 * <p> 1546 * Description: <b>The value in any kind of contact</b><br> 1547 * Type: <b>token</b><br> 1548 * Path: <b>Practitioner.telecom</b><br> 1549 * </p> 1550 */ 1551 public static final ca.uhn.fhir.rest.gclient.TokenClientParam TELECOM = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_TELECOM); 1552 1553 /** 1554 * Search parameter: <b>family</b> 1555 * <p> 1556 * Description: <b>A portion of the family name</b><br> 1557 * Type: <b>string</b><br> 1558 * Path: <b>Practitioner.name.family</b><br> 1559 * </p> 1560 */ 1561 @SearchParamDefinition(name="family", path="Practitioner.name.family", description="A portion of the family name", type="string" ) 1562 public static final String SP_FAMILY = "family"; 1563 /** 1564 * <b>Fluent Client</b> search parameter constant for <b>family</b> 1565 * <p> 1566 * Description: <b>A portion of the family name</b><br> 1567 * Type: <b>string</b><br> 1568 * Path: <b>Practitioner.name.family</b><br> 1569 * </p> 1570 */ 1571 public static final ca.uhn.fhir.rest.gclient.StringClientParam FAMILY = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_FAMILY); 1572 1573 /** 1574 * Search parameter: <b>address-city</b> 1575 * <p> 1576 * Description: <b>A city specified in an address</b><br> 1577 * Type: <b>string</b><br> 1578 * Path: <b>Practitioner.address.city</b><br> 1579 * </p> 1580 */ 1581 @SearchParamDefinition(name="address-city", path="Practitioner.address.city", description="A city specified in an address", type="string" ) 1582 public static final String SP_ADDRESS_CITY = "address-city"; 1583 /** 1584 * <b>Fluent Client</b> search parameter constant for <b>address-city</b> 1585 * <p> 1586 * Description: <b>A city specified in an address</b><br> 1587 * Type: <b>string</b><br> 1588 * Path: <b>Practitioner.address.city</b><br> 1589 * </p> 1590 */ 1591 public static final ca.uhn.fhir.rest.gclient.StringClientParam ADDRESS_CITY = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ADDRESS_CITY); 1592 1593 /** 1594 * Search parameter: <b>communication</b> 1595 * <p> 1596 * Description: <b>One of the languages that the practitioner can communicate with</b><br> 1597 * Type: <b>token</b><br> 1598 * Path: <b>Practitioner.communication</b><br> 1599 * </p> 1600 */ 1601 @SearchParamDefinition(name="communication", path="Practitioner.communication", description="One of the languages that the practitioner can communicate with", type="token" ) 1602 public static final String SP_COMMUNICATION = "communication"; 1603 /** 1604 * <b>Fluent Client</b> search parameter constant for <b>communication</b> 1605 * <p> 1606 * Description: <b>One of the languages that the practitioner can communicate with</b><br> 1607 * Type: <b>token</b><br> 1608 * Path: <b>Practitioner.communication</b><br> 1609 * </p> 1610 */ 1611 public static final ca.uhn.fhir.rest.gclient.TokenClientParam COMMUNICATION = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_COMMUNICATION); 1612 1613 /** 1614 * Search parameter: <b>email</b> 1615 * <p> 1616 * Description: <b>A value in an email contact</b><br> 1617 * Type: <b>token</b><br> 1618 * Path: <b>Practitioner.telecom(system=email)</b><br> 1619 * </p> 1620 */ 1621 @SearchParamDefinition(name="email", path="Practitioner.telecom.where(system='email')", description="A value in an email contact", type="token" ) 1622 public static final String SP_EMAIL = "email"; 1623 /** 1624 * <b>Fluent Client</b> search parameter constant for <b>email</b> 1625 * <p> 1626 * Description: <b>A value in an email contact</b><br> 1627 * Type: <b>token</b><br> 1628 * Path: <b>Practitioner.telecom(system=email)</b><br> 1629 * </p> 1630 */ 1631 public static final ca.uhn.fhir.rest.gclient.TokenClientParam EMAIL = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_EMAIL); 1632 1633 1634}