001package org.hl7.fhir.r5.model; 002 003/*- 004 * #%L 005 * org.hl7.fhir.r5 006 * %% 007 * Copyright (C) 2014 - 2019 Health Level 7 008 * %% 009 * Licensed under the Apache License, Version 2.0 (the "License"); 010 * you may not use this file except in compliance with the License. 011 * You may obtain a copy of the License at 012 * 013 * http://www.apache.org/licenses/LICENSE-2.0 014 * 015 * Unless required by applicable law or agreed to in writing, software 016 * distributed under the License is distributed on an "AS IS" BASIS, 017 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 018 * See the License for the specific language governing permissions and 019 * limitations under the License. 020 * #L% 021 */ 022 023/* 024 Copyright (c) 2011+, HL7, Inc. 025 All rights reserved. 026 027 Redistribution and use in source and binary forms, with or without modification, 028 are permitted provided that the following conditions are met: 029 030 * Redistributions of source code must retain the above copyright notice, this 031 list of conditions and the following disclaimer. 032 * Redistributions in binary form must reproduce the above copyright notice, 033 this list of conditions and the following disclaimer in the documentation 034 and/or other materials provided with the distribution. 035 * Neither the name of HL7 nor the names of its contributors may be used to 036 endorse or promote products derived from this software without specific 037 prior written permission. 038 039 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 040 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 041 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 042 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 043 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 044 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 045 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 046 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 047 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 048 POSSIBILITY OF SUCH DAMAGE. 049 050*/ 051 052// Generated on Thu, Dec 13, 2018 14:07+1100 for FHIR v4.0.0 053import java.util.ArrayList; 054import java.util.Date; 055import java.util.List; 056import org.hl7.fhir.exceptions.FHIRException; 057import org.hl7.fhir.instance.model.api.ICompositeType; 058 059import org.hl7.fhir.instance.model.api.IBaseDatatypeElement; 060import org.hl7.fhir.utilities.Utilities; 061import org.hl7.fhir.r5.model.Enumerations.*; 062import ca.uhn.fhir.model.api.annotation.ResourceDef; 063import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 064import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 065import ca.uhn.fhir.model.api.annotation.Child; 066import ca.uhn.fhir.model.api.annotation.ChildOrder; 067import ca.uhn.fhir.model.api.annotation.Description; 068import ca.uhn.fhir.model.api.annotation.Block; 069/** 070 * Details of a Health Insurance product/plan provided by an organization. 071 */ 072@ResourceDef(name="InsurancePlan", profile="http://hl7.org/fhir/StructureDefinition/InsurancePlan") 073public class InsurancePlan extends DomainResource { 074 075 @Block() 076 public static class InsurancePlanContactComponent extends BackboneElement implements IBaseBackboneElement { 077 /** 078 * Indicates a purpose for which the contact can be reached. 079 */ 080 @Child(name = "purpose", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 081 @Description(shortDefinition="The type of contact", formalDefinition="Indicates a purpose for which the contact can be reached." ) 082 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/contactentity-type") 083 protected CodeableConcept purpose; 084 085 /** 086 * A name associated with the contact. 087 */ 088 @Child(name = "name", type = {HumanName.class}, order=2, min=0, max=1, modifier=false, summary=false) 089 @Description(shortDefinition="A name associated with the contact", formalDefinition="A name associated with the contact." ) 090 protected HumanName name; 091 092 /** 093 * A contact detail (e.g. a telephone number or an email address) by which the party may be contacted. 094 */ 095 @Child(name = "telecom", type = {ContactPoint.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 096 @Description(shortDefinition="Contact details (telephone, email, etc.) for a contact", formalDefinition="A contact detail (e.g. a telephone number or an email address) by which the party may be contacted." ) 097 protected List<ContactPoint> telecom; 098 099 /** 100 * Visiting or postal addresses for the contact. 101 */ 102 @Child(name = "address", type = {Address.class}, order=4, min=0, max=1, modifier=false, summary=false) 103 @Description(shortDefinition="Visiting or postal addresses for the contact", formalDefinition="Visiting or postal addresses for the contact." ) 104 protected Address address; 105 106 private static final long serialVersionUID = 1831121305L; 107 108 /** 109 * Constructor 110 */ 111 public InsurancePlanContactComponent() { 112 super(); 113 } 114 115 /** 116 * @return {@link #purpose} (Indicates a purpose for which the contact can be reached.) 117 */ 118 public CodeableConcept getPurpose() { 119 if (this.purpose == null) 120 if (Configuration.errorOnAutoCreate()) 121 throw new Error("Attempt to auto-create InsurancePlanContactComponent.purpose"); 122 else if (Configuration.doAutoCreate()) 123 this.purpose = new CodeableConcept(); // cc 124 return this.purpose; 125 } 126 127 public boolean hasPurpose() { 128 return this.purpose != null && !this.purpose.isEmpty(); 129 } 130 131 /** 132 * @param value {@link #purpose} (Indicates a purpose for which the contact can be reached.) 133 */ 134 public InsurancePlanContactComponent setPurpose(CodeableConcept value) { 135 this.purpose = value; 136 return this; 137 } 138 139 /** 140 * @return {@link #name} (A name associated with the contact.) 141 */ 142 public HumanName getName() { 143 if (this.name == null) 144 if (Configuration.errorOnAutoCreate()) 145 throw new Error("Attempt to auto-create InsurancePlanContactComponent.name"); 146 else if (Configuration.doAutoCreate()) 147 this.name = new HumanName(); // cc 148 return this.name; 149 } 150 151 public boolean hasName() { 152 return this.name != null && !this.name.isEmpty(); 153 } 154 155 /** 156 * @param value {@link #name} (A name associated with the contact.) 157 */ 158 public InsurancePlanContactComponent setName(HumanName value) { 159 this.name = value; 160 return this; 161 } 162 163 /** 164 * @return {@link #telecom} (A contact detail (e.g. a telephone number or an email address) by which the party may be contacted.) 165 */ 166 public List<ContactPoint> getTelecom() { 167 if (this.telecom == null) 168 this.telecom = new ArrayList<ContactPoint>(); 169 return this.telecom; 170 } 171 172 /** 173 * @return Returns a reference to <code>this</code> for easy method chaining 174 */ 175 public InsurancePlanContactComponent setTelecom(List<ContactPoint> theTelecom) { 176 this.telecom = theTelecom; 177 return this; 178 } 179 180 public boolean hasTelecom() { 181 if (this.telecom == null) 182 return false; 183 for (ContactPoint item : this.telecom) 184 if (!item.isEmpty()) 185 return true; 186 return false; 187 } 188 189 public ContactPoint addTelecom() { //3 190 ContactPoint t = new ContactPoint(); 191 if (this.telecom == null) 192 this.telecom = new ArrayList<ContactPoint>(); 193 this.telecom.add(t); 194 return t; 195 } 196 197 public InsurancePlanContactComponent addTelecom(ContactPoint t) { //3 198 if (t == null) 199 return this; 200 if (this.telecom == null) 201 this.telecom = new ArrayList<ContactPoint>(); 202 this.telecom.add(t); 203 return this; 204 } 205 206 /** 207 * @return The first repetition of repeating field {@link #telecom}, creating it if it does not already exist 208 */ 209 public ContactPoint getTelecomFirstRep() { 210 if (getTelecom().isEmpty()) { 211 addTelecom(); 212 } 213 return getTelecom().get(0); 214 } 215 216 /** 217 * @return {@link #address} (Visiting or postal addresses for the contact.) 218 */ 219 public Address getAddress() { 220 if (this.address == null) 221 if (Configuration.errorOnAutoCreate()) 222 throw new Error("Attempt to auto-create InsurancePlanContactComponent.address"); 223 else if (Configuration.doAutoCreate()) 224 this.address = new Address(); // cc 225 return this.address; 226 } 227 228 public boolean hasAddress() { 229 return this.address != null && !this.address.isEmpty(); 230 } 231 232 /** 233 * @param value {@link #address} (Visiting or postal addresses for the contact.) 234 */ 235 public InsurancePlanContactComponent setAddress(Address value) { 236 this.address = value; 237 return this; 238 } 239 240 protected void listChildren(List<Property> children) { 241 super.listChildren(children); 242 children.add(new Property("purpose", "CodeableConcept", "Indicates a purpose for which the contact can be reached.", 0, 1, purpose)); 243 children.add(new Property("name", "HumanName", "A name associated with the contact.", 0, 1, name)); 244 children.add(new Property("telecom", "ContactPoint", "A contact detail (e.g. a telephone number or an email address) by which the party may be contacted.", 0, java.lang.Integer.MAX_VALUE, telecom)); 245 children.add(new Property("address", "Address", "Visiting or postal addresses for the contact.", 0, 1, address)); 246 } 247 248 @Override 249 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 250 switch (_hash) { 251 case -220463842: /*purpose*/ return new Property("purpose", "CodeableConcept", "Indicates a purpose for which the contact can be reached.", 0, 1, purpose); 252 case 3373707: /*name*/ return new Property("name", "HumanName", "A name associated with the contact.", 0, 1, name); 253 case -1429363305: /*telecom*/ return new Property("telecom", "ContactPoint", "A contact detail (e.g. a telephone number or an email address) by which the party may be contacted.", 0, java.lang.Integer.MAX_VALUE, telecom); 254 case -1147692044: /*address*/ return new Property("address", "Address", "Visiting or postal addresses for the contact.", 0, 1, address); 255 default: return super.getNamedProperty(_hash, _name, _checkValid); 256 } 257 258 } 259 260 @Override 261 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 262 switch (hash) { 263 case -220463842: /*purpose*/ return this.purpose == null ? new Base[0] : new Base[] {this.purpose}; // CodeableConcept 264 case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // HumanName 265 case -1429363305: /*telecom*/ return this.telecom == null ? new Base[0] : this.telecom.toArray(new Base[this.telecom.size()]); // ContactPoint 266 case -1147692044: /*address*/ return this.address == null ? new Base[0] : new Base[] {this.address}; // Address 267 default: return super.getProperty(hash, name, checkValid); 268 } 269 270 } 271 272 @Override 273 public Base setProperty(int hash, String name, Base value) throws FHIRException { 274 switch (hash) { 275 case -220463842: // purpose 276 this.purpose = castToCodeableConcept(value); // CodeableConcept 277 return value; 278 case 3373707: // name 279 this.name = castToHumanName(value); // HumanName 280 return value; 281 case -1429363305: // telecom 282 this.getTelecom().add(castToContactPoint(value)); // ContactPoint 283 return value; 284 case -1147692044: // address 285 this.address = castToAddress(value); // Address 286 return value; 287 default: return super.setProperty(hash, name, value); 288 } 289 290 } 291 292 @Override 293 public Base setProperty(String name, Base value) throws FHIRException { 294 if (name.equals("purpose")) { 295 this.purpose = castToCodeableConcept(value); // CodeableConcept 296 } else if (name.equals("name")) { 297 this.name = castToHumanName(value); // HumanName 298 } else if (name.equals("telecom")) { 299 this.getTelecom().add(castToContactPoint(value)); 300 } else if (name.equals("address")) { 301 this.address = castToAddress(value); // Address 302 } else 303 return super.setProperty(name, value); 304 return value; 305 } 306 307 @Override 308 public Base makeProperty(int hash, String name) throws FHIRException { 309 switch (hash) { 310 case -220463842: return getPurpose(); 311 case 3373707: return getName(); 312 case -1429363305: return addTelecom(); 313 case -1147692044: return getAddress(); 314 default: return super.makeProperty(hash, name); 315 } 316 317 } 318 319 @Override 320 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 321 switch (hash) { 322 case -220463842: /*purpose*/ return new String[] {"CodeableConcept"}; 323 case 3373707: /*name*/ return new String[] {"HumanName"}; 324 case -1429363305: /*telecom*/ return new String[] {"ContactPoint"}; 325 case -1147692044: /*address*/ return new String[] {"Address"}; 326 default: return super.getTypesForProperty(hash, name); 327 } 328 329 } 330 331 @Override 332 public Base addChild(String name) throws FHIRException { 333 if (name.equals("purpose")) { 334 this.purpose = new CodeableConcept(); 335 return this.purpose; 336 } 337 else if (name.equals("name")) { 338 this.name = new HumanName(); 339 return this.name; 340 } 341 else if (name.equals("telecom")) { 342 return addTelecom(); 343 } 344 else if (name.equals("address")) { 345 this.address = new Address(); 346 return this.address; 347 } 348 else 349 return super.addChild(name); 350 } 351 352 public InsurancePlanContactComponent copy() { 353 InsurancePlanContactComponent dst = new InsurancePlanContactComponent(); 354 copyValues(dst); 355 return dst; 356 } 357 358 public void copyValues(InsurancePlanContactComponent dst) { 359 super.copyValues(dst); 360 dst.purpose = purpose == null ? null : purpose.copy(); 361 dst.name = name == null ? null : name.copy(); 362 if (telecom != null) { 363 dst.telecom = new ArrayList<ContactPoint>(); 364 for (ContactPoint i : telecom) 365 dst.telecom.add(i.copy()); 366 }; 367 dst.address = address == null ? null : address.copy(); 368 } 369 370 @Override 371 public boolean equalsDeep(Base other_) { 372 if (!super.equalsDeep(other_)) 373 return false; 374 if (!(other_ instanceof InsurancePlanContactComponent)) 375 return false; 376 InsurancePlanContactComponent o = (InsurancePlanContactComponent) other_; 377 return compareDeep(purpose, o.purpose, true) && compareDeep(name, o.name, true) && compareDeep(telecom, o.telecom, true) 378 && compareDeep(address, o.address, true); 379 } 380 381 @Override 382 public boolean equalsShallow(Base other_) { 383 if (!super.equalsShallow(other_)) 384 return false; 385 if (!(other_ instanceof InsurancePlanContactComponent)) 386 return false; 387 InsurancePlanContactComponent o = (InsurancePlanContactComponent) other_; 388 return true; 389 } 390 391 public boolean isEmpty() { 392 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(purpose, name, telecom, address 393 ); 394 } 395 396 public String fhirType() { 397 return "InsurancePlan.contact"; 398 399 } 400 401 } 402 403 @Block() 404 public static class InsurancePlanCoverageComponent extends BackboneElement implements IBaseBackboneElement { 405 /** 406 * Type of coverage (Medical; Dental; Mental Health; Substance Abuse; Vision; Drug; Short Term; Long Term Care; Hospice; Home Health). 407 */ 408 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 409 @Description(shortDefinition="Type of coverage", formalDefinition="Type of coverage (Medical; Dental; Mental Health; Substance Abuse; Vision; Drug; Short Term; Long Term Care; Hospice; Home Health)." ) 410 protected CodeableConcept type; 411 412 /** 413 * Reference to the network that providing the type of coverage. 414 */ 415 @Child(name = "network", type = {Organization.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 416 @Description(shortDefinition="What networks provide coverage", formalDefinition="Reference to the network that providing the type of coverage." ) 417 protected List<Reference> network; 418 419 /** 420 * Specific benefits under this type of coverage. 421 */ 422 @Child(name = "benefit", type = {}, order=3, min=1, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 423 @Description(shortDefinition="List of benefits", formalDefinition="Specific benefits under this type of coverage." ) 424 protected List<CoverageBenefitComponent> benefit; 425 426 private static final long serialVersionUID = 79927205L; 427 428 /** 429 * Constructor 430 */ 431 public InsurancePlanCoverageComponent() { 432 super(); 433 } 434 435 /** 436 * Constructor 437 */ 438 public InsurancePlanCoverageComponent(CodeableConcept type) { 439 super(); 440 this.type = type; 441 } 442 443 /** 444 * @return {@link #type} (Type of coverage (Medical; Dental; Mental Health; Substance Abuse; Vision; Drug; Short Term; Long Term Care; Hospice; Home Health).) 445 */ 446 public CodeableConcept getType() { 447 if (this.type == null) 448 if (Configuration.errorOnAutoCreate()) 449 throw new Error("Attempt to auto-create InsurancePlanCoverageComponent.type"); 450 else if (Configuration.doAutoCreate()) 451 this.type = new CodeableConcept(); // cc 452 return this.type; 453 } 454 455 public boolean hasType() { 456 return this.type != null && !this.type.isEmpty(); 457 } 458 459 /** 460 * @param value {@link #type} (Type of coverage (Medical; Dental; Mental Health; Substance Abuse; Vision; Drug; Short Term; Long Term Care; Hospice; Home Health).) 461 */ 462 public InsurancePlanCoverageComponent setType(CodeableConcept value) { 463 this.type = value; 464 return this; 465 } 466 467 /** 468 * @return {@link #network} (Reference to the network that providing the type of coverage.) 469 */ 470 public List<Reference> getNetwork() { 471 if (this.network == null) 472 this.network = new ArrayList<Reference>(); 473 return this.network; 474 } 475 476 /** 477 * @return Returns a reference to <code>this</code> for easy method chaining 478 */ 479 public InsurancePlanCoverageComponent setNetwork(List<Reference> theNetwork) { 480 this.network = theNetwork; 481 return this; 482 } 483 484 public boolean hasNetwork() { 485 if (this.network == null) 486 return false; 487 for (Reference item : this.network) 488 if (!item.isEmpty()) 489 return true; 490 return false; 491 } 492 493 public Reference addNetwork() { //3 494 Reference t = new Reference(); 495 if (this.network == null) 496 this.network = new ArrayList<Reference>(); 497 this.network.add(t); 498 return t; 499 } 500 501 public InsurancePlanCoverageComponent addNetwork(Reference t) { //3 502 if (t == null) 503 return this; 504 if (this.network == null) 505 this.network = new ArrayList<Reference>(); 506 this.network.add(t); 507 return this; 508 } 509 510 /** 511 * @return The first repetition of repeating field {@link #network}, creating it if it does not already exist 512 */ 513 public Reference getNetworkFirstRep() { 514 if (getNetwork().isEmpty()) { 515 addNetwork(); 516 } 517 return getNetwork().get(0); 518 } 519 520 /** 521 * @return {@link #benefit} (Specific benefits under this type of coverage.) 522 */ 523 public List<CoverageBenefitComponent> getBenefit() { 524 if (this.benefit == null) 525 this.benefit = new ArrayList<CoverageBenefitComponent>(); 526 return this.benefit; 527 } 528 529 /** 530 * @return Returns a reference to <code>this</code> for easy method chaining 531 */ 532 public InsurancePlanCoverageComponent setBenefit(List<CoverageBenefitComponent> theBenefit) { 533 this.benefit = theBenefit; 534 return this; 535 } 536 537 public boolean hasBenefit() { 538 if (this.benefit == null) 539 return false; 540 for (CoverageBenefitComponent item : this.benefit) 541 if (!item.isEmpty()) 542 return true; 543 return false; 544 } 545 546 public CoverageBenefitComponent addBenefit() { //3 547 CoverageBenefitComponent t = new CoverageBenefitComponent(); 548 if (this.benefit == null) 549 this.benefit = new ArrayList<CoverageBenefitComponent>(); 550 this.benefit.add(t); 551 return t; 552 } 553 554 public InsurancePlanCoverageComponent addBenefit(CoverageBenefitComponent t) { //3 555 if (t == null) 556 return this; 557 if (this.benefit == null) 558 this.benefit = new ArrayList<CoverageBenefitComponent>(); 559 this.benefit.add(t); 560 return this; 561 } 562 563 /** 564 * @return The first repetition of repeating field {@link #benefit}, creating it if it does not already exist 565 */ 566 public CoverageBenefitComponent getBenefitFirstRep() { 567 if (getBenefit().isEmpty()) { 568 addBenefit(); 569 } 570 return getBenefit().get(0); 571 } 572 573 protected void listChildren(List<Property> children) { 574 super.listChildren(children); 575 children.add(new Property("type", "CodeableConcept", "Type of coverage (Medical; Dental; Mental Health; Substance Abuse; Vision; Drug; Short Term; Long Term Care; Hospice; Home Health).", 0, 1, type)); 576 children.add(new Property("network", "Reference(Organization)", "Reference to the network that providing the type of coverage.", 0, java.lang.Integer.MAX_VALUE, network)); 577 children.add(new Property("benefit", "", "Specific benefits under this type of coverage.", 0, java.lang.Integer.MAX_VALUE, benefit)); 578 } 579 580 @Override 581 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 582 switch (_hash) { 583 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Type of coverage (Medical; Dental; Mental Health; Substance Abuse; Vision; Drug; Short Term; Long Term Care; Hospice; Home Health).", 0, 1, type); 584 case 1843485230: /*network*/ return new Property("network", "Reference(Organization)", "Reference to the network that providing the type of coverage.", 0, java.lang.Integer.MAX_VALUE, network); 585 case -222710633: /*benefit*/ return new Property("benefit", "", "Specific benefits under this type of coverage.", 0, java.lang.Integer.MAX_VALUE, benefit); 586 default: return super.getNamedProperty(_hash, _name, _checkValid); 587 } 588 589 } 590 591 @Override 592 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 593 switch (hash) { 594 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 595 case 1843485230: /*network*/ return this.network == null ? new Base[0] : this.network.toArray(new Base[this.network.size()]); // Reference 596 case -222710633: /*benefit*/ return this.benefit == null ? new Base[0] : this.benefit.toArray(new Base[this.benefit.size()]); // CoverageBenefitComponent 597 default: return super.getProperty(hash, name, checkValid); 598 } 599 600 } 601 602 @Override 603 public Base setProperty(int hash, String name, Base value) throws FHIRException { 604 switch (hash) { 605 case 3575610: // type 606 this.type = castToCodeableConcept(value); // CodeableConcept 607 return value; 608 case 1843485230: // network 609 this.getNetwork().add(castToReference(value)); // Reference 610 return value; 611 case -222710633: // benefit 612 this.getBenefit().add((CoverageBenefitComponent) value); // CoverageBenefitComponent 613 return value; 614 default: return super.setProperty(hash, name, value); 615 } 616 617 } 618 619 @Override 620 public Base setProperty(String name, Base value) throws FHIRException { 621 if (name.equals("type")) { 622 this.type = castToCodeableConcept(value); // CodeableConcept 623 } else if (name.equals("network")) { 624 this.getNetwork().add(castToReference(value)); 625 } else if (name.equals("benefit")) { 626 this.getBenefit().add((CoverageBenefitComponent) value); 627 } else 628 return super.setProperty(name, value); 629 return value; 630 } 631 632 @Override 633 public Base makeProperty(int hash, String name) throws FHIRException { 634 switch (hash) { 635 case 3575610: return getType(); 636 case 1843485230: return addNetwork(); 637 case -222710633: return addBenefit(); 638 default: return super.makeProperty(hash, name); 639 } 640 641 } 642 643 @Override 644 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 645 switch (hash) { 646 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 647 case 1843485230: /*network*/ return new String[] {"Reference"}; 648 case -222710633: /*benefit*/ return new String[] {}; 649 default: return super.getTypesForProperty(hash, name); 650 } 651 652 } 653 654 @Override 655 public Base addChild(String name) throws FHIRException { 656 if (name.equals("type")) { 657 this.type = new CodeableConcept(); 658 return this.type; 659 } 660 else if (name.equals("network")) { 661 return addNetwork(); 662 } 663 else if (name.equals("benefit")) { 664 return addBenefit(); 665 } 666 else 667 return super.addChild(name); 668 } 669 670 public InsurancePlanCoverageComponent copy() { 671 InsurancePlanCoverageComponent dst = new InsurancePlanCoverageComponent(); 672 copyValues(dst); 673 return dst; 674 } 675 676 public void copyValues(InsurancePlanCoverageComponent dst) { 677 super.copyValues(dst); 678 dst.type = type == null ? null : type.copy(); 679 if (network != null) { 680 dst.network = new ArrayList<Reference>(); 681 for (Reference i : network) 682 dst.network.add(i.copy()); 683 }; 684 if (benefit != null) { 685 dst.benefit = new ArrayList<CoverageBenefitComponent>(); 686 for (CoverageBenefitComponent i : benefit) 687 dst.benefit.add(i.copy()); 688 }; 689 } 690 691 @Override 692 public boolean equalsDeep(Base other_) { 693 if (!super.equalsDeep(other_)) 694 return false; 695 if (!(other_ instanceof InsurancePlanCoverageComponent)) 696 return false; 697 InsurancePlanCoverageComponent o = (InsurancePlanCoverageComponent) other_; 698 return compareDeep(type, o.type, true) && compareDeep(network, o.network, true) && compareDeep(benefit, o.benefit, true) 699 ; 700 } 701 702 @Override 703 public boolean equalsShallow(Base other_) { 704 if (!super.equalsShallow(other_)) 705 return false; 706 if (!(other_ instanceof InsurancePlanCoverageComponent)) 707 return false; 708 InsurancePlanCoverageComponent o = (InsurancePlanCoverageComponent) other_; 709 return true; 710 } 711 712 public boolean isEmpty() { 713 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, network, benefit); 714 } 715 716 public String fhirType() { 717 return "InsurancePlan.coverage"; 718 719 } 720 721 } 722 723 @Block() 724 public static class CoverageBenefitComponent extends BackboneElement implements IBaseBackboneElement { 725 /** 726 * Type of benefit (primary care; speciality care; inpatient; outpatient). 727 */ 728 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 729 @Description(shortDefinition="Type of benefit", formalDefinition="Type of benefit (primary care; speciality care; inpatient; outpatient)." ) 730 protected CodeableConcept type; 731 732 /** 733 * The referral requirements to have access/coverage for this benefit. 734 */ 735 @Child(name = "requirement", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false) 736 @Description(shortDefinition="Referral requirements", formalDefinition="The referral requirements to have access/coverage for this benefit." ) 737 protected StringType requirement; 738 739 /** 740 * The specific limits on the benefit. 741 */ 742 @Child(name = "limit", type = {}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 743 @Description(shortDefinition="Benefit limits", formalDefinition="The specific limits on the benefit." ) 744 protected List<CoverageBenefitLimitComponent> limit; 745 746 private static final long serialVersionUID = -113658449L; 747 748 /** 749 * Constructor 750 */ 751 public CoverageBenefitComponent() { 752 super(); 753 } 754 755 /** 756 * Constructor 757 */ 758 public CoverageBenefitComponent(CodeableConcept type) { 759 super(); 760 this.type = type; 761 } 762 763 /** 764 * @return {@link #type} (Type of benefit (primary care; speciality care; inpatient; outpatient).) 765 */ 766 public CodeableConcept getType() { 767 if (this.type == null) 768 if (Configuration.errorOnAutoCreate()) 769 throw new Error("Attempt to auto-create CoverageBenefitComponent.type"); 770 else if (Configuration.doAutoCreate()) 771 this.type = new CodeableConcept(); // cc 772 return this.type; 773 } 774 775 public boolean hasType() { 776 return this.type != null && !this.type.isEmpty(); 777 } 778 779 /** 780 * @param value {@link #type} (Type of benefit (primary care; speciality care; inpatient; outpatient).) 781 */ 782 public CoverageBenefitComponent setType(CodeableConcept value) { 783 this.type = value; 784 return this; 785 } 786 787 /** 788 * @return {@link #requirement} (The referral requirements to have access/coverage for this benefit.). This is the underlying object with id, value and extensions. The accessor "getRequirement" gives direct access to the value 789 */ 790 public StringType getRequirementElement() { 791 if (this.requirement == null) 792 if (Configuration.errorOnAutoCreate()) 793 throw new Error("Attempt to auto-create CoverageBenefitComponent.requirement"); 794 else if (Configuration.doAutoCreate()) 795 this.requirement = new StringType(); // bb 796 return this.requirement; 797 } 798 799 public boolean hasRequirementElement() { 800 return this.requirement != null && !this.requirement.isEmpty(); 801 } 802 803 public boolean hasRequirement() { 804 return this.requirement != null && !this.requirement.isEmpty(); 805 } 806 807 /** 808 * @param value {@link #requirement} (The referral requirements to have access/coverage for this benefit.). This is the underlying object with id, value and extensions. The accessor "getRequirement" gives direct access to the value 809 */ 810 public CoverageBenefitComponent setRequirementElement(StringType value) { 811 this.requirement = value; 812 return this; 813 } 814 815 /** 816 * @return The referral requirements to have access/coverage for this benefit. 817 */ 818 public String getRequirement() { 819 return this.requirement == null ? null : this.requirement.getValue(); 820 } 821 822 /** 823 * @param value The referral requirements to have access/coverage for this benefit. 824 */ 825 public CoverageBenefitComponent setRequirement(String value) { 826 if (Utilities.noString(value)) 827 this.requirement = null; 828 else { 829 if (this.requirement == null) 830 this.requirement = new StringType(); 831 this.requirement.setValue(value); 832 } 833 return this; 834 } 835 836 /** 837 * @return {@link #limit} (The specific limits on the benefit.) 838 */ 839 public List<CoverageBenefitLimitComponent> getLimit() { 840 if (this.limit == null) 841 this.limit = new ArrayList<CoverageBenefitLimitComponent>(); 842 return this.limit; 843 } 844 845 /** 846 * @return Returns a reference to <code>this</code> for easy method chaining 847 */ 848 public CoverageBenefitComponent setLimit(List<CoverageBenefitLimitComponent> theLimit) { 849 this.limit = theLimit; 850 return this; 851 } 852 853 public boolean hasLimit() { 854 if (this.limit == null) 855 return false; 856 for (CoverageBenefitLimitComponent item : this.limit) 857 if (!item.isEmpty()) 858 return true; 859 return false; 860 } 861 862 public CoverageBenefitLimitComponent addLimit() { //3 863 CoverageBenefitLimitComponent t = new CoverageBenefitLimitComponent(); 864 if (this.limit == null) 865 this.limit = new ArrayList<CoverageBenefitLimitComponent>(); 866 this.limit.add(t); 867 return t; 868 } 869 870 public CoverageBenefitComponent addLimit(CoverageBenefitLimitComponent t) { //3 871 if (t == null) 872 return this; 873 if (this.limit == null) 874 this.limit = new ArrayList<CoverageBenefitLimitComponent>(); 875 this.limit.add(t); 876 return this; 877 } 878 879 /** 880 * @return The first repetition of repeating field {@link #limit}, creating it if it does not already exist 881 */ 882 public CoverageBenefitLimitComponent getLimitFirstRep() { 883 if (getLimit().isEmpty()) { 884 addLimit(); 885 } 886 return getLimit().get(0); 887 } 888 889 protected void listChildren(List<Property> children) { 890 super.listChildren(children); 891 children.add(new Property("type", "CodeableConcept", "Type of benefit (primary care; speciality care; inpatient; outpatient).", 0, 1, type)); 892 children.add(new Property("requirement", "string", "The referral requirements to have access/coverage for this benefit.", 0, 1, requirement)); 893 children.add(new Property("limit", "", "The specific limits on the benefit.", 0, java.lang.Integer.MAX_VALUE, limit)); 894 } 895 896 @Override 897 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 898 switch (_hash) { 899 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Type of benefit (primary care; speciality care; inpatient; outpatient).", 0, 1, type); 900 case 363387971: /*requirement*/ return new Property("requirement", "string", "The referral requirements to have access/coverage for this benefit.", 0, 1, requirement); 901 case 102976443: /*limit*/ return new Property("limit", "", "The specific limits on the benefit.", 0, java.lang.Integer.MAX_VALUE, limit); 902 default: return super.getNamedProperty(_hash, _name, _checkValid); 903 } 904 905 } 906 907 @Override 908 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 909 switch (hash) { 910 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 911 case 363387971: /*requirement*/ return this.requirement == null ? new Base[0] : new Base[] {this.requirement}; // StringType 912 case 102976443: /*limit*/ return this.limit == null ? new Base[0] : this.limit.toArray(new Base[this.limit.size()]); // CoverageBenefitLimitComponent 913 default: return super.getProperty(hash, name, checkValid); 914 } 915 916 } 917 918 @Override 919 public Base setProperty(int hash, String name, Base value) throws FHIRException { 920 switch (hash) { 921 case 3575610: // type 922 this.type = castToCodeableConcept(value); // CodeableConcept 923 return value; 924 case 363387971: // requirement 925 this.requirement = castToString(value); // StringType 926 return value; 927 case 102976443: // limit 928 this.getLimit().add((CoverageBenefitLimitComponent) value); // CoverageBenefitLimitComponent 929 return value; 930 default: return super.setProperty(hash, name, value); 931 } 932 933 } 934 935 @Override 936 public Base setProperty(String name, Base value) throws FHIRException { 937 if (name.equals("type")) { 938 this.type = castToCodeableConcept(value); // CodeableConcept 939 } else if (name.equals("requirement")) { 940 this.requirement = castToString(value); // StringType 941 } else if (name.equals("limit")) { 942 this.getLimit().add((CoverageBenefitLimitComponent) value); 943 } else 944 return super.setProperty(name, value); 945 return value; 946 } 947 948 @Override 949 public Base makeProperty(int hash, String name) throws FHIRException { 950 switch (hash) { 951 case 3575610: return getType(); 952 case 363387971: return getRequirementElement(); 953 case 102976443: return addLimit(); 954 default: return super.makeProperty(hash, name); 955 } 956 957 } 958 959 @Override 960 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 961 switch (hash) { 962 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 963 case 363387971: /*requirement*/ return new String[] {"string"}; 964 case 102976443: /*limit*/ return new String[] {}; 965 default: return super.getTypesForProperty(hash, name); 966 } 967 968 } 969 970 @Override 971 public Base addChild(String name) throws FHIRException { 972 if (name.equals("type")) { 973 this.type = new CodeableConcept(); 974 return this.type; 975 } 976 else if (name.equals("requirement")) { 977 throw new FHIRException("Cannot call addChild on a primitive type InsurancePlan.requirement"); 978 } 979 else if (name.equals("limit")) { 980 return addLimit(); 981 } 982 else 983 return super.addChild(name); 984 } 985 986 public CoverageBenefitComponent copy() { 987 CoverageBenefitComponent dst = new CoverageBenefitComponent(); 988 copyValues(dst); 989 return dst; 990 } 991 992 public void copyValues(CoverageBenefitComponent dst) { 993 super.copyValues(dst); 994 dst.type = type == null ? null : type.copy(); 995 dst.requirement = requirement == null ? null : requirement.copy(); 996 if (limit != null) { 997 dst.limit = new ArrayList<CoverageBenefitLimitComponent>(); 998 for (CoverageBenefitLimitComponent i : limit) 999 dst.limit.add(i.copy()); 1000 }; 1001 } 1002 1003 @Override 1004 public boolean equalsDeep(Base other_) { 1005 if (!super.equalsDeep(other_)) 1006 return false; 1007 if (!(other_ instanceof CoverageBenefitComponent)) 1008 return false; 1009 CoverageBenefitComponent o = (CoverageBenefitComponent) other_; 1010 return compareDeep(type, o.type, true) && compareDeep(requirement, o.requirement, true) && compareDeep(limit, o.limit, true) 1011 ; 1012 } 1013 1014 @Override 1015 public boolean equalsShallow(Base other_) { 1016 if (!super.equalsShallow(other_)) 1017 return false; 1018 if (!(other_ instanceof CoverageBenefitComponent)) 1019 return false; 1020 CoverageBenefitComponent o = (CoverageBenefitComponent) other_; 1021 return compareValues(requirement, o.requirement, true); 1022 } 1023 1024 public boolean isEmpty() { 1025 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, requirement, limit 1026 ); 1027 } 1028 1029 public String fhirType() { 1030 return "InsurancePlan.coverage.benefit"; 1031 1032 } 1033 1034 } 1035 1036 @Block() 1037 public static class CoverageBenefitLimitComponent extends BackboneElement implements IBaseBackboneElement { 1038 /** 1039 * The maximum amount of a service item a plan will pay for a covered benefit. For examples. wellness visits, or eyeglasses. 1040 */ 1041 @Child(name = "value", type = {Quantity.class}, order=1, min=0, max=1, modifier=false, summary=false) 1042 @Description(shortDefinition="Maximum value allowed", formalDefinition="The maximum amount of a service item a plan will pay for a covered benefit. For examples. wellness visits, or eyeglasses." ) 1043 protected Quantity value; 1044 1045 /** 1046 * The specific limit on the benefit. 1047 */ 1048 @Child(name = "code", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 1049 @Description(shortDefinition="Benefit limit details", formalDefinition="The specific limit on the benefit." ) 1050 protected CodeableConcept code; 1051 1052 private static final long serialVersionUID = -304318128L; 1053 1054 /** 1055 * Constructor 1056 */ 1057 public CoverageBenefitLimitComponent() { 1058 super(); 1059 } 1060 1061 /** 1062 * @return {@link #value} (The maximum amount of a service item a plan will pay for a covered benefit. For examples. wellness visits, or eyeglasses.) 1063 */ 1064 public Quantity getValue() { 1065 if (this.value == null) 1066 if (Configuration.errorOnAutoCreate()) 1067 throw new Error("Attempt to auto-create CoverageBenefitLimitComponent.value"); 1068 else if (Configuration.doAutoCreate()) 1069 this.value = new Quantity(); // cc 1070 return this.value; 1071 } 1072 1073 public boolean hasValue() { 1074 return this.value != null && !this.value.isEmpty(); 1075 } 1076 1077 /** 1078 * @param value {@link #value} (The maximum amount of a service item a plan will pay for a covered benefit. For examples. wellness visits, or eyeglasses.) 1079 */ 1080 public CoverageBenefitLimitComponent setValue(Quantity value) { 1081 this.value = value; 1082 return this; 1083 } 1084 1085 /** 1086 * @return {@link #code} (The specific limit on the benefit.) 1087 */ 1088 public CodeableConcept getCode() { 1089 if (this.code == null) 1090 if (Configuration.errorOnAutoCreate()) 1091 throw new Error("Attempt to auto-create CoverageBenefitLimitComponent.code"); 1092 else if (Configuration.doAutoCreate()) 1093 this.code = new CodeableConcept(); // cc 1094 return this.code; 1095 } 1096 1097 public boolean hasCode() { 1098 return this.code != null && !this.code.isEmpty(); 1099 } 1100 1101 /** 1102 * @param value {@link #code} (The specific limit on the benefit.) 1103 */ 1104 public CoverageBenefitLimitComponent setCode(CodeableConcept value) { 1105 this.code = value; 1106 return this; 1107 } 1108 1109 protected void listChildren(List<Property> children) { 1110 super.listChildren(children); 1111 children.add(new Property("value", "Quantity", "The maximum amount of a service item a plan will pay for a covered benefit. For examples. wellness visits, or eyeglasses.", 0, 1, value)); 1112 children.add(new Property("code", "CodeableConcept", "The specific limit on the benefit.", 0, 1, code)); 1113 } 1114 1115 @Override 1116 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1117 switch (_hash) { 1118 case 111972721: /*value*/ return new Property("value", "Quantity", "The maximum amount of a service item a plan will pay for a covered benefit. For examples. wellness visits, or eyeglasses.", 0, 1, value); 1119 case 3059181: /*code*/ return new Property("code", "CodeableConcept", "The specific limit on the benefit.", 0, 1, code); 1120 default: return super.getNamedProperty(_hash, _name, _checkValid); 1121 } 1122 1123 } 1124 1125 @Override 1126 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1127 switch (hash) { 1128 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // Quantity 1129 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 1130 default: return super.getProperty(hash, name, checkValid); 1131 } 1132 1133 } 1134 1135 @Override 1136 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1137 switch (hash) { 1138 case 111972721: // value 1139 this.value = castToQuantity(value); // Quantity 1140 return value; 1141 case 3059181: // code 1142 this.code = castToCodeableConcept(value); // CodeableConcept 1143 return value; 1144 default: return super.setProperty(hash, name, value); 1145 } 1146 1147 } 1148 1149 @Override 1150 public Base setProperty(String name, Base value) throws FHIRException { 1151 if (name.equals("value")) { 1152 this.value = castToQuantity(value); // Quantity 1153 } else if (name.equals("code")) { 1154 this.code = castToCodeableConcept(value); // CodeableConcept 1155 } else 1156 return super.setProperty(name, value); 1157 return value; 1158 } 1159 1160 @Override 1161 public Base makeProperty(int hash, String name) throws FHIRException { 1162 switch (hash) { 1163 case 111972721: return getValue(); 1164 case 3059181: return getCode(); 1165 default: return super.makeProperty(hash, name); 1166 } 1167 1168 } 1169 1170 @Override 1171 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1172 switch (hash) { 1173 case 111972721: /*value*/ return new String[] {"Quantity"}; 1174 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 1175 default: return super.getTypesForProperty(hash, name); 1176 } 1177 1178 } 1179 1180 @Override 1181 public Base addChild(String name) throws FHIRException { 1182 if (name.equals("value")) { 1183 this.value = new Quantity(); 1184 return this.value; 1185 } 1186 else if (name.equals("code")) { 1187 this.code = new CodeableConcept(); 1188 return this.code; 1189 } 1190 else 1191 return super.addChild(name); 1192 } 1193 1194 public CoverageBenefitLimitComponent copy() { 1195 CoverageBenefitLimitComponent dst = new CoverageBenefitLimitComponent(); 1196 copyValues(dst); 1197 return dst; 1198 } 1199 1200 public void copyValues(CoverageBenefitLimitComponent dst) { 1201 super.copyValues(dst); 1202 dst.value = value == null ? null : value.copy(); 1203 dst.code = code == null ? null : code.copy(); 1204 } 1205 1206 @Override 1207 public boolean equalsDeep(Base other_) { 1208 if (!super.equalsDeep(other_)) 1209 return false; 1210 if (!(other_ instanceof CoverageBenefitLimitComponent)) 1211 return false; 1212 CoverageBenefitLimitComponent o = (CoverageBenefitLimitComponent) other_; 1213 return compareDeep(value, o.value, true) && compareDeep(code, o.code, true); 1214 } 1215 1216 @Override 1217 public boolean equalsShallow(Base other_) { 1218 if (!super.equalsShallow(other_)) 1219 return false; 1220 if (!(other_ instanceof CoverageBenefitLimitComponent)) 1221 return false; 1222 CoverageBenefitLimitComponent o = (CoverageBenefitLimitComponent) other_; 1223 return true; 1224 } 1225 1226 public boolean isEmpty() { 1227 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(value, code); 1228 } 1229 1230 public String fhirType() { 1231 return "InsurancePlan.coverage.benefit.limit"; 1232 1233 } 1234 1235 } 1236 1237 @Block() 1238 public static class InsurancePlanPlanComponent extends BackboneElement implements IBaseBackboneElement { 1239 /** 1240 * Business identifiers assigned to this health insurance plan which remain constant as the resource is updated and propagates from server to server. 1241 */ 1242 @Child(name = "identifier", type = {Identifier.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1243 @Description(shortDefinition="Business Identifier for Product", formalDefinition="Business identifiers assigned to this health insurance plan which remain constant as the resource is updated and propagates from server to server." ) 1244 protected List<Identifier> identifier; 1245 1246 /** 1247 * Type of plan. For example, "Platinum" or "High Deductable". 1248 */ 1249 @Child(name = "type", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 1250 @Description(shortDefinition="Type of plan", formalDefinition="Type of plan. For example, \"Platinum\" or \"High Deductable\"." ) 1251 protected CodeableConcept type; 1252 1253 /** 1254 * The geographic region in which a health insurance plan's benefits apply. 1255 */ 1256 @Child(name = "coverageArea", type = {Location.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1257 @Description(shortDefinition="Where product applies", formalDefinition="The geographic region in which a health insurance plan's benefits apply." ) 1258 protected List<Reference> coverageArea; 1259 1260 /** 1261 * Reference to the network that providing the type of coverage. 1262 */ 1263 @Child(name = "network", type = {Organization.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1264 @Description(shortDefinition="What networks provide coverage", formalDefinition="Reference to the network that providing the type of coverage." ) 1265 protected List<Reference> network; 1266 1267 /** 1268 * Overall costs associated with the plan. 1269 */ 1270 @Child(name = "generalCost", type = {}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1271 @Description(shortDefinition="Overall costs", formalDefinition="Overall costs associated with the plan." ) 1272 protected List<InsurancePlanPlanGeneralCostComponent> generalCost; 1273 1274 /** 1275 * Costs associated with the coverage provided by the product. 1276 */ 1277 @Child(name = "specificCost", type = {}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1278 @Description(shortDefinition="Specific costs", formalDefinition="Costs associated with the coverage provided by the product." ) 1279 protected List<InsurancePlanPlanSpecificCostComponent> specificCost; 1280 1281 private static final long serialVersionUID = -782831938L; 1282 1283 /** 1284 * Constructor 1285 */ 1286 public InsurancePlanPlanComponent() { 1287 super(); 1288 } 1289 1290 /** 1291 * @return {@link #identifier} (Business identifiers assigned to this health insurance plan which remain constant as the resource is updated and propagates from server to server.) 1292 */ 1293 public List<Identifier> getIdentifier() { 1294 if (this.identifier == null) 1295 this.identifier = new ArrayList<Identifier>(); 1296 return this.identifier; 1297 } 1298 1299 /** 1300 * @return Returns a reference to <code>this</code> for easy method chaining 1301 */ 1302 public InsurancePlanPlanComponent setIdentifier(List<Identifier> theIdentifier) { 1303 this.identifier = theIdentifier; 1304 return this; 1305 } 1306 1307 public boolean hasIdentifier() { 1308 if (this.identifier == null) 1309 return false; 1310 for (Identifier item : this.identifier) 1311 if (!item.isEmpty()) 1312 return true; 1313 return false; 1314 } 1315 1316 public Identifier addIdentifier() { //3 1317 Identifier t = new Identifier(); 1318 if (this.identifier == null) 1319 this.identifier = new ArrayList<Identifier>(); 1320 this.identifier.add(t); 1321 return t; 1322 } 1323 1324 public InsurancePlanPlanComponent addIdentifier(Identifier t) { //3 1325 if (t == null) 1326 return this; 1327 if (this.identifier == null) 1328 this.identifier = new ArrayList<Identifier>(); 1329 this.identifier.add(t); 1330 return this; 1331 } 1332 1333 /** 1334 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist 1335 */ 1336 public Identifier getIdentifierFirstRep() { 1337 if (getIdentifier().isEmpty()) { 1338 addIdentifier(); 1339 } 1340 return getIdentifier().get(0); 1341 } 1342 1343 /** 1344 * @return {@link #type} (Type of plan. For example, "Platinum" or "High Deductable".) 1345 */ 1346 public CodeableConcept getType() { 1347 if (this.type == null) 1348 if (Configuration.errorOnAutoCreate()) 1349 throw new Error("Attempt to auto-create InsurancePlanPlanComponent.type"); 1350 else if (Configuration.doAutoCreate()) 1351 this.type = new CodeableConcept(); // cc 1352 return this.type; 1353 } 1354 1355 public boolean hasType() { 1356 return this.type != null && !this.type.isEmpty(); 1357 } 1358 1359 /** 1360 * @param value {@link #type} (Type of plan. For example, "Platinum" or "High Deductable".) 1361 */ 1362 public InsurancePlanPlanComponent setType(CodeableConcept value) { 1363 this.type = value; 1364 return this; 1365 } 1366 1367 /** 1368 * @return {@link #coverageArea} (The geographic region in which a health insurance plan's benefits apply.) 1369 */ 1370 public List<Reference> getCoverageArea() { 1371 if (this.coverageArea == null) 1372 this.coverageArea = new ArrayList<Reference>(); 1373 return this.coverageArea; 1374 } 1375 1376 /** 1377 * @return Returns a reference to <code>this</code> for easy method chaining 1378 */ 1379 public InsurancePlanPlanComponent setCoverageArea(List<Reference> theCoverageArea) { 1380 this.coverageArea = theCoverageArea; 1381 return this; 1382 } 1383 1384 public boolean hasCoverageArea() { 1385 if (this.coverageArea == null) 1386 return false; 1387 for (Reference item : this.coverageArea) 1388 if (!item.isEmpty()) 1389 return true; 1390 return false; 1391 } 1392 1393 public Reference addCoverageArea() { //3 1394 Reference t = new Reference(); 1395 if (this.coverageArea == null) 1396 this.coverageArea = new ArrayList<Reference>(); 1397 this.coverageArea.add(t); 1398 return t; 1399 } 1400 1401 public InsurancePlanPlanComponent addCoverageArea(Reference t) { //3 1402 if (t == null) 1403 return this; 1404 if (this.coverageArea == null) 1405 this.coverageArea = new ArrayList<Reference>(); 1406 this.coverageArea.add(t); 1407 return this; 1408 } 1409 1410 /** 1411 * @return The first repetition of repeating field {@link #coverageArea}, creating it if it does not already exist 1412 */ 1413 public Reference getCoverageAreaFirstRep() { 1414 if (getCoverageArea().isEmpty()) { 1415 addCoverageArea(); 1416 } 1417 return getCoverageArea().get(0); 1418 } 1419 1420 /** 1421 * @return {@link #network} (Reference to the network that providing the type of coverage.) 1422 */ 1423 public List<Reference> getNetwork() { 1424 if (this.network == null) 1425 this.network = new ArrayList<Reference>(); 1426 return this.network; 1427 } 1428 1429 /** 1430 * @return Returns a reference to <code>this</code> for easy method chaining 1431 */ 1432 public InsurancePlanPlanComponent setNetwork(List<Reference> theNetwork) { 1433 this.network = theNetwork; 1434 return this; 1435 } 1436 1437 public boolean hasNetwork() { 1438 if (this.network == null) 1439 return false; 1440 for (Reference item : this.network) 1441 if (!item.isEmpty()) 1442 return true; 1443 return false; 1444 } 1445 1446 public Reference addNetwork() { //3 1447 Reference t = new Reference(); 1448 if (this.network == null) 1449 this.network = new ArrayList<Reference>(); 1450 this.network.add(t); 1451 return t; 1452 } 1453 1454 public InsurancePlanPlanComponent addNetwork(Reference t) { //3 1455 if (t == null) 1456 return this; 1457 if (this.network == null) 1458 this.network = new ArrayList<Reference>(); 1459 this.network.add(t); 1460 return this; 1461 } 1462 1463 /** 1464 * @return The first repetition of repeating field {@link #network}, creating it if it does not already exist 1465 */ 1466 public Reference getNetworkFirstRep() { 1467 if (getNetwork().isEmpty()) { 1468 addNetwork(); 1469 } 1470 return getNetwork().get(0); 1471 } 1472 1473 /** 1474 * @return {@link #generalCost} (Overall costs associated with the plan.) 1475 */ 1476 public List<InsurancePlanPlanGeneralCostComponent> getGeneralCost() { 1477 if (this.generalCost == null) 1478 this.generalCost = new ArrayList<InsurancePlanPlanGeneralCostComponent>(); 1479 return this.generalCost; 1480 } 1481 1482 /** 1483 * @return Returns a reference to <code>this</code> for easy method chaining 1484 */ 1485 public InsurancePlanPlanComponent setGeneralCost(List<InsurancePlanPlanGeneralCostComponent> theGeneralCost) { 1486 this.generalCost = theGeneralCost; 1487 return this; 1488 } 1489 1490 public boolean hasGeneralCost() { 1491 if (this.generalCost == null) 1492 return false; 1493 for (InsurancePlanPlanGeneralCostComponent item : this.generalCost) 1494 if (!item.isEmpty()) 1495 return true; 1496 return false; 1497 } 1498 1499 public InsurancePlanPlanGeneralCostComponent addGeneralCost() { //3 1500 InsurancePlanPlanGeneralCostComponent t = new InsurancePlanPlanGeneralCostComponent(); 1501 if (this.generalCost == null) 1502 this.generalCost = new ArrayList<InsurancePlanPlanGeneralCostComponent>(); 1503 this.generalCost.add(t); 1504 return t; 1505 } 1506 1507 public InsurancePlanPlanComponent addGeneralCost(InsurancePlanPlanGeneralCostComponent t) { //3 1508 if (t == null) 1509 return this; 1510 if (this.generalCost == null) 1511 this.generalCost = new ArrayList<InsurancePlanPlanGeneralCostComponent>(); 1512 this.generalCost.add(t); 1513 return this; 1514 } 1515 1516 /** 1517 * @return The first repetition of repeating field {@link #generalCost}, creating it if it does not already exist 1518 */ 1519 public InsurancePlanPlanGeneralCostComponent getGeneralCostFirstRep() { 1520 if (getGeneralCost().isEmpty()) { 1521 addGeneralCost(); 1522 } 1523 return getGeneralCost().get(0); 1524 } 1525 1526 /** 1527 * @return {@link #specificCost} (Costs associated with the coverage provided by the product.) 1528 */ 1529 public List<InsurancePlanPlanSpecificCostComponent> getSpecificCost() { 1530 if (this.specificCost == null) 1531 this.specificCost = new ArrayList<InsurancePlanPlanSpecificCostComponent>(); 1532 return this.specificCost; 1533 } 1534 1535 /** 1536 * @return Returns a reference to <code>this</code> for easy method chaining 1537 */ 1538 public InsurancePlanPlanComponent setSpecificCost(List<InsurancePlanPlanSpecificCostComponent> theSpecificCost) { 1539 this.specificCost = theSpecificCost; 1540 return this; 1541 } 1542 1543 public boolean hasSpecificCost() { 1544 if (this.specificCost == null) 1545 return false; 1546 for (InsurancePlanPlanSpecificCostComponent item : this.specificCost) 1547 if (!item.isEmpty()) 1548 return true; 1549 return false; 1550 } 1551 1552 public InsurancePlanPlanSpecificCostComponent addSpecificCost() { //3 1553 InsurancePlanPlanSpecificCostComponent t = new InsurancePlanPlanSpecificCostComponent(); 1554 if (this.specificCost == null) 1555 this.specificCost = new ArrayList<InsurancePlanPlanSpecificCostComponent>(); 1556 this.specificCost.add(t); 1557 return t; 1558 } 1559 1560 public InsurancePlanPlanComponent addSpecificCost(InsurancePlanPlanSpecificCostComponent t) { //3 1561 if (t == null) 1562 return this; 1563 if (this.specificCost == null) 1564 this.specificCost = new ArrayList<InsurancePlanPlanSpecificCostComponent>(); 1565 this.specificCost.add(t); 1566 return this; 1567 } 1568 1569 /** 1570 * @return The first repetition of repeating field {@link #specificCost}, creating it if it does not already exist 1571 */ 1572 public InsurancePlanPlanSpecificCostComponent getSpecificCostFirstRep() { 1573 if (getSpecificCost().isEmpty()) { 1574 addSpecificCost(); 1575 } 1576 return getSpecificCost().get(0); 1577 } 1578 1579 protected void listChildren(List<Property> children) { 1580 super.listChildren(children); 1581 children.add(new Property("identifier", "Identifier", "Business identifiers assigned to this health insurance plan which remain constant as the resource is updated and propagates from server to server.", 0, java.lang.Integer.MAX_VALUE, identifier)); 1582 children.add(new Property("type", "CodeableConcept", "Type of plan. For example, \"Platinum\" or \"High Deductable\".", 0, 1, type)); 1583 children.add(new Property("coverageArea", "Reference(Location)", "The geographic region in which a health insurance plan's benefits apply.", 0, java.lang.Integer.MAX_VALUE, coverageArea)); 1584 children.add(new Property("network", "Reference(Organization)", "Reference to the network that providing the type of coverage.", 0, java.lang.Integer.MAX_VALUE, network)); 1585 children.add(new Property("generalCost", "", "Overall costs associated with the plan.", 0, java.lang.Integer.MAX_VALUE, generalCost)); 1586 children.add(new Property("specificCost", "", "Costs associated with the coverage provided by the product.", 0, java.lang.Integer.MAX_VALUE, specificCost)); 1587 } 1588 1589 @Override 1590 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1591 switch (_hash) { 1592 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "Business identifiers assigned to this health insurance plan which remain constant as the resource is updated and propagates from server to server.", 0, java.lang.Integer.MAX_VALUE, identifier); 1593 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Type of plan. For example, \"Platinum\" or \"High Deductable\".", 0, 1, type); 1594 case -1532328299: /*coverageArea*/ return new Property("coverageArea", "Reference(Location)", "The geographic region in which a health insurance plan's benefits apply.", 0, java.lang.Integer.MAX_VALUE, coverageArea); 1595 case 1843485230: /*network*/ return new Property("network", "Reference(Organization)", "Reference to the network that providing the type of coverage.", 0, java.lang.Integer.MAX_VALUE, network); 1596 case 878344405: /*generalCost*/ return new Property("generalCost", "", "Overall costs associated with the plan.", 0, java.lang.Integer.MAX_VALUE, generalCost); 1597 case -1205656545: /*specificCost*/ return new Property("specificCost", "", "Costs associated with the coverage provided by the product.", 0, java.lang.Integer.MAX_VALUE, specificCost); 1598 default: return super.getNamedProperty(_hash, _name, _checkValid); 1599 } 1600 1601 } 1602 1603 @Override 1604 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1605 switch (hash) { 1606 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 1607 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 1608 case -1532328299: /*coverageArea*/ return this.coverageArea == null ? new Base[0] : this.coverageArea.toArray(new Base[this.coverageArea.size()]); // Reference 1609 case 1843485230: /*network*/ return this.network == null ? new Base[0] : this.network.toArray(new Base[this.network.size()]); // Reference 1610 case 878344405: /*generalCost*/ return this.generalCost == null ? new Base[0] : this.generalCost.toArray(new Base[this.generalCost.size()]); // InsurancePlanPlanGeneralCostComponent 1611 case -1205656545: /*specificCost*/ return this.specificCost == null ? new Base[0] : this.specificCost.toArray(new Base[this.specificCost.size()]); // InsurancePlanPlanSpecificCostComponent 1612 default: return super.getProperty(hash, name, checkValid); 1613 } 1614 1615 } 1616 1617 @Override 1618 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1619 switch (hash) { 1620 case -1618432855: // identifier 1621 this.getIdentifier().add(castToIdentifier(value)); // Identifier 1622 return value; 1623 case 3575610: // type 1624 this.type = castToCodeableConcept(value); // CodeableConcept 1625 return value; 1626 case -1532328299: // coverageArea 1627 this.getCoverageArea().add(castToReference(value)); // Reference 1628 return value; 1629 case 1843485230: // network 1630 this.getNetwork().add(castToReference(value)); // Reference 1631 return value; 1632 case 878344405: // generalCost 1633 this.getGeneralCost().add((InsurancePlanPlanGeneralCostComponent) value); // InsurancePlanPlanGeneralCostComponent 1634 return value; 1635 case -1205656545: // specificCost 1636 this.getSpecificCost().add((InsurancePlanPlanSpecificCostComponent) value); // InsurancePlanPlanSpecificCostComponent 1637 return value; 1638 default: return super.setProperty(hash, name, value); 1639 } 1640 1641 } 1642 1643 @Override 1644 public Base setProperty(String name, Base value) throws FHIRException { 1645 if (name.equals("identifier")) { 1646 this.getIdentifier().add(castToIdentifier(value)); 1647 } else if (name.equals("type")) { 1648 this.type = castToCodeableConcept(value); // CodeableConcept 1649 } else if (name.equals("coverageArea")) { 1650 this.getCoverageArea().add(castToReference(value)); 1651 } else if (name.equals("network")) { 1652 this.getNetwork().add(castToReference(value)); 1653 } else if (name.equals("generalCost")) { 1654 this.getGeneralCost().add((InsurancePlanPlanGeneralCostComponent) value); 1655 } else if (name.equals("specificCost")) { 1656 this.getSpecificCost().add((InsurancePlanPlanSpecificCostComponent) value); 1657 } else 1658 return super.setProperty(name, value); 1659 return value; 1660 } 1661 1662 @Override 1663 public Base makeProperty(int hash, String name) throws FHIRException { 1664 switch (hash) { 1665 case -1618432855: return addIdentifier(); 1666 case 3575610: return getType(); 1667 case -1532328299: return addCoverageArea(); 1668 case 1843485230: return addNetwork(); 1669 case 878344405: return addGeneralCost(); 1670 case -1205656545: return addSpecificCost(); 1671 default: return super.makeProperty(hash, name); 1672 } 1673 1674 } 1675 1676 @Override 1677 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1678 switch (hash) { 1679 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 1680 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 1681 case -1532328299: /*coverageArea*/ return new String[] {"Reference"}; 1682 case 1843485230: /*network*/ return new String[] {"Reference"}; 1683 case 878344405: /*generalCost*/ return new String[] {}; 1684 case -1205656545: /*specificCost*/ return new String[] {}; 1685 default: return super.getTypesForProperty(hash, name); 1686 } 1687 1688 } 1689 1690 @Override 1691 public Base addChild(String name) throws FHIRException { 1692 if (name.equals("identifier")) { 1693 return addIdentifier(); 1694 } 1695 else if (name.equals("type")) { 1696 this.type = new CodeableConcept(); 1697 return this.type; 1698 } 1699 else if (name.equals("coverageArea")) { 1700 return addCoverageArea(); 1701 } 1702 else if (name.equals("network")) { 1703 return addNetwork(); 1704 } 1705 else if (name.equals("generalCost")) { 1706 return addGeneralCost(); 1707 } 1708 else if (name.equals("specificCost")) { 1709 return addSpecificCost(); 1710 } 1711 else 1712 return super.addChild(name); 1713 } 1714 1715 public InsurancePlanPlanComponent copy() { 1716 InsurancePlanPlanComponent dst = new InsurancePlanPlanComponent(); 1717 copyValues(dst); 1718 return dst; 1719 } 1720 1721 public void copyValues(InsurancePlanPlanComponent dst) { 1722 super.copyValues(dst); 1723 if (identifier != null) { 1724 dst.identifier = new ArrayList<Identifier>(); 1725 for (Identifier i : identifier) 1726 dst.identifier.add(i.copy()); 1727 }; 1728 dst.type = type == null ? null : type.copy(); 1729 if (coverageArea != null) { 1730 dst.coverageArea = new ArrayList<Reference>(); 1731 for (Reference i : coverageArea) 1732 dst.coverageArea.add(i.copy()); 1733 }; 1734 if (network != null) { 1735 dst.network = new ArrayList<Reference>(); 1736 for (Reference i : network) 1737 dst.network.add(i.copy()); 1738 }; 1739 if (generalCost != null) { 1740 dst.generalCost = new ArrayList<InsurancePlanPlanGeneralCostComponent>(); 1741 for (InsurancePlanPlanGeneralCostComponent i : generalCost) 1742 dst.generalCost.add(i.copy()); 1743 }; 1744 if (specificCost != null) { 1745 dst.specificCost = new ArrayList<InsurancePlanPlanSpecificCostComponent>(); 1746 for (InsurancePlanPlanSpecificCostComponent i : specificCost) 1747 dst.specificCost.add(i.copy()); 1748 }; 1749 } 1750 1751 @Override 1752 public boolean equalsDeep(Base other_) { 1753 if (!super.equalsDeep(other_)) 1754 return false; 1755 if (!(other_ instanceof InsurancePlanPlanComponent)) 1756 return false; 1757 InsurancePlanPlanComponent o = (InsurancePlanPlanComponent) other_; 1758 return compareDeep(identifier, o.identifier, true) && compareDeep(type, o.type, true) && compareDeep(coverageArea, o.coverageArea, true) 1759 && compareDeep(network, o.network, true) && compareDeep(generalCost, o.generalCost, true) && compareDeep(specificCost, o.specificCost, true) 1760 ; 1761 } 1762 1763 @Override 1764 public boolean equalsShallow(Base other_) { 1765 if (!super.equalsShallow(other_)) 1766 return false; 1767 if (!(other_ instanceof InsurancePlanPlanComponent)) 1768 return false; 1769 InsurancePlanPlanComponent o = (InsurancePlanPlanComponent) other_; 1770 return true; 1771 } 1772 1773 public boolean isEmpty() { 1774 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, type, coverageArea 1775 , network, generalCost, specificCost); 1776 } 1777 1778 public String fhirType() { 1779 return "InsurancePlan.plan"; 1780 1781 } 1782 1783 } 1784 1785 @Block() 1786 public static class InsurancePlanPlanGeneralCostComponent extends BackboneElement implements IBaseBackboneElement { 1787 /** 1788 * Type of cost. 1789 */ 1790 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 1791 @Description(shortDefinition="Type of cost", formalDefinition="Type of cost." ) 1792 protected CodeableConcept type; 1793 1794 /** 1795 * Number of participants enrolled in the plan. 1796 */ 1797 @Child(name = "groupSize", type = {PositiveIntType.class}, order=2, min=0, max=1, modifier=false, summary=false) 1798 @Description(shortDefinition="Number of enrollees", formalDefinition="Number of participants enrolled in the plan." ) 1799 protected PositiveIntType groupSize; 1800 1801 /** 1802 * Value of the cost. 1803 */ 1804 @Child(name = "cost", type = {Money.class}, order=3, min=0, max=1, modifier=false, summary=false) 1805 @Description(shortDefinition="Cost value", formalDefinition="Value of the cost." ) 1806 protected Money cost; 1807 1808 /** 1809 * Additional information about the general costs associated with this plan. 1810 */ 1811 @Child(name = "comment", type = {StringType.class}, order=4, min=0, max=1, modifier=false, summary=false) 1812 @Description(shortDefinition="Additional cost information", formalDefinition="Additional information about the general costs associated with this plan." ) 1813 protected StringType comment; 1814 1815 private static final long serialVersionUID = 1563949866L; 1816 1817 /** 1818 * Constructor 1819 */ 1820 public InsurancePlanPlanGeneralCostComponent() { 1821 super(); 1822 } 1823 1824 /** 1825 * @return {@link #type} (Type of cost.) 1826 */ 1827 public CodeableConcept getType() { 1828 if (this.type == null) 1829 if (Configuration.errorOnAutoCreate()) 1830 throw new Error("Attempt to auto-create InsurancePlanPlanGeneralCostComponent.type"); 1831 else if (Configuration.doAutoCreate()) 1832 this.type = new CodeableConcept(); // cc 1833 return this.type; 1834 } 1835 1836 public boolean hasType() { 1837 return this.type != null && !this.type.isEmpty(); 1838 } 1839 1840 /** 1841 * @param value {@link #type} (Type of cost.) 1842 */ 1843 public InsurancePlanPlanGeneralCostComponent setType(CodeableConcept value) { 1844 this.type = value; 1845 return this; 1846 } 1847 1848 /** 1849 * @return {@link #groupSize} (Number of participants enrolled in the plan.). This is the underlying object with id, value and extensions. The accessor "getGroupSize" gives direct access to the value 1850 */ 1851 public PositiveIntType getGroupSizeElement() { 1852 if (this.groupSize == null) 1853 if (Configuration.errorOnAutoCreate()) 1854 throw new Error("Attempt to auto-create InsurancePlanPlanGeneralCostComponent.groupSize"); 1855 else if (Configuration.doAutoCreate()) 1856 this.groupSize = new PositiveIntType(); // bb 1857 return this.groupSize; 1858 } 1859 1860 public boolean hasGroupSizeElement() { 1861 return this.groupSize != null && !this.groupSize.isEmpty(); 1862 } 1863 1864 public boolean hasGroupSize() { 1865 return this.groupSize != null && !this.groupSize.isEmpty(); 1866 } 1867 1868 /** 1869 * @param value {@link #groupSize} (Number of participants enrolled in the plan.). This is the underlying object with id, value and extensions. The accessor "getGroupSize" gives direct access to the value 1870 */ 1871 public InsurancePlanPlanGeneralCostComponent setGroupSizeElement(PositiveIntType value) { 1872 this.groupSize = value; 1873 return this; 1874 } 1875 1876 /** 1877 * @return Number of participants enrolled in the plan. 1878 */ 1879 public int getGroupSize() { 1880 return this.groupSize == null || this.groupSize.isEmpty() ? 0 : this.groupSize.getValue(); 1881 } 1882 1883 /** 1884 * @param value Number of participants enrolled in the plan. 1885 */ 1886 public InsurancePlanPlanGeneralCostComponent setGroupSize(int value) { 1887 if (this.groupSize == null) 1888 this.groupSize = new PositiveIntType(); 1889 this.groupSize.setValue(value); 1890 return this; 1891 } 1892 1893 /** 1894 * @return {@link #cost} (Value of the cost.) 1895 */ 1896 public Money getCost() { 1897 if (this.cost == null) 1898 if (Configuration.errorOnAutoCreate()) 1899 throw new Error("Attempt to auto-create InsurancePlanPlanGeneralCostComponent.cost"); 1900 else if (Configuration.doAutoCreate()) 1901 this.cost = new Money(); // cc 1902 return this.cost; 1903 } 1904 1905 public boolean hasCost() { 1906 return this.cost != null && !this.cost.isEmpty(); 1907 } 1908 1909 /** 1910 * @param value {@link #cost} (Value of the cost.) 1911 */ 1912 public InsurancePlanPlanGeneralCostComponent setCost(Money value) { 1913 this.cost = value; 1914 return this; 1915 } 1916 1917 /** 1918 * @return {@link #comment} (Additional information about the general costs associated with this plan.). This is the underlying object with id, value and extensions. The accessor "getComment" gives direct access to the value 1919 */ 1920 public StringType getCommentElement() { 1921 if (this.comment == null) 1922 if (Configuration.errorOnAutoCreate()) 1923 throw new Error("Attempt to auto-create InsurancePlanPlanGeneralCostComponent.comment"); 1924 else if (Configuration.doAutoCreate()) 1925 this.comment = new StringType(); // bb 1926 return this.comment; 1927 } 1928 1929 public boolean hasCommentElement() { 1930 return this.comment != null && !this.comment.isEmpty(); 1931 } 1932 1933 public boolean hasComment() { 1934 return this.comment != null && !this.comment.isEmpty(); 1935 } 1936 1937 /** 1938 * @param value {@link #comment} (Additional information about the general costs associated with this plan.). This is the underlying object with id, value and extensions. The accessor "getComment" gives direct access to the value 1939 */ 1940 public InsurancePlanPlanGeneralCostComponent setCommentElement(StringType value) { 1941 this.comment = value; 1942 return this; 1943 } 1944 1945 /** 1946 * @return Additional information about the general costs associated with this plan. 1947 */ 1948 public String getComment() { 1949 return this.comment == null ? null : this.comment.getValue(); 1950 } 1951 1952 /** 1953 * @param value Additional information about the general costs associated with this plan. 1954 */ 1955 public InsurancePlanPlanGeneralCostComponent setComment(String value) { 1956 if (Utilities.noString(value)) 1957 this.comment = null; 1958 else { 1959 if (this.comment == null) 1960 this.comment = new StringType(); 1961 this.comment.setValue(value); 1962 } 1963 return this; 1964 } 1965 1966 protected void listChildren(List<Property> children) { 1967 super.listChildren(children); 1968 children.add(new Property("type", "CodeableConcept", "Type of cost.", 0, 1, type)); 1969 children.add(new Property("groupSize", "positiveInt", "Number of participants enrolled in the plan.", 0, 1, groupSize)); 1970 children.add(new Property("cost", "Money", "Value of the cost.", 0, 1, cost)); 1971 children.add(new Property("comment", "string", "Additional information about the general costs associated with this plan.", 0, 1, comment)); 1972 } 1973 1974 @Override 1975 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1976 switch (_hash) { 1977 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Type of cost.", 0, 1, type); 1978 case -1483017440: /*groupSize*/ return new Property("groupSize", "positiveInt", "Number of participants enrolled in the plan.", 0, 1, groupSize); 1979 case 3059661: /*cost*/ return new Property("cost", "Money", "Value of the cost.", 0, 1, cost); 1980 case 950398559: /*comment*/ return new Property("comment", "string", "Additional information about the general costs associated with this plan.", 0, 1, comment); 1981 default: return super.getNamedProperty(_hash, _name, _checkValid); 1982 } 1983 1984 } 1985 1986 @Override 1987 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1988 switch (hash) { 1989 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 1990 case -1483017440: /*groupSize*/ return this.groupSize == null ? new Base[0] : new Base[] {this.groupSize}; // PositiveIntType 1991 case 3059661: /*cost*/ return this.cost == null ? new Base[0] : new Base[] {this.cost}; // Money 1992 case 950398559: /*comment*/ return this.comment == null ? new Base[0] : new Base[] {this.comment}; // StringType 1993 default: return super.getProperty(hash, name, checkValid); 1994 } 1995 1996 } 1997 1998 @Override 1999 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2000 switch (hash) { 2001 case 3575610: // type 2002 this.type = castToCodeableConcept(value); // CodeableConcept 2003 return value; 2004 case -1483017440: // groupSize 2005 this.groupSize = castToPositiveInt(value); // PositiveIntType 2006 return value; 2007 case 3059661: // cost 2008 this.cost = castToMoney(value); // Money 2009 return value; 2010 case 950398559: // comment 2011 this.comment = castToString(value); // StringType 2012 return value; 2013 default: return super.setProperty(hash, name, value); 2014 } 2015 2016 } 2017 2018 @Override 2019 public Base setProperty(String name, Base value) throws FHIRException { 2020 if (name.equals("type")) { 2021 this.type = castToCodeableConcept(value); // CodeableConcept 2022 } else if (name.equals("groupSize")) { 2023 this.groupSize = castToPositiveInt(value); // PositiveIntType 2024 } else if (name.equals("cost")) { 2025 this.cost = castToMoney(value); // Money 2026 } else if (name.equals("comment")) { 2027 this.comment = castToString(value); // StringType 2028 } else 2029 return super.setProperty(name, value); 2030 return value; 2031 } 2032 2033 @Override 2034 public Base makeProperty(int hash, String name) throws FHIRException { 2035 switch (hash) { 2036 case 3575610: return getType(); 2037 case -1483017440: return getGroupSizeElement(); 2038 case 3059661: return getCost(); 2039 case 950398559: return getCommentElement(); 2040 default: return super.makeProperty(hash, name); 2041 } 2042 2043 } 2044 2045 @Override 2046 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2047 switch (hash) { 2048 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 2049 case -1483017440: /*groupSize*/ return new String[] {"positiveInt"}; 2050 case 3059661: /*cost*/ return new String[] {"Money"}; 2051 case 950398559: /*comment*/ return new String[] {"string"}; 2052 default: return super.getTypesForProperty(hash, name); 2053 } 2054 2055 } 2056 2057 @Override 2058 public Base addChild(String name) throws FHIRException { 2059 if (name.equals("type")) { 2060 this.type = new CodeableConcept(); 2061 return this.type; 2062 } 2063 else if (name.equals("groupSize")) { 2064 throw new FHIRException("Cannot call addChild on a primitive type InsurancePlan.groupSize"); 2065 } 2066 else if (name.equals("cost")) { 2067 this.cost = new Money(); 2068 return this.cost; 2069 } 2070 else if (name.equals("comment")) { 2071 throw new FHIRException("Cannot call addChild on a primitive type InsurancePlan.comment"); 2072 } 2073 else 2074 return super.addChild(name); 2075 } 2076 2077 public InsurancePlanPlanGeneralCostComponent copy() { 2078 InsurancePlanPlanGeneralCostComponent dst = new InsurancePlanPlanGeneralCostComponent(); 2079 copyValues(dst); 2080 return dst; 2081 } 2082 2083 public void copyValues(InsurancePlanPlanGeneralCostComponent dst) { 2084 super.copyValues(dst); 2085 dst.type = type == null ? null : type.copy(); 2086 dst.groupSize = groupSize == null ? null : groupSize.copy(); 2087 dst.cost = cost == null ? null : cost.copy(); 2088 dst.comment = comment == null ? null : comment.copy(); 2089 } 2090 2091 @Override 2092 public boolean equalsDeep(Base other_) { 2093 if (!super.equalsDeep(other_)) 2094 return false; 2095 if (!(other_ instanceof InsurancePlanPlanGeneralCostComponent)) 2096 return false; 2097 InsurancePlanPlanGeneralCostComponent o = (InsurancePlanPlanGeneralCostComponent) other_; 2098 return compareDeep(type, o.type, true) && compareDeep(groupSize, o.groupSize, true) && compareDeep(cost, o.cost, true) 2099 && compareDeep(comment, o.comment, true); 2100 } 2101 2102 @Override 2103 public boolean equalsShallow(Base other_) { 2104 if (!super.equalsShallow(other_)) 2105 return false; 2106 if (!(other_ instanceof InsurancePlanPlanGeneralCostComponent)) 2107 return false; 2108 InsurancePlanPlanGeneralCostComponent o = (InsurancePlanPlanGeneralCostComponent) other_; 2109 return compareValues(groupSize, o.groupSize, true) && compareValues(comment, o.comment, true); 2110 } 2111 2112 public boolean isEmpty() { 2113 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, groupSize, cost, comment 2114 ); 2115 } 2116 2117 public String fhirType() { 2118 return "InsurancePlan.plan.generalCost"; 2119 2120 } 2121 2122 } 2123 2124 @Block() 2125 public static class InsurancePlanPlanSpecificCostComponent extends BackboneElement implements IBaseBackboneElement { 2126 /** 2127 * General category of benefit (Medical; Dental; Vision; Drug; Mental Health; Substance Abuse; Hospice, Home Health). 2128 */ 2129 @Child(name = "category", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 2130 @Description(shortDefinition="General category of benefit", formalDefinition="General category of benefit (Medical; Dental; Vision; Drug; Mental Health; Substance Abuse; Hospice, Home Health)." ) 2131 protected CodeableConcept category; 2132 2133 /** 2134 * List of the specific benefits under this category of benefit. 2135 */ 2136 @Child(name = "benefit", type = {}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2137 @Description(shortDefinition="Benefits list", formalDefinition="List of the specific benefits under this category of benefit." ) 2138 protected List<PlanBenefitComponent> benefit; 2139 2140 private static final long serialVersionUID = 922585525L; 2141 2142 /** 2143 * Constructor 2144 */ 2145 public InsurancePlanPlanSpecificCostComponent() { 2146 super(); 2147 } 2148 2149 /** 2150 * Constructor 2151 */ 2152 public InsurancePlanPlanSpecificCostComponent(CodeableConcept category) { 2153 super(); 2154 this.category = category; 2155 } 2156 2157 /** 2158 * @return {@link #category} (General category of benefit (Medical; Dental; Vision; Drug; Mental Health; Substance Abuse; Hospice, Home Health).) 2159 */ 2160 public CodeableConcept getCategory() { 2161 if (this.category == null) 2162 if (Configuration.errorOnAutoCreate()) 2163 throw new Error("Attempt to auto-create InsurancePlanPlanSpecificCostComponent.category"); 2164 else if (Configuration.doAutoCreate()) 2165 this.category = new CodeableConcept(); // cc 2166 return this.category; 2167 } 2168 2169 public boolean hasCategory() { 2170 return this.category != null && !this.category.isEmpty(); 2171 } 2172 2173 /** 2174 * @param value {@link #category} (General category of benefit (Medical; Dental; Vision; Drug; Mental Health; Substance Abuse; Hospice, Home Health).) 2175 */ 2176 public InsurancePlanPlanSpecificCostComponent setCategory(CodeableConcept value) { 2177 this.category = value; 2178 return this; 2179 } 2180 2181 /** 2182 * @return {@link #benefit} (List of the specific benefits under this category of benefit.) 2183 */ 2184 public List<PlanBenefitComponent> getBenefit() { 2185 if (this.benefit == null) 2186 this.benefit = new ArrayList<PlanBenefitComponent>(); 2187 return this.benefit; 2188 } 2189 2190 /** 2191 * @return Returns a reference to <code>this</code> for easy method chaining 2192 */ 2193 public InsurancePlanPlanSpecificCostComponent setBenefit(List<PlanBenefitComponent> theBenefit) { 2194 this.benefit = theBenefit; 2195 return this; 2196 } 2197 2198 public boolean hasBenefit() { 2199 if (this.benefit == null) 2200 return false; 2201 for (PlanBenefitComponent item : this.benefit) 2202 if (!item.isEmpty()) 2203 return true; 2204 return false; 2205 } 2206 2207 public PlanBenefitComponent addBenefit() { //3 2208 PlanBenefitComponent t = new PlanBenefitComponent(); 2209 if (this.benefit == null) 2210 this.benefit = new ArrayList<PlanBenefitComponent>(); 2211 this.benefit.add(t); 2212 return t; 2213 } 2214 2215 public InsurancePlanPlanSpecificCostComponent addBenefit(PlanBenefitComponent t) { //3 2216 if (t == null) 2217 return this; 2218 if (this.benefit == null) 2219 this.benefit = new ArrayList<PlanBenefitComponent>(); 2220 this.benefit.add(t); 2221 return this; 2222 } 2223 2224 /** 2225 * @return The first repetition of repeating field {@link #benefit}, creating it if it does not already exist 2226 */ 2227 public PlanBenefitComponent getBenefitFirstRep() { 2228 if (getBenefit().isEmpty()) { 2229 addBenefit(); 2230 } 2231 return getBenefit().get(0); 2232 } 2233 2234 protected void listChildren(List<Property> children) { 2235 super.listChildren(children); 2236 children.add(new Property("category", "CodeableConcept", "General category of benefit (Medical; Dental; Vision; Drug; Mental Health; Substance Abuse; Hospice, Home Health).", 0, 1, category)); 2237 children.add(new Property("benefit", "", "List of the specific benefits under this category of benefit.", 0, java.lang.Integer.MAX_VALUE, benefit)); 2238 } 2239 2240 @Override 2241 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2242 switch (_hash) { 2243 case 50511102: /*category*/ return new Property("category", "CodeableConcept", "General category of benefit (Medical; Dental; Vision; Drug; Mental Health; Substance Abuse; Hospice, Home Health).", 0, 1, category); 2244 case -222710633: /*benefit*/ return new Property("benefit", "", "List of the specific benefits under this category of benefit.", 0, java.lang.Integer.MAX_VALUE, benefit); 2245 default: return super.getNamedProperty(_hash, _name, _checkValid); 2246 } 2247 2248 } 2249 2250 @Override 2251 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2252 switch (hash) { 2253 case 50511102: /*category*/ return this.category == null ? new Base[0] : new Base[] {this.category}; // CodeableConcept 2254 case -222710633: /*benefit*/ return this.benefit == null ? new Base[0] : this.benefit.toArray(new Base[this.benefit.size()]); // PlanBenefitComponent 2255 default: return super.getProperty(hash, name, checkValid); 2256 } 2257 2258 } 2259 2260 @Override 2261 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2262 switch (hash) { 2263 case 50511102: // category 2264 this.category = castToCodeableConcept(value); // CodeableConcept 2265 return value; 2266 case -222710633: // benefit 2267 this.getBenefit().add((PlanBenefitComponent) value); // PlanBenefitComponent 2268 return value; 2269 default: return super.setProperty(hash, name, value); 2270 } 2271 2272 } 2273 2274 @Override 2275 public Base setProperty(String name, Base value) throws FHIRException { 2276 if (name.equals("category")) { 2277 this.category = castToCodeableConcept(value); // CodeableConcept 2278 } else if (name.equals("benefit")) { 2279 this.getBenefit().add((PlanBenefitComponent) value); 2280 } else 2281 return super.setProperty(name, value); 2282 return value; 2283 } 2284 2285 @Override 2286 public Base makeProperty(int hash, String name) throws FHIRException { 2287 switch (hash) { 2288 case 50511102: return getCategory(); 2289 case -222710633: return addBenefit(); 2290 default: return super.makeProperty(hash, name); 2291 } 2292 2293 } 2294 2295 @Override 2296 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2297 switch (hash) { 2298 case 50511102: /*category*/ return new String[] {"CodeableConcept"}; 2299 case -222710633: /*benefit*/ return new String[] {}; 2300 default: return super.getTypesForProperty(hash, name); 2301 } 2302 2303 } 2304 2305 @Override 2306 public Base addChild(String name) throws FHIRException { 2307 if (name.equals("category")) { 2308 this.category = new CodeableConcept(); 2309 return this.category; 2310 } 2311 else if (name.equals("benefit")) { 2312 return addBenefit(); 2313 } 2314 else 2315 return super.addChild(name); 2316 } 2317 2318 public InsurancePlanPlanSpecificCostComponent copy() { 2319 InsurancePlanPlanSpecificCostComponent dst = new InsurancePlanPlanSpecificCostComponent(); 2320 copyValues(dst); 2321 return dst; 2322 } 2323 2324 public void copyValues(InsurancePlanPlanSpecificCostComponent dst) { 2325 super.copyValues(dst); 2326 dst.category = category == null ? null : category.copy(); 2327 if (benefit != null) { 2328 dst.benefit = new ArrayList<PlanBenefitComponent>(); 2329 for (PlanBenefitComponent i : benefit) 2330 dst.benefit.add(i.copy()); 2331 }; 2332 } 2333 2334 @Override 2335 public boolean equalsDeep(Base other_) { 2336 if (!super.equalsDeep(other_)) 2337 return false; 2338 if (!(other_ instanceof InsurancePlanPlanSpecificCostComponent)) 2339 return false; 2340 InsurancePlanPlanSpecificCostComponent o = (InsurancePlanPlanSpecificCostComponent) other_; 2341 return compareDeep(category, o.category, true) && compareDeep(benefit, o.benefit, true); 2342 } 2343 2344 @Override 2345 public boolean equalsShallow(Base other_) { 2346 if (!super.equalsShallow(other_)) 2347 return false; 2348 if (!(other_ instanceof InsurancePlanPlanSpecificCostComponent)) 2349 return false; 2350 InsurancePlanPlanSpecificCostComponent o = (InsurancePlanPlanSpecificCostComponent) other_; 2351 return true; 2352 } 2353 2354 public boolean isEmpty() { 2355 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(category, benefit); 2356 } 2357 2358 public String fhirType() { 2359 return "InsurancePlan.plan.specificCost"; 2360 2361 } 2362 2363 } 2364 2365 @Block() 2366 public static class PlanBenefitComponent extends BackboneElement implements IBaseBackboneElement { 2367 /** 2368 * Type of specific benefit (preventative; primary care office visit; speciality office visit; hospitalization; emergency room; urgent care). 2369 */ 2370 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 2371 @Description(shortDefinition="Type of specific benefit", formalDefinition="Type of specific benefit (preventative; primary care office visit; speciality office visit; hospitalization; emergency room; urgent care)." ) 2372 protected CodeableConcept type; 2373 2374 /** 2375 * List of the costs associated with a specific benefit. 2376 */ 2377 @Child(name = "cost", type = {}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2378 @Description(shortDefinition="List of the costs", formalDefinition="List of the costs associated with a specific benefit." ) 2379 protected List<PlanBenefitCostComponent> cost; 2380 2381 private static final long serialVersionUID = 792296200L; 2382 2383 /** 2384 * Constructor 2385 */ 2386 public PlanBenefitComponent() { 2387 super(); 2388 } 2389 2390 /** 2391 * Constructor 2392 */ 2393 public PlanBenefitComponent(CodeableConcept type) { 2394 super(); 2395 this.type = type; 2396 } 2397 2398 /** 2399 * @return {@link #type} (Type of specific benefit (preventative; primary care office visit; speciality office visit; hospitalization; emergency room; urgent care).) 2400 */ 2401 public CodeableConcept getType() { 2402 if (this.type == null) 2403 if (Configuration.errorOnAutoCreate()) 2404 throw new Error("Attempt to auto-create PlanBenefitComponent.type"); 2405 else if (Configuration.doAutoCreate()) 2406 this.type = new CodeableConcept(); // cc 2407 return this.type; 2408 } 2409 2410 public boolean hasType() { 2411 return this.type != null && !this.type.isEmpty(); 2412 } 2413 2414 /** 2415 * @param value {@link #type} (Type of specific benefit (preventative; primary care office visit; speciality office visit; hospitalization; emergency room; urgent care).) 2416 */ 2417 public PlanBenefitComponent setType(CodeableConcept value) { 2418 this.type = value; 2419 return this; 2420 } 2421 2422 /** 2423 * @return {@link #cost} (List of the costs associated with a specific benefit.) 2424 */ 2425 public List<PlanBenefitCostComponent> getCost() { 2426 if (this.cost == null) 2427 this.cost = new ArrayList<PlanBenefitCostComponent>(); 2428 return this.cost; 2429 } 2430 2431 /** 2432 * @return Returns a reference to <code>this</code> for easy method chaining 2433 */ 2434 public PlanBenefitComponent setCost(List<PlanBenefitCostComponent> theCost) { 2435 this.cost = theCost; 2436 return this; 2437 } 2438 2439 public boolean hasCost() { 2440 if (this.cost == null) 2441 return false; 2442 for (PlanBenefitCostComponent item : this.cost) 2443 if (!item.isEmpty()) 2444 return true; 2445 return false; 2446 } 2447 2448 public PlanBenefitCostComponent addCost() { //3 2449 PlanBenefitCostComponent t = new PlanBenefitCostComponent(); 2450 if (this.cost == null) 2451 this.cost = new ArrayList<PlanBenefitCostComponent>(); 2452 this.cost.add(t); 2453 return t; 2454 } 2455 2456 public PlanBenefitComponent addCost(PlanBenefitCostComponent t) { //3 2457 if (t == null) 2458 return this; 2459 if (this.cost == null) 2460 this.cost = new ArrayList<PlanBenefitCostComponent>(); 2461 this.cost.add(t); 2462 return this; 2463 } 2464 2465 /** 2466 * @return The first repetition of repeating field {@link #cost}, creating it if it does not already exist 2467 */ 2468 public PlanBenefitCostComponent getCostFirstRep() { 2469 if (getCost().isEmpty()) { 2470 addCost(); 2471 } 2472 return getCost().get(0); 2473 } 2474 2475 protected void listChildren(List<Property> children) { 2476 super.listChildren(children); 2477 children.add(new Property("type", "CodeableConcept", "Type of specific benefit (preventative; primary care office visit; speciality office visit; hospitalization; emergency room; urgent care).", 0, 1, type)); 2478 children.add(new Property("cost", "", "List of the costs associated with a specific benefit.", 0, java.lang.Integer.MAX_VALUE, cost)); 2479 } 2480 2481 @Override 2482 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2483 switch (_hash) { 2484 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Type of specific benefit (preventative; primary care office visit; speciality office visit; hospitalization; emergency room; urgent care).", 0, 1, type); 2485 case 3059661: /*cost*/ return new Property("cost", "", "List of the costs associated with a specific benefit.", 0, java.lang.Integer.MAX_VALUE, cost); 2486 default: return super.getNamedProperty(_hash, _name, _checkValid); 2487 } 2488 2489 } 2490 2491 @Override 2492 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2493 switch (hash) { 2494 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 2495 case 3059661: /*cost*/ return this.cost == null ? new Base[0] : this.cost.toArray(new Base[this.cost.size()]); // PlanBenefitCostComponent 2496 default: return super.getProperty(hash, name, checkValid); 2497 } 2498 2499 } 2500 2501 @Override 2502 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2503 switch (hash) { 2504 case 3575610: // type 2505 this.type = castToCodeableConcept(value); // CodeableConcept 2506 return value; 2507 case 3059661: // cost 2508 this.getCost().add((PlanBenefitCostComponent) value); // PlanBenefitCostComponent 2509 return value; 2510 default: return super.setProperty(hash, name, value); 2511 } 2512 2513 } 2514 2515 @Override 2516 public Base setProperty(String name, Base value) throws FHIRException { 2517 if (name.equals("type")) { 2518 this.type = castToCodeableConcept(value); // CodeableConcept 2519 } else if (name.equals("cost")) { 2520 this.getCost().add((PlanBenefitCostComponent) value); 2521 } else 2522 return super.setProperty(name, value); 2523 return value; 2524 } 2525 2526 @Override 2527 public Base makeProperty(int hash, String name) throws FHIRException { 2528 switch (hash) { 2529 case 3575610: return getType(); 2530 case 3059661: return addCost(); 2531 default: return super.makeProperty(hash, name); 2532 } 2533 2534 } 2535 2536 @Override 2537 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2538 switch (hash) { 2539 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 2540 case 3059661: /*cost*/ return new String[] {}; 2541 default: return super.getTypesForProperty(hash, name); 2542 } 2543 2544 } 2545 2546 @Override 2547 public Base addChild(String name) throws FHIRException { 2548 if (name.equals("type")) { 2549 this.type = new CodeableConcept(); 2550 return this.type; 2551 } 2552 else if (name.equals("cost")) { 2553 return addCost(); 2554 } 2555 else 2556 return super.addChild(name); 2557 } 2558 2559 public PlanBenefitComponent copy() { 2560 PlanBenefitComponent dst = new PlanBenefitComponent(); 2561 copyValues(dst); 2562 return dst; 2563 } 2564 2565 public void copyValues(PlanBenefitComponent dst) { 2566 super.copyValues(dst); 2567 dst.type = type == null ? null : type.copy(); 2568 if (cost != null) { 2569 dst.cost = new ArrayList<PlanBenefitCostComponent>(); 2570 for (PlanBenefitCostComponent i : cost) 2571 dst.cost.add(i.copy()); 2572 }; 2573 } 2574 2575 @Override 2576 public boolean equalsDeep(Base other_) { 2577 if (!super.equalsDeep(other_)) 2578 return false; 2579 if (!(other_ instanceof PlanBenefitComponent)) 2580 return false; 2581 PlanBenefitComponent o = (PlanBenefitComponent) other_; 2582 return compareDeep(type, o.type, true) && compareDeep(cost, o.cost, true); 2583 } 2584 2585 @Override 2586 public boolean equalsShallow(Base other_) { 2587 if (!super.equalsShallow(other_)) 2588 return false; 2589 if (!(other_ instanceof PlanBenefitComponent)) 2590 return false; 2591 PlanBenefitComponent o = (PlanBenefitComponent) other_; 2592 return true; 2593 } 2594 2595 public boolean isEmpty() { 2596 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, cost); 2597 } 2598 2599 public String fhirType() { 2600 return "InsurancePlan.plan.specificCost.benefit"; 2601 2602 } 2603 2604 } 2605 2606 @Block() 2607 public static class PlanBenefitCostComponent extends BackboneElement implements IBaseBackboneElement { 2608 /** 2609 * Type of cost (copay; individual cap; family cap; coinsurance; deductible). 2610 */ 2611 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 2612 @Description(shortDefinition="Type of cost", formalDefinition="Type of cost (copay; individual cap; family cap; coinsurance; deductible)." ) 2613 protected CodeableConcept type; 2614 2615 /** 2616 * Whether the cost applies to in-network or out-of-network providers (in-network; out-of-network; other). 2617 */ 2618 @Child(name = "applicability", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 2619 @Description(shortDefinition="in-network | out-of-network | other", formalDefinition="Whether the cost applies to in-network or out-of-network providers (in-network; out-of-network; other)." ) 2620 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/insuranceplan-applicability") 2621 protected CodeableConcept applicability; 2622 2623 /** 2624 * Additional information about the cost, such as information about funding sources (e.g. HSA, HRA, FSA, RRA). 2625 */ 2626 @Child(name = "qualifiers", type = {CodeableConcept.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2627 @Description(shortDefinition="Additional information about the cost", formalDefinition="Additional information about the cost, such as information about funding sources (e.g. HSA, HRA, FSA, RRA)." ) 2628 protected List<CodeableConcept> qualifiers; 2629 2630 /** 2631 * The actual cost value. (some of the costs may be represented as percentages rather than currency, e.g. 10% coinsurance). 2632 */ 2633 @Child(name = "value", type = {Quantity.class}, order=4, min=0, max=1, modifier=false, summary=false) 2634 @Description(shortDefinition="The actual cost value", formalDefinition="The actual cost value. (some of the costs may be represented as percentages rather than currency, e.g. 10% coinsurance)." ) 2635 protected Quantity value; 2636 2637 private static final long serialVersionUID = -340688733L; 2638 2639 /** 2640 * Constructor 2641 */ 2642 public PlanBenefitCostComponent() { 2643 super(); 2644 } 2645 2646 /** 2647 * Constructor 2648 */ 2649 public PlanBenefitCostComponent(CodeableConcept type) { 2650 super(); 2651 this.type = type; 2652 } 2653 2654 /** 2655 * @return {@link #type} (Type of cost (copay; individual cap; family cap; coinsurance; deductible).) 2656 */ 2657 public CodeableConcept getType() { 2658 if (this.type == null) 2659 if (Configuration.errorOnAutoCreate()) 2660 throw new Error("Attempt to auto-create PlanBenefitCostComponent.type"); 2661 else if (Configuration.doAutoCreate()) 2662 this.type = new CodeableConcept(); // cc 2663 return this.type; 2664 } 2665 2666 public boolean hasType() { 2667 return this.type != null && !this.type.isEmpty(); 2668 } 2669 2670 /** 2671 * @param value {@link #type} (Type of cost (copay; individual cap; family cap; coinsurance; deductible).) 2672 */ 2673 public PlanBenefitCostComponent setType(CodeableConcept value) { 2674 this.type = value; 2675 return this; 2676 } 2677 2678 /** 2679 * @return {@link #applicability} (Whether the cost applies to in-network or out-of-network providers (in-network; out-of-network; other).) 2680 */ 2681 public CodeableConcept getApplicability() { 2682 if (this.applicability == null) 2683 if (Configuration.errorOnAutoCreate()) 2684 throw new Error("Attempt to auto-create PlanBenefitCostComponent.applicability"); 2685 else if (Configuration.doAutoCreate()) 2686 this.applicability = new CodeableConcept(); // cc 2687 return this.applicability; 2688 } 2689 2690 public boolean hasApplicability() { 2691 return this.applicability != null && !this.applicability.isEmpty(); 2692 } 2693 2694 /** 2695 * @param value {@link #applicability} (Whether the cost applies to in-network or out-of-network providers (in-network; out-of-network; other).) 2696 */ 2697 public PlanBenefitCostComponent setApplicability(CodeableConcept value) { 2698 this.applicability = value; 2699 return this; 2700 } 2701 2702 /** 2703 * @return {@link #qualifiers} (Additional information about the cost, such as information about funding sources (e.g. HSA, HRA, FSA, RRA).) 2704 */ 2705 public List<CodeableConcept> getQualifiers() { 2706 if (this.qualifiers == null) 2707 this.qualifiers = new ArrayList<CodeableConcept>(); 2708 return this.qualifiers; 2709 } 2710 2711 /** 2712 * @return Returns a reference to <code>this</code> for easy method chaining 2713 */ 2714 public PlanBenefitCostComponent setQualifiers(List<CodeableConcept> theQualifiers) { 2715 this.qualifiers = theQualifiers; 2716 return this; 2717 } 2718 2719 public boolean hasQualifiers() { 2720 if (this.qualifiers == null) 2721 return false; 2722 for (CodeableConcept item : this.qualifiers) 2723 if (!item.isEmpty()) 2724 return true; 2725 return false; 2726 } 2727 2728 public CodeableConcept addQualifiers() { //3 2729 CodeableConcept t = new CodeableConcept(); 2730 if (this.qualifiers == null) 2731 this.qualifiers = new ArrayList<CodeableConcept>(); 2732 this.qualifiers.add(t); 2733 return t; 2734 } 2735 2736 public PlanBenefitCostComponent addQualifiers(CodeableConcept t) { //3 2737 if (t == null) 2738 return this; 2739 if (this.qualifiers == null) 2740 this.qualifiers = new ArrayList<CodeableConcept>(); 2741 this.qualifiers.add(t); 2742 return this; 2743 } 2744 2745 /** 2746 * @return The first repetition of repeating field {@link #qualifiers}, creating it if it does not already exist 2747 */ 2748 public CodeableConcept getQualifiersFirstRep() { 2749 if (getQualifiers().isEmpty()) { 2750 addQualifiers(); 2751 } 2752 return getQualifiers().get(0); 2753 } 2754 2755 /** 2756 * @return {@link #value} (The actual cost value. (some of the costs may be represented as percentages rather than currency, e.g. 10% coinsurance).) 2757 */ 2758 public Quantity getValue() { 2759 if (this.value == null) 2760 if (Configuration.errorOnAutoCreate()) 2761 throw new Error("Attempt to auto-create PlanBenefitCostComponent.value"); 2762 else if (Configuration.doAutoCreate()) 2763 this.value = new Quantity(); // cc 2764 return this.value; 2765 } 2766 2767 public boolean hasValue() { 2768 return this.value != null && !this.value.isEmpty(); 2769 } 2770 2771 /** 2772 * @param value {@link #value} (The actual cost value. (some of the costs may be represented as percentages rather than currency, e.g. 10% coinsurance).) 2773 */ 2774 public PlanBenefitCostComponent setValue(Quantity value) { 2775 this.value = value; 2776 return this; 2777 } 2778 2779 protected void listChildren(List<Property> children) { 2780 super.listChildren(children); 2781 children.add(new Property("type", "CodeableConcept", "Type of cost (copay; individual cap; family cap; coinsurance; deductible).", 0, 1, type)); 2782 children.add(new Property("applicability", "CodeableConcept", "Whether the cost applies to in-network or out-of-network providers (in-network; out-of-network; other).", 0, 1, applicability)); 2783 children.add(new Property("qualifiers", "CodeableConcept", "Additional information about the cost, such as information about funding sources (e.g. HSA, HRA, FSA, RRA).", 0, java.lang.Integer.MAX_VALUE, qualifiers)); 2784 children.add(new Property("value", "Quantity", "The actual cost value. (some of the costs may be represented as percentages rather than currency, e.g. 10% coinsurance).", 0, 1, value)); 2785 } 2786 2787 @Override 2788 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2789 switch (_hash) { 2790 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Type of cost (copay; individual cap; family cap; coinsurance; deductible).", 0, 1, type); 2791 case -1526770491: /*applicability*/ return new Property("applicability", "CodeableConcept", "Whether the cost applies to in-network or out-of-network providers (in-network; out-of-network; other).", 0, 1, applicability); 2792 case -31447799: /*qualifiers*/ return new Property("qualifiers", "CodeableConcept", "Additional information about the cost, such as information about funding sources (e.g. HSA, HRA, FSA, RRA).", 0, java.lang.Integer.MAX_VALUE, qualifiers); 2793 case 111972721: /*value*/ return new Property("value", "Quantity", "The actual cost value. (some of the costs may be represented as percentages rather than currency, e.g. 10% coinsurance).", 0, 1, value); 2794 default: return super.getNamedProperty(_hash, _name, _checkValid); 2795 } 2796 2797 } 2798 2799 @Override 2800 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2801 switch (hash) { 2802 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 2803 case -1526770491: /*applicability*/ return this.applicability == null ? new Base[0] : new Base[] {this.applicability}; // CodeableConcept 2804 case -31447799: /*qualifiers*/ return this.qualifiers == null ? new Base[0] : this.qualifiers.toArray(new Base[this.qualifiers.size()]); // CodeableConcept 2805 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // Quantity 2806 default: return super.getProperty(hash, name, checkValid); 2807 } 2808 2809 } 2810 2811 @Override 2812 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2813 switch (hash) { 2814 case 3575610: // type 2815 this.type = castToCodeableConcept(value); // CodeableConcept 2816 return value; 2817 case -1526770491: // applicability 2818 this.applicability = castToCodeableConcept(value); // CodeableConcept 2819 return value; 2820 case -31447799: // qualifiers 2821 this.getQualifiers().add(castToCodeableConcept(value)); // CodeableConcept 2822 return value; 2823 case 111972721: // value 2824 this.value = castToQuantity(value); // Quantity 2825 return value; 2826 default: return super.setProperty(hash, name, value); 2827 } 2828 2829 } 2830 2831 @Override 2832 public Base setProperty(String name, Base value) throws FHIRException { 2833 if (name.equals("type")) { 2834 this.type = castToCodeableConcept(value); // CodeableConcept 2835 } else if (name.equals("applicability")) { 2836 this.applicability = castToCodeableConcept(value); // CodeableConcept 2837 } else if (name.equals("qualifiers")) { 2838 this.getQualifiers().add(castToCodeableConcept(value)); 2839 } else if (name.equals("value")) { 2840 this.value = castToQuantity(value); // Quantity 2841 } else 2842 return super.setProperty(name, value); 2843 return value; 2844 } 2845 2846 @Override 2847 public Base makeProperty(int hash, String name) throws FHIRException { 2848 switch (hash) { 2849 case 3575610: return getType(); 2850 case -1526770491: return getApplicability(); 2851 case -31447799: return addQualifiers(); 2852 case 111972721: return getValue(); 2853 default: return super.makeProperty(hash, name); 2854 } 2855 2856 } 2857 2858 @Override 2859 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2860 switch (hash) { 2861 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 2862 case -1526770491: /*applicability*/ return new String[] {"CodeableConcept"}; 2863 case -31447799: /*qualifiers*/ return new String[] {"CodeableConcept"}; 2864 case 111972721: /*value*/ return new String[] {"Quantity"}; 2865 default: return super.getTypesForProperty(hash, name); 2866 } 2867 2868 } 2869 2870 @Override 2871 public Base addChild(String name) throws FHIRException { 2872 if (name.equals("type")) { 2873 this.type = new CodeableConcept(); 2874 return this.type; 2875 } 2876 else if (name.equals("applicability")) { 2877 this.applicability = new CodeableConcept(); 2878 return this.applicability; 2879 } 2880 else if (name.equals("qualifiers")) { 2881 return addQualifiers(); 2882 } 2883 else if (name.equals("value")) { 2884 this.value = new Quantity(); 2885 return this.value; 2886 } 2887 else 2888 return super.addChild(name); 2889 } 2890 2891 public PlanBenefitCostComponent copy() { 2892 PlanBenefitCostComponent dst = new PlanBenefitCostComponent(); 2893 copyValues(dst); 2894 return dst; 2895 } 2896 2897 public void copyValues(PlanBenefitCostComponent dst) { 2898 super.copyValues(dst); 2899 dst.type = type == null ? null : type.copy(); 2900 dst.applicability = applicability == null ? null : applicability.copy(); 2901 if (qualifiers != null) { 2902 dst.qualifiers = new ArrayList<CodeableConcept>(); 2903 for (CodeableConcept i : qualifiers) 2904 dst.qualifiers.add(i.copy()); 2905 }; 2906 dst.value = value == null ? null : value.copy(); 2907 } 2908 2909 @Override 2910 public boolean equalsDeep(Base other_) { 2911 if (!super.equalsDeep(other_)) 2912 return false; 2913 if (!(other_ instanceof PlanBenefitCostComponent)) 2914 return false; 2915 PlanBenefitCostComponent o = (PlanBenefitCostComponent) other_; 2916 return compareDeep(type, o.type, true) && compareDeep(applicability, o.applicability, true) && compareDeep(qualifiers, o.qualifiers, true) 2917 && compareDeep(value, o.value, true); 2918 } 2919 2920 @Override 2921 public boolean equalsShallow(Base other_) { 2922 if (!super.equalsShallow(other_)) 2923 return false; 2924 if (!(other_ instanceof PlanBenefitCostComponent)) 2925 return false; 2926 PlanBenefitCostComponent o = (PlanBenefitCostComponent) other_; 2927 return true; 2928 } 2929 2930 public boolean isEmpty() { 2931 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, applicability, qualifiers 2932 , value); 2933 } 2934 2935 public String fhirType() { 2936 return "InsurancePlan.plan.specificCost.benefit.cost"; 2937 2938 } 2939 2940 } 2941 2942 /** 2943 * Business identifiers assigned to this health insurance product which remain constant as the resource is updated and propagates from server to server. 2944 */ 2945 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 2946 @Description(shortDefinition="Business Identifier for Product", formalDefinition="Business identifiers assigned to this health insurance product which remain constant as the resource is updated and propagates from server to server." ) 2947 protected List<Identifier> identifier; 2948 2949 /** 2950 * The current state of the health insurance product. 2951 */ 2952 @Child(name = "status", type = {CodeType.class}, order=1, min=0, max=1, modifier=true, summary=true) 2953 @Description(shortDefinition="draft | active | retired | unknown", formalDefinition="The current state of the health insurance product." ) 2954 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/publication-status") 2955 protected Enumeration<PublicationStatus> status; 2956 2957 /** 2958 * The kind of health insurance product. 2959 */ 2960 @Child(name = "type", type = {CodeableConcept.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 2961 @Description(shortDefinition="Kind of product", formalDefinition="The kind of health insurance product." ) 2962 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/insuranceplan-type") 2963 protected List<CodeableConcept> type; 2964 2965 /** 2966 * Official name of the health insurance product as designated by the owner. 2967 */ 2968 @Child(name = "name", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=true) 2969 @Description(shortDefinition="Official name", formalDefinition="Official name of the health insurance product as designated by the owner." ) 2970 protected StringType name; 2971 2972 /** 2973 * A list of alternate names that the product is known as, or was known as in the past. 2974 */ 2975 @Child(name = "alias", type = {StringType.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2976 @Description(shortDefinition="Alternate names", formalDefinition="A list of alternate names that the product is known as, or was known as in the past." ) 2977 protected List<StringType> alias; 2978 2979 /** 2980 * The period of time that the health insurance product is available. 2981 */ 2982 @Child(name = "period", type = {Period.class}, order=5, min=0, max=1, modifier=false, summary=false) 2983 @Description(shortDefinition="When the product is available", formalDefinition="The period of time that the health insurance product is available." ) 2984 protected Period period; 2985 2986 /** 2987 * The entity that is providing the health insurance product and underwriting the risk. This is typically an insurance carriers, other third-party payers, or health plan sponsors comonly referred to as 'payers'. 2988 */ 2989 @Child(name = "ownedBy", type = {Organization.class}, order=6, min=0, max=1, modifier=false, summary=true) 2990 @Description(shortDefinition="Plan issuer", formalDefinition="The entity that is providing the health insurance product and underwriting the risk. This is typically an insurance carriers, other third-party payers, or health plan sponsors comonly referred to as 'payers'." ) 2991 protected Reference ownedBy; 2992 2993 /** 2994 * An organization which administer other services such as underwriting, customer service and/or claims processing on behalf of the health insurance product owner. 2995 */ 2996 @Child(name = "administeredBy", type = {Organization.class}, order=7, min=0, max=1, modifier=false, summary=true) 2997 @Description(shortDefinition="Product administrator", formalDefinition="An organization which administer other services such as underwriting, customer service and/or claims processing on behalf of the health insurance product owner." ) 2998 protected Reference administeredBy; 2999 3000 /** 3001 * The geographic region in which a health insurance product's benefits apply. 3002 */ 3003 @Child(name = "coverageArea", type = {Location.class}, order=8, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 3004 @Description(shortDefinition="Where product applies", formalDefinition="The geographic region in which a health insurance product's benefits apply." ) 3005 protected List<Reference> coverageArea; 3006 3007 /** 3008 * The contact for the health insurance product for a certain purpose. 3009 */ 3010 @Child(name = "contact", type = {}, order=9, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 3011 @Description(shortDefinition="Contact for the product", formalDefinition="The contact for the health insurance product for a certain purpose." ) 3012 protected List<InsurancePlanContactComponent> contact; 3013 3014 /** 3015 * The technical endpoints providing access to services operated for the health insurance product. 3016 */ 3017 @Child(name = "endpoint", type = {Endpoint.class}, order=10, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 3018 @Description(shortDefinition="Technical endpoint", formalDefinition="The technical endpoints providing access to services operated for the health insurance product." ) 3019 protected List<Reference> endpoint; 3020 3021 /** 3022 * Reference to the network included in the health insurance product. 3023 */ 3024 @Child(name = "network", type = {Organization.class}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 3025 @Description(shortDefinition="What networks are Included", formalDefinition="Reference to the network included in the health insurance product." ) 3026 protected List<Reference> network; 3027 3028 /** 3029 * Details about the coverage offered by the insurance product. 3030 */ 3031 @Child(name = "coverage", type = {}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 3032 @Description(shortDefinition="Coverage details", formalDefinition="Details about the coverage offered by the insurance product." ) 3033 protected List<InsurancePlanCoverageComponent> coverage; 3034 3035 /** 3036 * Details about an insurance plan. 3037 */ 3038 @Child(name = "plan", type = {}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 3039 @Description(shortDefinition="Plan details", formalDefinition="Details about an insurance plan." ) 3040 protected List<InsurancePlanPlanComponent> plan; 3041 3042 private static final long serialVersionUID = -947586130L; 3043 3044 /** 3045 * Constructor 3046 */ 3047 public InsurancePlan() { 3048 super(); 3049 } 3050 3051 /** 3052 * @return {@link #identifier} (Business identifiers assigned to this health insurance product which remain constant as the resource is updated and propagates from server to server.) 3053 */ 3054 public List<Identifier> getIdentifier() { 3055 if (this.identifier == null) 3056 this.identifier = new ArrayList<Identifier>(); 3057 return this.identifier; 3058 } 3059 3060 /** 3061 * @return Returns a reference to <code>this</code> for easy method chaining 3062 */ 3063 public InsurancePlan setIdentifier(List<Identifier> theIdentifier) { 3064 this.identifier = theIdentifier; 3065 return this; 3066 } 3067 3068 public boolean hasIdentifier() { 3069 if (this.identifier == null) 3070 return false; 3071 for (Identifier item : this.identifier) 3072 if (!item.isEmpty()) 3073 return true; 3074 return false; 3075 } 3076 3077 public Identifier addIdentifier() { //3 3078 Identifier t = new Identifier(); 3079 if (this.identifier == null) 3080 this.identifier = new ArrayList<Identifier>(); 3081 this.identifier.add(t); 3082 return t; 3083 } 3084 3085 public InsurancePlan addIdentifier(Identifier t) { //3 3086 if (t == null) 3087 return this; 3088 if (this.identifier == null) 3089 this.identifier = new ArrayList<Identifier>(); 3090 this.identifier.add(t); 3091 return this; 3092 } 3093 3094 /** 3095 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist 3096 */ 3097 public Identifier getIdentifierFirstRep() { 3098 if (getIdentifier().isEmpty()) { 3099 addIdentifier(); 3100 } 3101 return getIdentifier().get(0); 3102 } 3103 3104 /** 3105 * @return {@link #status} (The current state of the health insurance product.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 3106 */ 3107 public Enumeration<PublicationStatus> getStatusElement() { 3108 if (this.status == null) 3109 if (Configuration.errorOnAutoCreate()) 3110 throw new Error("Attempt to auto-create InsurancePlan.status"); 3111 else if (Configuration.doAutoCreate()) 3112 this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); // bb 3113 return this.status; 3114 } 3115 3116 public boolean hasStatusElement() { 3117 return this.status != null && !this.status.isEmpty(); 3118 } 3119 3120 public boolean hasStatus() { 3121 return this.status != null && !this.status.isEmpty(); 3122 } 3123 3124 /** 3125 * @param value {@link #status} (The current state of the health insurance product.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 3126 */ 3127 public InsurancePlan setStatusElement(Enumeration<PublicationStatus> value) { 3128 this.status = value; 3129 return this; 3130 } 3131 3132 /** 3133 * @return The current state of the health insurance product. 3134 */ 3135 public PublicationStatus getStatus() { 3136 return this.status == null ? null : this.status.getValue(); 3137 } 3138 3139 /** 3140 * @param value The current state of the health insurance product. 3141 */ 3142 public InsurancePlan setStatus(PublicationStatus value) { 3143 if (value == null) 3144 this.status = null; 3145 else { 3146 if (this.status == null) 3147 this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); 3148 this.status.setValue(value); 3149 } 3150 return this; 3151 } 3152 3153 /** 3154 * @return {@link #type} (The kind of health insurance product.) 3155 */ 3156 public List<CodeableConcept> getType() { 3157 if (this.type == null) 3158 this.type = new ArrayList<CodeableConcept>(); 3159 return this.type; 3160 } 3161 3162 /** 3163 * @return Returns a reference to <code>this</code> for easy method chaining 3164 */ 3165 public InsurancePlan setType(List<CodeableConcept> theType) { 3166 this.type = theType; 3167 return this; 3168 } 3169 3170 public boolean hasType() { 3171 if (this.type == null) 3172 return false; 3173 for (CodeableConcept item : this.type) 3174 if (!item.isEmpty()) 3175 return true; 3176 return false; 3177 } 3178 3179 public CodeableConcept addType() { //3 3180 CodeableConcept t = new CodeableConcept(); 3181 if (this.type == null) 3182 this.type = new ArrayList<CodeableConcept>(); 3183 this.type.add(t); 3184 return t; 3185 } 3186 3187 public InsurancePlan addType(CodeableConcept t) { //3 3188 if (t == null) 3189 return this; 3190 if (this.type == null) 3191 this.type = new ArrayList<CodeableConcept>(); 3192 this.type.add(t); 3193 return this; 3194 } 3195 3196 /** 3197 * @return The first repetition of repeating field {@link #type}, creating it if it does not already exist 3198 */ 3199 public CodeableConcept getTypeFirstRep() { 3200 if (getType().isEmpty()) { 3201 addType(); 3202 } 3203 return getType().get(0); 3204 } 3205 3206 /** 3207 * @return {@link #name} (Official name of the health insurance product as designated by the owner.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 3208 */ 3209 public StringType getNameElement() { 3210 if (this.name == null) 3211 if (Configuration.errorOnAutoCreate()) 3212 throw new Error("Attempt to auto-create InsurancePlan.name"); 3213 else if (Configuration.doAutoCreate()) 3214 this.name = new StringType(); // bb 3215 return this.name; 3216 } 3217 3218 public boolean hasNameElement() { 3219 return this.name != null && !this.name.isEmpty(); 3220 } 3221 3222 public boolean hasName() { 3223 return this.name != null && !this.name.isEmpty(); 3224 } 3225 3226 /** 3227 * @param value {@link #name} (Official name of the health insurance product as designated by the owner.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 3228 */ 3229 public InsurancePlan setNameElement(StringType value) { 3230 this.name = value; 3231 return this; 3232 } 3233 3234 /** 3235 * @return Official name of the health insurance product as designated by the owner. 3236 */ 3237 public String getName() { 3238 return this.name == null ? null : this.name.getValue(); 3239 } 3240 3241 /** 3242 * @param value Official name of the health insurance product as designated by the owner. 3243 */ 3244 public InsurancePlan setName(String value) { 3245 if (Utilities.noString(value)) 3246 this.name = null; 3247 else { 3248 if (this.name == null) 3249 this.name = new StringType(); 3250 this.name.setValue(value); 3251 } 3252 return this; 3253 } 3254 3255 /** 3256 * @return {@link #alias} (A list of alternate names that the product is known as, or was known as in the past.) 3257 */ 3258 public List<StringType> getAlias() { 3259 if (this.alias == null) 3260 this.alias = new ArrayList<StringType>(); 3261 return this.alias; 3262 } 3263 3264 /** 3265 * @return Returns a reference to <code>this</code> for easy method chaining 3266 */ 3267 public InsurancePlan setAlias(List<StringType> theAlias) { 3268 this.alias = theAlias; 3269 return this; 3270 } 3271 3272 public boolean hasAlias() { 3273 if (this.alias == null) 3274 return false; 3275 for (StringType item : this.alias) 3276 if (!item.isEmpty()) 3277 return true; 3278 return false; 3279 } 3280 3281 /** 3282 * @return {@link #alias} (A list of alternate names that the product is known as, or was known as in the past.) 3283 */ 3284 public StringType addAliasElement() {//2 3285 StringType t = new StringType(); 3286 if (this.alias == null) 3287 this.alias = new ArrayList<StringType>(); 3288 this.alias.add(t); 3289 return t; 3290 } 3291 3292 /** 3293 * @param value {@link #alias} (A list of alternate names that the product is known as, or was known as in the past.) 3294 */ 3295 public InsurancePlan addAlias(String value) { //1 3296 StringType t = new StringType(); 3297 t.setValue(value); 3298 if (this.alias == null) 3299 this.alias = new ArrayList<StringType>(); 3300 this.alias.add(t); 3301 return this; 3302 } 3303 3304 /** 3305 * @param value {@link #alias} (A list of alternate names that the product is known as, or was known as in the past.) 3306 */ 3307 public boolean hasAlias(String value) { 3308 if (this.alias == null) 3309 return false; 3310 for (StringType v : this.alias) 3311 if (v.getValue().equals(value)) // string 3312 return true; 3313 return false; 3314 } 3315 3316 /** 3317 * @return {@link #period} (The period of time that the health insurance product is available.) 3318 */ 3319 public Period getPeriod() { 3320 if (this.period == null) 3321 if (Configuration.errorOnAutoCreate()) 3322 throw new Error("Attempt to auto-create InsurancePlan.period"); 3323 else if (Configuration.doAutoCreate()) 3324 this.period = new Period(); // cc 3325 return this.period; 3326 } 3327 3328 public boolean hasPeriod() { 3329 return this.period != null && !this.period.isEmpty(); 3330 } 3331 3332 /** 3333 * @param value {@link #period} (The period of time that the health insurance product is available.) 3334 */ 3335 public InsurancePlan setPeriod(Period value) { 3336 this.period = value; 3337 return this; 3338 } 3339 3340 /** 3341 * @return {@link #ownedBy} (The entity that is providing the health insurance product and underwriting the risk. This is typically an insurance carriers, other third-party payers, or health plan sponsors comonly referred to as 'payers'.) 3342 */ 3343 public Reference getOwnedBy() { 3344 if (this.ownedBy == null) 3345 if (Configuration.errorOnAutoCreate()) 3346 throw new Error("Attempt to auto-create InsurancePlan.ownedBy"); 3347 else if (Configuration.doAutoCreate()) 3348 this.ownedBy = new Reference(); // cc 3349 return this.ownedBy; 3350 } 3351 3352 public boolean hasOwnedBy() { 3353 return this.ownedBy != null && !this.ownedBy.isEmpty(); 3354 } 3355 3356 /** 3357 * @param value {@link #ownedBy} (The entity that is providing the health insurance product and underwriting the risk. This is typically an insurance carriers, other third-party payers, or health plan sponsors comonly referred to as 'payers'.) 3358 */ 3359 public InsurancePlan setOwnedBy(Reference value) { 3360 this.ownedBy = value; 3361 return this; 3362 } 3363 3364 /** 3365 * @return {@link #administeredBy} (An organization which administer other services such as underwriting, customer service and/or claims processing on behalf of the health insurance product owner.) 3366 */ 3367 public Reference getAdministeredBy() { 3368 if (this.administeredBy == null) 3369 if (Configuration.errorOnAutoCreate()) 3370 throw new Error("Attempt to auto-create InsurancePlan.administeredBy"); 3371 else if (Configuration.doAutoCreate()) 3372 this.administeredBy = new Reference(); // cc 3373 return this.administeredBy; 3374 } 3375 3376 public boolean hasAdministeredBy() { 3377 return this.administeredBy != null && !this.administeredBy.isEmpty(); 3378 } 3379 3380 /** 3381 * @param value {@link #administeredBy} (An organization which administer other services such as underwriting, customer service and/or claims processing on behalf of the health insurance product owner.) 3382 */ 3383 public InsurancePlan setAdministeredBy(Reference value) { 3384 this.administeredBy = value; 3385 return this; 3386 } 3387 3388 /** 3389 * @return {@link #coverageArea} (The geographic region in which a health insurance product's benefits apply.) 3390 */ 3391 public List<Reference> getCoverageArea() { 3392 if (this.coverageArea == null) 3393 this.coverageArea = new ArrayList<Reference>(); 3394 return this.coverageArea; 3395 } 3396 3397 /** 3398 * @return Returns a reference to <code>this</code> for easy method chaining 3399 */ 3400 public InsurancePlan setCoverageArea(List<Reference> theCoverageArea) { 3401 this.coverageArea = theCoverageArea; 3402 return this; 3403 } 3404 3405 public boolean hasCoverageArea() { 3406 if (this.coverageArea == null) 3407 return false; 3408 for (Reference item : this.coverageArea) 3409 if (!item.isEmpty()) 3410 return true; 3411 return false; 3412 } 3413 3414 public Reference addCoverageArea() { //3 3415 Reference t = new Reference(); 3416 if (this.coverageArea == null) 3417 this.coverageArea = new ArrayList<Reference>(); 3418 this.coverageArea.add(t); 3419 return t; 3420 } 3421 3422 public InsurancePlan addCoverageArea(Reference t) { //3 3423 if (t == null) 3424 return this; 3425 if (this.coverageArea == null) 3426 this.coverageArea = new ArrayList<Reference>(); 3427 this.coverageArea.add(t); 3428 return this; 3429 } 3430 3431 /** 3432 * @return The first repetition of repeating field {@link #coverageArea}, creating it if it does not already exist 3433 */ 3434 public Reference getCoverageAreaFirstRep() { 3435 if (getCoverageArea().isEmpty()) { 3436 addCoverageArea(); 3437 } 3438 return getCoverageArea().get(0); 3439 } 3440 3441 /** 3442 * @return {@link #contact} (The contact for the health insurance product for a certain purpose.) 3443 */ 3444 public List<InsurancePlanContactComponent> getContact() { 3445 if (this.contact == null) 3446 this.contact = new ArrayList<InsurancePlanContactComponent>(); 3447 return this.contact; 3448 } 3449 3450 /** 3451 * @return Returns a reference to <code>this</code> for easy method chaining 3452 */ 3453 public InsurancePlan setContact(List<InsurancePlanContactComponent> theContact) { 3454 this.contact = theContact; 3455 return this; 3456 } 3457 3458 public boolean hasContact() { 3459 if (this.contact == null) 3460 return false; 3461 for (InsurancePlanContactComponent item : this.contact) 3462 if (!item.isEmpty()) 3463 return true; 3464 return false; 3465 } 3466 3467 public InsurancePlanContactComponent addContact() { //3 3468 InsurancePlanContactComponent t = new InsurancePlanContactComponent(); 3469 if (this.contact == null) 3470 this.contact = new ArrayList<InsurancePlanContactComponent>(); 3471 this.contact.add(t); 3472 return t; 3473 } 3474 3475 public InsurancePlan addContact(InsurancePlanContactComponent t) { //3 3476 if (t == null) 3477 return this; 3478 if (this.contact == null) 3479 this.contact = new ArrayList<InsurancePlanContactComponent>(); 3480 this.contact.add(t); 3481 return this; 3482 } 3483 3484 /** 3485 * @return The first repetition of repeating field {@link #contact}, creating it if it does not already exist 3486 */ 3487 public InsurancePlanContactComponent getContactFirstRep() { 3488 if (getContact().isEmpty()) { 3489 addContact(); 3490 } 3491 return getContact().get(0); 3492 } 3493 3494 /** 3495 * @return {@link #endpoint} (The technical endpoints providing access to services operated for the health insurance product.) 3496 */ 3497 public List<Reference> getEndpoint() { 3498 if (this.endpoint == null) 3499 this.endpoint = new ArrayList<Reference>(); 3500 return this.endpoint; 3501 } 3502 3503 /** 3504 * @return Returns a reference to <code>this</code> for easy method chaining 3505 */ 3506 public InsurancePlan setEndpoint(List<Reference> theEndpoint) { 3507 this.endpoint = theEndpoint; 3508 return this; 3509 } 3510 3511 public boolean hasEndpoint() { 3512 if (this.endpoint == null) 3513 return false; 3514 for (Reference item : this.endpoint) 3515 if (!item.isEmpty()) 3516 return true; 3517 return false; 3518 } 3519 3520 public Reference addEndpoint() { //3 3521 Reference t = new Reference(); 3522 if (this.endpoint == null) 3523 this.endpoint = new ArrayList<Reference>(); 3524 this.endpoint.add(t); 3525 return t; 3526 } 3527 3528 public InsurancePlan addEndpoint(Reference t) { //3 3529 if (t == null) 3530 return this; 3531 if (this.endpoint == null) 3532 this.endpoint = new ArrayList<Reference>(); 3533 this.endpoint.add(t); 3534 return this; 3535 } 3536 3537 /** 3538 * @return The first repetition of repeating field {@link #endpoint}, creating it if it does not already exist 3539 */ 3540 public Reference getEndpointFirstRep() { 3541 if (getEndpoint().isEmpty()) { 3542 addEndpoint(); 3543 } 3544 return getEndpoint().get(0); 3545 } 3546 3547 /** 3548 * @return {@link #network} (Reference to the network included in the health insurance product.) 3549 */ 3550 public List<Reference> getNetwork() { 3551 if (this.network == null) 3552 this.network = new ArrayList<Reference>(); 3553 return this.network; 3554 } 3555 3556 /** 3557 * @return Returns a reference to <code>this</code> for easy method chaining 3558 */ 3559 public InsurancePlan setNetwork(List<Reference> theNetwork) { 3560 this.network = theNetwork; 3561 return this; 3562 } 3563 3564 public boolean hasNetwork() { 3565 if (this.network == null) 3566 return false; 3567 for (Reference item : this.network) 3568 if (!item.isEmpty()) 3569 return true; 3570 return false; 3571 } 3572 3573 public Reference addNetwork() { //3 3574 Reference t = new Reference(); 3575 if (this.network == null) 3576 this.network = new ArrayList<Reference>(); 3577 this.network.add(t); 3578 return t; 3579 } 3580 3581 public InsurancePlan addNetwork(Reference t) { //3 3582 if (t == null) 3583 return this; 3584 if (this.network == null) 3585 this.network = new ArrayList<Reference>(); 3586 this.network.add(t); 3587 return this; 3588 } 3589 3590 /** 3591 * @return The first repetition of repeating field {@link #network}, creating it if it does not already exist 3592 */ 3593 public Reference getNetworkFirstRep() { 3594 if (getNetwork().isEmpty()) { 3595 addNetwork(); 3596 } 3597 return getNetwork().get(0); 3598 } 3599 3600 /** 3601 * @return {@link #coverage} (Details about the coverage offered by the insurance product.) 3602 */ 3603 public List<InsurancePlanCoverageComponent> getCoverage() { 3604 if (this.coverage == null) 3605 this.coverage = new ArrayList<InsurancePlanCoverageComponent>(); 3606 return this.coverage; 3607 } 3608 3609 /** 3610 * @return Returns a reference to <code>this</code> for easy method chaining 3611 */ 3612 public InsurancePlan setCoverage(List<InsurancePlanCoverageComponent> theCoverage) { 3613 this.coverage = theCoverage; 3614 return this; 3615 } 3616 3617 public boolean hasCoverage() { 3618 if (this.coverage == null) 3619 return false; 3620 for (InsurancePlanCoverageComponent item : this.coverage) 3621 if (!item.isEmpty()) 3622 return true; 3623 return false; 3624 } 3625 3626 public InsurancePlanCoverageComponent addCoverage() { //3 3627 InsurancePlanCoverageComponent t = new InsurancePlanCoverageComponent(); 3628 if (this.coverage == null) 3629 this.coverage = new ArrayList<InsurancePlanCoverageComponent>(); 3630 this.coverage.add(t); 3631 return t; 3632 } 3633 3634 public InsurancePlan addCoverage(InsurancePlanCoverageComponent t) { //3 3635 if (t == null) 3636 return this; 3637 if (this.coverage == null) 3638 this.coverage = new ArrayList<InsurancePlanCoverageComponent>(); 3639 this.coverage.add(t); 3640 return this; 3641 } 3642 3643 /** 3644 * @return The first repetition of repeating field {@link #coverage}, creating it if it does not already exist 3645 */ 3646 public InsurancePlanCoverageComponent getCoverageFirstRep() { 3647 if (getCoverage().isEmpty()) { 3648 addCoverage(); 3649 } 3650 return getCoverage().get(0); 3651 } 3652 3653 /** 3654 * @return {@link #plan} (Details about an insurance plan.) 3655 */ 3656 public List<InsurancePlanPlanComponent> getPlan() { 3657 if (this.plan == null) 3658 this.plan = new ArrayList<InsurancePlanPlanComponent>(); 3659 return this.plan; 3660 } 3661 3662 /** 3663 * @return Returns a reference to <code>this</code> for easy method chaining 3664 */ 3665 public InsurancePlan setPlan(List<InsurancePlanPlanComponent> thePlan) { 3666 this.plan = thePlan; 3667 return this; 3668 } 3669 3670 public boolean hasPlan() { 3671 if (this.plan == null) 3672 return false; 3673 for (InsurancePlanPlanComponent item : this.plan) 3674 if (!item.isEmpty()) 3675 return true; 3676 return false; 3677 } 3678 3679 public InsurancePlanPlanComponent addPlan() { //3 3680 InsurancePlanPlanComponent t = new InsurancePlanPlanComponent(); 3681 if (this.plan == null) 3682 this.plan = new ArrayList<InsurancePlanPlanComponent>(); 3683 this.plan.add(t); 3684 return t; 3685 } 3686 3687 public InsurancePlan addPlan(InsurancePlanPlanComponent t) { //3 3688 if (t == null) 3689 return this; 3690 if (this.plan == null) 3691 this.plan = new ArrayList<InsurancePlanPlanComponent>(); 3692 this.plan.add(t); 3693 return this; 3694 } 3695 3696 /** 3697 * @return The first repetition of repeating field {@link #plan}, creating it if it does not already exist 3698 */ 3699 public InsurancePlanPlanComponent getPlanFirstRep() { 3700 if (getPlan().isEmpty()) { 3701 addPlan(); 3702 } 3703 return getPlan().get(0); 3704 } 3705 3706 protected void listChildren(List<Property> children) { 3707 super.listChildren(children); 3708 children.add(new Property("identifier", "Identifier", "Business identifiers assigned to this health insurance product which remain constant as the resource is updated and propagates from server to server.", 0, java.lang.Integer.MAX_VALUE, identifier)); 3709 children.add(new Property("status", "code", "The current state of the health insurance product.", 0, 1, status)); 3710 children.add(new Property("type", "CodeableConcept", "The kind of health insurance product.", 0, java.lang.Integer.MAX_VALUE, type)); 3711 children.add(new Property("name", "string", "Official name of the health insurance product as designated by the owner.", 0, 1, name)); 3712 children.add(new Property("alias", "string", "A list of alternate names that the product is known as, or was known as in the past.", 0, java.lang.Integer.MAX_VALUE, alias)); 3713 children.add(new Property("period", "Period", "The period of time that the health insurance product is available.", 0, 1, period)); 3714 children.add(new Property("ownedBy", "Reference(Organization)", "The entity that is providing the health insurance product and underwriting the risk. This is typically an insurance carriers, other third-party payers, or health plan sponsors comonly referred to as 'payers'.", 0, 1, ownedBy)); 3715 children.add(new Property("administeredBy", "Reference(Organization)", "An organization which administer other services such as underwriting, customer service and/or claims processing on behalf of the health insurance product owner.", 0, 1, administeredBy)); 3716 children.add(new Property("coverageArea", "Reference(Location)", "The geographic region in which a health insurance product's benefits apply.", 0, java.lang.Integer.MAX_VALUE, coverageArea)); 3717 children.add(new Property("contact", "", "The contact for the health insurance product for a certain purpose.", 0, java.lang.Integer.MAX_VALUE, contact)); 3718 children.add(new Property("endpoint", "Reference(Endpoint)", "The technical endpoints providing access to services operated for the health insurance product.", 0, java.lang.Integer.MAX_VALUE, endpoint)); 3719 children.add(new Property("network", "Reference(Organization)", "Reference to the network included in the health insurance product.", 0, java.lang.Integer.MAX_VALUE, network)); 3720 children.add(new Property("coverage", "", "Details about the coverage offered by the insurance product.", 0, java.lang.Integer.MAX_VALUE, coverage)); 3721 children.add(new Property("plan", "", "Details about an insurance plan.", 0, java.lang.Integer.MAX_VALUE, plan)); 3722 } 3723 3724 @Override 3725 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 3726 switch (_hash) { 3727 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "Business identifiers assigned to this health insurance product which remain constant as the resource is updated and propagates from server to server.", 0, java.lang.Integer.MAX_VALUE, identifier); 3728 case -892481550: /*status*/ return new Property("status", "code", "The current state of the health insurance product.", 0, 1, status); 3729 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The kind of health insurance product.", 0, java.lang.Integer.MAX_VALUE, type); 3730 case 3373707: /*name*/ return new Property("name", "string", "Official name of the health insurance product as designated by the owner.", 0, 1, name); 3731 case 92902992: /*alias*/ return new Property("alias", "string", "A list of alternate names that the product is known as, or was known as in the past.", 0, java.lang.Integer.MAX_VALUE, alias); 3732 case -991726143: /*period*/ return new Property("period", "Period", "The period of time that the health insurance product is available.", 0, 1, period); 3733 case -1054743076: /*ownedBy*/ return new Property("ownedBy", "Reference(Organization)", "The entity that is providing the health insurance product and underwriting the risk. This is typically an insurance carriers, other third-party payers, or health plan sponsors comonly referred to as 'payers'.", 0, 1, ownedBy); 3734 case 898770462: /*administeredBy*/ return new Property("administeredBy", "Reference(Organization)", "An organization which administer other services such as underwriting, customer service and/or claims processing on behalf of the health insurance product owner.", 0, 1, administeredBy); 3735 case -1532328299: /*coverageArea*/ return new Property("coverageArea", "Reference(Location)", "The geographic region in which a health insurance product's benefits apply.", 0, java.lang.Integer.MAX_VALUE, coverageArea); 3736 case 951526432: /*contact*/ return new Property("contact", "", "The contact for the health insurance product for a certain purpose.", 0, java.lang.Integer.MAX_VALUE, contact); 3737 case 1741102485: /*endpoint*/ return new Property("endpoint", "Reference(Endpoint)", "The technical endpoints providing access to services operated for the health insurance product.", 0, java.lang.Integer.MAX_VALUE, endpoint); 3738 case 1843485230: /*network*/ return new Property("network", "Reference(Organization)", "Reference to the network included in the health insurance product.", 0, java.lang.Integer.MAX_VALUE, network); 3739 case -351767064: /*coverage*/ return new Property("coverage", "", "Details about the coverage offered by the insurance product.", 0, java.lang.Integer.MAX_VALUE, coverage); 3740 case 3443497: /*plan*/ return new Property("plan", "", "Details about an insurance plan.", 0, java.lang.Integer.MAX_VALUE, plan); 3741 default: return super.getNamedProperty(_hash, _name, _checkValid); 3742 } 3743 3744 } 3745 3746 @Override 3747 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 3748 switch (hash) { 3749 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 3750 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<PublicationStatus> 3751 case 3575610: /*type*/ return this.type == null ? new Base[0] : this.type.toArray(new Base[this.type.size()]); // CodeableConcept 3752 case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType 3753 case 92902992: /*alias*/ return this.alias == null ? new Base[0] : this.alias.toArray(new Base[this.alias.size()]); // StringType 3754 case -991726143: /*period*/ return this.period == null ? new Base[0] : new Base[] {this.period}; // Period 3755 case -1054743076: /*ownedBy*/ return this.ownedBy == null ? new Base[0] : new Base[] {this.ownedBy}; // Reference 3756 case 898770462: /*administeredBy*/ return this.administeredBy == null ? new Base[0] : new Base[] {this.administeredBy}; // Reference 3757 case -1532328299: /*coverageArea*/ return this.coverageArea == null ? new Base[0] : this.coverageArea.toArray(new Base[this.coverageArea.size()]); // Reference 3758 case 951526432: /*contact*/ return this.contact == null ? new Base[0] : this.contact.toArray(new Base[this.contact.size()]); // InsurancePlanContactComponent 3759 case 1741102485: /*endpoint*/ return this.endpoint == null ? new Base[0] : this.endpoint.toArray(new Base[this.endpoint.size()]); // Reference 3760 case 1843485230: /*network*/ return this.network == null ? new Base[0] : this.network.toArray(new Base[this.network.size()]); // Reference 3761 case -351767064: /*coverage*/ return this.coverage == null ? new Base[0] : this.coverage.toArray(new Base[this.coverage.size()]); // InsurancePlanCoverageComponent 3762 case 3443497: /*plan*/ return this.plan == null ? new Base[0] : this.plan.toArray(new Base[this.plan.size()]); // InsurancePlanPlanComponent 3763 default: return super.getProperty(hash, name, checkValid); 3764 } 3765 3766 } 3767 3768 @Override 3769 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3770 switch (hash) { 3771 case -1618432855: // identifier 3772 this.getIdentifier().add(castToIdentifier(value)); // Identifier 3773 return value; 3774 case -892481550: // status 3775 value = new PublicationStatusEnumFactory().fromType(castToCode(value)); 3776 this.status = (Enumeration) value; // Enumeration<PublicationStatus> 3777 return value; 3778 case 3575610: // type 3779 this.getType().add(castToCodeableConcept(value)); // CodeableConcept 3780 return value; 3781 case 3373707: // name 3782 this.name = castToString(value); // StringType 3783 return value; 3784 case 92902992: // alias 3785 this.getAlias().add(castToString(value)); // StringType 3786 return value; 3787 case -991726143: // period 3788 this.period = castToPeriod(value); // Period 3789 return value; 3790 case -1054743076: // ownedBy 3791 this.ownedBy = castToReference(value); // Reference 3792 return value; 3793 case 898770462: // administeredBy 3794 this.administeredBy = castToReference(value); // Reference 3795 return value; 3796 case -1532328299: // coverageArea 3797 this.getCoverageArea().add(castToReference(value)); // Reference 3798 return value; 3799 case 951526432: // contact 3800 this.getContact().add((InsurancePlanContactComponent) value); // InsurancePlanContactComponent 3801 return value; 3802 case 1741102485: // endpoint 3803 this.getEndpoint().add(castToReference(value)); // Reference 3804 return value; 3805 case 1843485230: // network 3806 this.getNetwork().add(castToReference(value)); // Reference 3807 return value; 3808 case -351767064: // coverage 3809 this.getCoverage().add((InsurancePlanCoverageComponent) value); // InsurancePlanCoverageComponent 3810 return value; 3811 case 3443497: // plan 3812 this.getPlan().add((InsurancePlanPlanComponent) value); // InsurancePlanPlanComponent 3813 return value; 3814 default: return super.setProperty(hash, name, value); 3815 } 3816 3817 } 3818 3819 @Override 3820 public Base setProperty(String name, Base value) throws FHIRException { 3821 if (name.equals("identifier")) { 3822 this.getIdentifier().add(castToIdentifier(value)); 3823 } else if (name.equals("status")) { 3824 value = new PublicationStatusEnumFactory().fromType(castToCode(value)); 3825 this.status = (Enumeration) value; // Enumeration<PublicationStatus> 3826 } else if (name.equals("type")) { 3827 this.getType().add(castToCodeableConcept(value)); 3828 } else if (name.equals("name")) { 3829 this.name = castToString(value); // StringType 3830 } else if (name.equals("alias")) { 3831 this.getAlias().add(castToString(value)); 3832 } else if (name.equals("period")) { 3833 this.period = castToPeriod(value); // Period 3834 } else if (name.equals("ownedBy")) { 3835 this.ownedBy = castToReference(value); // Reference 3836 } else if (name.equals("administeredBy")) { 3837 this.administeredBy = castToReference(value); // Reference 3838 } else if (name.equals("coverageArea")) { 3839 this.getCoverageArea().add(castToReference(value)); 3840 } else if (name.equals("contact")) { 3841 this.getContact().add((InsurancePlanContactComponent) value); 3842 } else if (name.equals("endpoint")) { 3843 this.getEndpoint().add(castToReference(value)); 3844 } else if (name.equals("network")) { 3845 this.getNetwork().add(castToReference(value)); 3846 } else if (name.equals("coverage")) { 3847 this.getCoverage().add((InsurancePlanCoverageComponent) value); 3848 } else if (name.equals("plan")) { 3849 this.getPlan().add((InsurancePlanPlanComponent) value); 3850 } else 3851 return super.setProperty(name, value); 3852 return value; 3853 } 3854 3855 @Override 3856 public Base makeProperty(int hash, String name) throws FHIRException { 3857 switch (hash) { 3858 case -1618432855: return addIdentifier(); 3859 case -892481550: return getStatusElement(); 3860 case 3575610: return addType(); 3861 case 3373707: return getNameElement(); 3862 case 92902992: return addAliasElement(); 3863 case -991726143: return getPeriod(); 3864 case -1054743076: return getOwnedBy(); 3865 case 898770462: return getAdministeredBy(); 3866 case -1532328299: return addCoverageArea(); 3867 case 951526432: return addContact(); 3868 case 1741102485: return addEndpoint(); 3869 case 1843485230: return addNetwork(); 3870 case -351767064: return addCoverage(); 3871 case 3443497: return addPlan(); 3872 default: return super.makeProperty(hash, name); 3873 } 3874 3875 } 3876 3877 @Override 3878 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 3879 switch (hash) { 3880 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 3881 case -892481550: /*status*/ return new String[] {"code"}; 3882 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 3883 case 3373707: /*name*/ return new String[] {"string"}; 3884 case 92902992: /*alias*/ return new String[] {"string"}; 3885 case -991726143: /*period*/ return new String[] {"Period"}; 3886 case -1054743076: /*ownedBy*/ return new String[] {"Reference"}; 3887 case 898770462: /*administeredBy*/ return new String[] {"Reference"}; 3888 case -1532328299: /*coverageArea*/ return new String[] {"Reference"}; 3889 case 951526432: /*contact*/ return new String[] {}; 3890 case 1741102485: /*endpoint*/ return new String[] {"Reference"}; 3891 case 1843485230: /*network*/ return new String[] {"Reference"}; 3892 case -351767064: /*coverage*/ return new String[] {}; 3893 case 3443497: /*plan*/ return new String[] {}; 3894 default: return super.getTypesForProperty(hash, name); 3895 } 3896 3897 } 3898 3899 @Override 3900 public Base addChild(String name) throws FHIRException { 3901 if (name.equals("identifier")) { 3902 return addIdentifier(); 3903 } 3904 else if (name.equals("status")) { 3905 throw new FHIRException("Cannot call addChild on a primitive type InsurancePlan.status"); 3906 } 3907 else if (name.equals("type")) { 3908 return addType(); 3909 } 3910 else if (name.equals("name")) { 3911 throw new FHIRException("Cannot call addChild on a primitive type InsurancePlan.name"); 3912 } 3913 else if (name.equals("alias")) { 3914 throw new FHIRException("Cannot call addChild on a primitive type InsurancePlan.alias"); 3915 } 3916 else if (name.equals("period")) { 3917 this.period = new Period(); 3918 return this.period; 3919 } 3920 else if (name.equals("ownedBy")) { 3921 this.ownedBy = new Reference(); 3922 return this.ownedBy; 3923 } 3924 else if (name.equals("administeredBy")) { 3925 this.administeredBy = new Reference(); 3926 return this.administeredBy; 3927 } 3928 else if (name.equals("coverageArea")) { 3929 return addCoverageArea(); 3930 } 3931 else if (name.equals("contact")) { 3932 return addContact(); 3933 } 3934 else if (name.equals("endpoint")) { 3935 return addEndpoint(); 3936 } 3937 else if (name.equals("network")) { 3938 return addNetwork(); 3939 } 3940 else if (name.equals("coverage")) { 3941 return addCoverage(); 3942 } 3943 else if (name.equals("plan")) { 3944 return addPlan(); 3945 } 3946 else 3947 return super.addChild(name); 3948 } 3949 3950 public String fhirType() { 3951 return "InsurancePlan"; 3952 3953 } 3954 3955 public InsurancePlan copy() { 3956 InsurancePlan dst = new InsurancePlan(); 3957 copyValues(dst); 3958 return dst; 3959 } 3960 3961 public void copyValues(InsurancePlan dst) { 3962 super.copyValues(dst); 3963 if (identifier != null) { 3964 dst.identifier = new ArrayList<Identifier>(); 3965 for (Identifier i : identifier) 3966 dst.identifier.add(i.copy()); 3967 }; 3968 dst.status = status == null ? null : status.copy(); 3969 if (type != null) { 3970 dst.type = new ArrayList<CodeableConcept>(); 3971 for (CodeableConcept i : type) 3972 dst.type.add(i.copy()); 3973 }; 3974 dst.name = name == null ? null : name.copy(); 3975 if (alias != null) { 3976 dst.alias = new ArrayList<StringType>(); 3977 for (StringType i : alias) 3978 dst.alias.add(i.copy()); 3979 }; 3980 dst.period = period == null ? null : period.copy(); 3981 dst.ownedBy = ownedBy == null ? null : ownedBy.copy(); 3982 dst.administeredBy = administeredBy == null ? null : administeredBy.copy(); 3983 if (coverageArea != null) { 3984 dst.coverageArea = new ArrayList<Reference>(); 3985 for (Reference i : coverageArea) 3986 dst.coverageArea.add(i.copy()); 3987 }; 3988 if (contact != null) { 3989 dst.contact = new ArrayList<InsurancePlanContactComponent>(); 3990 for (InsurancePlanContactComponent i : contact) 3991 dst.contact.add(i.copy()); 3992 }; 3993 if (endpoint != null) { 3994 dst.endpoint = new ArrayList<Reference>(); 3995 for (Reference i : endpoint) 3996 dst.endpoint.add(i.copy()); 3997 }; 3998 if (network != null) { 3999 dst.network = new ArrayList<Reference>(); 4000 for (Reference i : network) 4001 dst.network.add(i.copy()); 4002 }; 4003 if (coverage != null) { 4004 dst.coverage = new ArrayList<InsurancePlanCoverageComponent>(); 4005 for (InsurancePlanCoverageComponent i : coverage) 4006 dst.coverage.add(i.copy()); 4007 }; 4008 if (plan != null) { 4009 dst.plan = new ArrayList<InsurancePlanPlanComponent>(); 4010 for (InsurancePlanPlanComponent i : plan) 4011 dst.plan.add(i.copy()); 4012 }; 4013 } 4014 4015 protected InsurancePlan typedCopy() { 4016 return copy(); 4017 } 4018 4019 @Override 4020 public boolean equalsDeep(Base other_) { 4021 if (!super.equalsDeep(other_)) 4022 return false; 4023 if (!(other_ instanceof InsurancePlan)) 4024 return false; 4025 InsurancePlan o = (InsurancePlan) other_; 4026 return compareDeep(identifier, o.identifier, true) && compareDeep(status, o.status, true) && compareDeep(type, o.type, true) 4027 && compareDeep(name, o.name, true) && compareDeep(alias, o.alias, true) && compareDeep(period, o.period, true) 4028 && compareDeep(ownedBy, o.ownedBy, true) && compareDeep(administeredBy, o.administeredBy, true) 4029 && compareDeep(coverageArea, o.coverageArea, true) && compareDeep(contact, o.contact, true) && compareDeep(endpoint, o.endpoint, true) 4030 && compareDeep(network, o.network, true) && compareDeep(coverage, o.coverage, true) && compareDeep(plan, o.plan, true) 4031 ; 4032 } 4033 4034 @Override 4035 public boolean equalsShallow(Base other_) { 4036 if (!super.equalsShallow(other_)) 4037 return false; 4038 if (!(other_ instanceof InsurancePlan)) 4039 return false; 4040 InsurancePlan o = (InsurancePlan) other_; 4041 return compareValues(status, o.status, true) && compareValues(name, o.name, true) && compareValues(alias, o.alias, true) 4042 ; 4043 } 4044 4045 public boolean isEmpty() { 4046 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, status, type 4047 , name, alias, period, ownedBy, administeredBy, coverageArea, contact, endpoint 4048 , network, coverage, plan); 4049 } 4050 4051 @Override 4052 public ResourceType getResourceType() { 4053 return ResourceType.InsurancePlan; 4054 } 4055 4056 /** 4057 * Search parameter: <b>identifier</b> 4058 * <p> 4059 * Description: <b>Any identifier for the organization (not the accreditation issuer's identifier)</b><br> 4060 * Type: <b>token</b><br> 4061 * Path: <b>InsurancePlan.identifier</b><br> 4062 * </p> 4063 */ 4064 @SearchParamDefinition(name="identifier", path="InsurancePlan.identifier", description="Any identifier for the organization (not the accreditation issuer's identifier)", type="token" ) 4065 public static final String SP_IDENTIFIER = "identifier"; 4066 /** 4067 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 4068 * <p> 4069 * Description: <b>Any identifier for the organization (not the accreditation issuer's identifier)</b><br> 4070 * Type: <b>token</b><br> 4071 * Path: <b>InsurancePlan.identifier</b><br> 4072 * </p> 4073 */ 4074 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 4075 4076 /** 4077 * Search parameter: <b>address</b> 4078 * <p> 4079 * 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> 4080 * Type: <b>string</b><br> 4081 * Path: <b>InsurancePlan.contact.address</b><br> 4082 * </p> 4083 */ 4084 @SearchParamDefinition(name="address", path="InsurancePlan.contact.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" ) 4085 public static final String SP_ADDRESS = "address"; 4086 /** 4087 * <b>Fluent Client</b> search parameter constant for <b>address</b> 4088 * <p> 4089 * 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> 4090 * Type: <b>string</b><br> 4091 * Path: <b>InsurancePlan.contact.address</b><br> 4092 * </p> 4093 */ 4094 public static final ca.uhn.fhir.rest.gclient.StringClientParam ADDRESS = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ADDRESS); 4095 4096 /** 4097 * Search parameter: <b>address-state</b> 4098 * <p> 4099 * Description: <b>A state specified in an address</b><br> 4100 * Type: <b>string</b><br> 4101 * Path: <b>InsurancePlan.contact.address.state</b><br> 4102 * </p> 4103 */ 4104 @SearchParamDefinition(name="address-state", path="InsurancePlan.contact.address.state", description="A state specified in an address", type="string" ) 4105 public static final String SP_ADDRESS_STATE = "address-state"; 4106 /** 4107 * <b>Fluent Client</b> search parameter constant for <b>address-state</b> 4108 * <p> 4109 * Description: <b>A state specified in an address</b><br> 4110 * Type: <b>string</b><br> 4111 * Path: <b>InsurancePlan.contact.address.state</b><br> 4112 * </p> 4113 */ 4114 public static final ca.uhn.fhir.rest.gclient.StringClientParam ADDRESS_STATE = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ADDRESS_STATE); 4115 4116 /** 4117 * Search parameter: <b>owned-by</b> 4118 * <p> 4119 * Description: <b>An organization of which this organization forms a part</b><br> 4120 * Type: <b>reference</b><br> 4121 * Path: <b>InsurancePlan.ownedBy</b><br> 4122 * </p> 4123 */ 4124 @SearchParamDefinition(name="owned-by", path="InsurancePlan.ownedBy", description="An organization of which this organization forms a part", type="reference", target={Organization.class } ) 4125 public static final String SP_OWNED_BY = "owned-by"; 4126 /** 4127 * <b>Fluent Client</b> search parameter constant for <b>owned-by</b> 4128 * <p> 4129 * Description: <b>An organization of which this organization forms a part</b><br> 4130 * Type: <b>reference</b><br> 4131 * Path: <b>InsurancePlan.ownedBy</b><br> 4132 * </p> 4133 */ 4134 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam OWNED_BY = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_OWNED_BY); 4135 4136/** 4137 * Constant for fluent queries to be used to add include statements. Specifies 4138 * the path value of "<b>InsurancePlan:owned-by</b>". 4139 */ 4140 public static final ca.uhn.fhir.model.api.Include INCLUDE_OWNED_BY = new ca.uhn.fhir.model.api.Include("InsurancePlan:owned-by").toLocked(); 4141 4142 /** 4143 * Search parameter: <b>type</b> 4144 * <p> 4145 * Description: <b>A code for the type of organization</b><br> 4146 * Type: <b>token</b><br> 4147 * Path: <b>InsurancePlan.type</b><br> 4148 * </p> 4149 */ 4150 @SearchParamDefinition(name="type", path="InsurancePlan.type", description="A code for the type of organization", type="token" ) 4151 public static final String SP_TYPE = "type"; 4152 /** 4153 * <b>Fluent Client</b> search parameter constant for <b>type</b> 4154 * <p> 4155 * Description: <b>A code for the type of organization</b><br> 4156 * Type: <b>token</b><br> 4157 * Path: <b>InsurancePlan.type</b><br> 4158 * </p> 4159 */ 4160 public static final ca.uhn.fhir.rest.gclient.TokenClientParam TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_TYPE); 4161 4162 /** 4163 * Search parameter: <b>address-postalcode</b> 4164 * <p> 4165 * Description: <b>A postal code specified in an address</b><br> 4166 * Type: <b>string</b><br> 4167 * Path: <b>InsurancePlan.contact.address.postalCode</b><br> 4168 * </p> 4169 */ 4170 @SearchParamDefinition(name="address-postalcode", path="InsurancePlan.contact.address.postalCode", description="A postal code specified in an address", type="string" ) 4171 public static final String SP_ADDRESS_POSTALCODE = "address-postalcode"; 4172 /** 4173 * <b>Fluent Client</b> search parameter constant for <b>address-postalcode</b> 4174 * <p> 4175 * Description: <b>A postal code specified in an address</b><br> 4176 * Type: <b>string</b><br> 4177 * Path: <b>InsurancePlan.contact.address.postalCode</b><br> 4178 * </p> 4179 */ 4180 public static final ca.uhn.fhir.rest.gclient.StringClientParam ADDRESS_POSTALCODE = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ADDRESS_POSTALCODE); 4181 4182 /** 4183 * Search parameter: <b>administered-by</b> 4184 * <p> 4185 * Description: <b>Product administrator</b><br> 4186 * Type: <b>reference</b><br> 4187 * Path: <b>InsurancePlan.administeredBy</b><br> 4188 * </p> 4189 */ 4190 @SearchParamDefinition(name="administered-by", path="InsurancePlan.administeredBy", description="Product administrator", type="reference", target={Organization.class } ) 4191 public static final String SP_ADMINISTERED_BY = "administered-by"; 4192 /** 4193 * <b>Fluent Client</b> search parameter constant for <b>administered-by</b> 4194 * <p> 4195 * Description: <b>Product administrator</b><br> 4196 * Type: <b>reference</b><br> 4197 * Path: <b>InsurancePlan.administeredBy</b><br> 4198 * </p> 4199 */ 4200 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ADMINISTERED_BY = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ADMINISTERED_BY); 4201 4202/** 4203 * Constant for fluent queries to be used to add include statements. Specifies 4204 * the path value of "<b>InsurancePlan:administered-by</b>". 4205 */ 4206 public static final ca.uhn.fhir.model.api.Include INCLUDE_ADMINISTERED_BY = new ca.uhn.fhir.model.api.Include("InsurancePlan:administered-by").toLocked(); 4207 4208 /** 4209 * Search parameter: <b>address-country</b> 4210 * <p> 4211 * Description: <b>A country specified in an address</b><br> 4212 * Type: <b>string</b><br> 4213 * Path: <b>InsurancePlan.contact.address.country</b><br> 4214 * </p> 4215 */ 4216 @SearchParamDefinition(name="address-country", path="InsurancePlan.contact.address.country", description="A country specified in an address", type="string" ) 4217 public static final String SP_ADDRESS_COUNTRY = "address-country"; 4218 /** 4219 * <b>Fluent Client</b> search parameter constant for <b>address-country</b> 4220 * <p> 4221 * Description: <b>A country specified in an address</b><br> 4222 * Type: <b>string</b><br> 4223 * Path: <b>InsurancePlan.contact.address.country</b><br> 4224 * </p> 4225 */ 4226 public static final ca.uhn.fhir.rest.gclient.StringClientParam ADDRESS_COUNTRY = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ADDRESS_COUNTRY); 4227 4228 /** 4229 * Search parameter: <b>endpoint</b> 4230 * <p> 4231 * Description: <b>Technical endpoint</b><br> 4232 * Type: <b>reference</b><br> 4233 * Path: <b>InsurancePlan.endpoint</b><br> 4234 * </p> 4235 */ 4236 @SearchParamDefinition(name="endpoint", path="InsurancePlan.endpoint", description="Technical endpoint", type="reference", target={Endpoint.class } ) 4237 public static final String SP_ENDPOINT = "endpoint"; 4238 /** 4239 * <b>Fluent Client</b> search parameter constant for <b>endpoint</b> 4240 * <p> 4241 * Description: <b>Technical endpoint</b><br> 4242 * Type: <b>reference</b><br> 4243 * Path: <b>InsurancePlan.endpoint</b><br> 4244 * </p> 4245 */ 4246 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ENDPOINT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ENDPOINT); 4247 4248/** 4249 * Constant for fluent queries to be used to add include statements. Specifies 4250 * the path value of "<b>InsurancePlan:endpoint</b>". 4251 */ 4252 public static final ca.uhn.fhir.model.api.Include INCLUDE_ENDPOINT = new ca.uhn.fhir.model.api.Include("InsurancePlan:endpoint").toLocked(); 4253 4254 /** 4255 * Search parameter: <b>phonetic</b> 4256 * <p> 4257 * Description: <b>A portion of the organization's name using some kind of phonetic matching algorithm</b><br> 4258 * Type: <b>string</b><br> 4259 * Path: <b>InsurancePlan.name</b><br> 4260 * </p> 4261 */ 4262 @SearchParamDefinition(name="phonetic", path="InsurancePlan.name", description="A portion of the organization's name using some kind of phonetic matching algorithm", type="string" ) 4263 public static final String SP_PHONETIC = "phonetic"; 4264 /** 4265 * <b>Fluent Client</b> search parameter constant for <b>phonetic</b> 4266 * <p> 4267 * Description: <b>A portion of the organization's name using some kind of phonetic matching algorithm</b><br> 4268 * Type: <b>string</b><br> 4269 * Path: <b>InsurancePlan.name</b><br> 4270 * </p> 4271 */ 4272 public static final ca.uhn.fhir.rest.gclient.StringClientParam PHONETIC = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_PHONETIC); 4273 4274 /** 4275 * Search parameter: <b>name</b> 4276 * <p> 4277 * Description: <b>A portion of the organization's name or alias</b><br> 4278 * Type: <b>string</b><br> 4279 * Path: <b>InsurancePlan.name, InsurancePlan.alias</b><br> 4280 * </p> 4281 */ 4282 @SearchParamDefinition(name="name", path="name | alias", description="A portion of the organization's name or alias", type="string" ) 4283 public static final String SP_NAME = "name"; 4284 /** 4285 * <b>Fluent Client</b> search parameter constant for <b>name</b> 4286 * <p> 4287 * Description: <b>A portion of the organization's name or alias</b><br> 4288 * Type: <b>string</b><br> 4289 * Path: <b>InsurancePlan.name, InsurancePlan.alias</b><br> 4290 * </p> 4291 */ 4292 public static final ca.uhn.fhir.rest.gclient.StringClientParam NAME = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_NAME); 4293 4294 /** 4295 * Search parameter: <b>address-use</b> 4296 * <p> 4297 * Description: <b>A use code specified in an address</b><br> 4298 * Type: <b>token</b><br> 4299 * Path: <b>InsurancePlan.contact.address.use</b><br> 4300 * </p> 4301 */ 4302 @SearchParamDefinition(name="address-use", path="InsurancePlan.contact.address.use", description="A use code specified in an address", type="token" ) 4303 public static final String SP_ADDRESS_USE = "address-use"; 4304 /** 4305 * <b>Fluent Client</b> search parameter constant for <b>address-use</b> 4306 * <p> 4307 * Description: <b>A use code specified in an address</b><br> 4308 * Type: <b>token</b><br> 4309 * Path: <b>InsurancePlan.contact.address.use</b><br> 4310 * </p> 4311 */ 4312 public static final ca.uhn.fhir.rest.gclient.TokenClientParam ADDRESS_USE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_ADDRESS_USE); 4313 4314 /** 4315 * Search parameter: <b>address-city</b> 4316 * <p> 4317 * Description: <b>A city specified in an address</b><br> 4318 * Type: <b>string</b><br> 4319 * Path: <b>InsurancePlan.contact.address.city</b><br> 4320 * </p> 4321 */ 4322 @SearchParamDefinition(name="address-city", path="InsurancePlan.contact.address.city", description="A city specified in an address", type="string" ) 4323 public static final String SP_ADDRESS_CITY = "address-city"; 4324 /** 4325 * <b>Fluent Client</b> search parameter constant for <b>address-city</b> 4326 * <p> 4327 * Description: <b>A city specified in an address</b><br> 4328 * Type: <b>string</b><br> 4329 * Path: <b>InsurancePlan.contact.address.city</b><br> 4330 * </p> 4331 */ 4332 public static final ca.uhn.fhir.rest.gclient.StringClientParam ADDRESS_CITY = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_ADDRESS_CITY); 4333 4334 /** 4335 * Search parameter: <b>status</b> 4336 * <p> 4337 * Description: <b>Is the Organization record active</b><br> 4338 * Type: <b>token</b><br> 4339 * Path: <b>InsurancePlan.status</b><br> 4340 * </p> 4341 */ 4342 @SearchParamDefinition(name="status", path="InsurancePlan.status", description="Is the Organization record active", type="token" ) 4343 public static final String SP_STATUS = "status"; 4344 /** 4345 * <b>Fluent Client</b> search parameter constant for <b>status</b> 4346 * <p> 4347 * Description: <b>Is the Organization record active</b><br> 4348 * Type: <b>token</b><br> 4349 * Path: <b>InsurancePlan.status</b><br> 4350 * </p> 4351 */ 4352 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 4353 4354 4355} 4356