001package org.hl7.fhir.r5.model; 002 003 004/* 005 Copyright (c) 2011+, HL7, Inc. 006 All rights reserved. 007 008 Redistribution and use in source and binary forms, with or without modification, \ 009 are permitted provided that the following conditions are met: 010 011 * Redistributions of source code must retain the above copyright notice, this \ 012 list of conditions and the following disclaimer. 013 * Redistributions in binary form must reproduce the above copyright notice, \ 014 this list of conditions and the following disclaimer in the documentation \ 015 and/or other materials provided with the distribution. 016 * Neither the name of HL7 nor the names of its contributors may be used to 017 endorse or promote products derived from this software without specific 018 prior written permission. 019 020 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND \ 021 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \ 022 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \ 023 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \ 024 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT \ 025 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR \ 026 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \ 027 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) \ 028 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE \ 029 POSSIBILITY OF SUCH DAMAGE. 030 */ 031 032// Generated on Tue, Dec 28, 2021 07:16+1100 for FHIR v5.0.0-snapshot1 033 034import java.util.ArrayList; 035import java.util.Date; 036import java.util.List; 037import org.hl7.fhir.utilities.Utilities; 038import org.hl7.fhir.r5.model.Enumerations.*; 039import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 040import org.hl7.fhir.exceptions.FHIRException; 041import org.hl7.fhir.instance.model.api.ICompositeType; 042import ca.uhn.fhir.model.api.annotation.ResourceDef; 043import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 044import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 045import ca.uhn.fhir.model.api.annotation.Child; 046import ca.uhn.fhir.model.api.annotation.ChildOrder; 047import ca.uhn.fhir.model.api.annotation.Description; 048import ca.uhn.fhir.model.api.annotation.Block; 049 050/** 051 * Financial instrument which may be used to reimburse or pay for health care products and services. Includes both insurance and self-payment. 052 */ 053@ResourceDef(name="Coverage", profile="http://hl7.org/fhir/StructureDefinition/Coverage") 054public class Coverage extends DomainResource { 055 056 @Block() 057 public static class ClassComponent extends BackboneElement implements IBaseBackboneElement { 058 /** 059 * The type of classification for which an insurer-specific class label or number and optional name is provided. For example, type may be used to identify a class of coverage or employer group, policy, or plan. 060 */ 061 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=true) 062 @Description(shortDefinition="Type of class such as 'group' or 'plan'", formalDefinition="The type of classification for which an insurer-specific class label or number and optional name is provided. For example, type may be used to identify a class of coverage or employer group, policy, or plan." ) 063 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/coverage-class") 064 protected CodeableConcept type; 065 066 /** 067 * The alphanumeric string value associated with the insurer issued label. 068 */ 069 @Child(name = "value", type = {StringType.class}, order=2, min=1, max=1, modifier=false, summary=true) 070 @Description(shortDefinition="Value associated with the type", formalDefinition="The alphanumeric string value associated with the insurer issued label." ) 071 protected StringType value; 072 073 /** 074 * A short description for the class. 075 */ 076 @Child(name = "name", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=true) 077 @Description(shortDefinition="Human readable description of the type and value", formalDefinition="A short description for the class." ) 078 protected StringType name; 079 080 private static final long serialVersionUID = -1501519769L; 081 082 /** 083 * Constructor 084 */ 085 public ClassComponent() { 086 super(); 087 } 088 089 /** 090 * Constructor 091 */ 092 public ClassComponent(CodeableConcept type, String value) { 093 super(); 094 this.setType(type); 095 this.setValue(value); 096 } 097 098 /** 099 * @return {@link #type} (The type of classification for which an insurer-specific class label or number and optional name is provided. For example, type may be used to identify a class of coverage or employer group, policy, or plan.) 100 */ 101 public CodeableConcept getType() { 102 if (this.type == null) 103 if (Configuration.errorOnAutoCreate()) 104 throw new Error("Attempt to auto-create ClassComponent.type"); 105 else if (Configuration.doAutoCreate()) 106 this.type = new CodeableConcept(); // cc 107 return this.type; 108 } 109 110 public boolean hasType() { 111 return this.type != null && !this.type.isEmpty(); 112 } 113 114 /** 115 * @param value {@link #type} (The type of classification for which an insurer-specific class label or number and optional name is provided. For example, type may be used to identify a class of coverage or employer group, policy, or plan.) 116 */ 117 public ClassComponent setType(CodeableConcept value) { 118 this.type = value; 119 return this; 120 } 121 122 /** 123 * @return {@link #value} (The alphanumeric string value associated with the insurer issued label.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 124 */ 125 public StringType getValueElement() { 126 if (this.value == null) 127 if (Configuration.errorOnAutoCreate()) 128 throw new Error("Attempt to auto-create ClassComponent.value"); 129 else if (Configuration.doAutoCreate()) 130 this.value = new StringType(); // bb 131 return this.value; 132 } 133 134 public boolean hasValueElement() { 135 return this.value != null && !this.value.isEmpty(); 136 } 137 138 public boolean hasValue() { 139 return this.value != null && !this.value.isEmpty(); 140 } 141 142 /** 143 * @param value {@link #value} (The alphanumeric string value associated with the insurer issued label.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 144 */ 145 public ClassComponent setValueElement(StringType value) { 146 this.value = value; 147 return this; 148 } 149 150 /** 151 * @return The alphanumeric string value associated with the insurer issued label. 152 */ 153 public String getValue() { 154 return this.value == null ? null : this.value.getValue(); 155 } 156 157 /** 158 * @param value The alphanumeric string value associated with the insurer issued label. 159 */ 160 public ClassComponent setValue(String value) { 161 if (this.value == null) 162 this.value = new StringType(); 163 this.value.setValue(value); 164 return this; 165 } 166 167 /** 168 * @return {@link #name} (A short description for the class.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 169 */ 170 public StringType getNameElement() { 171 if (this.name == null) 172 if (Configuration.errorOnAutoCreate()) 173 throw new Error("Attempt to auto-create ClassComponent.name"); 174 else if (Configuration.doAutoCreate()) 175 this.name = new StringType(); // bb 176 return this.name; 177 } 178 179 public boolean hasNameElement() { 180 return this.name != null && !this.name.isEmpty(); 181 } 182 183 public boolean hasName() { 184 return this.name != null && !this.name.isEmpty(); 185 } 186 187 /** 188 * @param value {@link #name} (A short description for the class.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 189 */ 190 public ClassComponent setNameElement(StringType value) { 191 this.name = value; 192 return this; 193 } 194 195 /** 196 * @return A short description for the class. 197 */ 198 public String getName() { 199 return this.name == null ? null : this.name.getValue(); 200 } 201 202 /** 203 * @param value A short description for the class. 204 */ 205 public ClassComponent setName(String value) { 206 if (Utilities.noString(value)) 207 this.name = null; 208 else { 209 if (this.name == null) 210 this.name = new StringType(); 211 this.name.setValue(value); 212 } 213 return this; 214 } 215 216 protected void listChildren(List<Property> children) { 217 super.listChildren(children); 218 children.add(new Property("type", "CodeableConcept", "The type of classification for which an insurer-specific class label or number and optional name is provided. For example, type may be used to identify a class of coverage or employer group, policy, or plan.", 0, 1, type)); 219 children.add(new Property("value", "string", "The alphanumeric string value associated with the insurer issued label.", 0, 1, value)); 220 children.add(new Property("name", "string", "A short description for the class.", 0, 1, name)); 221 } 222 223 @Override 224 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 225 switch (_hash) { 226 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The type of classification for which an insurer-specific class label or number and optional name is provided. For example, type may be used to identify a class of coverage or employer group, policy, or plan.", 0, 1, type); 227 case 111972721: /*value*/ return new Property("value", "string", "The alphanumeric string value associated with the insurer issued label.", 0, 1, value); 228 case 3373707: /*name*/ return new Property("name", "string", "A short description for the class.", 0, 1, name); 229 default: return super.getNamedProperty(_hash, _name, _checkValid); 230 } 231 232 } 233 234 @Override 235 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 236 switch (hash) { 237 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 238 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // StringType 239 case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType 240 default: return super.getProperty(hash, name, checkValid); 241 } 242 243 } 244 245 @Override 246 public Base setProperty(int hash, String name, Base value) throws FHIRException { 247 switch (hash) { 248 case 3575610: // type 249 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 250 return value; 251 case 111972721: // value 252 this.value = TypeConvertor.castToString(value); // StringType 253 return value; 254 case 3373707: // name 255 this.name = TypeConvertor.castToString(value); // StringType 256 return value; 257 default: return super.setProperty(hash, name, value); 258 } 259 260 } 261 262 @Override 263 public Base setProperty(String name, Base value) throws FHIRException { 264 if (name.equals("type")) { 265 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 266 } else if (name.equals("value")) { 267 this.value = TypeConvertor.castToString(value); // StringType 268 } else if (name.equals("name")) { 269 this.name = TypeConvertor.castToString(value); // StringType 270 } else 271 return super.setProperty(name, value); 272 return value; 273 } 274 275 @Override 276 public Base makeProperty(int hash, String name) throws FHIRException { 277 switch (hash) { 278 case 3575610: return getType(); 279 case 111972721: return getValueElement(); 280 case 3373707: return getNameElement(); 281 default: return super.makeProperty(hash, name); 282 } 283 284 } 285 286 @Override 287 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 288 switch (hash) { 289 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 290 case 111972721: /*value*/ return new String[] {"string"}; 291 case 3373707: /*name*/ return new String[] {"string"}; 292 default: return super.getTypesForProperty(hash, name); 293 } 294 295 } 296 297 @Override 298 public Base addChild(String name) throws FHIRException { 299 if (name.equals("type")) { 300 this.type = new CodeableConcept(); 301 return this.type; 302 } 303 else if (name.equals("value")) { 304 throw new FHIRException("Cannot call addChild on a primitive type Coverage.class.value"); 305 } 306 else if (name.equals("name")) { 307 throw new FHIRException("Cannot call addChild on a primitive type Coverage.class.name"); 308 } 309 else 310 return super.addChild(name); 311 } 312 313 public ClassComponent copy() { 314 ClassComponent dst = new ClassComponent(); 315 copyValues(dst); 316 return dst; 317 } 318 319 public void copyValues(ClassComponent dst) { 320 super.copyValues(dst); 321 dst.type = type == null ? null : type.copy(); 322 dst.value = value == null ? null : value.copy(); 323 dst.name = name == null ? null : name.copy(); 324 } 325 326 @Override 327 public boolean equalsDeep(Base other_) { 328 if (!super.equalsDeep(other_)) 329 return false; 330 if (!(other_ instanceof ClassComponent)) 331 return false; 332 ClassComponent o = (ClassComponent) other_; 333 return compareDeep(type, o.type, true) && compareDeep(value, o.value, true) && compareDeep(name, o.name, true) 334 ; 335 } 336 337 @Override 338 public boolean equalsShallow(Base other_) { 339 if (!super.equalsShallow(other_)) 340 return false; 341 if (!(other_ instanceof ClassComponent)) 342 return false; 343 ClassComponent o = (ClassComponent) other_; 344 return compareValues(value, o.value, true) && compareValues(name, o.name, true); 345 } 346 347 public boolean isEmpty() { 348 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, value, name); 349 } 350 351 public String fhirType() { 352 return "Coverage.class"; 353 354 } 355 356 } 357 358 @Block() 359 public static class CostToBeneficiaryComponent extends BackboneElement implements IBaseBackboneElement { 360 /** 361 * The category of patient centric costs associated with treatment. 362 */ 363 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=true) 364 @Description(shortDefinition="Cost category", formalDefinition="The category of patient centric costs associated with treatment." ) 365 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/coverage-copay-type") 366 protected CodeableConcept type; 367 368 /** 369 * The amount due from the patient for the cost category. 370 */ 371 @Child(name = "value", type = {Quantity.class, Money.class}, order=2, min=1, max=1, modifier=false, summary=true) 372 @Description(shortDefinition="The amount or percentage due from the beneficiary", formalDefinition="The amount due from the patient for the cost category." ) 373 protected DataType value; 374 375 /** 376 * A suite of codes indicating exceptions or reductions to patient costs and their effective periods. 377 */ 378 @Child(name = "exception", type = {}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 379 @Description(shortDefinition="Exceptions for patient payments", formalDefinition="A suite of codes indicating exceptions or reductions to patient costs and their effective periods." ) 380 protected List<ExemptionComponent> exception; 381 382 private static final long serialVersionUID = -1531646137L; 383 384 /** 385 * Constructor 386 */ 387 public CostToBeneficiaryComponent() { 388 super(); 389 } 390 391 /** 392 * Constructor 393 */ 394 public CostToBeneficiaryComponent(DataType value) { 395 super(); 396 this.setValue(value); 397 } 398 399 /** 400 * @return {@link #type} (The category of patient centric costs associated with treatment.) 401 */ 402 public CodeableConcept getType() { 403 if (this.type == null) 404 if (Configuration.errorOnAutoCreate()) 405 throw new Error("Attempt to auto-create CostToBeneficiaryComponent.type"); 406 else if (Configuration.doAutoCreate()) 407 this.type = new CodeableConcept(); // cc 408 return this.type; 409 } 410 411 public boolean hasType() { 412 return this.type != null && !this.type.isEmpty(); 413 } 414 415 /** 416 * @param value {@link #type} (The category of patient centric costs associated with treatment.) 417 */ 418 public CostToBeneficiaryComponent setType(CodeableConcept value) { 419 this.type = value; 420 return this; 421 } 422 423 /** 424 * @return {@link #value} (The amount due from the patient for the cost category.) 425 */ 426 public DataType getValue() { 427 return this.value; 428 } 429 430 /** 431 * @return {@link #value} (The amount due from the patient for the cost category.) 432 */ 433 public Quantity getValueQuantity() throws FHIRException { 434 if (this.value == null) 435 this.value = new Quantity(); 436 if (!(this.value instanceof Quantity)) 437 throw new FHIRException("Type mismatch: the type Quantity was expected, but "+this.value.getClass().getName()+" was encountered"); 438 return (Quantity) this.value; 439 } 440 441 public boolean hasValueQuantity() { 442 return this != null && this.value instanceof Quantity; 443 } 444 445 /** 446 * @return {@link #value} (The amount due from the patient for the cost category.) 447 */ 448 public Money getValueMoney() throws FHIRException { 449 if (this.value == null) 450 this.value = new Money(); 451 if (!(this.value instanceof Money)) 452 throw new FHIRException("Type mismatch: the type Money was expected, but "+this.value.getClass().getName()+" was encountered"); 453 return (Money) this.value; 454 } 455 456 public boolean hasValueMoney() { 457 return this != null && this.value instanceof Money; 458 } 459 460 public boolean hasValue() { 461 return this.value != null && !this.value.isEmpty(); 462 } 463 464 /** 465 * @param value {@link #value} (The amount due from the patient for the cost category.) 466 */ 467 public CostToBeneficiaryComponent setValue(DataType value) { 468 if (value != null && !(value instanceof Quantity || value instanceof Money)) 469 throw new Error("Not the right type for Coverage.costToBeneficiary.value[x]: "+value.fhirType()); 470 this.value = value; 471 return this; 472 } 473 474 /** 475 * @return {@link #exception} (A suite of codes indicating exceptions or reductions to patient costs and their effective periods.) 476 */ 477 public List<ExemptionComponent> getException() { 478 if (this.exception == null) 479 this.exception = new ArrayList<ExemptionComponent>(); 480 return this.exception; 481 } 482 483 /** 484 * @return Returns a reference to <code>this</code> for easy method chaining 485 */ 486 public CostToBeneficiaryComponent setException(List<ExemptionComponent> theException) { 487 this.exception = theException; 488 return this; 489 } 490 491 public boolean hasException() { 492 if (this.exception == null) 493 return false; 494 for (ExemptionComponent item : this.exception) 495 if (!item.isEmpty()) 496 return true; 497 return false; 498 } 499 500 public ExemptionComponent addException() { //3 501 ExemptionComponent t = new ExemptionComponent(); 502 if (this.exception == null) 503 this.exception = new ArrayList<ExemptionComponent>(); 504 this.exception.add(t); 505 return t; 506 } 507 508 public CostToBeneficiaryComponent addException(ExemptionComponent t) { //3 509 if (t == null) 510 return this; 511 if (this.exception == null) 512 this.exception = new ArrayList<ExemptionComponent>(); 513 this.exception.add(t); 514 return this; 515 } 516 517 /** 518 * @return The first repetition of repeating field {@link #exception}, creating it if it does not already exist {3} 519 */ 520 public ExemptionComponent getExceptionFirstRep() { 521 if (getException().isEmpty()) { 522 addException(); 523 } 524 return getException().get(0); 525 } 526 527 protected void listChildren(List<Property> children) { 528 super.listChildren(children); 529 children.add(new Property("type", "CodeableConcept", "The category of patient centric costs associated with treatment.", 0, 1, type)); 530 children.add(new Property("value[x]", "Quantity|Money", "The amount due from the patient for the cost category.", 0, 1, value)); 531 children.add(new Property("exception", "", "A suite of codes indicating exceptions or reductions to patient costs and their effective periods.", 0, java.lang.Integer.MAX_VALUE, exception)); 532 } 533 534 @Override 535 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 536 switch (_hash) { 537 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The category of patient centric costs associated with treatment.", 0, 1, type); 538 case -1410166417: /*value[x]*/ return new Property("value[x]", "Quantity|Money", "The amount due from the patient for the cost category.", 0, 1, value); 539 case 111972721: /*value*/ return new Property("value[x]", "Quantity|Money", "The amount due from the patient for the cost category.", 0, 1, value); 540 case -2029823716: /*valueQuantity*/ return new Property("value[x]", "Quantity", "The amount due from the patient for the cost category.", 0, 1, value); 541 case 2026560975: /*valueMoney*/ return new Property("value[x]", "Money", "The amount due from the patient for the cost category.", 0, 1, value); 542 case 1481625679: /*exception*/ return new Property("exception", "", "A suite of codes indicating exceptions or reductions to patient costs and their effective periods.", 0, java.lang.Integer.MAX_VALUE, exception); 543 default: return super.getNamedProperty(_hash, _name, _checkValid); 544 } 545 546 } 547 548 @Override 549 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 550 switch (hash) { 551 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 552 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // DataType 553 case 1481625679: /*exception*/ return this.exception == null ? new Base[0] : this.exception.toArray(new Base[this.exception.size()]); // ExemptionComponent 554 default: return super.getProperty(hash, name, checkValid); 555 } 556 557 } 558 559 @Override 560 public Base setProperty(int hash, String name, Base value) throws FHIRException { 561 switch (hash) { 562 case 3575610: // type 563 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 564 return value; 565 case 111972721: // value 566 this.value = TypeConvertor.castToType(value); // DataType 567 return value; 568 case 1481625679: // exception 569 this.getException().add((ExemptionComponent) value); // ExemptionComponent 570 return value; 571 default: return super.setProperty(hash, name, value); 572 } 573 574 } 575 576 @Override 577 public Base setProperty(String name, Base value) throws FHIRException { 578 if (name.equals("type")) { 579 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 580 } else if (name.equals("value[x]")) { 581 this.value = TypeConvertor.castToType(value); // DataType 582 } else if (name.equals("exception")) { 583 this.getException().add((ExemptionComponent) value); 584 } else 585 return super.setProperty(name, value); 586 return value; 587 } 588 589 @Override 590 public Base makeProperty(int hash, String name) throws FHIRException { 591 switch (hash) { 592 case 3575610: return getType(); 593 case -1410166417: return getValue(); 594 case 111972721: return getValue(); 595 case 1481625679: return addException(); 596 default: return super.makeProperty(hash, name); 597 } 598 599 } 600 601 @Override 602 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 603 switch (hash) { 604 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 605 case 111972721: /*value*/ return new String[] {"Quantity", "Money"}; 606 case 1481625679: /*exception*/ return new String[] {}; 607 default: return super.getTypesForProperty(hash, name); 608 } 609 610 } 611 612 @Override 613 public Base addChild(String name) throws FHIRException { 614 if (name.equals("type")) { 615 this.type = new CodeableConcept(); 616 return this.type; 617 } 618 else if (name.equals("valueQuantity")) { 619 this.value = new Quantity(); 620 return this.value; 621 } 622 else if (name.equals("valueMoney")) { 623 this.value = new Money(); 624 return this.value; 625 } 626 else if (name.equals("exception")) { 627 return addException(); 628 } 629 else 630 return super.addChild(name); 631 } 632 633 public CostToBeneficiaryComponent copy() { 634 CostToBeneficiaryComponent dst = new CostToBeneficiaryComponent(); 635 copyValues(dst); 636 return dst; 637 } 638 639 public void copyValues(CostToBeneficiaryComponent dst) { 640 super.copyValues(dst); 641 dst.type = type == null ? null : type.copy(); 642 dst.value = value == null ? null : value.copy(); 643 if (exception != null) { 644 dst.exception = new ArrayList<ExemptionComponent>(); 645 for (ExemptionComponent i : exception) 646 dst.exception.add(i.copy()); 647 }; 648 } 649 650 @Override 651 public boolean equalsDeep(Base other_) { 652 if (!super.equalsDeep(other_)) 653 return false; 654 if (!(other_ instanceof CostToBeneficiaryComponent)) 655 return false; 656 CostToBeneficiaryComponent o = (CostToBeneficiaryComponent) other_; 657 return compareDeep(type, o.type, true) && compareDeep(value, o.value, true) && compareDeep(exception, o.exception, true) 658 ; 659 } 660 661 @Override 662 public boolean equalsShallow(Base other_) { 663 if (!super.equalsShallow(other_)) 664 return false; 665 if (!(other_ instanceof CostToBeneficiaryComponent)) 666 return false; 667 CostToBeneficiaryComponent o = (CostToBeneficiaryComponent) other_; 668 return true; 669 } 670 671 public boolean isEmpty() { 672 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, value, exception); 673 } 674 675 public String fhirType() { 676 return "Coverage.costToBeneficiary"; 677 678 } 679 680 } 681 682 @Block() 683 public static class ExemptionComponent extends BackboneElement implements IBaseBackboneElement { 684 /** 685 * The code for the specific exception. 686 */ 687 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=true) 688 @Description(shortDefinition="Exception category", formalDefinition="The code for the specific exception." ) 689 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/coverage-financial-exception") 690 protected CodeableConcept type; 691 692 /** 693 * The timeframe the exception is in force. 694 */ 695 @Child(name = "period", type = {Period.class}, order=2, min=0, max=1, modifier=false, summary=true) 696 @Description(shortDefinition="The effective period of the exception", formalDefinition="The timeframe the exception is in force." ) 697 protected Period period; 698 699 private static final long serialVersionUID = 523191991L; 700 701 /** 702 * Constructor 703 */ 704 public ExemptionComponent() { 705 super(); 706 } 707 708 /** 709 * Constructor 710 */ 711 public ExemptionComponent(CodeableConcept type) { 712 super(); 713 this.setType(type); 714 } 715 716 /** 717 * @return {@link #type} (The code for the specific exception.) 718 */ 719 public CodeableConcept getType() { 720 if (this.type == null) 721 if (Configuration.errorOnAutoCreate()) 722 throw new Error("Attempt to auto-create ExemptionComponent.type"); 723 else if (Configuration.doAutoCreate()) 724 this.type = new CodeableConcept(); // cc 725 return this.type; 726 } 727 728 public boolean hasType() { 729 return this.type != null && !this.type.isEmpty(); 730 } 731 732 /** 733 * @param value {@link #type} (The code for the specific exception.) 734 */ 735 public ExemptionComponent setType(CodeableConcept value) { 736 this.type = value; 737 return this; 738 } 739 740 /** 741 * @return {@link #period} (The timeframe the exception is in force.) 742 */ 743 public Period getPeriod() { 744 if (this.period == null) 745 if (Configuration.errorOnAutoCreate()) 746 throw new Error("Attempt to auto-create ExemptionComponent.period"); 747 else if (Configuration.doAutoCreate()) 748 this.period = new Period(); // cc 749 return this.period; 750 } 751 752 public boolean hasPeriod() { 753 return this.period != null && !this.period.isEmpty(); 754 } 755 756 /** 757 * @param value {@link #period} (The timeframe the exception is in force.) 758 */ 759 public ExemptionComponent setPeriod(Period value) { 760 this.period = value; 761 return this; 762 } 763 764 protected void listChildren(List<Property> children) { 765 super.listChildren(children); 766 children.add(new Property("type", "CodeableConcept", "The code for the specific exception.", 0, 1, type)); 767 children.add(new Property("period", "Period", "The timeframe the exception is in force.", 0, 1, period)); 768 } 769 770 @Override 771 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 772 switch (_hash) { 773 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The code for the specific exception.", 0, 1, type); 774 case -991726143: /*period*/ return new Property("period", "Period", "The timeframe the exception is in force.", 0, 1, period); 775 default: return super.getNamedProperty(_hash, _name, _checkValid); 776 } 777 778 } 779 780 @Override 781 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 782 switch (hash) { 783 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 784 case -991726143: /*period*/ return this.period == null ? new Base[0] : new Base[] {this.period}; // Period 785 default: return super.getProperty(hash, name, checkValid); 786 } 787 788 } 789 790 @Override 791 public Base setProperty(int hash, String name, Base value) throws FHIRException { 792 switch (hash) { 793 case 3575610: // type 794 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 795 return value; 796 case -991726143: // period 797 this.period = TypeConvertor.castToPeriod(value); // Period 798 return value; 799 default: return super.setProperty(hash, name, value); 800 } 801 802 } 803 804 @Override 805 public Base setProperty(String name, Base value) throws FHIRException { 806 if (name.equals("type")) { 807 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 808 } else if (name.equals("period")) { 809 this.period = TypeConvertor.castToPeriod(value); // Period 810 } else 811 return super.setProperty(name, value); 812 return value; 813 } 814 815 @Override 816 public Base makeProperty(int hash, String name) throws FHIRException { 817 switch (hash) { 818 case 3575610: return getType(); 819 case -991726143: return getPeriod(); 820 default: return super.makeProperty(hash, name); 821 } 822 823 } 824 825 @Override 826 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 827 switch (hash) { 828 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 829 case -991726143: /*period*/ return new String[] {"Period"}; 830 default: return super.getTypesForProperty(hash, name); 831 } 832 833 } 834 835 @Override 836 public Base addChild(String name) throws FHIRException { 837 if (name.equals("type")) { 838 this.type = new CodeableConcept(); 839 return this.type; 840 } 841 else if (name.equals("period")) { 842 this.period = new Period(); 843 return this.period; 844 } 845 else 846 return super.addChild(name); 847 } 848 849 public ExemptionComponent copy() { 850 ExemptionComponent dst = new ExemptionComponent(); 851 copyValues(dst); 852 return dst; 853 } 854 855 public void copyValues(ExemptionComponent dst) { 856 super.copyValues(dst); 857 dst.type = type == null ? null : type.copy(); 858 dst.period = period == null ? null : period.copy(); 859 } 860 861 @Override 862 public boolean equalsDeep(Base other_) { 863 if (!super.equalsDeep(other_)) 864 return false; 865 if (!(other_ instanceof ExemptionComponent)) 866 return false; 867 ExemptionComponent o = (ExemptionComponent) other_; 868 return compareDeep(type, o.type, true) && compareDeep(period, o.period, true); 869 } 870 871 @Override 872 public boolean equalsShallow(Base other_) { 873 if (!super.equalsShallow(other_)) 874 return false; 875 if (!(other_ instanceof ExemptionComponent)) 876 return false; 877 ExemptionComponent o = (ExemptionComponent) other_; 878 return true; 879 } 880 881 public boolean isEmpty() { 882 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, period); 883 } 884 885 public String fhirType() { 886 return "Coverage.costToBeneficiary.exception"; 887 888 } 889 890 } 891 892 /** 893 * A unique identifier assigned to this coverage. 894 */ 895 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 896 @Description(shortDefinition="Business Identifier for the coverage", formalDefinition="A unique identifier assigned to this coverage." ) 897 protected List<Identifier> identifier; 898 899 /** 900 * The status of the resource instance. 901 */ 902 @Child(name = "status", type = {CodeType.class}, order=1, min=1, max=1, modifier=true, summary=true) 903 @Description(shortDefinition="active | cancelled | draft | entered-in-error", formalDefinition="The status of the resource instance." ) 904 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/fm-status") 905 protected Enumeration<FinancialResourceStatusCodes> status; 906 907 /** 908 * The type of coverage: social program, medical plan, accident coverage (workers compensation, auto), group health or payment by an individual or organization. 909 */ 910 @Child(name = "type", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=true) 911 @Description(shortDefinition="Coverage category such as medical or accident", formalDefinition="The type of coverage: social program, medical plan, accident coverage (workers compensation, auto), group health or payment by an individual or organization." ) 912 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/coverage-type") 913 protected CodeableConcept type; 914 915 /** 916 * The party who 'owns' the insurance policy. 917 */ 918 @Child(name = "policyHolder", type = {Patient.class, RelatedPerson.class, Organization.class}, order=3, min=0, max=1, modifier=false, summary=true) 919 @Description(shortDefinition="Owner of the policy", formalDefinition="The party who 'owns' the insurance policy." ) 920 protected Reference policyHolder; 921 922 /** 923 * The party who has signed-up for or 'owns' the contractual relationship to the policy or to whom the benefit of the policy for services rendered to them or their family is due. 924 */ 925 @Child(name = "subscriber", type = {Patient.class, RelatedPerson.class}, order=4, min=0, max=1, modifier=false, summary=true) 926 @Description(shortDefinition="Subscriber to the policy", formalDefinition="The party who has signed-up for or 'owns' the contractual relationship to the policy or to whom the benefit of the policy for services rendered to them or their family is due." ) 927 protected Reference subscriber; 928 929 /** 930 * The insurer assigned ID for the Subscriber. 931 */ 932 @Child(name = "subscriberId", type = {Identifier.class}, order=5, min=0, max=1, modifier=false, summary=true) 933 @Description(shortDefinition="ID assigned to the subscriber", formalDefinition="The insurer assigned ID for the Subscriber." ) 934 protected Identifier subscriberId; 935 936 /** 937 * The party who benefits from the insurance coverage; the patient when products and/or services are provided. 938 */ 939 @Child(name = "beneficiary", type = {Patient.class}, order=6, min=1, max=1, modifier=false, summary=true) 940 @Description(shortDefinition="Plan beneficiary", formalDefinition="The party who benefits from the insurance coverage; the patient when products and/or services are provided." ) 941 protected Reference beneficiary; 942 943 /** 944 * A designator for a dependent under the coverage. 945 */ 946 @Child(name = "dependent", type = {StringType.class}, order=7, min=0, max=1, modifier=false, summary=true) 947 @Description(shortDefinition="Dependent number", formalDefinition="A designator for a dependent under the coverage." ) 948 protected StringType dependent; 949 950 /** 951 * The relationship of beneficiary (patient) to the subscriber. 952 */ 953 @Child(name = "relationship", type = {CodeableConcept.class}, order=8, min=0, max=1, modifier=false, summary=false) 954 @Description(shortDefinition="Beneficiary relationship to the subscriber", formalDefinition="The relationship of beneficiary (patient) to the subscriber." ) 955 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/subscriber-relationship") 956 protected CodeableConcept relationship; 957 958 /** 959 * Time period during which the coverage is in force. A missing start date indicates the start date isn't known, a missing end date means the coverage is continuing to be in force. 960 */ 961 @Child(name = "period", type = {Period.class}, order=9, min=0, max=1, modifier=false, summary=true) 962 @Description(shortDefinition="Coverage start and end dates", formalDefinition="Time period during which the coverage is in force. A missing start date indicates the start date isn't known, a missing end date means the coverage is continuing to be in force." ) 963 protected Period period; 964 965 /** 966 * The program or plan underwriter or payor including both insurance and non-insurance agreements, such as patient-pay agreements. 967 */ 968 @Child(name = "payor", type = {Organization.class, Patient.class, RelatedPerson.class}, order=10, min=1, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 969 @Description(shortDefinition="Issuer of the policy", formalDefinition="The program or plan underwriter or payor including both insurance and non-insurance agreements, such as patient-pay agreements." ) 970 protected List<Reference> payor; 971 972 /** 973 * A suite of underwriter specific classifiers. 974 */ 975 @Child(name = "class", type = {}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 976 @Description(shortDefinition="Additional coverage classifications", formalDefinition="A suite of underwriter specific classifiers." ) 977 protected List<ClassComponent> class_; 978 979 /** 980 * The order of applicability of this coverage relative to other coverages which are currently in force. Note, there may be gaps in the numbering and this does not imply primary, secondary etc. as the specific positioning of coverages depends upon the episode of care. 981 */ 982 @Child(name = "order", type = {PositiveIntType.class}, order=12, min=0, max=1, modifier=false, summary=true) 983 @Description(shortDefinition="Relative order of the coverage", formalDefinition="The order of applicability of this coverage relative to other coverages which are currently in force. Note, there may be gaps in the numbering and this does not imply primary, secondary etc. as the specific positioning of coverages depends upon the episode of care." ) 984 protected PositiveIntType order; 985 986 /** 987 * The insurer-specific identifier for the insurer-defined network of providers to which the beneficiary may seek treatment which will be covered at the 'in-network' rate, otherwise 'out of network' terms and conditions apply. 988 */ 989 @Child(name = "network", type = {StringType.class}, order=13, min=0, max=1, modifier=false, summary=true) 990 @Description(shortDefinition="Insurer network", formalDefinition="The insurer-specific identifier for the insurer-defined network of providers to which the beneficiary may seek treatment which will be covered at the 'in-network' rate, otherwise 'out of network' terms and conditions apply." ) 991 protected StringType network; 992 993 /** 994 * A suite of codes indicating the cost category and associated amount which have been detailed in the policy and may have been included on the health card. 995 */ 996 @Child(name = "costToBeneficiary", type = {}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 997 @Description(shortDefinition="Patient payments for services/products", formalDefinition="A suite of codes indicating the cost category and associated amount which have been detailed in the policy and may have been included on the health card." ) 998 protected List<CostToBeneficiaryComponent> costToBeneficiary; 999 1000 /** 1001 * When 'subrogation=true' this insurance instance has been included not for adjudication but to provide insurers with the details to recover costs. 1002 */ 1003 @Child(name = "subrogation", type = {BooleanType.class}, order=15, min=0, max=1, modifier=false, summary=false) 1004 @Description(shortDefinition="Reimbursement to insurer", formalDefinition="When 'subrogation=true' this insurance instance has been included not for adjudication but to provide insurers with the details to recover costs." ) 1005 protected BooleanType subrogation; 1006 1007 /** 1008 * The policy(s) which constitute this insurance coverage. 1009 */ 1010 @Child(name = "contract", type = {Contract.class}, order=16, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1011 @Description(shortDefinition="Contract details", formalDefinition="The policy(s) which constitute this insurance coverage." ) 1012 protected List<Reference> contract; 1013 1014 private static final long serialVersionUID = 344887058L; 1015 1016 /** 1017 * Constructor 1018 */ 1019 public Coverage() { 1020 super(); 1021 } 1022 1023 /** 1024 * Constructor 1025 */ 1026 public Coverage(FinancialResourceStatusCodes status, Reference beneficiary, Reference payor) { 1027 super(); 1028 this.setStatus(status); 1029 this.setBeneficiary(beneficiary); 1030 this.addPayor(payor); 1031 } 1032 1033 /** 1034 * @return {@link #identifier} (A unique identifier assigned to this coverage.) 1035 */ 1036 public List<Identifier> getIdentifier() { 1037 if (this.identifier == null) 1038 this.identifier = new ArrayList<Identifier>(); 1039 return this.identifier; 1040 } 1041 1042 /** 1043 * @return Returns a reference to <code>this</code> for easy method chaining 1044 */ 1045 public Coverage setIdentifier(List<Identifier> theIdentifier) { 1046 this.identifier = theIdentifier; 1047 return this; 1048 } 1049 1050 public boolean hasIdentifier() { 1051 if (this.identifier == null) 1052 return false; 1053 for (Identifier item : this.identifier) 1054 if (!item.isEmpty()) 1055 return true; 1056 return false; 1057 } 1058 1059 public Identifier addIdentifier() { //3 1060 Identifier t = new Identifier(); 1061 if (this.identifier == null) 1062 this.identifier = new ArrayList<Identifier>(); 1063 this.identifier.add(t); 1064 return t; 1065 } 1066 1067 public Coverage addIdentifier(Identifier t) { //3 1068 if (t == null) 1069 return this; 1070 if (this.identifier == null) 1071 this.identifier = new ArrayList<Identifier>(); 1072 this.identifier.add(t); 1073 return this; 1074 } 1075 1076 /** 1077 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist {3} 1078 */ 1079 public Identifier getIdentifierFirstRep() { 1080 if (getIdentifier().isEmpty()) { 1081 addIdentifier(); 1082 } 1083 return getIdentifier().get(0); 1084 } 1085 1086 /** 1087 * @return {@link #status} (The status of the resource instance.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 1088 */ 1089 public Enumeration<FinancialResourceStatusCodes> getStatusElement() { 1090 if (this.status == null) 1091 if (Configuration.errorOnAutoCreate()) 1092 throw new Error("Attempt to auto-create Coverage.status"); 1093 else if (Configuration.doAutoCreate()) 1094 this.status = new Enumeration<FinancialResourceStatusCodes>(new FinancialResourceStatusCodesEnumFactory()); // bb 1095 return this.status; 1096 } 1097 1098 public boolean hasStatusElement() { 1099 return this.status != null && !this.status.isEmpty(); 1100 } 1101 1102 public boolean hasStatus() { 1103 return this.status != null && !this.status.isEmpty(); 1104 } 1105 1106 /** 1107 * @param value {@link #status} (The status of the resource instance.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 1108 */ 1109 public Coverage setStatusElement(Enumeration<FinancialResourceStatusCodes> value) { 1110 this.status = value; 1111 return this; 1112 } 1113 1114 /** 1115 * @return The status of the resource instance. 1116 */ 1117 public FinancialResourceStatusCodes getStatus() { 1118 return this.status == null ? null : this.status.getValue(); 1119 } 1120 1121 /** 1122 * @param value The status of the resource instance. 1123 */ 1124 public Coverage setStatus(FinancialResourceStatusCodes value) { 1125 if (this.status == null) 1126 this.status = new Enumeration<FinancialResourceStatusCodes>(new FinancialResourceStatusCodesEnumFactory()); 1127 this.status.setValue(value); 1128 return this; 1129 } 1130 1131 /** 1132 * @return {@link #type} (The type of coverage: social program, medical plan, accident coverage (workers compensation, auto), group health or payment by an individual or organization.) 1133 */ 1134 public CodeableConcept getType() { 1135 if (this.type == null) 1136 if (Configuration.errorOnAutoCreate()) 1137 throw new Error("Attempt to auto-create Coverage.type"); 1138 else if (Configuration.doAutoCreate()) 1139 this.type = new CodeableConcept(); // cc 1140 return this.type; 1141 } 1142 1143 public boolean hasType() { 1144 return this.type != null && !this.type.isEmpty(); 1145 } 1146 1147 /** 1148 * @param value {@link #type} (The type of coverage: social program, medical plan, accident coverage (workers compensation, auto), group health or payment by an individual or organization.) 1149 */ 1150 public Coverage setType(CodeableConcept value) { 1151 this.type = value; 1152 return this; 1153 } 1154 1155 /** 1156 * @return {@link #policyHolder} (The party who 'owns' the insurance policy.) 1157 */ 1158 public Reference getPolicyHolder() { 1159 if (this.policyHolder == null) 1160 if (Configuration.errorOnAutoCreate()) 1161 throw new Error("Attempt to auto-create Coverage.policyHolder"); 1162 else if (Configuration.doAutoCreate()) 1163 this.policyHolder = new Reference(); // cc 1164 return this.policyHolder; 1165 } 1166 1167 public boolean hasPolicyHolder() { 1168 return this.policyHolder != null && !this.policyHolder.isEmpty(); 1169 } 1170 1171 /** 1172 * @param value {@link #policyHolder} (The party who 'owns' the insurance policy.) 1173 */ 1174 public Coverage setPolicyHolder(Reference value) { 1175 this.policyHolder = value; 1176 return this; 1177 } 1178 1179 /** 1180 * @return {@link #subscriber} (The party who has signed-up for or 'owns' the contractual relationship to the policy or to whom the benefit of the policy for services rendered to them or their family is due.) 1181 */ 1182 public Reference getSubscriber() { 1183 if (this.subscriber == null) 1184 if (Configuration.errorOnAutoCreate()) 1185 throw new Error("Attempt to auto-create Coverage.subscriber"); 1186 else if (Configuration.doAutoCreate()) 1187 this.subscriber = new Reference(); // cc 1188 return this.subscriber; 1189 } 1190 1191 public boolean hasSubscriber() { 1192 return this.subscriber != null && !this.subscriber.isEmpty(); 1193 } 1194 1195 /** 1196 * @param value {@link #subscriber} (The party who has signed-up for or 'owns' the contractual relationship to the policy or to whom the benefit of the policy for services rendered to them or their family is due.) 1197 */ 1198 public Coverage setSubscriber(Reference value) { 1199 this.subscriber = value; 1200 return this; 1201 } 1202 1203 /** 1204 * @return {@link #subscriberId} (The insurer assigned ID for the Subscriber.) 1205 */ 1206 public Identifier getSubscriberId() { 1207 if (this.subscriberId == null) 1208 if (Configuration.errorOnAutoCreate()) 1209 throw new Error("Attempt to auto-create Coverage.subscriberId"); 1210 else if (Configuration.doAutoCreate()) 1211 this.subscriberId = new Identifier(); // cc 1212 return this.subscriberId; 1213 } 1214 1215 public boolean hasSubscriberId() { 1216 return this.subscriberId != null && !this.subscriberId.isEmpty(); 1217 } 1218 1219 /** 1220 * @param value {@link #subscriberId} (The insurer assigned ID for the Subscriber.) 1221 */ 1222 public Coverage setSubscriberId(Identifier value) { 1223 this.subscriberId = value; 1224 return this; 1225 } 1226 1227 /** 1228 * @return {@link #beneficiary} (The party who benefits from the insurance coverage; the patient when products and/or services are provided.) 1229 */ 1230 public Reference getBeneficiary() { 1231 if (this.beneficiary == null) 1232 if (Configuration.errorOnAutoCreate()) 1233 throw new Error("Attempt to auto-create Coverage.beneficiary"); 1234 else if (Configuration.doAutoCreate()) 1235 this.beneficiary = new Reference(); // cc 1236 return this.beneficiary; 1237 } 1238 1239 public boolean hasBeneficiary() { 1240 return this.beneficiary != null && !this.beneficiary.isEmpty(); 1241 } 1242 1243 /** 1244 * @param value {@link #beneficiary} (The party who benefits from the insurance coverage; the patient when products and/or services are provided.) 1245 */ 1246 public Coverage setBeneficiary(Reference value) { 1247 this.beneficiary = value; 1248 return this; 1249 } 1250 1251 /** 1252 * @return {@link #dependent} (A designator for a dependent under the coverage.). This is the underlying object with id, value and extensions. The accessor "getDependent" gives direct access to the value 1253 */ 1254 public StringType getDependentElement() { 1255 if (this.dependent == null) 1256 if (Configuration.errorOnAutoCreate()) 1257 throw new Error("Attempt to auto-create Coverage.dependent"); 1258 else if (Configuration.doAutoCreate()) 1259 this.dependent = new StringType(); // bb 1260 return this.dependent; 1261 } 1262 1263 public boolean hasDependentElement() { 1264 return this.dependent != null && !this.dependent.isEmpty(); 1265 } 1266 1267 public boolean hasDependent() { 1268 return this.dependent != null && !this.dependent.isEmpty(); 1269 } 1270 1271 /** 1272 * @param value {@link #dependent} (A designator for a dependent under the coverage.). This is the underlying object with id, value and extensions. The accessor "getDependent" gives direct access to the value 1273 */ 1274 public Coverage setDependentElement(StringType value) { 1275 this.dependent = value; 1276 return this; 1277 } 1278 1279 /** 1280 * @return A designator for a dependent under the coverage. 1281 */ 1282 public String getDependent() { 1283 return this.dependent == null ? null : this.dependent.getValue(); 1284 } 1285 1286 /** 1287 * @param value A designator for a dependent under the coverage. 1288 */ 1289 public Coverage setDependent(String value) { 1290 if (Utilities.noString(value)) 1291 this.dependent = null; 1292 else { 1293 if (this.dependent == null) 1294 this.dependent = new StringType(); 1295 this.dependent.setValue(value); 1296 } 1297 return this; 1298 } 1299 1300 /** 1301 * @return {@link #relationship} (The relationship of beneficiary (patient) to the subscriber.) 1302 */ 1303 public CodeableConcept getRelationship() { 1304 if (this.relationship == null) 1305 if (Configuration.errorOnAutoCreate()) 1306 throw new Error("Attempt to auto-create Coverage.relationship"); 1307 else if (Configuration.doAutoCreate()) 1308 this.relationship = new CodeableConcept(); // cc 1309 return this.relationship; 1310 } 1311 1312 public boolean hasRelationship() { 1313 return this.relationship != null && !this.relationship.isEmpty(); 1314 } 1315 1316 /** 1317 * @param value {@link #relationship} (The relationship of beneficiary (patient) to the subscriber.) 1318 */ 1319 public Coverage setRelationship(CodeableConcept value) { 1320 this.relationship = value; 1321 return this; 1322 } 1323 1324 /** 1325 * @return {@link #period} (Time period during which the coverage is in force. A missing start date indicates the start date isn't known, a missing end date means the coverage is continuing to be in force.) 1326 */ 1327 public Period getPeriod() { 1328 if (this.period == null) 1329 if (Configuration.errorOnAutoCreate()) 1330 throw new Error("Attempt to auto-create Coverage.period"); 1331 else if (Configuration.doAutoCreate()) 1332 this.period = new Period(); // cc 1333 return this.period; 1334 } 1335 1336 public boolean hasPeriod() { 1337 return this.period != null && !this.period.isEmpty(); 1338 } 1339 1340 /** 1341 * @param value {@link #period} (Time period during which the coverage is in force. A missing start date indicates the start date isn't known, a missing end date means the coverage is continuing to be in force.) 1342 */ 1343 public Coverage setPeriod(Period value) { 1344 this.period = value; 1345 return this; 1346 } 1347 1348 /** 1349 * @return {@link #payor} (The program or plan underwriter or payor including both insurance and non-insurance agreements, such as patient-pay agreements.) 1350 */ 1351 public List<Reference> getPayor() { 1352 if (this.payor == null) 1353 this.payor = new ArrayList<Reference>(); 1354 return this.payor; 1355 } 1356 1357 /** 1358 * @return Returns a reference to <code>this</code> for easy method chaining 1359 */ 1360 public Coverage setPayor(List<Reference> thePayor) { 1361 this.payor = thePayor; 1362 return this; 1363 } 1364 1365 public boolean hasPayor() { 1366 if (this.payor == null) 1367 return false; 1368 for (Reference item : this.payor) 1369 if (!item.isEmpty()) 1370 return true; 1371 return false; 1372 } 1373 1374 public Reference addPayor() { //3 1375 Reference t = new Reference(); 1376 if (this.payor == null) 1377 this.payor = new ArrayList<Reference>(); 1378 this.payor.add(t); 1379 return t; 1380 } 1381 1382 public Coverage addPayor(Reference t) { //3 1383 if (t == null) 1384 return this; 1385 if (this.payor == null) 1386 this.payor = new ArrayList<Reference>(); 1387 this.payor.add(t); 1388 return this; 1389 } 1390 1391 /** 1392 * @return The first repetition of repeating field {@link #payor}, creating it if it does not already exist {3} 1393 */ 1394 public Reference getPayorFirstRep() { 1395 if (getPayor().isEmpty()) { 1396 addPayor(); 1397 } 1398 return getPayor().get(0); 1399 } 1400 1401 /** 1402 * @return {@link #class_} (A suite of underwriter specific classifiers.) 1403 */ 1404 public List<ClassComponent> getClass_() { 1405 if (this.class_ == null) 1406 this.class_ = new ArrayList<ClassComponent>(); 1407 return this.class_; 1408 } 1409 1410 /** 1411 * @return Returns a reference to <code>this</code> for easy method chaining 1412 */ 1413 public Coverage setClass_(List<ClassComponent> theClass_) { 1414 this.class_ = theClass_; 1415 return this; 1416 } 1417 1418 public boolean hasClass_() { 1419 if (this.class_ == null) 1420 return false; 1421 for (ClassComponent item : this.class_) 1422 if (!item.isEmpty()) 1423 return true; 1424 return false; 1425 } 1426 1427 public ClassComponent addClass_() { //3 1428 ClassComponent t = new ClassComponent(); 1429 if (this.class_ == null) 1430 this.class_ = new ArrayList<ClassComponent>(); 1431 this.class_.add(t); 1432 return t; 1433 } 1434 1435 public Coverage addClass_(ClassComponent t) { //3 1436 if (t == null) 1437 return this; 1438 if (this.class_ == null) 1439 this.class_ = new ArrayList<ClassComponent>(); 1440 this.class_.add(t); 1441 return this; 1442 } 1443 1444 /** 1445 * @return The first repetition of repeating field {@link #class_}, creating it if it does not already exist {3} 1446 */ 1447 public ClassComponent getClass_FirstRep() { 1448 if (getClass_().isEmpty()) { 1449 addClass_(); 1450 } 1451 return getClass_().get(0); 1452 } 1453 1454 /** 1455 * @return {@link #order} (The order of applicability of this coverage relative to other coverages which are currently in force. Note, there may be gaps in the numbering and this does not imply primary, secondary etc. as the specific positioning of coverages depends upon the episode of care.). This is the underlying object with id, value and extensions. The accessor "getOrder" gives direct access to the value 1456 */ 1457 public PositiveIntType getOrderElement() { 1458 if (this.order == null) 1459 if (Configuration.errorOnAutoCreate()) 1460 throw new Error("Attempt to auto-create Coverage.order"); 1461 else if (Configuration.doAutoCreate()) 1462 this.order = new PositiveIntType(); // bb 1463 return this.order; 1464 } 1465 1466 public boolean hasOrderElement() { 1467 return this.order != null && !this.order.isEmpty(); 1468 } 1469 1470 public boolean hasOrder() { 1471 return this.order != null && !this.order.isEmpty(); 1472 } 1473 1474 /** 1475 * @param value {@link #order} (The order of applicability of this coverage relative to other coverages which are currently in force. Note, there may be gaps in the numbering and this does not imply primary, secondary etc. as the specific positioning of coverages depends upon the episode of care.). This is the underlying object with id, value and extensions. The accessor "getOrder" gives direct access to the value 1476 */ 1477 public Coverage setOrderElement(PositiveIntType value) { 1478 this.order = value; 1479 return this; 1480 } 1481 1482 /** 1483 * @return The order of applicability of this coverage relative to other coverages which are currently in force. Note, there may be gaps in the numbering and this does not imply primary, secondary etc. as the specific positioning of coverages depends upon the episode of care. 1484 */ 1485 public int getOrder() { 1486 return this.order == null || this.order.isEmpty() ? 0 : this.order.getValue(); 1487 } 1488 1489 /** 1490 * @param value The order of applicability of this coverage relative to other coverages which are currently in force. Note, there may be gaps in the numbering and this does not imply primary, secondary etc. as the specific positioning of coverages depends upon the episode of care. 1491 */ 1492 public Coverage setOrder(int value) { 1493 if (this.order == null) 1494 this.order = new PositiveIntType(); 1495 this.order.setValue(value); 1496 return this; 1497 } 1498 1499 /** 1500 * @return {@link #network} (The insurer-specific identifier for the insurer-defined network of providers to which the beneficiary may seek treatment which will be covered at the 'in-network' rate, otherwise 'out of network' terms and conditions apply.). This is the underlying object with id, value and extensions. The accessor "getNetwork" gives direct access to the value 1501 */ 1502 public StringType getNetworkElement() { 1503 if (this.network == null) 1504 if (Configuration.errorOnAutoCreate()) 1505 throw new Error("Attempt to auto-create Coverage.network"); 1506 else if (Configuration.doAutoCreate()) 1507 this.network = new StringType(); // bb 1508 return this.network; 1509 } 1510 1511 public boolean hasNetworkElement() { 1512 return this.network != null && !this.network.isEmpty(); 1513 } 1514 1515 public boolean hasNetwork() { 1516 return this.network != null && !this.network.isEmpty(); 1517 } 1518 1519 /** 1520 * @param value {@link #network} (The insurer-specific identifier for the insurer-defined network of providers to which the beneficiary may seek treatment which will be covered at the 'in-network' rate, otherwise 'out of network' terms and conditions apply.). This is the underlying object with id, value and extensions. The accessor "getNetwork" gives direct access to the value 1521 */ 1522 public Coverage setNetworkElement(StringType value) { 1523 this.network = value; 1524 return this; 1525 } 1526 1527 /** 1528 * @return The insurer-specific identifier for the insurer-defined network of providers to which the beneficiary may seek treatment which will be covered at the 'in-network' rate, otherwise 'out of network' terms and conditions apply. 1529 */ 1530 public String getNetwork() { 1531 return this.network == null ? null : this.network.getValue(); 1532 } 1533 1534 /** 1535 * @param value The insurer-specific identifier for the insurer-defined network of providers to which the beneficiary may seek treatment which will be covered at the 'in-network' rate, otherwise 'out of network' terms and conditions apply. 1536 */ 1537 public Coverage setNetwork(String value) { 1538 if (Utilities.noString(value)) 1539 this.network = null; 1540 else { 1541 if (this.network == null) 1542 this.network = new StringType(); 1543 this.network.setValue(value); 1544 } 1545 return this; 1546 } 1547 1548 /** 1549 * @return {@link #costToBeneficiary} (A suite of codes indicating the cost category and associated amount which have been detailed in the policy and may have been included on the health card.) 1550 */ 1551 public List<CostToBeneficiaryComponent> getCostToBeneficiary() { 1552 if (this.costToBeneficiary == null) 1553 this.costToBeneficiary = new ArrayList<CostToBeneficiaryComponent>(); 1554 return this.costToBeneficiary; 1555 } 1556 1557 /** 1558 * @return Returns a reference to <code>this</code> for easy method chaining 1559 */ 1560 public Coverage setCostToBeneficiary(List<CostToBeneficiaryComponent> theCostToBeneficiary) { 1561 this.costToBeneficiary = theCostToBeneficiary; 1562 return this; 1563 } 1564 1565 public boolean hasCostToBeneficiary() { 1566 if (this.costToBeneficiary == null) 1567 return false; 1568 for (CostToBeneficiaryComponent item : this.costToBeneficiary) 1569 if (!item.isEmpty()) 1570 return true; 1571 return false; 1572 } 1573 1574 public CostToBeneficiaryComponent addCostToBeneficiary() { //3 1575 CostToBeneficiaryComponent t = new CostToBeneficiaryComponent(); 1576 if (this.costToBeneficiary == null) 1577 this.costToBeneficiary = new ArrayList<CostToBeneficiaryComponent>(); 1578 this.costToBeneficiary.add(t); 1579 return t; 1580 } 1581 1582 public Coverage addCostToBeneficiary(CostToBeneficiaryComponent t) { //3 1583 if (t == null) 1584 return this; 1585 if (this.costToBeneficiary == null) 1586 this.costToBeneficiary = new ArrayList<CostToBeneficiaryComponent>(); 1587 this.costToBeneficiary.add(t); 1588 return this; 1589 } 1590 1591 /** 1592 * @return The first repetition of repeating field {@link #costToBeneficiary}, creating it if it does not already exist {3} 1593 */ 1594 public CostToBeneficiaryComponent getCostToBeneficiaryFirstRep() { 1595 if (getCostToBeneficiary().isEmpty()) { 1596 addCostToBeneficiary(); 1597 } 1598 return getCostToBeneficiary().get(0); 1599 } 1600 1601 /** 1602 * @return {@link #subrogation} (When 'subrogation=true' this insurance instance has been included not for adjudication but to provide insurers with the details to recover costs.). This is the underlying object with id, value and extensions. The accessor "getSubrogation" gives direct access to the value 1603 */ 1604 public BooleanType getSubrogationElement() { 1605 if (this.subrogation == null) 1606 if (Configuration.errorOnAutoCreate()) 1607 throw new Error("Attempt to auto-create Coverage.subrogation"); 1608 else if (Configuration.doAutoCreate()) 1609 this.subrogation = new BooleanType(); // bb 1610 return this.subrogation; 1611 } 1612 1613 public boolean hasSubrogationElement() { 1614 return this.subrogation != null && !this.subrogation.isEmpty(); 1615 } 1616 1617 public boolean hasSubrogation() { 1618 return this.subrogation != null && !this.subrogation.isEmpty(); 1619 } 1620 1621 /** 1622 * @param value {@link #subrogation} (When 'subrogation=true' this insurance instance has been included not for adjudication but to provide insurers with the details to recover costs.). This is the underlying object with id, value and extensions. The accessor "getSubrogation" gives direct access to the value 1623 */ 1624 public Coverage setSubrogationElement(BooleanType value) { 1625 this.subrogation = value; 1626 return this; 1627 } 1628 1629 /** 1630 * @return When 'subrogation=true' this insurance instance has been included not for adjudication but to provide insurers with the details to recover costs. 1631 */ 1632 public boolean getSubrogation() { 1633 return this.subrogation == null || this.subrogation.isEmpty() ? false : this.subrogation.getValue(); 1634 } 1635 1636 /** 1637 * @param value When 'subrogation=true' this insurance instance has been included not for adjudication but to provide insurers with the details to recover costs. 1638 */ 1639 public Coverage setSubrogation(boolean value) { 1640 if (this.subrogation == null) 1641 this.subrogation = new BooleanType(); 1642 this.subrogation.setValue(value); 1643 return this; 1644 } 1645 1646 /** 1647 * @return {@link #contract} (The policy(s) which constitute this insurance coverage.) 1648 */ 1649 public List<Reference> getContract() { 1650 if (this.contract == null) 1651 this.contract = new ArrayList<Reference>(); 1652 return this.contract; 1653 } 1654 1655 /** 1656 * @return Returns a reference to <code>this</code> for easy method chaining 1657 */ 1658 public Coverage setContract(List<Reference> theContract) { 1659 this.contract = theContract; 1660 return this; 1661 } 1662 1663 public boolean hasContract() { 1664 if (this.contract == null) 1665 return false; 1666 for (Reference item : this.contract) 1667 if (!item.isEmpty()) 1668 return true; 1669 return false; 1670 } 1671 1672 public Reference addContract() { //3 1673 Reference t = new Reference(); 1674 if (this.contract == null) 1675 this.contract = new ArrayList<Reference>(); 1676 this.contract.add(t); 1677 return t; 1678 } 1679 1680 public Coverage addContract(Reference t) { //3 1681 if (t == null) 1682 return this; 1683 if (this.contract == null) 1684 this.contract = new ArrayList<Reference>(); 1685 this.contract.add(t); 1686 return this; 1687 } 1688 1689 /** 1690 * @return The first repetition of repeating field {@link #contract}, creating it if it does not already exist {3} 1691 */ 1692 public Reference getContractFirstRep() { 1693 if (getContract().isEmpty()) { 1694 addContract(); 1695 } 1696 return getContract().get(0); 1697 } 1698 1699 protected void listChildren(List<Property> children) { 1700 super.listChildren(children); 1701 children.add(new Property("identifier", "Identifier", "A unique identifier assigned to this coverage.", 0, java.lang.Integer.MAX_VALUE, identifier)); 1702 children.add(new Property("status", "code", "The status of the resource instance.", 0, 1, status)); 1703 children.add(new Property("type", "CodeableConcept", "The type of coverage: social program, medical plan, accident coverage (workers compensation, auto), group health or payment by an individual or organization.", 0, 1, type)); 1704 children.add(new Property("policyHolder", "Reference(Patient|RelatedPerson|Organization)", "The party who 'owns' the insurance policy.", 0, 1, policyHolder)); 1705 children.add(new Property("subscriber", "Reference(Patient|RelatedPerson)", "The party who has signed-up for or 'owns' the contractual relationship to the policy or to whom the benefit of the policy for services rendered to them or their family is due.", 0, 1, subscriber)); 1706 children.add(new Property("subscriberId", "Identifier", "The insurer assigned ID for the Subscriber.", 0, 1, subscriberId)); 1707 children.add(new Property("beneficiary", "Reference(Patient)", "The party who benefits from the insurance coverage; the patient when products and/or services are provided.", 0, 1, beneficiary)); 1708 children.add(new Property("dependent", "string", "A designator for a dependent under the coverage.", 0, 1, dependent)); 1709 children.add(new Property("relationship", "CodeableConcept", "The relationship of beneficiary (patient) to the subscriber.", 0, 1, relationship)); 1710 children.add(new Property("period", "Period", "Time period during which the coverage is in force. A missing start date indicates the start date isn't known, a missing end date means the coverage is continuing to be in force.", 0, 1, period)); 1711 children.add(new Property("payor", "Reference(Organization|Patient|RelatedPerson)", "The program or plan underwriter or payor including both insurance and non-insurance agreements, such as patient-pay agreements.", 0, java.lang.Integer.MAX_VALUE, payor)); 1712 children.add(new Property("class", "", "A suite of underwriter specific classifiers.", 0, java.lang.Integer.MAX_VALUE, class_)); 1713 children.add(new Property("order", "positiveInt", "The order of applicability of this coverage relative to other coverages which are currently in force. Note, there may be gaps in the numbering and this does not imply primary, secondary etc. as the specific positioning of coverages depends upon the episode of care.", 0, 1, order)); 1714 children.add(new Property("network", "string", "The insurer-specific identifier for the insurer-defined network of providers to which the beneficiary may seek treatment which will be covered at the 'in-network' rate, otherwise 'out of network' terms and conditions apply.", 0, 1, network)); 1715 children.add(new Property("costToBeneficiary", "", "A suite of codes indicating the cost category and associated amount which have been detailed in the policy and may have been included on the health card.", 0, java.lang.Integer.MAX_VALUE, costToBeneficiary)); 1716 children.add(new Property("subrogation", "boolean", "When 'subrogation=true' this insurance instance has been included not for adjudication but to provide insurers with the details to recover costs.", 0, 1, subrogation)); 1717 children.add(new Property("contract", "Reference(Contract)", "The policy(s) which constitute this insurance coverage.", 0, java.lang.Integer.MAX_VALUE, contract)); 1718 } 1719 1720 @Override 1721 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1722 switch (_hash) { 1723 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "A unique identifier assigned to this coverage.", 0, java.lang.Integer.MAX_VALUE, identifier); 1724 case -892481550: /*status*/ return new Property("status", "code", "The status of the resource instance.", 0, 1, status); 1725 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The type of coverage: social program, medical plan, accident coverage (workers compensation, auto), group health or payment by an individual or organization.", 0, 1, type); 1726 case 2046898558: /*policyHolder*/ return new Property("policyHolder", "Reference(Patient|RelatedPerson|Organization)", "The party who 'owns' the insurance policy.", 0, 1, policyHolder); 1727 case -1219769240: /*subscriber*/ return new Property("subscriber", "Reference(Patient|RelatedPerson)", "The party who has signed-up for or 'owns' the contractual relationship to the policy or to whom the benefit of the policy for services rendered to them or their family is due.", 0, 1, subscriber); 1728 case 327834531: /*subscriberId*/ return new Property("subscriberId", "Identifier", "The insurer assigned ID for the Subscriber.", 0, 1, subscriberId); 1729 case -565102875: /*beneficiary*/ return new Property("beneficiary", "Reference(Patient)", "The party who benefits from the insurance coverage; the patient when products and/or services are provided.", 0, 1, beneficiary); 1730 case -1109226753: /*dependent*/ return new Property("dependent", "string", "A designator for a dependent under the coverage.", 0, 1, dependent); 1731 case -261851592: /*relationship*/ return new Property("relationship", "CodeableConcept", "The relationship of beneficiary (patient) to the subscriber.", 0, 1, relationship); 1732 case -991726143: /*period*/ return new Property("period", "Period", "Time period during which the coverage is in force. A missing start date indicates the start date isn't known, a missing end date means the coverage is continuing to be in force.", 0, 1, period); 1733 case 106443915: /*payor*/ return new Property("payor", "Reference(Organization|Patient|RelatedPerson)", "The program or plan underwriter or payor including both insurance and non-insurance agreements, such as patient-pay agreements.", 0, java.lang.Integer.MAX_VALUE, payor); 1734 case 94742904: /*class*/ return new Property("class", "", "A suite of underwriter specific classifiers.", 0, java.lang.Integer.MAX_VALUE, class_); 1735 case 106006350: /*order*/ return new Property("order", "positiveInt", "The order of applicability of this coverage relative to other coverages which are currently in force. Note, there may be gaps in the numbering and this does not imply primary, secondary etc. as the specific positioning of coverages depends upon the episode of care.", 0, 1, order); 1736 case 1843485230: /*network*/ return new Property("network", "string", "The insurer-specific identifier for the insurer-defined network of providers to which the beneficiary may seek treatment which will be covered at the 'in-network' rate, otherwise 'out of network' terms and conditions apply.", 0, 1, network); 1737 case -1866474851: /*costToBeneficiary*/ return new Property("costToBeneficiary", "", "A suite of codes indicating the cost category and associated amount which have been detailed in the policy and may have been included on the health card.", 0, java.lang.Integer.MAX_VALUE, costToBeneficiary); 1738 case 837389739: /*subrogation*/ return new Property("subrogation", "boolean", "When 'subrogation=true' this insurance instance has been included not for adjudication but to provide insurers with the details to recover costs.", 0, 1, subrogation); 1739 case -566947566: /*contract*/ return new Property("contract", "Reference(Contract)", "The policy(s) which constitute this insurance coverage.", 0, java.lang.Integer.MAX_VALUE, contract); 1740 default: return super.getNamedProperty(_hash, _name, _checkValid); 1741 } 1742 1743 } 1744 1745 @Override 1746 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1747 switch (hash) { 1748 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 1749 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<FinancialResourceStatusCodes> 1750 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 1751 case 2046898558: /*policyHolder*/ return this.policyHolder == null ? new Base[0] : new Base[] {this.policyHolder}; // Reference 1752 case -1219769240: /*subscriber*/ return this.subscriber == null ? new Base[0] : new Base[] {this.subscriber}; // Reference 1753 case 327834531: /*subscriberId*/ return this.subscriberId == null ? new Base[0] : new Base[] {this.subscriberId}; // Identifier 1754 case -565102875: /*beneficiary*/ return this.beneficiary == null ? new Base[0] : new Base[] {this.beneficiary}; // Reference 1755 case -1109226753: /*dependent*/ return this.dependent == null ? new Base[0] : new Base[] {this.dependent}; // StringType 1756 case -261851592: /*relationship*/ return this.relationship == null ? new Base[0] : new Base[] {this.relationship}; // CodeableConcept 1757 case -991726143: /*period*/ return this.period == null ? new Base[0] : new Base[] {this.period}; // Period 1758 case 106443915: /*payor*/ return this.payor == null ? new Base[0] : this.payor.toArray(new Base[this.payor.size()]); // Reference 1759 case 94742904: /*class*/ return this.class_ == null ? new Base[0] : this.class_.toArray(new Base[this.class_.size()]); // ClassComponent 1760 case 106006350: /*order*/ return this.order == null ? new Base[0] : new Base[] {this.order}; // PositiveIntType 1761 case 1843485230: /*network*/ return this.network == null ? new Base[0] : new Base[] {this.network}; // StringType 1762 case -1866474851: /*costToBeneficiary*/ return this.costToBeneficiary == null ? new Base[0] : this.costToBeneficiary.toArray(new Base[this.costToBeneficiary.size()]); // CostToBeneficiaryComponent 1763 case 837389739: /*subrogation*/ return this.subrogation == null ? new Base[0] : new Base[] {this.subrogation}; // BooleanType 1764 case -566947566: /*contract*/ return this.contract == null ? new Base[0] : this.contract.toArray(new Base[this.contract.size()]); // Reference 1765 default: return super.getProperty(hash, name, checkValid); 1766 } 1767 1768 } 1769 1770 @Override 1771 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1772 switch (hash) { 1773 case -1618432855: // identifier 1774 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); // Identifier 1775 return value; 1776 case -892481550: // status 1777 value = new FinancialResourceStatusCodesEnumFactory().fromType(TypeConvertor.castToCode(value)); 1778 this.status = (Enumeration) value; // Enumeration<FinancialResourceStatusCodes> 1779 return value; 1780 case 3575610: // type 1781 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1782 return value; 1783 case 2046898558: // policyHolder 1784 this.policyHolder = TypeConvertor.castToReference(value); // Reference 1785 return value; 1786 case -1219769240: // subscriber 1787 this.subscriber = TypeConvertor.castToReference(value); // Reference 1788 return value; 1789 case 327834531: // subscriberId 1790 this.subscriberId = TypeConvertor.castToIdentifier(value); // Identifier 1791 return value; 1792 case -565102875: // beneficiary 1793 this.beneficiary = TypeConvertor.castToReference(value); // Reference 1794 return value; 1795 case -1109226753: // dependent 1796 this.dependent = TypeConvertor.castToString(value); // StringType 1797 return value; 1798 case -261851592: // relationship 1799 this.relationship = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1800 return value; 1801 case -991726143: // period 1802 this.period = TypeConvertor.castToPeriod(value); // Period 1803 return value; 1804 case 106443915: // payor 1805 this.getPayor().add(TypeConvertor.castToReference(value)); // Reference 1806 return value; 1807 case 94742904: // class 1808 this.getClass_().add((ClassComponent) value); // ClassComponent 1809 return value; 1810 case 106006350: // order 1811 this.order = TypeConvertor.castToPositiveInt(value); // PositiveIntType 1812 return value; 1813 case 1843485230: // network 1814 this.network = TypeConvertor.castToString(value); // StringType 1815 return value; 1816 case -1866474851: // costToBeneficiary 1817 this.getCostToBeneficiary().add((CostToBeneficiaryComponent) value); // CostToBeneficiaryComponent 1818 return value; 1819 case 837389739: // subrogation 1820 this.subrogation = TypeConvertor.castToBoolean(value); // BooleanType 1821 return value; 1822 case -566947566: // contract 1823 this.getContract().add(TypeConvertor.castToReference(value)); // Reference 1824 return value; 1825 default: return super.setProperty(hash, name, value); 1826 } 1827 1828 } 1829 1830 @Override 1831 public Base setProperty(String name, Base value) throws FHIRException { 1832 if (name.equals("identifier")) { 1833 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); 1834 } else if (name.equals("status")) { 1835 value = new FinancialResourceStatusCodesEnumFactory().fromType(TypeConvertor.castToCode(value)); 1836 this.status = (Enumeration) value; // Enumeration<FinancialResourceStatusCodes> 1837 } else if (name.equals("type")) { 1838 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1839 } else if (name.equals("policyHolder")) { 1840 this.policyHolder = TypeConvertor.castToReference(value); // Reference 1841 } else if (name.equals("subscriber")) { 1842 this.subscriber = TypeConvertor.castToReference(value); // Reference 1843 } else if (name.equals("subscriberId")) { 1844 this.subscriberId = TypeConvertor.castToIdentifier(value); // Identifier 1845 } else if (name.equals("beneficiary")) { 1846 this.beneficiary = TypeConvertor.castToReference(value); // Reference 1847 } else if (name.equals("dependent")) { 1848 this.dependent = TypeConvertor.castToString(value); // StringType 1849 } else if (name.equals("relationship")) { 1850 this.relationship = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1851 } else if (name.equals("period")) { 1852 this.period = TypeConvertor.castToPeriod(value); // Period 1853 } else if (name.equals("payor")) { 1854 this.getPayor().add(TypeConvertor.castToReference(value)); 1855 } else if (name.equals("class")) { 1856 this.getClass_().add((ClassComponent) value); 1857 } else if (name.equals("order")) { 1858 this.order = TypeConvertor.castToPositiveInt(value); // PositiveIntType 1859 } else if (name.equals("network")) { 1860 this.network = TypeConvertor.castToString(value); // StringType 1861 } else if (name.equals("costToBeneficiary")) { 1862 this.getCostToBeneficiary().add((CostToBeneficiaryComponent) value); 1863 } else if (name.equals("subrogation")) { 1864 this.subrogation = TypeConvertor.castToBoolean(value); // BooleanType 1865 } else if (name.equals("contract")) { 1866 this.getContract().add(TypeConvertor.castToReference(value)); 1867 } else 1868 return super.setProperty(name, value); 1869 return value; 1870 } 1871 1872 @Override 1873 public Base makeProperty(int hash, String name) throws FHIRException { 1874 switch (hash) { 1875 case -1618432855: return addIdentifier(); 1876 case -892481550: return getStatusElement(); 1877 case 3575610: return getType(); 1878 case 2046898558: return getPolicyHolder(); 1879 case -1219769240: return getSubscriber(); 1880 case 327834531: return getSubscriberId(); 1881 case -565102875: return getBeneficiary(); 1882 case -1109226753: return getDependentElement(); 1883 case -261851592: return getRelationship(); 1884 case -991726143: return getPeriod(); 1885 case 106443915: return addPayor(); 1886 case 94742904: return addClass_(); 1887 case 106006350: return getOrderElement(); 1888 case 1843485230: return getNetworkElement(); 1889 case -1866474851: return addCostToBeneficiary(); 1890 case 837389739: return getSubrogationElement(); 1891 case -566947566: return addContract(); 1892 default: return super.makeProperty(hash, name); 1893 } 1894 1895 } 1896 1897 @Override 1898 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1899 switch (hash) { 1900 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 1901 case -892481550: /*status*/ return new String[] {"code"}; 1902 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 1903 case 2046898558: /*policyHolder*/ return new String[] {"Reference"}; 1904 case -1219769240: /*subscriber*/ return new String[] {"Reference"}; 1905 case 327834531: /*subscriberId*/ return new String[] {"Identifier"}; 1906 case -565102875: /*beneficiary*/ return new String[] {"Reference"}; 1907 case -1109226753: /*dependent*/ return new String[] {"string"}; 1908 case -261851592: /*relationship*/ return new String[] {"CodeableConcept"}; 1909 case -991726143: /*period*/ return new String[] {"Period"}; 1910 case 106443915: /*payor*/ return new String[] {"Reference"}; 1911 case 94742904: /*class*/ return new String[] {}; 1912 case 106006350: /*order*/ return new String[] {"positiveInt"}; 1913 case 1843485230: /*network*/ return new String[] {"string"}; 1914 case -1866474851: /*costToBeneficiary*/ return new String[] {}; 1915 case 837389739: /*subrogation*/ return new String[] {"boolean"}; 1916 case -566947566: /*contract*/ return new String[] {"Reference"}; 1917 default: return super.getTypesForProperty(hash, name); 1918 } 1919 1920 } 1921 1922 @Override 1923 public Base addChild(String name) throws FHIRException { 1924 if (name.equals("identifier")) { 1925 return addIdentifier(); 1926 } 1927 else if (name.equals("status")) { 1928 throw new FHIRException("Cannot call addChild on a primitive type Coverage.status"); 1929 } 1930 else if (name.equals("type")) { 1931 this.type = new CodeableConcept(); 1932 return this.type; 1933 } 1934 else if (name.equals("policyHolder")) { 1935 this.policyHolder = new Reference(); 1936 return this.policyHolder; 1937 } 1938 else if (name.equals("subscriber")) { 1939 this.subscriber = new Reference(); 1940 return this.subscriber; 1941 } 1942 else if (name.equals("subscriberId")) { 1943 this.subscriberId = new Identifier(); 1944 return this.subscriberId; 1945 } 1946 else if (name.equals("beneficiary")) { 1947 this.beneficiary = new Reference(); 1948 return this.beneficiary; 1949 } 1950 else if (name.equals("dependent")) { 1951 throw new FHIRException("Cannot call addChild on a primitive type Coverage.dependent"); 1952 } 1953 else if (name.equals("relationship")) { 1954 this.relationship = new CodeableConcept(); 1955 return this.relationship; 1956 } 1957 else if (name.equals("period")) { 1958 this.period = new Period(); 1959 return this.period; 1960 } 1961 else if (name.equals("payor")) { 1962 return addPayor(); 1963 } 1964 else if (name.equals("class")) { 1965 return addClass_(); 1966 } 1967 else if (name.equals("order")) { 1968 throw new FHIRException("Cannot call addChild on a primitive type Coverage.order"); 1969 } 1970 else if (name.equals("network")) { 1971 throw new FHIRException("Cannot call addChild on a primitive type Coverage.network"); 1972 } 1973 else if (name.equals("costToBeneficiary")) { 1974 return addCostToBeneficiary(); 1975 } 1976 else if (name.equals("subrogation")) { 1977 throw new FHIRException("Cannot call addChild on a primitive type Coverage.subrogation"); 1978 } 1979 else if (name.equals("contract")) { 1980 return addContract(); 1981 } 1982 else 1983 return super.addChild(name); 1984 } 1985 1986 public String fhirType() { 1987 return "Coverage"; 1988 1989 } 1990 1991 public Coverage copy() { 1992 Coverage dst = new Coverage(); 1993 copyValues(dst); 1994 return dst; 1995 } 1996 1997 public void copyValues(Coverage dst) { 1998 super.copyValues(dst); 1999 if (identifier != null) { 2000 dst.identifier = new ArrayList<Identifier>(); 2001 for (Identifier i : identifier) 2002 dst.identifier.add(i.copy()); 2003 }; 2004 dst.status = status == null ? null : status.copy(); 2005 dst.type = type == null ? null : type.copy(); 2006 dst.policyHolder = policyHolder == null ? null : policyHolder.copy(); 2007 dst.subscriber = subscriber == null ? null : subscriber.copy(); 2008 dst.subscriberId = subscriberId == null ? null : subscriberId.copy(); 2009 dst.beneficiary = beneficiary == null ? null : beneficiary.copy(); 2010 dst.dependent = dependent == null ? null : dependent.copy(); 2011 dst.relationship = relationship == null ? null : relationship.copy(); 2012 dst.period = period == null ? null : period.copy(); 2013 if (payor != null) { 2014 dst.payor = new ArrayList<Reference>(); 2015 for (Reference i : payor) 2016 dst.payor.add(i.copy()); 2017 }; 2018 if (class_ != null) { 2019 dst.class_ = new ArrayList<ClassComponent>(); 2020 for (ClassComponent i : class_) 2021 dst.class_.add(i.copy()); 2022 }; 2023 dst.order = order == null ? null : order.copy(); 2024 dst.network = network == null ? null : network.copy(); 2025 if (costToBeneficiary != null) { 2026 dst.costToBeneficiary = new ArrayList<CostToBeneficiaryComponent>(); 2027 for (CostToBeneficiaryComponent i : costToBeneficiary) 2028 dst.costToBeneficiary.add(i.copy()); 2029 }; 2030 dst.subrogation = subrogation == null ? null : subrogation.copy(); 2031 if (contract != null) { 2032 dst.contract = new ArrayList<Reference>(); 2033 for (Reference i : contract) 2034 dst.contract.add(i.copy()); 2035 }; 2036 } 2037 2038 protected Coverage typedCopy() { 2039 return copy(); 2040 } 2041 2042 @Override 2043 public boolean equalsDeep(Base other_) { 2044 if (!super.equalsDeep(other_)) 2045 return false; 2046 if (!(other_ instanceof Coverage)) 2047 return false; 2048 Coverage o = (Coverage) other_; 2049 return compareDeep(identifier, o.identifier, true) && compareDeep(status, o.status, true) && compareDeep(type, o.type, true) 2050 && compareDeep(policyHolder, o.policyHolder, true) && compareDeep(subscriber, o.subscriber, true) 2051 && compareDeep(subscriberId, o.subscriberId, true) && compareDeep(beneficiary, o.beneficiary, true) 2052 && compareDeep(dependent, o.dependent, true) && compareDeep(relationship, o.relationship, true) 2053 && compareDeep(period, o.period, true) && compareDeep(payor, o.payor, true) && compareDeep(class_, o.class_, true) 2054 && compareDeep(order, o.order, true) && compareDeep(network, o.network, true) && compareDeep(costToBeneficiary, o.costToBeneficiary, true) 2055 && compareDeep(subrogation, o.subrogation, true) && compareDeep(contract, o.contract, true); 2056 } 2057 2058 @Override 2059 public boolean equalsShallow(Base other_) { 2060 if (!super.equalsShallow(other_)) 2061 return false; 2062 if (!(other_ instanceof Coverage)) 2063 return false; 2064 Coverage o = (Coverage) other_; 2065 return compareValues(status, o.status, true) && compareValues(dependent, o.dependent, true) && compareValues(order, o.order, true) 2066 && compareValues(network, o.network, true) && compareValues(subrogation, o.subrogation, true); 2067 } 2068 2069 public boolean isEmpty() { 2070 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, status, type 2071 , policyHolder, subscriber, subscriberId, beneficiary, dependent, relationship, period 2072 , payor, class_, order, network, costToBeneficiary, subrogation, contract); 2073 } 2074 2075 @Override 2076 public ResourceType getResourceType() { 2077 return ResourceType.Coverage; 2078 } 2079 2080 /** 2081 * Search parameter: <b>beneficiary</b> 2082 * <p> 2083 * Description: <b>Covered party</b><br> 2084 * Type: <b>reference</b><br> 2085 * Path: <b>Coverage.beneficiary</b><br> 2086 * </p> 2087 */ 2088 @SearchParamDefinition(name="beneficiary", path="Coverage.beneficiary", description="Covered party", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Patient") }, target={Patient.class } ) 2089 public static final String SP_BENEFICIARY = "beneficiary"; 2090 /** 2091 * <b>Fluent Client</b> search parameter constant for <b>beneficiary</b> 2092 * <p> 2093 * Description: <b>Covered party</b><br> 2094 * Type: <b>reference</b><br> 2095 * Path: <b>Coverage.beneficiary</b><br> 2096 * </p> 2097 */ 2098 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam BENEFICIARY = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_BENEFICIARY); 2099 2100/** 2101 * Constant for fluent queries to be used to add include statements. Specifies 2102 * the path value of "<b>Coverage:beneficiary</b>". 2103 */ 2104 public static final ca.uhn.fhir.model.api.Include INCLUDE_BENEFICIARY = new ca.uhn.fhir.model.api.Include("Coverage:beneficiary").toLocked(); 2105 2106 /** 2107 * Search parameter: <b>class-type</b> 2108 * <p> 2109 * Description: <b>Coverage class (eg. plan, group)</b><br> 2110 * Type: <b>token</b><br> 2111 * Path: <b>Coverage.class.type</b><br> 2112 * </p> 2113 */ 2114 @SearchParamDefinition(name="class-type", path="Coverage.class.type", description="Coverage class (eg. plan, group)", type="token" ) 2115 public static final String SP_CLASS_TYPE = "class-type"; 2116 /** 2117 * <b>Fluent Client</b> search parameter constant for <b>class-type</b> 2118 * <p> 2119 * Description: <b>Coverage class (eg. plan, group)</b><br> 2120 * Type: <b>token</b><br> 2121 * Path: <b>Coverage.class.type</b><br> 2122 * </p> 2123 */ 2124 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CLASS_TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CLASS_TYPE); 2125 2126 /** 2127 * Search parameter: <b>class-value</b> 2128 * <p> 2129 * Description: <b>Value of the class (eg. Plan number, group number)</b><br> 2130 * Type: <b>string</b><br> 2131 * Path: <b>Coverage.class.value</b><br> 2132 * </p> 2133 */ 2134 @SearchParamDefinition(name="class-value", path="Coverage.class.value", description="Value of the class (eg. Plan number, group number)", type="string" ) 2135 public static final String SP_CLASS_VALUE = "class-value"; 2136 /** 2137 * <b>Fluent Client</b> search parameter constant for <b>class-value</b> 2138 * <p> 2139 * Description: <b>Value of the class (eg. Plan number, group number)</b><br> 2140 * Type: <b>string</b><br> 2141 * Path: <b>Coverage.class.value</b><br> 2142 * </p> 2143 */ 2144 public static final ca.uhn.fhir.rest.gclient.StringClientParam CLASS_VALUE = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_CLASS_VALUE); 2145 2146 /** 2147 * Search parameter: <b>dependent</b> 2148 * <p> 2149 * Description: <b>Dependent number</b><br> 2150 * Type: <b>string</b><br> 2151 * Path: <b>Coverage.dependent</b><br> 2152 * </p> 2153 */ 2154 @SearchParamDefinition(name="dependent", path="Coverage.dependent", description="Dependent number", type="string" ) 2155 public static final String SP_DEPENDENT = "dependent"; 2156 /** 2157 * <b>Fluent Client</b> search parameter constant for <b>dependent</b> 2158 * <p> 2159 * Description: <b>Dependent number</b><br> 2160 * Type: <b>string</b><br> 2161 * Path: <b>Coverage.dependent</b><br> 2162 * </p> 2163 */ 2164 public static final ca.uhn.fhir.rest.gclient.StringClientParam DEPENDENT = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_DEPENDENT); 2165 2166 /** 2167 * Search parameter: <b>identifier</b> 2168 * <p> 2169 * Description: <b>The primary identifier of the insured and the coverage</b><br> 2170 * Type: <b>token</b><br> 2171 * Path: <b>Coverage.identifier</b><br> 2172 * </p> 2173 */ 2174 @SearchParamDefinition(name="identifier", path="Coverage.identifier", description="The primary identifier of the insured and the coverage", type="token" ) 2175 public static final String SP_IDENTIFIER = "identifier"; 2176 /** 2177 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 2178 * <p> 2179 * Description: <b>The primary identifier of the insured and the coverage</b><br> 2180 * Type: <b>token</b><br> 2181 * Path: <b>Coverage.identifier</b><br> 2182 * </p> 2183 */ 2184 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 2185 2186 /** 2187 * Search parameter: <b>patient</b> 2188 * <p> 2189 * Description: <b>Retrieve coverages for a patient</b><br> 2190 * Type: <b>reference</b><br> 2191 * Path: <b>Coverage.beneficiary</b><br> 2192 * </p> 2193 */ 2194 @SearchParamDefinition(name="patient", path="Coverage.beneficiary", description="Retrieve coverages for a patient", type="reference", target={Patient.class } ) 2195 public static final String SP_PATIENT = "patient"; 2196 /** 2197 * <b>Fluent Client</b> search parameter constant for <b>patient</b> 2198 * <p> 2199 * Description: <b>Retrieve coverages for a patient</b><br> 2200 * Type: <b>reference</b><br> 2201 * Path: <b>Coverage.beneficiary</b><br> 2202 * </p> 2203 */ 2204 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT); 2205 2206/** 2207 * Constant for fluent queries to be used to add include statements. Specifies 2208 * the path value of "<b>Coverage:patient</b>". 2209 */ 2210 public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("Coverage:patient").toLocked(); 2211 2212 /** 2213 * Search parameter: <b>payor</b> 2214 * <p> 2215 * Description: <b>The identity of the insurer or party paying for services</b><br> 2216 * Type: <b>reference</b><br> 2217 * Path: <b>Coverage.payor</b><br> 2218 * </p> 2219 */ 2220 @SearchParamDefinition(name="payor", path="Coverage.payor", description="The identity of the insurer or party paying for services", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Patient"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for RelatedPerson") }, target={Organization.class, Patient.class, RelatedPerson.class } ) 2221 public static final String SP_PAYOR = "payor"; 2222 /** 2223 * <b>Fluent Client</b> search parameter constant for <b>payor</b> 2224 * <p> 2225 * Description: <b>The identity of the insurer or party paying for services</b><br> 2226 * Type: <b>reference</b><br> 2227 * Path: <b>Coverage.payor</b><br> 2228 * </p> 2229 */ 2230 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PAYOR = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PAYOR); 2231 2232/** 2233 * Constant for fluent queries to be used to add include statements. Specifies 2234 * the path value of "<b>Coverage:payor</b>". 2235 */ 2236 public static final ca.uhn.fhir.model.api.Include INCLUDE_PAYOR = new ca.uhn.fhir.model.api.Include("Coverage:payor").toLocked(); 2237 2238 /** 2239 * Search parameter: <b>policy-holder</b> 2240 * <p> 2241 * Description: <b>Reference to the policyholder</b><br> 2242 * Type: <b>reference</b><br> 2243 * Path: <b>Coverage.policyHolder</b><br> 2244 * </p> 2245 */ 2246 @SearchParamDefinition(name="policy-holder", path="Coverage.policyHolder", description="Reference to the policyholder", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Patient"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for RelatedPerson") }, target={Organization.class, Patient.class, RelatedPerson.class } ) 2247 public static final String SP_POLICY_HOLDER = "policy-holder"; 2248 /** 2249 * <b>Fluent Client</b> search parameter constant for <b>policy-holder</b> 2250 * <p> 2251 * Description: <b>Reference to the policyholder</b><br> 2252 * Type: <b>reference</b><br> 2253 * Path: <b>Coverage.policyHolder</b><br> 2254 * </p> 2255 */ 2256 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam POLICY_HOLDER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_POLICY_HOLDER); 2257 2258/** 2259 * Constant for fluent queries to be used to add include statements. Specifies 2260 * the path value of "<b>Coverage:policy-holder</b>". 2261 */ 2262 public static final ca.uhn.fhir.model.api.Include INCLUDE_POLICY_HOLDER = new ca.uhn.fhir.model.api.Include("Coverage:policy-holder").toLocked(); 2263 2264 /** 2265 * Search parameter: <b>status</b> 2266 * <p> 2267 * Description: <b>The status of the Coverage</b><br> 2268 * Type: <b>token</b><br> 2269 * Path: <b>Coverage.status</b><br> 2270 * </p> 2271 */ 2272 @SearchParamDefinition(name="status", path="Coverage.status", description="The status of the Coverage", type="token" ) 2273 public static final String SP_STATUS = "status"; 2274 /** 2275 * <b>Fluent Client</b> search parameter constant for <b>status</b> 2276 * <p> 2277 * Description: <b>The status of the Coverage</b><br> 2278 * Type: <b>token</b><br> 2279 * Path: <b>Coverage.status</b><br> 2280 * </p> 2281 */ 2282 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 2283 2284 /** 2285 * Search parameter: <b>subscriber</b> 2286 * <p> 2287 * Description: <b>Reference to the subscriber</b><br> 2288 * Type: <b>reference</b><br> 2289 * Path: <b>Coverage.subscriber</b><br> 2290 * </p> 2291 */ 2292 @SearchParamDefinition(name="subscriber", path="Coverage.subscriber", description="Reference to the subscriber", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Patient"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for RelatedPerson") }, target={Patient.class, RelatedPerson.class } ) 2293 public static final String SP_SUBSCRIBER = "subscriber"; 2294 /** 2295 * <b>Fluent Client</b> search parameter constant for <b>subscriber</b> 2296 * <p> 2297 * Description: <b>Reference to the subscriber</b><br> 2298 * Type: <b>reference</b><br> 2299 * Path: <b>Coverage.subscriber</b><br> 2300 * </p> 2301 */ 2302 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SUBSCRIBER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SUBSCRIBER); 2303 2304/** 2305 * Constant for fluent queries to be used to add include statements. Specifies 2306 * the path value of "<b>Coverage:subscriber</b>". 2307 */ 2308 public static final ca.uhn.fhir.model.api.Include INCLUDE_SUBSCRIBER = new ca.uhn.fhir.model.api.Include("Coverage:subscriber").toLocked(); 2309 2310 /** 2311 * Search parameter: <b>type</b> 2312 * <p> 2313 * Description: <b>The kind of coverage (health plan, auto, Workers Compensation)</b><br> 2314 * Type: <b>token</b><br> 2315 * Path: <b>Coverage.type</b><br> 2316 * </p> 2317 */ 2318 @SearchParamDefinition(name="type", path="Coverage.type", description="The kind of coverage (health plan, auto, Workers Compensation)", type="token" ) 2319 public static final String SP_TYPE = "type"; 2320 /** 2321 * <b>Fluent Client</b> search parameter constant for <b>type</b> 2322 * <p> 2323 * Description: <b>The kind of coverage (health plan, auto, Workers Compensation)</b><br> 2324 * Type: <b>token</b><br> 2325 * Path: <b>Coverage.type</b><br> 2326 * </p> 2327 */ 2328 public static final ca.uhn.fhir.rest.gclient.TokenClientParam TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_TYPE); 2329 2330 2331} 2332