001package org.hl7.fhir.r5.model; 002 003/*- 004 * #%L 005 * org.hl7.fhir.r5 006 * %% 007 * Copyright (C) 2014 - 2019 Health Level 7 008 * %% 009 * Licensed under the Apache License, Version 2.0 (the "License"); 010 * you may not use this file except in compliance with the License. 011 * You may obtain a copy of the License at 012 * 013 * http://www.apache.org/licenses/LICENSE-2.0 014 * 015 * Unless required by applicable law or agreed to in writing, software 016 * distributed under the License is distributed on an "AS IS" BASIS, 017 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 018 * See the License for the specific language governing permissions and 019 * limitations under the License. 020 * #L% 021 */ 022 023/* 024 Copyright (c) 2011+, HL7, Inc. 025 All rights reserved. 026 027 Redistribution and use in source and binary forms, with or without modification, 028 are permitted provided that the following conditions are met: 029 030 * Redistributions of source code must retain the above copyright notice, this 031 list of conditions and the following disclaimer. 032 * Redistributions in binary form must reproduce the above copyright notice, 033 this list of conditions and the following disclaimer in the documentation 034 and/or other materials provided with the distribution. 035 * Neither the name of HL7 nor the names of its contributors may be used to 036 endorse or promote products derived from this software without specific 037 prior written permission. 038 039 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 040 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 041 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 042 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 043 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 044 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 045 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 046 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 047 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 048 POSSIBILITY OF SUCH DAMAGE. 049 050*/ 051 052// Generated on Thu, Dec 13, 2018 14:07+1100 for FHIR v4.0.0 053import java.util.ArrayList; 054import java.util.Date; 055import java.util.List; 056import org.hl7.fhir.exceptions.FHIRException; 057import org.hl7.fhir.instance.model.api.ICompositeType; 058 059import org.hl7.fhir.instance.model.api.IBaseDatatypeElement; 060import org.hl7.fhir.utilities.Utilities; 061import org.hl7.fhir.r5.model.Enumerations.*; 062import ca.uhn.fhir.model.api.annotation.ResourceDef; 063import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 064import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 065import ca.uhn.fhir.model.api.annotation.Child; 066import ca.uhn.fhir.model.api.annotation.ChildOrder; 067import ca.uhn.fhir.model.api.annotation.Description; 068import ca.uhn.fhir.model.api.annotation.Block; 069/** 070 * This resource provides eligibility and plan details from the processing of an CoverageEligibilityRequest resource. 071 */ 072@ResourceDef(name="CoverageEligibilityResponse", profile="http://hl7.org/fhir/StructureDefinition/CoverageEligibilityResponse") 073public class CoverageEligibilityResponse extends DomainResource { 074 075 public enum EligibilityResponseStatus { 076 /** 077 * The instance is currently in-force. 078 */ 079 ACTIVE, 080 /** 081 * The instance is withdrawn, rescinded or reversed. 082 */ 083 CANCELLED, 084 /** 085 * A new instance the contents of which is not complete. 086 */ 087 DRAFT, 088 /** 089 * The instance was entered in error. 090 */ 091 ENTEREDINERROR, 092 /** 093 * added to help the parsers with the generic types 094 */ 095 NULL; 096 public static EligibilityResponseStatus fromCode(String codeString) throws FHIRException { 097 if (codeString == null || "".equals(codeString)) 098 return null; 099 if ("active".equals(codeString)) 100 return ACTIVE; 101 if ("cancelled".equals(codeString)) 102 return CANCELLED; 103 if ("draft".equals(codeString)) 104 return DRAFT; 105 if ("entered-in-error".equals(codeString)) 106 return ENTEREDINERROR; 107 if (Configuration.isAcceptInvalidEnums()) 108 return null; 109 else 110 throw new FHIRException("Unknown EligibilityResponseStatus code '"+codeString+"'"); 111 } 112 public String toCode() { 113 switch (this) { 114 case ACTIVE: return "active"; 115 case CANCELLED: return "cancelled"; 116 case DRAFT: return "draft"; 117 case ENTEREDINERROR: return "entered-in-error"; 118 default: return "?"; 119 } 120 } 121 public String getSystem() { 122 switch (this) { 123 case ACTIVE: return "http://hl7.org/fhir/fm-status"; 124 case CANCELLED: return "http://hl7.org/fhir/fm-status"; 125 case DRAFT: return "http://hl7.org/fhir/fm-status"; 126 case ENTEREDINERROR: return "http://hl7.org/fhir/fm-status"; 127 default: return "?"; 128 } 129 } 130 public String getDefinition() { 131 switch (this) { 132 case ACTIVE: return "The instance is currently in-force."; 133 case CANCELLED: return "The instance is withdrawn, rescinded or reversed."; 134 case DRAFT: return "A new instance the contents of which is not complete."; 135 case ENTEREDINERROR: return "The instance was entered in error."; 136 default: return "?"; 137 } 138 } 139 public String getDisplay() { 140 switch (this) { 141 case ACTIVE: return "Active"; 142 case CANCELLED: return "Cancelled"; 143 case DRAFT: return "Draft"; 144 case ENTEREDINERROR: return "Entered in Error"; 145 default: return "?"; 146 } 147 } 148 } 149 150 public static class EligibilityResponseStatusEnumFactory implements EnumFactory<EligibilityResponseStatus> { 151 public EligibilityResponseStatus fromCode(String codeString) throws IllegalArgumentException { 152 if (codeString == null || "".equals(codeString)) 153 if (codeString == null || "".equals(codeString)) 154 return null; 155 if ("active".equals(codeString)) 156 return EligibilityResponseStatus.ACTIVE; 157 if ("cancelled".equals(codeString)) 158 return EligibilityResponseStatus.CANCELLED; 159 if ("draft".equals(codeString)) 160 return EligibilityResponseStatus.DRAFT; 161 if ("entered-in-error".equals(codeString)) 162 return EligibilityResponseStatus.ENTEREDINERROR; 163 throw new IllegalArgumentException("Unknown EligibilityResponseStatus code '"+codeString+"'"); 164 } 165 public Enumeration<EligibilityResponseStatus> fromType(Base code) throws FHIRException { 166 if (code == null) 167 return null; 168 if (code.isEmpty()) 169 return new Enumeration<EligibilityResponseStatus>(this); 170 String codeString = ((PrimitiveType) code).asStringValue(); 171 if (codeString == null || "".equals(codeString)) 172 return null; 173 if ("active".equals(codeString)) 174 return new Enumeration<EligibilityResponseStatus>(this, EligibilityResponseStatus.ACTIVE); 175 if ("cancelled".equals(codeString)) 176 return new Enumeration<EligibilityResponseStatus>(this, EligibilityResponseStatus.CANCELLED); 177 if ("draft".equals(codeString)) 178 return new Enumeration<EligibilityResponseStatus>(this, EligibilityResponseStatus.DRAFT); 179 if ("entered-in-error".equals(codeString)) 180 return new Enumeration<EligibilityResponseStatus>(this, EligibilityResponseStatus.ENTEREDINERROR); 181 throw new FHIRException("Unknown EligibilityResponseStatus code '"+codeString+"'"); 182 } 183 public String toCode(EligibilityResponseStatus code) { 184 if (code == EligibilityResponseStatus.ACTIVE) 185 return "active"; 186 if (code == EligibilityResponseStatus.CANCELLED) 187 return "cancelled"; 188 if (code == EligibilityResponseStatus.DRAFT) 189 return "draft"; 190 if (code == EligibilityResponseStatus.ENTEREDINERROR) 191 return "entered-in-error"; 192 return "?"; 193 } 194 public String toSystem(EligibilityResponseStatus code) { 195 return code.getSystem(); 196 } 197 } 198 199 public enum EligibilityResponsePurpose { 200 /** 201 * The prior authorization requirements for the listed, or discovered if specified, converages for the categories of service and/or specifed biling codes are requested. 202 */ 203 AUTHREQUIREMENTS, 204 /** 205 * The plan benefits and optionally benefits consumed for the listed, or discovered if specified, converages are requested. 206 */ 207 BENEFITS, 208 /** 209 * The insurer is requested to report on any coverages which they are aware of in addition to any specifed. 210 */ 211 DISCOVERY, 212 /** 213 * A check that the specified coverages are in-force is requested. 214 */ 215 VALIDATION, 216 /** 217 * added to help the parsers with the generic types 218 */ 219 NULL; 220 public static EligibilityResponsePurpose fromCode(String codeString) throws FHIRException { 221 if (codeString == null || "".equals(codeString)) 222 return null; 223 if ("auth-requirements".equals(codeString)) 224 return AUTHREQUIREMENTS; 225 if ("benefits".equals(codeString)) 226 return BENEFITS; 227 if ("discovery".equals(codeString)) 228 return DISCOVERY; 229 if ("validation".equals(codeString)) 230 return VALIDATION; 231 if (Configuration.isAcceptInvalidEnums()) 232 return null; 233 else 234 throw new FHIRException("Unknown EligibilityResponsePurpose code '"+codeString+"'"); 235 } 236 public String toCode() { 237 switch (this) { 238 case AUTHREQUIREMENTS: return "auth-requirements"; 239 case BENEFITS: return "benefits"; 240 case DISCOVERY: return "discovery"; 241 case VALIDATION: return "validation"; 242 default: return "?"; 243 } 244 } 245 public String getSystem() { 246 switch (this) { 247 case AUTHREQUIREMENTS: return "http://hl7.org/fhir/eligibilityresponse-purpose"; 248 case BENEFITS: return "http://hl7.org/fhir/eligibilityresponse-purpose"; 249 case DISCOVERY: return "http://hl7.org/fhir/eligibilityresponse-purpose"; 250 case VALIDATION: return "http://hl7.org/fhir/eligibilityresponse-purpose"; 251 default: return "?"; 252 } 253 } 254 public String getDefinition() { 255 switch (this) { 256 case AUTHREQUIREMENTS: return "The prior authorization requirements for the listed, or discovered if specified, converages for the categories of service and/or specifed biling codes are requested."; 257 case BENEFITS: return "The plan benefits and optionally benefits consumed for the listed, or discovered if specified, converages are requested."; 258 case DISCOVERY: return "The insurer is requested to report on any coverages which they are aware of in addition to any specifed."; 259 case VALIDATION: return "A check that the specified coverages are in-force is requested."; 260 default: return "?"; 261 } 262 } 263 public String getDisplay() { 264 switch (this) { 265 case AUTHREQUIREMENTS: return "Coverage auth-requirements"; 266 case BENEFITS: return "Coverage benefits"; 267 case DISCOVERY: return "Coverage Discovery"; 268 case VALIDATION: return "Coverage Validation"; 269 default: return "?"; 270 } 271 } 272 } 273 274 public static class EligibilityResponsePurposeEnumFactory implements EnumFactory<EligibilityResponsePurpose> { 275 public EligibilityResponsePurpose fromCode(String codeString) throws IllegalArgumentException { 276 if (codeString == null || "".equals(codeString)) 277 if (codeString == null || "".equals(codeString)) 278 return null; 279 if ("auth-requirements".equals(codeString)) 280 return EligibilityResponsePurpose.AUTHREQUIREMENTS; 281 if ("benefits".equals(codeString)) 282 return EligibilityResponsePurpose.BENEFITS; 283 if ("discovery".equals(codeString)) 284 return EligibilityResponsePurpose.DISCOVERY; 285 if ("validation".equals(codeString)) 286 return EligibilityResponsePurpose.VALIDATION; 287 throw new IllegalArgumentException("Unknown EligibilityResponsePurpose code '"+codeString+"'"); 288 } 289 public Enumeration<EligibilityResponsePurpose> fromType(Base code) throws FHIRException { 290 if (code == null) 291 return null; 292 if (code.isEmpty()) 293 return new Enumeration<EligibilityResponsePurpose>(this); 294 String codeString = ((PrimitiveType) code).asStringValue(); 295 if (codeString == null || "".equals(codeString)) 296 return null; 297 if ("auth-requirements".equals(codeString)) 298 return new Enumeration<EligibilityResponsePurpose>(this, EligibilityResponsePurpose.AUTHREQUIREMENTS); 299 if ("benefits".equals(codeString)) 300 return new Enumeration<EligibilityResponsePurpose>(this, EligibilityResponsePurpose.BENEFITS); 301 if ("discovery".equals(codeString)) 302 return new Enumeration<EligibilityResponsePurpose>(this, EligibilityResponsePurpose.DISCOVERY); 303 if ("validation".equals(codeString)) 304 return new Enumeration<EligibilityResponsePurpose>(this, EligibilityResponsePurpose.VALIDATION); 305 throw new FHIRException("Unknown EligibilityResponsePurpose code '"+codeString+"'"); 306 } 307 public String toCode(EligibilityResponsePurpose code) { 308 if (code == EligibilityResponsePurpose.AUTHREQUIREMENTS) 309 return "auth-requirements"; 310 if (code == EligibilityResponsePurpose.BENEFITS) 311 return "benefits"; 312 if (code == EligibilityResponsePurpose.DISCOVERY) 313 return "discovery"; 314 if (code == EligibilityResponsePurpose.VALIDATION) 315 return "validation"; 316 return "?"; 317 } 318 public String toSystem(EligibilityResponsePurpose code) { 319 return code.getSystem(); 320 } 321 } 322 323 @Block() 324 public static class InsuranceComponent extends BackboneElement implements IBaseBackboneElement { 325 /** 326 * Reference to the insurance card level information contained in the Coverage resource. The coverage issuing insurer will use these details to locate the patient's actual coverage within the insurer's information system. 327 */ 328 @Child(name = "coverage", type = {Coverage.class}, order=1, min=1, max=1, modifier=false, summary=true) 329 @Description(shortDefinition="Insurance information", formalDefinition="Reference to the insurance card level information contained in the Coverage resource. The coverage issuing insurer will use these details to locate the patient's actual coverage within the insurer's information system." ) 330 protected Reference coverage; 331 332 /** 333 * Flag indicating if the coverage provided is inforce currently if no service date(s) specified or for the whole duration of the service dates. 334 */ 335 @Child(name = "inforce", type = {BooleanType.class}, order=2, min=0, max=1, modifier=false, summary=false) 336 @Description(shortDefinition="Coverage inforce indicator", formalDefinition="Flag indicating if the coverage provided is inforce currently if no service date(s) specified or for the whole duration of the service dates." ) 337 protected BooleanType inforce; 338 339 /** 340 * The term of the benefits documented in this response. 341 */ 342 @Child(name = "benefitPeriod", type = {Period.class}, order=3, min=0, max=1, modifier=false, summary=false) 343 @Description(shortDefinition="When the benefits are applicable", formalDefinition="The term of the benefits documented in this response." ) 344 protected Period benefitPeriod; 345 346 /** 347 * Benefits and optionally current balances, and authorization details by category or service. 348 */ 349 @Child(name = "item", type = {}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 350 @Description(shortDefinition="Benefits and authorization details", formalDefinition="Benefits and optionally current balances, and authorization details by category or service." ) 351 protected List<ItemsComponent> item; 352 353 private static final long serialVersionUID = 1473928476L; 354 355 /** 356 * Constructor 357 */ 358 public InsuranceComponent() { 359 super(); 360 } 361 362 /** 363 * Constructor 364 */ 365 public InsuranceComponent(Reference coverage) { 366 super(); 367 this.coverage = coverage; 368 } 369 370 /** 371 * @return {@link #coverage} (Reference to the insurance card level information contained in the Coverage resource. The coverage issuing insurer will use these details to locate the patient's actual coverage within the insurer's information system.) 372 */ 373 public Reference getCoverage() { 374 if (this.coverage == null) 375 if (Configuration.errorOnAutoCreate()) 376 throw new Error("Attempt to auto-create InsuranceComponent.coverage"); 377 else if (Configuration.doAutoCreate()) 378 this.coverage = new Reference(); // cc 379 return this.coverage; 380 } 381 382 public boolean hasCoverage() { 383 return this.coverage != null && !this.coverage.isEmpty(); 384 } 385 386 /** 387 * @param value {@link #coverage} (Reference to the insurance card level information contained in the Coverage resource. The coverage issuing insurer will use these details to locate the patient's actual coverage within the insurer's information system.) 388 */ 389 public InsuranceComponent setCoverage(Reference value) { 390 this.coverage = value; 391 return this; 392 } 393 394 /** 395 * @return {@link #inforce} (Flag indicating if the coverage provided is inforce currently if no service date(s) specified or for the whole duration of the service dates.). This is the underlying object with id, value and extensions. The accessor "getInforce" gives direct access to the value 396 */ 397 public BooleanType getInforceElement() { 398 if (this.inforce == null) 399 if (Configuration.errorOnAutoCreate()) 400 throw new Error("Attempt to auto-create InsuranceComponent.inforce"); 401 else if (Configuration.doAutoCreate()) 402 this.inforce = new BooleanType(); // bb 403 return this.inforce; 404 } 405 406 public boolean hasInforceElement() { 407 return this.inforce != null && !this.inforce.isEmpty(); 408 } 409 410 public boolean hasInforce() { 411 return this.inforce != null && !this.inforce.isEmpty(); 412 } 413 414 /** 415 * @param value {@link #inforce} (Flag indicating if the coverage provided is inforce currently if no service date(s) specified or for the whole duration of the service dates.). This is the underlying object with id, value and extensions. The accessor "getInforce" gives direct access to the value 416 */ 417 public InsuranceComponent setInforceElement(BooleanType value) { 418 this.inforce = value; 419 return this; 420 } 421 422 /** 423 * @return Flag indicating if the coverage provided is inforce currently if no service date(s) specified or for the whole duration of the service dates. 424 */ 425 public boolean getInforce() { 426 return this.inforce == null || this.inforce.isEmpty() ? false : this.inforce.getValue(); 427 } 428 429 /** 430 * @param value Flag indicating if the coverage provided is inforce currently if no service date(s) specified or for the whole duration of the service dates. 431 */ 432 public InsuranceComponent setInforce(boolean value) { 433 if (this.inforce == null) 434 this.inforce = new BooleanType(); 435 this.inforce.setValue(value); 436 return this; 437 } 438 439 /** 440 * @return {@link #benefitPeriod} (The term of the benefits documented in this response.) 441 */ 442 public Period getBenefitPeriod() { 443 if (this.benefitPeriod == null) 444 if (Configuration.errorOnAutoCreate()) 445 throw new Error("Attempt to auto-create InsuranceComponent.benefitPeriod"); 446 else if (Configuration.doAutoCreate()) 447 this.benefitPeriod = new Period(); // cc 448 return this.benefitPeriod; 449 } 450 451 public boolean hasBenefitPeriod() { 452 return this.benefitPeriod != null && !this.benefitPeriod.isEmpty(); 453 } 454 455 /** 456 * @param value {@link #benefitPeriod} (The term of the benefits documented in this response.) 457 */ 458 public InsuranceComponent setBenefitPeriod(Period value) { 459 this.benefitPeriod = value; 460 return this; 461 } 462 463 /** 464 * @return {@link #item} (Benefits and optionally current balances, and authorization details by category or service.) 465 */ 466 public List<ItemsComponent> getItem() { 467 if (this.item == null) 468 this.item = new ArrayList<ItemsComponent>(); 469 return this.item; 470 } 471 472 /** 473 * @return Returns a reference to <code>this</code> for easy method chaining 474 */ 475 public InsuranceComponent setItem(List<ItemsComponent> theItem) { 476 this.item = theItem; 477 return this; 478 } 479 480 public boolean hasItem() { 481 if (this.item == null) 482 return false; 483 for (ItemsComponent item : this.item) 484 if (!item.isEmpty()) 485 return true; 486 return false; 487 } 488 489 public ItemsComponent addItem() { //3 490 ItemsComponent t = new ItemsComponent(); 491 if (this.item == null) 492 this.item = new ArrayList<ItemsComponent>(); 493 this.item.add(t); 494 return t; 495 } 496 497 public InsuranceComponent addItem(ItemsComponent t) { //3 498 if (t == null) 499 return this; 500 if (this.item == null) 501 this.item = new ArrayList<ItemsComponent>(); 502 this.item.add(t); 503 return this; 504 } 505 506 /** 507 * @return The first repetition of repeating field {@link #item}, creating it if it does not already exist 508 */ 509 public ItemsComponent getItemFirstRep() { 510 if (getItem().isEmpty()) { 511 addItem(); 512 } 513 return getItem().get(0); 514 } 515 516 protected void listChildren(List<Property> children) { 517 super.listChildren(children); 518 children.add(new Property("coverage", "Reference(Coverage)", "Reference to the insurance card level information contained in the Coverage resource. The coverage issuing insurer will use these details to locate the patient's actual coverage within the insurer's information system.", 0, 1, coverage)); 519 children.add(new Property("inforce", "boolean", "Flag indicating if the coverage provided is inforce currently if no service date(s) specified or for the whole duration of the service dates.", 0, 1, inforce)); 520 children.add(new Property("benefitPeriod", "Period", "The term of the benefits documented in this response.", 0, 1, benefitPeriod)); 521 children.add(new Property("item", "", "Benefits and optionally current balances, and authorization details by category or service.", 0, java.lang.Integer.MAX_VALUE, item)); 522 } 523 524 @Override 525 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 526 switch (_hash) { 527 case -351767064: /*coverage*/ return new Property("coverage", "Reference(Coverage)", "Reference to the insurance card level information contained in the Coverage resource. The coverage issuing insurer will use these details to locate the patient's actual coverage within the insurer's information system.", 0, 1, coverage); 528 case 1945431270: /*inforce*/ return new Property("inforce", "boolean", "Flag indicating if the coverage provided is inforce currently if no service date(s) specified or for the whole duration of the service dates.", 0, 1, inforce); 529 case -407369416: /*benefitPeriod*/ return new Property("benefitPeriod", "Period", "The term of the benefits documented in this response.", 0, 1, benefitPeriod); 530 case 3242771: /*item*/ return new Property("item", "", "Benefits and optionally current balances, and authorization details by category or service.", 0, java.lang.Integer.MAX_VALUE, item); 531 default: return super.getNamedProperty(_hash, _name, _checkValid); 532 } 533 534 } 535 536 @Override 537 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 538 switch (hash) { 539 case -351767064: /*coverage*/ return this.coverage == null ? new Base[0] : new Base[] {this.coverage}; // Reference 540 case 1945431270: /*inforce*/ return this.inforce == null ? new Base[0] : new Base[] {this.inforce}; // BooleanType 541 case -407369416: /*benefitPeriod*/ return this.benefitPeriod == null ? new Base[0] : new Base[] {this.benefitPeriod}; // Period 542 case 3242771: /*item*/ return this.item == null ? new Base[0] : this.item.toArray(new Base[this.item.size()]); // ItemsComponent 543 default: return super.getProperty(hash, name, checkValid); 544 } 545 546 } 547 548 @Override 549 public Base setProperty(int hash, String name, Base value) throws FHIRException { 550 switch (hash) { 551 case -351767064: // coverage 552 this.coverage = castToReference(value); // Reference 553 return value; 554 case 1945431270: // inforce 555 this.inforce = castToBoolean(value); // BooleanType 556 return value; 557 case -407369416: // benefitPeriod 558 this.benefitPeriod = castToPeriod(value); // Period 559 return value; 560 case 3242771: // item 561 this.getItem().add((ItemsComponent) value); // ItemsComponent 562 return value; 563 default: return super.setProperty(hash, name, value); 564 } 565 566 } 567 568 @Override 569 public Base setProperty(String name, Base value) throws FHIRException { 570 if (name.equals("coverage")) { 571 this.coverage = castToReference(value); // Reference 572 } else if (name.equals("inforce")) { 573 this.inforce = castToBoolean(value); // BooleanType 574 } else if (name.equals("benefitPeriod")) { 575 this.benefitPeriod = castToPeriod(value); // Period 576 } else if (name.equals("item")) { 577 this.getItem().add((ItemsComponent) value); 578 } else 579 return super.setProperty(name, value); 580 return value; 581 } 582 583 @Override 584 public Base makeProperty(int hash, String name) throws FHIRException { 585 switch (hash) { 586 case -351767064: return getCoverage(); 587 case 1945431270: return getInforceElement(); 588 case -407369416: return getBenefitPeriod(); 589 case 3242771: return addItem(); 590 default: return super.makeProperty(hash, name); 591 } 592 593 } 594 595 @Override 596 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 597 switch (hash) { 598 case -351767064: /*coverage*/ return new String[] {"Reference"}; 599 case 1945431270: /*inforce*/ return new String[] {"boolean"}; 600 case -407369416: /*benefitPeriod*/ return new String[] {"Period"}; 601 case 3242771: /*item*/ return new String[] {}; 602 default: return super.getTypesForProperty(hash, name); 603 } 604 605 } 606 607 @Override 608 public Base addChild(String name) throws FHIRException { 609 if (name.equals("coverage")) { 610 this.coverage = new Reference(); 611 return this.coverage; 612 } 613 else if (name.equals("inforce")) { 614 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.inforce"); 615 } 616 else if (name.equals("benefitPeriod")) { 617 this.benefitPeriod = new Period(); 618 return this.benefitPeriod; 619 } 620 else if (name.equals("item")) { 621 return addItem(); 622 } 623 else 624 return super.addChild(name); 625 } 626 627 public InsuranceComponent copy() { 628 InsuranceComponent dst = new InsuranceComponent(); 629 copyValues(dst); 630 return dst; 631 } 632 633 public void copyValues(InsuranceComponent dst) { 634 super.copyValues(dst); 635 dst.coverage = coverage == null ? null : coverage.copy(); 636 dst.inforce = inforce == null ? null : inforce.copy(); 637 dst.benefitPeriod = benefitPeriod == null ? null : benefitPeriod.copy(); 638 if (item != null) { 639 dst.item = new ArrayList<ItemsComponent>(); 640 for (ItemsComponent i : item) 641 dst.item.add(i.copy()); 642 }; 643 } 644 645 @Override 646 public boolean equalsDeep(Base other_) { 647 if (!super.equalsDeep(other_)) 648 return false; 649 if (!(other_ instanceof InsuranceComponent)) 650 return false; 651 InsuranceComponent o = (InsuranceComponent) other_; 652 return compareDeep(coverage, o.coverage, true) && compareDeep(inforce, o.inforce, true) && compareDeep(benefitPeriod, o.benefitPeriod, true) 653 && compareDeep(item, o.item, true); 654 } 655 656 @Override 657 public boolean equalsShallow(Base other_) { 658 if (!super.equalsShallow(other_)) 659 return false; 660 if (!(other_ instanceof InsuranceComponent)) 661 return false; 662 InsuranceComponent o = (InsuranceComponent) other_; 663 return compareValues(inforce, o.inforce, true); 664 } 665 666 public boolean isEmpty() { 667 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(coverage, inforce, benefitPeriod 668 , item); 669 } 670 671 public String fhirType() { 672 return "CoverageEligibilityResponse.insurance"; 673 674 } 675 676 } 677 678 @Block() 679 public static class ItemsComponent extends BackboneElement implements IBaseBackboneElement { 680 /** 681 * Code to identify the general type of benefits under which products and services are provided. 682 */ 683 @Child(name = "category", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 684 @Description(shortDefinition="Benefit classification", formalDefinition="Code to identify the general type of benefits under which products and services are provided." ) 685 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/ex-benefitcategory") 686 protected CodeableConcept category; 687 688 /** 689 * This contains the product, service, drug or other billing code for the item. 690 */ 691 @Child(name = "productOrService", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 692 @Description(shortDefinition="Billing, service, product, or drug code", formalDefinition="This contains the product, service, drug or other billing code for the item." ) 693 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/service-uscls") 694 protected CodeableConcept productOrService; 695 696 /** 697 * Item typification or modifiers codes to convey additional context for the product or service. 698 */ 699 @Child(name = "modifier", type = {CodeableConcept.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 700 @Description(shortDefinition="Product or service billing modifiers", formalDefinition="Item typification or modifiers codes to convey additional context for the product or service." ) 701 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/claim-modifiers") 702 protected List<CodeableConcept> modifier; 703 704 /** 705 * The practitioner who is eligible for the provision of the product or service. 706 */ 707 @Child(name = "provider", type = {Practitioner.class, PractitionerRole.class}, order=4, min=0, max=1, modifier=false, summary=false) 708 @Description(shortDefinition="Performing practitioner", formalDefinition="The practitioner who is eligible for the provision of the product or service." ) 709 protected Reference provider; 710 711 /** 712 * True if the indicated class of service is excluded from the plan, missing or False indicates the product or service is included in the coverage. 713 */ 714 @Child(name = "excluded", type = {BooleanType.class}, order=5, min=0, max=1, modifier=false, summary=false) 715 @Description(shortDefinition="Excluded from the plan", formalDefinition="True if the indicated class of service is excluded from the plan, missing or False indicates the product or service is included in the coverage." ) 716 protected BooleanType excluded; 717 718 /** 719 * A short name or tag for the benefit. 720 */ 721 @Child(name = "name", type = {StringType.class}, order=6, min=0, max=1, modifier=false, summary=false) 722 @Description(shortDefinition="Short name for the benefit", formalDefinition="A short name or tag for the benefit." ) 723 protected StringType name; 724 725 /** 726 * A richer description of the benefit or services covered. 727 */ 728 @Child(name = "description", type = {StringType.class}, order=7, min=0, max=1, modifier=false, summary=false) 729 @Description(shortDefinition="Description of the benefit or services covered", formalDefinition="A richer description of the benefit or services covered." ) 730 protected StringType description; 731 732 /** 733 * Is a flag to indicate whether the benefits refer to in-network providers or out-of-network providers. 734 */ 735 @Child(name = "network", type = {CodeableConcept.class}, order=8, min=0, max=1, modifier=false, summary=false) 736 @Description(shortDefinition="In or out of network", formalDefinition="Is a flag to indicate whether the benefits refer to in-network providers or out-of-network providers." ) 737 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/benefit-network") 738 protected CodeableConcept network; 739 740 /** 741 * Indicates if the benefits apply to an individual or to the family. 742 */ 743 @Child(name = "unit", type = {CodeableConcept.class}, order=9, min=0, max=1, modifier=false, summary=false) 744 @Description(shortDefinition="Individual or family", formalDefinition="Indicates if the benefits apply to an individual or to the family." ) 745 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/benefit-unit") 746 protected CodeableConcept unit; 747 748 /** 749 * The term or period of the values such as 'maximum lifetime benefit' or 'maximum annual visits'. 750 */ 751 @Child(name = "term", type = {CodeableConcept.class}, order=10, min=0, max=1, modifier=false, summary=false) 752 @Description(shortDefinition="Annual or lifetime", formalDefinition="The term or period of the values such as 'maximum lifetime benefit' or 'maximum annual visits'." ) 753 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/benefit-term") 754 protected CodeableConcept term; 755 756 /** 757 * Benefits used to date. 758 */ 759 @Child(name = "benefit", type = {}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 760 @Description(shortDefinition="Benefit Summary", formalDefinition="Benefits used to date." ) 761 protected List<BenefitComponent> benefit; 762 763 /** 764 * A boolean flag indicating whether a preauthorization is required prior to actual service delivery. 765 */ 766 @Child(name = "authorizationRequired", type = {BooleanType.class}, order=12, min=0, max=1, modifier=false, summary=false) 767 @Description(shortDefinition="Authorization required flag", formalDefinition="A boolean flag indicating whether a preauthorization is required prior to actual service delivery." ) 768 protected BooleanType authorizationRequired; 769 770 /** 771 * Codes or comments regarding information or actions associated with the preauthorization. 772 */ 773 @Child(name = "authorizationSupporting", type = {CodeableConcept.class}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 774 @Description(shortDefinition="Type of required supporting materials", formalDefinition="Codes or comments regarding information or actions associated with the preauthorization." ) 775 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/coverageeligibilityresponse-ex-auth-support") 776 protected List<CodeableConcept> authorizationSupporting; 777 778 /** 779 * A web location for obtaining requirements or descriptive information regarding the preauthorization. 780 */ 781 @Child(name = "authorizationUrl", type = {UriType.class}, order=14, min=0, max=1, modifier=false, summary=false) 782 @Description(shortDefinition="Preauthorization requirements endpoint", formalDefinition="A web location for obtaining requirements or descriptive information regarding the preauthorization." ) 783 protected UriType authorizationUrl; 784 785 private static final long serialVersionUID = 1706159945L; 786 787 /** 788 * Constructor 789 */ 790 public ItemsComponent() { 791 super(); 792 } 793 794 /** 795 * @return {@link #category} (Code to identify the general type of benefits under which products and services are provided.) 796 */ 797 public CodeableConcept getCategory() { 798 if (this.category == null) 799 if (Configuration.errorOnAutoCreate()) 800 throw new Error("Attempt to auto-create ItemsComponent.category"); 801 else if (Configuration.doAutoCreate()) 802 this.category = new CodeableConcept(); // cc 803 return this.category; 804 } 805 806 public boolean hasCategory() { 807 return this.category != null && !this.category.isEmpty(); 808 } 809 810 /** 811 * @param value {@link #category} (Code to identify the general type of benefits under which products and services are provided.) 812 */ 813 public ItemsComponent setCategory(CodeableConcept value) { 814 this.category = value; 815 return this; 816 } 817 818 /** 819 * @return {@link #productOrService} (This contains the product, service, drug or other billing code for the item.) 820 */ 821 public CodeableConcept getProductOrService() { 822 if (this.productOrService == null) 823 if (Configuration.errorOnAutoCreate()) 824 throw new Error("Attempt to auto-create ItemsComponent.productOrService"); 825 else if (Configuration.doAutoCreate()) 826 this.productOrService = new CodeableConcept(); // cc 827 return this.productOrService; 828 } 829 830 public boolean hasProductOrService() { 831 return this.productOrService != null && !this.productOrService.isEmpty(); 832 } 833 834 /** 835 * @param value {@link #productOrService} (This contains the product, service, drug or other billing code for the item.) 836 */ 837 public ItemsComponent setProductOrService(CodeableConcept value) { 838 this.productOrService = value; 839 return this; 840 } 841 842 /** 843 * @return {@link #modifier} (Item typification or modifiers codes to convey additional context for the product or service.) 844 */ 845 public List<CodeableConcept> getModifier() { 846 if (this.modifier == null) 847 this.modifier = new ArrayList<CodeableConcept>(); 848 return this.modifier; 849 } 850 851 /** 852 * @return Returns a reference to <code>this</code> for easy method chaining 853 */ 854 public ItemsComponent setModifier(List<CodeableConcept> theModifier) { 855 this.modifier = theModifier; 856 return this; 857 } 858 859 public boolean hasModifier() { 860 if (this.modifier == null) 861 return false; 862 for (CodeableConcept item : this.modifier) 863 if (!item.isEmpty()) 864 return true; 865 return false; 866 } 867 868 public CodeableConcept addModifier() { //3 869 CodeableConcept t = new CodeableConcept(); 870 if (this.modifier == null) 871 this.modifier = new ArrayList<CodeableConcept>(); 872 this.modifier.add(t); 873 return t; 874 } 875 876 public ItemsComponent addModifier(CodeableConcept t) { //3 877 if (t == null) 878 return this; 879 if (this.modifier == null) 880 this.modifier = new ArrayList<CodeableConcept>(); 881 this.modifier.add(t); 882 return this; 883 } 884 885 /** 886 * @return The first repetition of repeating field {@link #modifier}, creating it if it does not already exist 887 */ 888 public CodeableConcept getModifierFirstRep() { 889 if (getModifier().isEmpty()) { 890 addModifier(); 891 } 892 return getModifier().get(0); 893 } 894 895 /** 896 * @return {@link #provider} (The practitioner who is eligible for the provision of the product or service.) 897 */ 898 public Reference getProvider() { 899 if (this.provider == null) 900 if (Configuration.errorOnAutoCreate()) 901 throw new Error("Attempt to auto-create ItemsComponent.provider"); 902 else if (Configuration.doAutoCreate()) 903 this.provider = new Reference(); // cc 904 return this.provider; 905 } 906 907 public boolean hasProvider() { 908 return this.provider != null && !this.provider.isEmpty(); 909 } 910 911 /** 912 * @param value {@link #provider} (The practitioner who is eligible for the provision of the product or service.) 913 */ 914 public ItemsComponent setProvider(Reference value) { 915 this.provider = value; 916 return this; 917 } 918 919 /** 920 * @return {@link #excluded} (True if the indicated class of service is excluded from the plan, missing or False indicates the product or service is included in the coverage.). This is the underlying object with id, value and extensions. The accessor "getExcluded" gives direct access to the value 921 */ 922 public BooleanType getExcludedElement() { 923 if (this.excluded == null) 924 if (Configuration.errorOnAutoCreate()) 925 throw new Error("Attempt to auto-create ItemsComponent.excluded"); 926 else if (Configuration.doAutoCreate()) 927 this.excluded = new BooleanType(); // bb 928 return this.excluded; 929 } 930 931 public boolean hasExcludedElement() { 932 return this.excluded != null && !this.excluded.isEmpty(); 933 } 934 935 public boolean hasExcluded() { 936 return this.excluded != null && !this.excluded.isEmpty(); 937 } 938 939 /** 940 * @param value {@link #excluded} (True if the indicated class of service is excluded from the plan, missing or False indicates the product or service is included in the coverage.). This is the underlying object with id, value and extensions. The accessor "getExcluded" gives direct access to the value 941 */ 942 public ItemsComponent setExcludedElement(BooleanType value) { 943 this.excluded = value; 944 return this; 945 } 946 947 /** 948 * @return True if the indicated class of service is excluded from the plan, missing or False indicates the product or service is included in the coverage. 949 */ 950 public boolean getExcluded() { 951 return this.excluded == null || this.excluded.isEmpty() ? false : this.excluded.getValue(); 952 } 953 954 /** 955 * @param value True if the indicated class of service is excluded from the plan, missing or False indicates the product or service is included in the coverage. 956 */ 957 public ItemsComponent setExcluded(boolean value) { 958 if (this.excluded == null) 959 this.excluded = new BooleanType(); 960 this.excluded.setValue(value); 961 return this; 962 } 963 964 /** 965 * @return {@link #name} (A short name or tag for the benefit.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 966 */ 967 public StringType getNameElement() { 968 if (this.name == null) 969 if (Configuration.errorOnAutoCreate()) 970 throw new Error("Attempt to auto-create ItemsComponent.name"); 971 else if (Configuration.doAutoCreate()) 972 this.name = new StringType(); // bb 973 return this.name; 974 } 975 976 public boolean hasNameElement() { 977 return this.name != null && !this.name.isEmpty(); 978 } 979 980 public boolean hasName() { 981 return this.name != null && !this.name.isEmpty(); 982 } 983 984 /** 985 * @param value {@link #name} (A short name or tag for the benefit.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 986 */ 987 public ItemsComponent setNameElement(StringType value) { 988 this.name = value; 989 return this; 990 } 991 992 /** 993 * @return A short name or tag for the benefit. 994 */ 995 public String getName() { 996 return this.name == null ? null : this.name.getValue(); 997 } 998 999 /** 1000 * @param value A short name or tag for the benefit. 1001 */ 1002 public ItemsComponent setName(String value) { 1003 if (Utilities.noString(value)) 1004 this.name = null; 1005 else { 1006 if (this.name == null) 1007 this.name = new StringType(); 1008 this.name.setValue(value); 1009 } 1010 return this; 1011 } 1012 1013 /** 1014 * @return {@link #description} (A richer description of the benefit or services covered.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 1015 */ 1016 public StringType getDescriptionElement() { 1017 if (this.description == null) 1018 if (Configuration.errorOnAutoCreate()) 1019 throw new Error("Attempt to auto-create ItemsComponent.description"); 1020 else if (Configuration.doAutoCreate()) 1021 this.description = new StringType(); // bb 1022 return this.description; 1023 } 1024 1025 public boolean hasDescriptionElement() { 1026 return this.description != null && !this.description.isEmpty(); 1027 } 1028 1029 public boolean hasDescription() { 1030 return this.description != null && !this.description.isEmpty(); 1031 } 1032 1033 /** 1034 * @param value {@link #description} (A richer description of the benefit or services covered.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 1035 */ 1036 public ItemsComponent setDescriptionElement(StringType value) { 1037 this.description = value; 1038 return this; 1039 } 1040 1041 /** 1042 * @return A richer description of the benefit or services covered. 1043 */ 1044 public String getDescription() { 1045 return this.description == null ? null : this.description.getValue(); 1046 } 1047 1048 /** 1049 * @param value A richer description of the benefit or services covered. 1050 */ 1051 public ItemsComponent setDescription(String value) { 1052 if (Utilities.noString(value)) 1053 this.description = null; 1054 else { 1055 if (this.description == null) 1056 this.description = new StringType(); 1057 this.description.setValue(value); 1058 } 1059 return this; 1060 } 1061 1062 /** 1063 * @return {@link #network} (Is a flag to indicate whether the benefits refer to in-network providers or out-of-network providers.) 1064 */ 1065 public CodeableConcept getNetwork() { 1066 if (this.network == null) 1067 if (Configuration.errorOnAutoCreate()) 1068 throw new Error("Attempt to auto-create ItemsComponent.network"); 1069 else if (Configuration.doAutoCreate()) 1070 this.network = new CodeableConcept(); // cc 1071 return this.network; 1072 } 1073 1074 public boolean hasNetwork() { 1075 return this.network != null && !this.network.isEmpty(); 1076 } 1077 1078 /** 1079 * @param value {@link #network} (Is a flag to indicate whether the benefits refer to in-network providers or out-of-network providers.) 1080 */ 1081 public ItemsComponent setNetwork(CodeableConcept value) { 1082 this.network = value; 1083 return this; 1084 } 1085 1086 /** 1087 * @return {@link #unit} (Indicates if the benefits apply to an individual or to the family.) 1088 */ 1089 public CodeableConcept getUnit() { 1090 if (this.unit == null) 1091 if (Configuration.errorOnAutoCreate()) 1092 throw new Error("Attempt to auto-create ItemsComponent.unit"); 1093 else if (Configuration.doAutoCreate()) 1094 this.unit = new CodeableConcept(); // cc 1095 return this.unit; 1096 } 1097 1098 public boolean hasUnit() { 1099 return this.unit != null && !this.unit.isEmpty(); 1100 } 1101 1102 /** 1103 * @param value {@link #unit} (Indicates if the benefits apply to an individual or to the family.) 1104 */ 1105 public ItemsComponent setUnit(CodeableConcept value) { 1106 this.unit = value; 1107 return this; 1108 } 1109 1110 /** 1111 * @return {@link #term} (The term or period of the values such as 'maximum lifetime benefit' or 'maximum annual visits'.) 1112 */ 1113 public CodeableConcept getTerm() { 1114 if (this.term == null) 1115 if (Configuration.errorOnAutoCreate()) 1116 throw new Error("Attempt to auto-create ItemsComponent.term"); 1117 else if (Configuration.doAutoCreate()) 1118 this.term = new CodeableConcept(); // cc 1119 return this.term; 1120 } 1121 1122 public boolean hasTerm() { 1123 return this.term != null && !this.term.isEmpty(); 1124 } 1125 1126 /** 1127 * @param value {@link #term} (The term or period of the values such as 'maximum lifetime benefit' or 'maximum annual visits'.) 1128 */ 1129 public ItemsComponent setTerm(CodeableConcept value) { 1130 this.term = value; 1131 return this; 1132 } 1133 1134 /** 1135 * @return {@link #benefit} (Benefits used to date.) 1136 */ 1137 public List<BenefitComponent> getBenefit() { 1138 if (this.benefit == null) 1139 this.benefit = new ArrayList<BenefitComponent>(); 1140 return this.benefit; 1141 } 1142 1143 /** 1144 * @return Returns a reference to <code>this</code> for easy method chaining 1145 */ 1146 public ItemsComponent setBenefit(List<BenefitComponent> theBenefit) { 1147 this.benefit = theBenefit; 1148 return this; 1149 } 1150 1151 public boolean hasBenefit() { 1152 if (this.benefit == null) 1153 return false; 1154 for (BenefitComponent item : this.benefit) 1155 if (!item.isEmpty()) 1156 return true; 1157 return false; 1158 } 1159 1160 public BenefitComponent addBenefit() { //3 1161 BenefitComponent t = new BenefitComponent(); 1162 if (this.benefit == null) 1163 this.benefit = new ArrayList<BenefitComponent>(); 1164 this.benefit.add(t); 1165 return t; 1166 } 1167 1168 public ItemsComponent addBenefit(BenefitComponent t) { //3 1169 if (t == null) 1170 return this; 1171 if (this.benefit == null) 1172 this.benefit = new ArrayList<BenefitComponent>(); 1173 this.benefit.add(t); 1174 return this; 1175 } 1176 1177 /** 1178 * @return The first repetition of repeating field {@link #benefit}, creating it if it does not already exist 1179 */ 1180 public BenefitComponent getBenefitFirstRep() { 1181 if (getBenefit().isEmpty()) { 1182 addBenefit(); 1183 } 1184 return getBenefit().get(0); 1185 } 1186 1187 /** 1188 * @return {@link #authorizationRequired} (A boolean flag indicating whether a preauthorization is required prior to actual service delivery.). This is the underlying object with id, value and extensions. The accessor "getAuthorizationRequired" gives direct access to the value 1189 */ 1190 public BooleanType getAuthorizationRequiredElement() { 1191 if (this.authorizationRequired == null) 1192 if (Configuration.errorOnAutoCreate()) 1193 throw new Error("Attempt to auto-create ItemsComponent.authorizationRequired"); 1194 else if (Configuration.doAutoCreate()) 1195 this.authorizationRequired = new BooleanType(); // bb 1196 return this.authorizationRequired; 1197 } 1198 1199 public boolean hasAuthorizationRequiredElement() { 1200 return this.authorizationRequired != null && !this.authorizationRequired.isEmpty(); 1201 } 1202 1203 public boolean hasAuthorizationRequired() { 1204 return this.authorizationRequired != null && !this.authorizationRequired.isEmpty(); 1205 } 1206 1207 /** 1208 * @param value {@link #authorizationRequired} (A boolean flag indicating whether a preauthorization is required prior to actual service delivery.). This is the underlying object with id, value and extensions. The accessor "getAuthorizationRequired" gives direct access to the value 1209 */ 1210 public ItemsComponent setAuthorizationRequiredElement(BooleanType value) { 1211 this.authorizationRequired = value; 1212 return this; 1213 } 1214 1215 /** 1216 * @return A boolean flag indicating whether a preauthorization is required prior to actual service delivery. 1217 */ 1218 public boolean getAuthorizationRequired() { 1219 return this.authorizationRequired == null || this.authorizationRequired.isEmpty() ? false : this.authorizationRequired.getValue(); 1220 } 1221 1222 /** 1223 * @param value A boolean flag indicating whether a preauthorization is required prior to actual service delivery. 1224 */ 1225 public ItemsComponent setAuthorizationRequired(boolean value) { 1226 if (this.authorizationRequired == null) 1227 this.authorizationRequired = new BooleanType(); 1228 this.authorizationRequired.setValue(value); 1229 return this; 1230 } 1231 1232 /** 1233 * @return {@link #authorizationSupporting} (Codes or comments regarding information or actions associated with the preauthorization.) 1234 */ 1235 public List<CodeableConcept> getAuthorizationSupporting() { 1236 if (this.authorizationSupporting == null) 1237 this.authorizationSupporting = new ArrayList<CodeableConcept>(); 1238 return this.authorizationSupporting; 1239 } 1240 1241 /** 1242 * @return Returns a reference to <code>this</code> for easy method chaining 1243 */ 1244 public ItemsComponent setAuthorizationSupporting(List<CodeableConcept> theAuthorizationSupporting) { 1245 this.authorizationSupporting = theAuthorizationSupporting; 1246 return this; 1247 } 1248 1249 public boolean hasAuthorizationSupporting() { 1250 if (this.authorizationSupporting == null) 1251 return false; 1252 for (CodeableConcept item : this.authorizationSupporting) 1253 if (!item.isEmpty()) 1254 return true; 1255 return false; 1256 } 1257 1258 public CodeableConcept addAuthorizationSupporting() { //3 1259 CodeableConcept t = new CodeableConcept(); 1260 if (this.authorizationSupporting == null) 1261 this.authorizationSupporting = new ArrayList<CodeableConcept>(); 1262 this.authorizationSupporting.add(t); 1263 return t; 1264 } 1265 1266 public ItemsComponent addAuthorizationSupporting(CodeableConcept t) { //3 1267 if (t == null) 1268 return this; 1269 if (this.authorizationSupporting == null) 1270 this.authorizationSupporting = new ArrayList<CodeableConcept>(); 1271 this.authorizationSupporting.add(t); 1272 return this; 1273 } 1274 1275 /** 1276 * @return The first repetition of repeating field {@link #authorizationSupporting}, creating it if it does not already exist 1277 */ 1278 public CodeableConcept getAuthorizationSupportingFirstRep() { 1279 if (getAuthorizationSupporting().isEmpty()) { 1280 addAuthorizationSupporting(); 1281 } 1282 return getAuthorizationSupporting().get(0); 1283 } 1284 1285 /** 1286 * @return {@link #authorizationUrl} (A web location for obtaining requirements or descriptive information regarding the preauthorization.). This is the underlying object with id, value and extensions. The accessor "getAuthorizationUrl" gives direct access to the value 1287 */ 1288 public UriType getAuthorizationUrlElement() { 1289 if (this.authorizationUrl == null) 1290 if (Configuration.errorOnAutoCreate()) 1291 throw new Error("Attempt to auto-create ItemsComponent.authorizationUrl"); 1292 else if (Configuration.doAutoCreate()) 1293 this.authorizationUrl = new UriType(); // bb 1294 return this.authorizationUrl; 1295 } 1296 1297 public boolean hasAuthorizationUrlElement() { 1298 return this.authorizationUrl != null && !this.authorizationUrl.isEmpty(); 1299 } 1300 1301 public boolean hasAuthorizationUrl() { 1302 return this.authorizationUrl != null && !this.authorizationUrl.isEmpty(); 1303 } 1304 1305 /** 1306 * @param value {@link #authorizationUrl} (A web location for obtaining requirements or descriptive information regarding the preauthorization.). This is the underlying object with id, value and extensions. The accessor "getAuthorizationUrl" gives direct access to the value 1307 */ 1308 public ItemsComponent setAuthorizationUrlElement(UriType value) { 1309 this.authorizationUrl = value; 1310 return this; 1311 } 1312 1313 /** 1314 * @return A web location for obtaining requirements or descriptive information regarding the preauthorization. 1315 */ 1316 public String getAuthorizationUrl() { 1317 return this.authorizationUrl == null ? null : this.authorizationUrl.getValue(); 1318 } 1319 1320 /** 1321 * @param value A web location for obtaining requirements or descriptive information regarding the preauthorization. 1322 */ 1323 public ItemsComponent setAuthorizationUrl(String value) { 1324 if (Utilities.noString(value)) 1325 this.authorizationUrl = null; 1326 else { 1327 if (this.authorizationUrl == null) 1328 this.authorizationUrl = new UriType(); 1329 this.authorizationUrl.setValue(value); 1330 } 1331 return this; 1332 } 1333 1334 protected void listChildren(List<Property> children) { 1335 super.listChildren(children); 1336 children.add(new Property("category", "CodeableConcept", "Code to identify the general type of benefits under which products and services are provided.", 0, 1, category)); 1337 children.add(new Property("productOrService", "CodeableConcept", "This contains the product, service, drug or other billing code for the item.", 0, 1, productOrService)); 1338 children.add(new Property("modifier", "CodeableConcept", "Item typification or modifiers codes to convey additional context for the product or service.", 0, java.lang.Integer.MAX_VALUE, modifier)); 1339 children.add(new Property("provider", "Reference(Practitioner|PractitionerRole)", "The practitioner who is eligible for the provision of the product or service.", 0, 1, provider)); 1340 children.add(new Property("excluded", "boolean", "True if the indicated class of service is excluded from the plan, missing or False indicates the product or service is included in the coverage.", 0, 1, excluded)); 1341 children.add(new Property("name", "string", "A short name or tag for the benefit.", 0, 1, name)); 1342 children.add(new Property("description", "string", "A richer description of the benefit or services covered.", 0, 1, description)); 1343 children.add(new Property("network", "CodeableConcept", "Is a flag to indicate whether the benefits refer to in-network providers or out-of-network providers.", 0, 1, network)); 1344 children.add(new Property("unit", "CodeableConcept", "Indicates if the benefits apply to an individual or to the family.", 0, 1, unit)); 1345 children.add(new Property("term", "CodeableConcept", "The term or period of the values such as 'maximum lifetime benefit' or 'maximum annual visits'.", 0, 1, term)); 1346 children.add(new Property("benefit", "", "Benefits used to date.", 0, java.lang.Integer.MAX_VALUE, benefit)); 1347 children.add(new Property("authorizationRequired", "boolean", "A boolean flag indicating whether a preauthorization is required prior to actual service delivery.", 0, 1, authorizationRequired)); 1348 children.add(new Property("authorizationSupporting", "CodeableConcept", "Codes or comments regarding information or actions associated with the preauthorization.", 0, java.lang.Integer.MAX_VALUE, authorizationSupporting)); 1349 children.add(new Property("authorizationUrl", "uri", "A web location for obtaining requirements or descriptive information regarding the preauthorization.", 0, 1, authorizationUrl)); 1350 } 1351 1352 @Override 1353 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1354 switch (_hash) { 1355 case 50511102: /*category*/ return new Property("category", "CodeableConcept", "Code to identify the general type of benefits under which products and services are provided.", 0, 1, category); 1356 case 1957227299: /*productOrService*/ return new Property("productOrService", "CodeableConcept", "This contains the product, service, drug or other billing code for the item.", 0, 1, productOrService); 1357 case -615513385: /*modifier*/ return new Property("modifier", "CodeableConcept", "Item typification or modifiers codes to convey additional context for the product or service.", 0, java.lang.Integer.MAX_VALUE, modifier); 1358 case -987494927: /*provider*/ return new Property("provider", "Reference(Practitioner|PractitionerRole)", "The practitioner who is eligible for the provision of the product or service.", 0, 1, provider); 1359 case 1994055114: /*excluded*/ return new Property("excluded", "boolean", "True if the indicated class of service is excluded from the plan, missing or False indicates the product or service is included in the coverage.", 0, 1, excluded); 1360 case 3373707: /*name*/ return new Property("name", "string", "A short name or tag for the benefit.", 0, 1, name); 1361 case -1724546052: /*description*/ return new Property("description", "string", "A richer description of the benefit or services covered.", 0, 1, description); 1362 case 1843485230: /*network*/ return new Property("network", "CodeableConcept", "Is a flag to indicate whether the benefits refer to in-network providers or out-of-network providers.", 0, 1, network); 1363 case 3594628: /*unit*/ return new Property("unit", "CodeableConcept", "Indicates if the benefits apply to an individual or to the family.", 0, 1, unit); 1364 case 3556460: /*term*/ return new Property("term", "CodeableConcept", "The term or period of the values such as 'maximum lifetime benefit' or 'maximum annual visits'.", 0, 1, term); 1365 case -222710633: /*benefit*/ return new Property("benefit", "", "Benefits used to date.", 0, java.lang.Integer.MAX_VALUE, benefit); 1366 case 374204216: /*authorizationRequired*/ return new Property("authorizationRequired", "boolean", "A boolean flag indicating whether a preauthorization is required prior to actual service delivery.", 0, 1, authorizationRequired); 1367 case -1931146484: /*authorizationSupporting*/ return new Property("authorizationSupporting", "CodeableConcept", "Codes or comments regarding information or actions associated with the preauthorization.", 0, java.lang.Integer.MAX_VALUE, authorizationSupporting); 1368 case 1409445430: /*authorizationUrl*/ return new Property("authorizationUrl", "uri", "A web location for obtaining requirements or descriptive information regarding the preauthorization.", 0, 1, authorizationUrl); 1369 default: return super.getNamedProperty(_hash, _name, _checkValid); 1370 } 1371 1372 } 1373 1374 @Override 1375 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1376 switch (hash) { 1377 case 50511102: /*category*/ return this.category == null ? new Base[0] : new Base[] {this.category}; // CodeableConcept 1378 case 1957227299: /*productOrService*/ return this.productOrService == null ? new Base[0] : new Base[] {this.productOrService}; // CodeableConcept 1379 case -615513385: /*modifier*/ return this.modifier == null ? new Base[0] : this.modifier.toArray(new Base[this.modifier.size()]); // CodeableConcept 1380 case -987494927: /*provider*/ return this.provider == null ? new Base[0] : new Base[] {this.provider}; // Reference 1381 case 1994055114: /*excluded*/ return this.excluded == null ? new Base[0] : new Base[] {this.excluded}; // BooleanType 1382 case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType 1383 case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType 1384 case 1843485230: /*network*/ return this.network == null ? new Base[0] : new Base[] {this.network}; // CodeableConcept 1385 case 3594628: /*unit*/ return this.unit == null ? new Base[0] : new Base[] {this.unit}; // CodeableConcept 1386 case 3556460: /*term*/ return this.term == null ? new Base[0] : new Base[] {this.term}; // CodeableConcept 1387 case -222710633: /*benefit*/ return this.benefit == null ? new Base[0] : this.benefit.toArray(new Base[this.benefit.size()]); // BenefitComponent 1388 case 374204216: /*authorizationRequired*/ return this.authorizationRequired == null ? new Base[0] : new Base[] {this.authorizationRequired}; // BooleanType 1389 case -1931146484: /*authorizationSupporting*/ return this.authorizationSupporting == null ? new Base[0] : this.authorizationSupporting.toArray(new Base[this.authorizationSupporting.size()]); // CodeableConcept 1390 case 1409445430: /*authorizationUrl*/ return this.authorizationUrl == null ? new Base[0] : new Base[] {this.authorizationUrl}; // UriType 1391 default: return super.getProperty(hash, name, checkValid); 1392 } 1393 1394 } 1395 1396 @Override 1397 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1398 switch (hash) { 1399 case 50511102: // category 1400 this.category = castToCodeableConcept(value); // CodeableConcept 1401 return value; 1402 case 1957227299: // productOrService 1403 this.productOrService = castToCodeableConcept(value); // CodeableConcept 1404 return value; 1405 case -615513385: // modifier 1406 this.getModifier().add(castToCodeableConcept(value)); // CodeableConcept 1407 return value; 1408 case -987494927: // provider 1409 this.provider = castToReference(value); // Reference 1410 return value; 1411 case 1994055114: // excluded 1412 this.excluded = castToBoolean(value); // BooleanType 1413 return value; 1414 case 3373707: // name 1415 this.name = castToString(value); // StringType 1416 return value; 1417 case -1724546052: // description 1418 this.description = castToString(value); // StringType 1419 return value; 1420 case 1843485230: // network 1421 this.network = castToCodeableConcept(value); // CodeableConcept 1422 return value; 1423 case 3594628: // unit 1424 this.unit = castToCodeableConcept(value); // CodeableConcept 1425 return value; 1426 case 3556460: // term 1427 this.term = castToCodeableConcept(value); // CodeableConcept 1428 return value; 1429 case -222710633: // benefit 1430 this.getBenefit().add((BenefitComponent) value); // BenefitComponent 1431 return value; 1432 case 374204216: // authorizationRequired 1433 this.authorizationRequired = castToBoolean(value); // BooleanType 1434 return value; 1435 case -1931146484: // authorizationSupporting 1436 this.getAuthorizationSupporting().add(castToCodeableConcept(value)); // CodeableConcept 1437 return value; 1438 case 1409445430: // authorizationUrl 1439 this.authorizationUrl = castToUri(value); // UriType 1440 return value; 1441 default: return super.setProperty(hash, name, value); 1442 } 1443 1444 } 1445 1446 @Override 1447 public Base setProperty(String name, Base value) throws FHIRException { 1448 if (name.equals("category")) { 1449 this.category = castToCodeableConcept(value); // CodeableConcept 1450 } else if (name.equals("productOrService")) { 1451 this.productOrService = castToCodeableConcept(value); // CodeableConcept 1452 } else if (name.equals("modifier")) { 1453 this.getModifier().add(castToCodeableConcept(value)); 1454 } else if (name.equals("provider")) { 1455 this.provider = castToReference(value); // Reference 1456 } else if (name.equals("excluded")) { 1457 this.excluded = castToBoolean(value); // BooleanType 1458 } else if (name.equals("name")) { 1459 this.name = castToString(value); // StringType 1460 } else if (name.equals("description")) { 1461 this.description = castToString(value); // StringType 1462 } else if (name.equals("network")) { 1463 this.network = castToCodeableConcept(value); // CodeableConcept 1464 } else if (name.equals("unit")) { 1465 this.unit = castToCodeableConcept(value); // CodeableConcept 1466 } else if (name.equals("term")) { 1467 this.term = castToCodeableConcept(value); // CodeableConcept 1468 } else if (name.equals("benefit")) { 1469 this.getBenefit().add((BenefitComponent) value); 1470 } else if (name.equals("authorizationRequired")) { 1471 this.authorizationRequired = castToBoolean(value); // BooleanType 1472 } else if (name.equals("authorizationSupporting")) { 1473 this.getAuthorizationSupporting().add(castToCodeableConcept(value)); 1474 } else if (name.equals("authorizationUrl")) { 1475 this.authorizationUrl = castToUri(value); // UriType 1476 } else 1477 return super.setProperty(name, value); 1478 return value; 1479 } 1480 1481 @Override 1482 public Base makeProperty(int hash, String name) throws FHIRException { 1483 switch (hash) { 1484 case 50511102: return getCategory(); 1485 case 1957227299: return getProductOrService(); 1486 case -615513385: return addModifier(); 1487 case -987494927: return getProvider(); 1488 case 1994055114: return getExcludedElement(); 1489 case 3373707: return getNameElement(); 1490 case -1724546052: return getDescriptionElement(); 1491 case 1843485230: return getNetwork(); 1492 case 3594628: return getUnit(); 1493 case 3556460: return getTerm(); 1494 case -222710633: return addBenefit(); 1495 case 374204216: return getAuthorizationRequiredElement(); 1496 case -1931146484: return addAuthorizationSupporting(); 1497 case 1409445430: return getAuthorizationUrlElement(); 1498 default: return super.makeProperty(hash, name); 1499 } 1500 1501 } 1502 1503 @Override 1504 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1505 switch (hash) { 1506 case 50511102: /*category*/ return new String[] {"CodeableConcept"}; 1507 case 1957227299: /*productOrService*/ return new String[] {"CodeableConcept"}; 1508 case -615513385: /*modifier*/ return new String[] {"CodeableConcept"}; 1509 case -987494927: /*provider*/ return new String[] {"Reference"}; 1510 case 1994055114: /*excluded*/ return new String[] {"boolean"}; 1511 case 3373707: /*name*/ return new String[] {"string"}; 1512 case -1724546052: /*description*/ return new String[] {"string"}; 1513 case 1843485230: /*network*/ return new String[] {"CodeableConcept"}; 1514 case 3594628: /*unit*/ return new String[] {"CodeableConcept"}; 1515 case 3556460: /*term*/ return new String[] {"CodeableConcept"}; 1516 case -222710633: /*benefit*/ return new String[] {}; 1517 case 374204216: /*authorizationRequired*/ return new String[] {"boolean"}; 1518 case -1931146484: /*authorizationSupporting*/ return new String[] {"CodeableConcept"}; 1519 case 1409445430: /*authorizationUrl*/ return new String[] {"uri"}; 1520 default: return super.getTypesForProperty(hash, name); 1521 } 1522 1523 } 1524 1525 @Override 1526 public Base addChild(String name) throws FHIRException { 1527 if (name.equals("category")) { 1528 this.category = new CodeableConcept(); 1529 return this.category; 1530 } 1531 else if (name.equals("productOrService")) { 1532 this.productOrService = new CodeableConcept(); 1533 return this.productOrService; 1534 } 1535 else if (name.equals("modifier")) { 1536 return addModifier(); 1537 } 1538 else if (name.equals("provider")) { 1539 this.provider = new Reference(); 1540 return this.provider; 1541 } 1542 else if (name.equals("excluded")) { 1543 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.excluded"); 1544 } 1545 else if (name.equals("name")) { 1546 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.name"); 1547 } 1548 else if (name.equals("description")) { 1549 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.description"); 1550 } 1551 else if (name.equals("network")) { 1552 this.network = new CodeableConcept(); 1553 return this.network; 1554 } 1555 else if (name.equals("unit")) { 1556 this.unit = new CodeableConcept(); 1557 return this.unit; 1558 } 1559 else if (name.equals("term")) { 1560 this.term = new CodeableConcept(); 1561 return this.term; 1562 } 1563 else if (name.equals("benefit")) { 1564 return addBenefit(); 1565 } 1566 else if (name.equals("authorizationRequired")) { 1567 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.authorizationRequired"); 1568 } 1569 else if (name.equals("authorizationSupporting")) { 1570 return addAuthorizationSupporting(); 1571 } 1572 else if (name.equals("authorizationUrl")) { 1573 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.authorizationUrl"); 1574 } 1575 else 1576 return super.addChild(name); 1577 } 1578 1579 public ItemsComponent copy() { 1580 ItemsComponent dst = new ItemsComponent(); 1581 copyValues(dst); 1582 return dst; 1583 } 1584 1585 public void copyValues(ItemsComponent dst) { 1586 super.copyValues(dst); 1587 dst.category = category == null ? null : category.copy(); 1588 dst.productOrService = productOrService == null ? null : productOrService.copy(); 1589 if (modifier != null) { 1590 dst.modifier = new ArrayList<CodeableConcept>(); 1591 for (CodeableConcept i : modifier) 1592 dst.modifier.add(i.copy()); 1593 }; 1594 dst.provider = provider == null ? null : provider.copy(); 1595 dst.excluded = excluded == null ? null : excluded.copy(); 1596 dst.name = name == null ? null : name.copy(); 1597 dst.description = description == null ? null : description.copy(); 1598 dst.network = network == null ? null : network.copy(); 1599 dst.unit = unit == null ? null : unit.copy(); 1600 dst.term = term == null ? null : term.copy(); 1601 if (benefit != null) { 1602 dst.benefit = new ArrayList<BenefitComponent>(); 1603 for (BenefitComponent i : benefit) 1604 dst.benefit.add(i.copy()); 1605 }; 1606 dst.authorizationRequired = authorizationRequired == null ? null : authorizationRequired.copy(); 1607 if (authorizationSupporting != null) { 1608 dst.authorizationSupporting = new ArrayList<CodeableConcept>(); 1609 for (CodeableConcept i : authorizationSupporting) 1610 dst.authorizationSupporting.add(i.copy()); 1611 }; 1612 dst.authorizationUrl = authorizationUrl == null ? null : authorizationUrl.copy(); 1613 } 1614 1615 @Override 1616 public boolean equalsDeep(Base other_) { 1617 if (!super.equalsDeep(other_)) 1618 return false; 1619 if (!(other_ instanceof ItemsComponent)) 1620 return false; 1621 ItemsComponent o = (ItemsComponent) other_; 1622 return compareDeep(category, o.category, true) && compareDeep(productOrService, o.productOrService, true) 1623 && compareDeep(modifier, o.modifier, true) && compareDeep(provider, o.provider, true) && compareDeep(excluded, o.excluded, true) 1624 && compareDeep(name, o.name, true) && compareDeep(description, o.description, true) && compareDeep(network, o.network, true) 1625 && compareDeep(unit, o.unit, true) && compareDeep(term, o.term, true) && compareDeep(benefit, o.benefit, true) 1626 && compareDeep(authorizationRequired, o.authorizationRequired, true) && compareDeep(authorizationSupporting, o.authorizationSupporting, true) 1627 && compareDeep(authorizationUrl, o.authorizationUrl, true); 1628 } 1629 1630 @Override 1631 public boolean equalsShallow(Base other_) { 1632 if (!super.equalsShallow(other_)) 1633 return false; 1634 if (!(other_ instanceof ItemsComponent)) 1635 return false; 1636 ItemsComponent o = (ItemsComponent) other_; 1637 return compareValues(excluded, o.excluded, true) && compareValues(name, o.name, true) && compareValues(description, o.description, true) 1638 && compareValues(authorizationRequired, o.authorizationRequired, true) && compareValues(authorizationUrl, o.authorizationUrl, true) 1639 ; 1640 } 1641 1642 public boolean isEmpty() { 1643 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(category, productOrService 1644 , modifier, provider, excluded, name, description, network, unit, term, benefit 1645 , authorizationRequired, authorizationSupporting, authorizationUrl); 1646 } 1647 1648 public String fhirType() { 1649 return "CoverageEligibilityResponse.insurance.item"; 1650 1651 } 1652 1653 } 1654 1655 @Block() 1656 public static class BenefitComponent extends BackboneElement implements IBaseBackboneElement { 1657 /** 1658 * Classification of benefit being provided. 1659 */ 1660 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 1661 @Description(shortDefinition="Benefit classification", formalDefinition="Classification of benefit being provided." ) 1662 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/benefit-type") 1663 protected CodeableConcept type; 1664 1665 /** 1666 * The quantity of the benefit which is permitted under the coverage. 1667 */ 1668 @Child(name = "allowed", type = {UnsignedIntType.class, StringType.class, Money.class}, order=2, min=0, max=1, modifier=false, summary=false) 1669 @Description(shortDefinition="Benefits allowed", formalDefinition="The quantity of the benefit which is permitted under the coverage." ) 1670 protected Type allowed; 1671 1672 /** 1673 * The quantity of the benefit which have been consumed to date. 1674 */ 1675 @Child(name = "used", type = {UnsignedIntType.class, StringType.class, Money.class}, order=3, min=0, max=1, modifier=false, summary=false) 1676 @Description(shortDefinition="Benefits used", formalDefinition="The quantity of the benefit which have been consumed to date." ) 1677 protected Type used; 1678 1679 private static final long serialVersionUID = -1506285314L; 1680 1681 /** 1682 * Constructor 1683 */ 1684 public BenefitComponent() { 1685 super(); 1686 } 1687 1688 /** 1689 * Constructor 1690 */ 1691 public BenefitComponent(CodeableConcept type) { 1692 super(); 1693 this.type = type; 1694 } 1695 1696 /** 1697 * @return {@link #type} (Classification of benefit being provided.) 1698 */ 1699 public CodeableConcept getType() { 1700 if (this.type == null) 1701 if (Configuration.errorOnAutoCreate()) 1702 throw new Error("Attempt to auto-create BenefitComponent.type"); 1703 else if (Configuration.doAutoCreate()) 1704 this.type = new CodeableConcept(); // cc 1705 return this.type; 1706 } 1707 1708 public boolean hasType() { 1709 return this.type != null && !this.type.isEmpty(); 1710 } 1711 1712 /** 1713 * @param value {@link #type} (Classification of benefit being provided.) 1714 */ 1715 public BenefitComponent setType(CodeableConcept value) { 1716 this.type = value; 1717 return this; 1718 } 1719 1720 /** 1721 * @return {@link #allowed} (The quantity of the benefit which is permitted under the coverage.) 1722 */ 1723 public Type getAllowed() { 1724 return this.allowed; 1725 } 1726 1727 /** 1728 * @return {@link #allowed} (The quantity of the benefit which is permitted under the coverage.) 1729 */ 1730 public UnsignedIntType getAllowedUnsignedIntType() throws FHIRException { 1731 if (this.allowed == null) 1732 this.allowed = new UnsignedIntType(); 1733 if (!(this.allowed instanceof UnsignedIntType)) 1734 throw new FHIRException("Type mismatch: the type UnsignedIntType was expected, but "+this.allowed.getClass().getName()+" was encountered"); 1735 return (UnsignedIntType) this.allowed; 1736 } 1737 1738 public boolean hasAllowedUnsignedIntType() { 1739 return this != null && this.allowed instanceof UnsignedIntType; 1740 } 1741 1742 /** 1743 * @return {@link #allowed} (The quantity of the benefit which is permitted under the coverage.) 1744 */ 1745 public StringType getAllowedStringType() throws FHIRException { 1746 if (this.allowed == null) 1747 this.allowed = new StringType(); 1748 if (!(this.allowed instanceof StringType)) 1749 throw new FHIRException("Type mismatch: the type StringType was expected, but "+this.allowed.getClass().getName()+" was encountered"); 1750 return (StringType) this.allowed; 1751 } 1752 1753 public boolean hasAllowedStringType() { 1754 return this != null && this.allowed instanceof StringType; 1755 } 1756 1757 /** 1758 * @return {@link #allowed} (The quantity of the benefit which is permitted under the coverage.) 1759 */ 1760 public Money getAllowedMoney() throws FHIRException { 1761 if (this.allowed == null) 1762 this.allowed = new Money(); 1763 if (!(this.allowed instanceof Money)) 1764 throw new FHIRException("Type mismatch: the type Money was expected, but "+this.allowed.getClass().getName()+" was encountered"); 1765 return (Money) this.allowed; 1766 } 1767 1768 public boolean hasAllowedMoney() { 1769 return this != null && this.allowed instanceof Money; 1770 } 1771 1772 public boolean hasAllowed() { 1773 return this.allowed != null && !this.allowed.isEmpty(); 1774 } 1775 1776 /** 1777 * @param value {@link #allowed} (The quantity of the benefit which is permitted under the coverage.) 1778 */ 1779 public BenefitComponent setAllowed(Type value) { 1780 if (value != null && !(value instanceof UnsignedIntType || value instanceof StringType || value instanceof Money)) 1781 throw new Error("Not the right type for CoverageEligibilityResponse.insurance.item.benefit.allowed[x]: "+value.fhirType()); 1782 this.allowed = value; 1783 return this; 1784 } 1785 1786 /** 1787 * @return {@link #used} (The quantity of the benefit which have been consumed to date.) 1788 */ 1789 public Type getUsed() { 1790 return this.used; 1791 } 1792 1793 /** 1794 * @return {@link #used} (The quantity of the benefit which have been consumed to date.) 1795 */ 1796 public UnsignedIntType getUsedUnsignedIntType() throws FHIRException { 1797 if (this.used == null) 1798 this.used = new UnsignedIntType(); 1799 if (!(this.used instanceof UnsignedIntType)) 1800 throw new FHIRException("Type mismatch: the type UnsignedIntType was expected, but "+this.used.getClass().getName()+" was encountered"); 1801 return (UnsignedIntType) this.used; 1802 } 1803 1804 public boolean hasUsedUnsignedIntType() { 1805 return this != null && this.used instanceof UnsignedIntType; 1806 } 1807 1808 /** 1809 * @return {@link #used} (The quantity of the benefit which have been consumed to date.) 1810 */ 1811 public StringType getUsedStringType() throws FHIRException { 1812 if (this.used == null) 1813 this.used = new StringType(); 1814 if (!(this.used instanceof StringType)) 1815 throw new FHIRException("Type mismatch: the type StringType was expected, but "+this.used.getClass().getName()+" was encountered"); 1816 return (StringType) this.used; 1817 } 1818 1819 public boolean hasUsedStringType() { 1820 return this != null && this.used instanceof StringType; 1821 } 1822 1823 /** 1824 * @return {@link #used} (The quantity of the benefit which have been consumed to date.) 1825 */ 1826 public Money getUsedMoney() throws FHIRException { 1827 if (this.used == null) 1828 this.used = new Money(); 1829 if (!(this.used instanceof Money)) 1830 throw new FHIRException("Type mismatch: the type Money was expected, but "+this.used.getClass().getName()+" was encountered"); 1831 return (Money) this.used; 1832 } 1833 1834 public boolean hasUsedMoney() { 1835 return this != null && this.used instanceof Money; 1836 } 1837 1838 public boolean hasUsed() { 1839 return this.used != null && !this.used.isEmpty(); 1840 } 1841 1842 /** 1843 * @param value {@link #used} (The quantity of the benefit which have been consumed to date.) 1844 */ 1845 public BenefitComponent setUsed(Type value) { 1846 if (value != null && !(value instanceof UnsignedIntType || value instanceof StringType || value instanceof Money)) 1847 throw new Error("Not the right type for CoverageEligibilityResponse.insurance.item.benefit.used[x]: "+value.fhirType()); 1848 this.used = value; 1849 return this; 1850 } 1851 1852 protected void listChildren(List<Property> children) { 1853 super.listChildren(children); 1854 children.add(new Property("type", "CodeableConcept", "Classification of benefit being provided.", 0, 1, type)); 1855 children.add(new Property("allowed[x]", "unsignedInt|string|Money", "The quantity of the benefit which is permitted under the coverage.", 0, 1, allowed)); 1856 children.add(new Property("used[x]", "unsignedInt|string|Money", "The quantity of the benefit which have been consumed to date.", 0, 1, used)); 1857 } 1858 1859 @Override 1860 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1861 switch (_hash) { 1862 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Classification of benefit being provided.", 0, 1, type); 1863 case -1336663592: /*allowed[x]*/ return new Property("allowed[x]", "unsignedInt|string|Money", "The quantity of the benefit which is permitted under the coverage.", 0, 1, allowed); 1864 case -911343192: /*allowed*/ return new Property("allowed[x]", "unsignedInt|string|Money", "The quantity of the benefit which is permitted under the coverage.", 0, 1, allowed); 1865 case 1668802034: /*allowedUnsignedInt*/ return new Property("allowed[x]", "unsignedInt|string|Money", "The quantity of the benefit which is permitted under the coverage.", 0, 1, allowed); 1866 case -2135265319: /*allowedString*/ return new Property("allowed[x]", "unsignedInt|string|Money", "The quantity of the benefit which is permitted under the coverage.", 0, 1, allowed); 1867 case -351668232: /*allowedMoney*/ return new Property("allowed[x]", "unsignedInt|string|Money", "The quantity of the benefit which is permitted under the coverage.", 0, 1, allowed); 1868 case -147553373: /*used[x]*/ return new Property("used[x]", "unsignedInt|string|Money", "The quantity of the benefit which have been consumed to date.", 0, 1, used); 1869 case 3599293: /*used*/ return new Property("used[x]", "unsignedInt|string|Money", "The quantity of the benefit which have been consumed to date.", 0, 1, used); 1870 case 1252740285: /*usedUnsignedInt*/ return new Property("used[x]", "unsignedInt|string|Money", "The quantity of the benefit which have been consumed to date.", 0, 1, used); 1871 case 2051978798: /*usedString*/ return new Property("used[x]", "unsignedInt|string|Money", "The quantity of the benefit which have been consumed to date.", 0, 1, used); 1872 case -78048509: /*usedMoney*/ return new Property("used[x]", "unsignedInt|string|Money", "The quantity of the benefit which have been consumed to date.", 0, 1, used); 1873 default: return super.getNamedProperty(_hash, _name, _checkValid); 1874 } 1875 1876 } 1877 1878 @Override 1879 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1880 switch (hash) { 1881 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 1882 case -911343192: /*allowed*/ return this.allowed == null ? new Base[0] : new Base[] {this.allowed}; // Type 1883 case 3599293: /*used*/ return this.used == null ? new Base[0] : new Base[] {this.used}; // Type 1884 default: return super.getProperty(hash, name, checkValid); 1885 } 1886 1887 } 1888 1889 @Override 1890 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1891 switch (hash) { 1892 case 3575610: // type 1893 this.type = castToCodeableConcept(value); // CodeableConcept 1894 return value; 1895 case -911343192: // allowed 1896 this.allowed = castToType(value); // Type 1897 return value; 1898 case 3599293: // used 1899 this.used = castToType(value); // Type 1900 return value; 1901 default: return super.setProperty(hash, name, value); 1902 } 1903 1904 } 1905 1906 @Override 1907 public Base setProperty(String name, Base value) throws FHIRException { 1908 if (name.equals("type")) { 1909 this.type = castToCodeableConcept(value); // CodeableConcept 1910 } else if (name.equals("allowed[x]")) { 1911 this.allowed = castToType(value); // Type 1912 } else if (name.equals("used[x]")) { 1913 this.used = castToType(value); // Type 1914 } else 1915 return super.setProperty(name, value); 1916 return value; 1917 } 1918 1919 @Override 1920 public Base makeProperty(int hash, String name) throws FHIRException { 1921 switch (hash) { 1922 case 3575610: return getType(); 1923 case -1336663592: return getAllowed(); 1924 case -911343192: return getAllowed(); 1925 case -147553373: return getUsed(); 1926 case 3599293: return getUsed(); 1927 default: return super.makeProperty(hash, name); 1928 } 1929 1930 } 1931 1932 @Override 1933 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1934 switch (hash) { 1935 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 1936 case -911343192: /*allowed*/ return new String[] {"unsignedInt", "string", "Money"}; 1937 case 3599293: /*used*/ return new String[] {"unsignedInt", "string", "Money"}; 1938 default: return super.getTypesForProperty(hash, name); 1939 } 1940 1941 } 1942 1943 @Override 1944 public Base addChild(String name) throws FHIRException { 1945 if (name.equals("type")) { 1946 this.type = new CodeableConcept(); 1947 return this.type; 1948 } 1949 else if (name.equals("allowedUnsignedInt")) { 1950 this.allowed = new UnsignedIntType(); 1951 return this.allowed; 1952 } 1953 else if (name.equals("allowedString")) { 1954 this.allowed = new StringType(); 1955 return this.allowed; 1956 } 1957 else if (name.equals("allowedMoney")) { 1958 this.allowed = new Money(); 1959 return this.allowed; 1960 } 1961 else if (name.equals("usedUnsignedInt")) { 1962 this.used = new UnsignedIntType(); 1963 return this.used; 1964 } 1965 else if (name.equals("usedString")) { 1966 this.used = new StringType(); 1967 return this.used; 1968 } 1969 else if (name.equals("usedMoney")) { 1970 this.used = new Money(); 1971 return this.used; 1972 } 1973 else 1974 return super.addChild(name); 1975 } 1976 1977 public BenefitComponent copy() { 1978 BenefitComponent dst = new BenefitComponent(); 1979 copyValues(dst); 1980 return dst; 1981 } 1982 1983 public void copyValues(BenefitComponent dst) { 1984 super.copyValues(dst); 1985 dst.type = type == null ? null : type.copy(); 1986 dst.allowed = allowed == null ? null : allowed.copy(); 1987 dst.used = used == null ? null : used.copy(); 1988 } 1989 1990 @Override 1991 public boolean equalsDeep(Base other_) { 1992 if (!super.equalsDeep(other_)) 1993 return false; 1994 if (!(other_ instanceof BenefitComponent)) 1995 return false; 1996 BenefitComponent o = (BenefitComponent) other_; 1997 return compareDeep(type, o.type, true) && compareDeep(allowed, o.allowed, true) && compareDeep(used, o.used, true) 1998 ; 1999 } 2000 2001 @Override 2002 public boolean equalsShallow(Base other_) { 2003 if (!super.equalsShallow(other_)) 2004 return false; 2005 if (!(other_ instanceof BenefitComponent)) 2006 return false; 2007 BenefitComponent o = (BenefitComponent) other_; 2008 return true; 2009 } 2010 2011 public boolean isEmpty() { 2012 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, allowed, used); 2013 } 2014 2015 public String fhirType() { 2016 return "CoverageEligibilityResponse.insurance.item.benefit"; 2017 2018 } 2019 2020 } 2021 2022 @Block() 2023 public static class ErrorsComponent extends BackboneElement implements IBaseBackboneElement { 2024 /** 2025 * An error code,from a specified code system, which details why the eligibility check could not be performed. 2026 */ 2027 @Child(name = "code", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 2028 @Description(shortDefinition="Error code detailing processing issues", formalDefinition="An error code,from a specified code system, which details why the eligibility check could not be performed." ) 2029 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/adjudication-error") 2030 protected CodeableConcept code; 2031 2032 private static final long serialVersionUID = -1048343046L; 2033 2034 /** 2035 * Constructor 2036 */ 2037 public ErrorsComponent() { 2038 super(); 2039 } 2040 2041 /** 2042 * Constructor 2043 */ 2044 public ErrorsComponent(CodeableConcept code) { 2045 super(); 2046 this.code = code; 2047 } 2048 2049 /** 2050 * @return {@link #code} (An error code,from a specified code system, which details why the eligibility check could not be performed.) 2051 */ 2052 public CodeableConcept getCode() { 2053 if (this.code == null) 2054 if (Configuration.errorOnAutoCreate()) 2055 throw new Error("Attempt to auto-create ErrorsComponent.code"); 2056 else if (Configuration.doAutoCreate()) 2057 this.code = new CodeableConcept(); // cc 2058 return this.code; 2059 } 2060 2061 public boolean hasCode() { 2062 return this.code != null && !this.code.isEmpty(); 2063 } 2064 2065 /** 2066 * @param value {@link #code} (An error code,from a specified code system, which details why the eligibility check could not be performed.) 2067 */ 2068 public ErrorsComponent setCode(CodeableConcept value) { 2069 this.code = value; 2070 return this; 2071 } 2072 2073 protected void listChildren(List<Property> children) { 2074 super.listChildren(children); 2075 children.add(new Property("code", "CodeableConcept", "An error code,from a specified code system, which details why the eligibility check could not be performed.", 0, 1, code)); 2076 } 2077 2078 @Override 2079 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2080 switch (_hash) { 2081 case 3059181: /*code*/ return new Property("code", "CodeableConcept", "An error code,from a specified code system, which details why the eligibility check could not be performed.", 0, 1, code); 2082 default: return super.getNamedProperty(_hash, _name, _checkValid); 2083 } 2084 2085 } 2086 2087 @Override 2088 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2089 switch (hash) { 2090 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 2091 default: return super.getProperty(hash, name, checkValid); 2092 } 2093 2094 } 2095 2096 @Override 2097 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2098 switch (hash) { 2099 case 3059181: // code 2100 this.code = castToCodeableConcept(value); // CodeableConcept 2101 return value; 2102 default: return super.setProperty(hash, name, value); 2103 } 2104 2105 } 2106 2107 @Override 2108 public Base setProperty(String name, Base value) throws FHIRException { 2109 if (name.equals("code")) { 2110 this.code = castToCodeableConcept(value); // CodeableConcept 2111 } else 2112 return super.setProperty(name, value); 2113 return value; 2114 } 2115 2116 @Override 2117 public Base makeProperty(int hash, String name) throws FHIRException { 2118 switch (hash) { 2119 case 3059181: return getCode(); 2120 default: return super.makeProperty(hash, name); 2121 } 2122 2123 } 2124 2125 @Override 2126 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2127 switch (hash) { 2128 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 2129 default: return super.getTypesForProperty(hash, name); 2130 } 2131 2132 } 2133 2134 @Override 2135 public Base addChild(String name) throws FHIRException { 2136 if (name.equals("code")) { 2137 this.code = new CodeableConcept(); 2138 return this.code; 2139 } 2140 else 2141 return super.addChild(name); 2142 } 2143 2144 public ErrorsComponent copy() { 2145 ErrorsComponent dst = new ErrorsComponent(); 2146 copyValues(dst); 2147 return dst; 2148 } 2149 2150 public void copyValues(ErrorsComponent dst) { 2151 super.copyValues(dst); 2152 dst.code = code == null ? null : code.copy(); 2153 } 2154 2155 @Override 2156 public boolean equalsDeep(Base other_) { 2157 if (!super.equalsDeep(other_)) 2158 return false; 2159 if (!(other_ instanceof ErrorsComponent)) 2160 return false; 2161 ErrorsComponent o = (ErrorsComponent) other_; 2162 return compareDeep(code, o.code, true); 2163 } 2164 2165 @Override 2166 public boolean equalsShallow(Base other_) { 2167 if (!super.equalsShallow(other_)) 2168 return false; 2169 if (!(other_ instanceof ErrorsComponent)) 2170 return false; 2171 ErrorsComponent o = (ErrorsComponent) other_; 2172 return true; 2173 } 2174 2175 public boolean isEmpty() { 2176 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code); 2177 } 2178 2179 public String fhirType() { 2180 return "CoverageEligibilityResponse.error"; 2181 2182 } 2183 2184 } 2185 2186 /** 2187 * A unique identifier assigned to this coverage eligiblity request. 2188 */ 2189 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2190 @Description(shortDefinition="Business Identifier for coverage eligiblity request", formalDefinition="A unique identifier assigned to this coverage eligiblity request." ) 2191 protected List<Identifier> identifier; 2192 2193 /** 2194 * The status of the resource instance. 2195 */ 2196 @Child(name = "status", type = {CodeType.class}, order=1, min=1, max=1, modifier=true, summary=true) 2197 @Description(shortDefinition="active | cancelled | draft | entered-in-error", formalDefinition="The status of the resource instance." ) 2198 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/fm-status") 2199 protected Enumeration<EligibilityResponseStatus> status; 2200 2201 /** 2202 * Code to specify whether requesting: prior authorization requirements for some service categories or billing codes; benefits for coverages specified or discovered; discovery and return of coverages for the patient; and/or validation that the specified coverage is in-force at the date/period specified or 'now' if not specified. 2203 */ 2204 @Child(name = "purpose", type = {CodeType.class}, order=2, min=1, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 2205 @Description(shortDefinition="auth-requirements | benefits | discovery | validation", formalDefinition="Code to specify whether requesting: prior authorization requirements for some service categories or billing codes; benefits for coverages specified or discovered; discovery and return of coverages for the patient; and/or validation that the specified coverage is in-force at the date/period specified or 'now' if not specified." ) 2206 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/eligibilityresponse-purpose") 2207 protected List<Enumeration<EligibilityResponsePurpose>> purpose; 2208 2209 /** 2210 * The party who is the beneficiary of the supplied coverage and for whom eligibility is sought. 2211 */ 2212 @Child(name = "patient", type = {Patient.class}, order=3, min=1, max=1, modifier=false, summary=true) 2213 @Description(shortDefinition="Intended recipient of products and services", formalDefinition="The party who is the beneficiary of the supplied coverage and for whom eligibility is sought." ) 2214 protected Reference patient; 2215 2216 /** 2217 * The date or dates when the enclosed suite of services were performed or completed. 2218 */ 2219 @Child(name = "serviced", type = {DateType.class, Period.class}, order=4, min=0, max=1, modifier=false, summary=false) 2220 @Description(shortDefinition="Estimated date or dates of service", formalDefinition="The date or dates when the enclosed suite of services were performed or completed." ) 2221 protected Type serviced; 2222 2223 /** 2224 * The date this resource was created. 2225 */ 2226 @Child(name = "created", type = {DateTimeType.class}, order=5, min=1, max=1, modifier=false, summary=true) 2227 @Description(shortDefinition="Response creation date", formalDefinition="The date this resource was created." ) 2228 protected DateTimeType created; 2229 2230 /** 2231 * The provider which is responsible for the request. 2232 */ 2233 @Child(name = "requestor", type = {Practitioner.class, PractitionerRole.class, Organization.class}, order=6, min=0, max=1, modifier=false, summary=false) 2234 @Description(shortDefinition="Party responsible for the request", formalDefinition="The provider which is responsible for the request." ) 2235 protected Reference requestor; 2236 2237 /** 2238 * Reference to the original request resource. 2239 */ 2240 @Child(name = "request", type = {CoverageEligibilityRequest.class}, order=7, min=1, max=1, modifier=false, summary=true) 2241 @Description(shortDefinition="Eligibility request reference", formalDefinition="Reference to the original request resource." ) 2242 protected Reference request; 2243 2244 /** 2245 * The outcome of the request processing. 2246 */ 2247 @Child(name = "outcome", type = {CodeType.class}, order=8, min=1, max=1, modifier=false, summary=true) 2248 @Description(shortDefinition="queued | complete | error | partial", formalDefinition="The outcome of the request processing." ) 2249 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/remittance-outcome") 2250 protected Enumeration<RemittanceOutcome> outcome; 2251 2252 /** 2253 * A human readable description of the status of the adjudication. 2254 */ 2255 @Child(name = "disposition", type = {StringType.class}, order=9, min=0, max=1, modifier=false, summary=false) 2256 @Description(shortDefinition="Disposition Message", formalDefinition="A human readable description of the status of the adjudication." ) 2257 protected StringType disposition; 2258 2259 /** 2260 * The Insurer who issued the coverage in question and is the author of the response. 2261 */ 2262 @Child(name = "insurer", type = {Organization.class}, order=10, min=1, max=1, modifier=false, summary=true) 2263 @Description(shortDefinition="Coverage issuer", formalDefinition="The Insurer who issued the coverage in question and is the author of the response." ) 2264 protected Reference insurer; 2265 2266 /** 2267 * Financial instruments for reimbursement for the health care products and services. 2268 */ 2269 @Child(name = "insurance", type = {}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2270 @Description(shortDefinition="Patient insurance information", formalDefinition="Financial instruments for reimbursement for the health care products and services." ) 2271 protected List<InsuranceComponent> insurance; 2272 2273 /** 2274 * A reference from the Insurer to which these services pertain to be used on further communication and as proof that the request occurred. 2275 */ 2276 @Child(name = "preAuthRef", type = {StringType.class}, order=12, min=0, max=1, modifier=false, summary=false) 2277 @Description(shortDefinition="Preauthorization reference", formalDefinition="A reference from the Insurer to which these services pertain to be used on further communication and as proof that the request occurred." ) 2278 protected StringType preAuthRef; 2279 2280 /** 2281 * A code for the form to be used for printing the content. 2282 */ 2283 @Child(name = "form", type = {CodeableConcept.class}, order=13, min=0, max=1, modifier=false, summary=false) 2284 @Description(shortDefinition="Printed form identifier", formalDefinition="A code for the form to be used for printing the content." ) 2285 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/forms") 2286 protected CodeableConcept form; 2287 2288 /** 2289 * Errors encountered during the processing of the request. 2290 */ 2291 @Child(name = "error", type = {}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2292 @Description(shortDefinition="Processing errors", formalDefinition="Errors encountered during the processing of the request." ) 2293 protected List<ErrorsComponent> error; 2294 2295 private static final long serialVersionUID = -1527014784L; 2296 2297 /** 2298 * Constructor 2299 */ 2300 public CoverageEligibilityResponse() { 2301 super(); 2302 } 2303 2304 /** 2305 * Constructor 2306 */ 2307 public CoverageEligibilityResponse(Enumeration<EligibilityResponseStatus> status, Reference patient, DateTimeType created, Reference request, Enumeration<RemittanceOutcome> outcome, Reference insurer) { 2308 super(); 2309 this.status = status; 2310 this.patient = patient; 2311 this.created = created; 2312 this.request = request; 2313 this.outcome = outcome; 2314 this.insurer = insurer; 2315 } 2316 2317 /** 2318 * @return {@link #identifier} (A unique identifier assigned to this coverage eligiblity request.) 2319 */ 2320 public List<Identifier> getIdentifier() { 2321 if (this.identifier == null) 2322 this.identifier = new ArrayList<Identifier>(); 2323 return this.identifier; 2324 } 2325 2326 /** 2327 * @return Returns a reference to <code>this</code> for easy method chaining 2328 */ 2329 public CoverageEligibilityResponse setIdentifier(List<Identifier> theIdentifier) { 2330 this.identifier = theIdentifier; 2331 return this; 2332 } 2333 2334 public boolean hasIdentifier() { 2335 if (this.identifier == null) 2336 return false; 2337 for (Identifier item : this.identifier) 2338 if (!item.isEmpty()) 2339 return true; 2340 return false; 2341 } 2342 2343 public Identifier addIdentifier() { //3 2344 Identifier t = new Identifier(); 2345 if (this.identifier == null) 2346 this.identifier = new ArrayList<Identifier>(); 2347 this.identifier.add(t); 2348 return t; 2349 } 2350 2351 public CoverageEligibilityResponse addIdentifier(Identifier t) { //3 2352 if (t == null) 2353 return this; 2354 if (this.identifier == null) 2355 this.identifier = new ArrayList<Identifier>(); 2356 this.identifier.add(t); 2357 return this; 2358 } 2359 2360 /** 2361 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist 2362 */ 2363 public Identifier getIdentifierFirstRep() { 2364 if (getIdentifier().isEmpty()) { 2365 addIdentifier(); 2366 } 2367 return getIdentifier().get(0); 2368 } 2369 2370 /** 2371 * @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 2372 */ 2373 public Enumeration<EligibilityResponseStatus> getStatusElement() { 2374 if (this.status == null) 2375 if (Configuration.errorOnAutoCreate()) 2376 throw new Error("Attempt to auto-create CoverageEligibilityResponse.status"); 2377 else if (Configuration.doAutoCreate()) 2378 this.status = new Enumeration<EligibilityResponseStatus>(new EligibilityResponseStatusEnumFactory()); // bb 2379 return this.status; 2380 } 2381 2382 public boolean hasStatusElement() { 2383 return this.status != null && !this.status.isEmpty(); 2384 } 2385 2386 public boolean hasStatus() { 2387 return this.status != null && !this.status.isEmpty(); 2388 } 2389 2390 /** 2391 * @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 2392 */ 2393 public CoverageEligibilityResponse setStatusElement(Enumeration<EligibilityResponseStatus> value) { 2394 this.status = value; 2395 return this; 2396 } 2397 2398 /** 2399 * @return The status of the resource instance. 2400 */ 2401 public EligibilityResponseStatus getStatus() { 2402 return this.status == null ? null : this.status.getValue(); 2403 } 2404 2405 /** 2406 * @param value The status of the resource instance. 2407 */ 2408 public CoverageEligibilityResponse setStatus(EligibilityResponseStatus value) { 2409 if (this.status == null) 2410 this.status = new Enumeration<EligibilityResponseStatus>(new EligibilityResponseStatusEnumFactory()); 2411 this.status.setValue(value); 2412 return this; 2413 } 2414 2415 /** 2416 * @return {@link #purpose} (Code to specify whether requesting: prior authorization requirements for some service categories or billing codes; benefits for coverages specified or discovered; discovery and return of coverages for the patient; and/or validation that the specified coverage is in-force at the date/period specified or 'now' if not specified.) 2417 */ 2418 public List<Enumeration<EligibilityResponsePurpose>> getPurpose() { 2419 if (this.purpose == null) 2420 this.purpose = new ArrayList<Enumeration<EligibilityResponsePurpose>>(); 2421 return this.purpose; 2422 } 2423 2424 /** 2425 * @return Returns a reference to <code>this</code> for easy method chaining 2426 */ 2427 public CoverageEligibilityResponse setPurpose(List<Enumeration<EligibilityResponsePurpose>> thePurpose) { 2428 this.purpose = thePurpose; 2429 return this; 2430 } 2431 2432 public boolean hasPurpose() { 2433 if (this.purpose == null) 2434 return false; 2435 for (Enumeration<EligibilityResponsePurpose> item : this.purpose) 2436 if (!item.isEmpty()) 2437 return true; 2438 return false; 2439 } 2440 2441 /** 2442 * @return {@link #purpose} (Code to specify whether requesting: prior authorization requirements for some service categories or billing codes; benefits for coverages specified or discovered; discovery and return of coverages for the patient; and/or validation that the specified coverage is in-force at the date/period specified or 'now' if not specified.) 2443 */ 2444 public Enumeration<EligibilityResponsePurpose> addPurposeElement() {//2 2445 Enumeration<EligibilityResponsePurpose> t = new Enumeration<EligibilityResponsePurpose>(new EligibilityResponsePurposeEnumFactory()); 2446 if (this.purpose == null) 2447 this.purpose = new ArrayList<Enumeration<EligibilityResponsePurpose>>(); 2448 this.purpose.add(t); 2449 return t; 2450 } 2451 2452 /** 2453 * @param value {@link #purpose} (Code to specify whether requesting: prior authorization requirements for some service categories or billing codes; benefits for coverages specified or discovered; discovery and return of coverages for the patient; and/or validation that the specified coverage is in-force at the date/period specified or 'now' if not specified.) 2454 */ 2455 public CoverageEligibilityResponse addPurpose(EligibilityResponsePurpose value) { //1 2456 Enumeration<EligibilityResponsePurpose> t = new Enumeration<EligibilityResponsePurpose>(new EligibilityResponsePurposeEnumFactory()); 2457 t.setValue(value); 2458 if (this.purpose == null) 2459 this.purpose = new ArrayList<Enumeration<EligibilityResponsePurpose>>(); 2460 this.purpose.add(t); 2461 return this; 2462 } 2463 2464 /** 2465 * @param value {@link #purpose} (Code to specify whether requesting: prior authorization requirements for some service categories or billing codes; benefits for coverages specified or discovered; discovery and return of coverages for the patient; and/or validation that the specified coverage is in-force at the date/period specified or 'now' if not specified.) 2466 */ 2467 public boolean hasPurpose(EligibilityResponsePurpose value) { 2468 if (this.purpose == null) 2469 return false; 2470 for (Enumeration<EligibilityResponsePurpose> v : this.purpose) 2471 if (v.getValue().equals(value)) // code 2472 return true; 2473 return false; 2474 } 2475 2476 /** 2477 * @return {@link #patient} (The party who is the beneficiary of the supplied coverage and for whom eligibility is sought.) 2478 */ 2479 public Reference getPatient() { 2480 if (this.patient == null) 2481 if (Configuration.errorOnAutoCreate()) 2482 throw new Error("Attempt to auto-create CoverageEligibilityResponse.patient"); 2483 else if (Configuration.doAutoCreate()) 2484 this.patient = new Reference(); // cc 2485 return this.patient; 2486 } 2487 2488 public boolean hasPatient() { 2489 return this.patient != null && !this.patient.isEmpty(); 2490 } 2491 2492 /** 2493 * @param value {@link #patient} (The party who is the beneficiary of the supplied coverage and for whom eligibility is sought.) 2494 */ 2495 public CoverageEligibilityResponse setPatient(Reference value) { 2496 this.patient = value; 2497 return this; 2498 } 2499 2500 /** 2501 * @return {@link #serviced} (The date or dates when the enclosed suite of services were performed or completed.) 2502 */ 2503 public Type getServiced() { 2504 return this.serviced; 2505 } 2506 2507 /** 2508 * @return {@link #serviced} (The date or dates when the enclosed suite of services were performed or completed.) 2509 */ 2510 public DateType getServicedDateType() throws FHIRException { 2511 if (this.serviced == null) 2512 this.serviced = new DateType(); 2513 if (!(this.serviced instanceof DateType)) 2514 throw new FHIRException("Type mismatch: the type DateType was expected, but "+this.serviced.getClass().getName()+" was encountered"); 2515 return (DateType) this.serviced; 2516 } 2517 2518 public boolean hasServicedDateType() { 2519 return this != null && this.serviced instanceof DateType; 2520 } 2521 2522 /** 2523 * @return {@link #serviced} (The date or dates when the enclosed suite of services were performed or completed.) 2524 */ 2525 public Period getServicedPeriod() throws FHIRException { 2526 if (this.serviced == null) 2527 this.serviced = new Period(); 2528 if (!(this.serviced instanceof Period)) 2529 throw new FHIRException("Type mismatch: the type Period was expected, but "+this.serviced.getClass().getName()+" was encountered"); 2530 return (Period) this.serviced; 2531 } 2532 2533 public boolean hasServicedPeriod() { 2534 return this != null && this.serviced instanceof Period; 2535 } 2536 2537 public boolean hasServiced() { 2538 return this.serviced != null && !this.serviced.isEmpty(); 2539 } 2540 2541 /** 2542 * @param value {@link #serviced} (The date or dates when the enclosed suite of services were performed or completed.) 2543 */ 2544 public CoverageEligibilityResponse setServiced(Type value) { 2545 if (value != null && !(value instanceof DateType || value instanceof Period)) 2546 throw new Error("Not the right type for CoverageEligibilityResponse.serviced[x]: "+value.fhirType()); 2547 this.serviced = value; 2548 return this; 2549 } 2550 2551 /** 2552 * @return {@link #created} (The date this resource was created.). This is the underlying object with id, value and extensions. The accessor "getCreated" gives direct access to the value 2553 */ 2554 public DateTimeType getCreatedElement() { 2555 if (this.created == null) 2556 if (Configuration.errorOnAutoCreate()) 2557 throw new Error("Attempt to auto-create CoverageEligibilityResponse.created"); 2558 else if (Configuration.doAutoCreate()) 2559 this.created = new DateTimeType(); // bb 2560 return this.created; 2561 } 2562 2563 public boolean hasCreatedElement() { 2564 return this.created != null && !this.created.isEmpty(); 2565 } 2566 2567 public boolean hasCreated() { 2568 return this.created != null && !this.created.isEmpty(); 2569 } 2570 2571 /** 2572 * @param value {@link #created} (The date this resource was created.). This is the underlying object with id, value and extensions. The accessor "getCreated" gives direct access to the value 2573 */ 2574 public CoverageEligibilityResponse setCreatedElement(DateTimeType value) { 2575 this.created = value; 2576 return this; 2577 } 2578 2579 /** 2580 * @return The date this resource was created. 2581 */ 2582 public Date getCreated() { 2583 return this.created == null ? null : this.created.getValue(); 2584 } 2585 2586 /** 2587 * @param value The date this resource was created. 2588 */ 2589 public CoverageEligibilityResponse setCreated(Date value) { 2590 if (this.created == null) 2591 this.created = new DateTimeType(); 2592 this.created.setValue(value); 2593 return this; 2594 } 2595 2596 /** 2597 * @return {@link #requestor} (The provider which is responsible for the request.) 2598 */ 2599 public Reference getRequestor() { 2600 if (this.requestor == null) 2601 if (Configuration.errorOnAutoCreate()) 2602 throw new Error("Attempt to auto-create CoverageEligibilityResponse.requestor"); 2603 else if (Configuration.doAutoCreate()) 2604 this.requestor = new Reference(); // cc 2605 return this.requestor; 2606 } 2607 2608 public boolean hasRequestor() { 2609 return this.requestor != null && !this.requestor.isEmpty(); 2610 } 2611 2612 /** 2613 * @param value {@link #requestor} (The provider which is responsible for the request.) 2614 */ 2615 public CoverageEligibilityResponse setRequestor(Reference value) { 2616 this.requestor = value; 2617 return this; 2618 } 2619 2620 /** 2621 * @return {@link #request} (Reference to the original request resource.) 2622 */ 2623 public Reference getRequest() { 2624 if (this.request == null) 2625 if (Configuration.errorOnAutoCreate()) 2626 throw new Error("Attempt to auto-create CoverageEligibilityResponse.request"); 2627 else if (Configuration.doAutoCreate()) 2628 this.request = new Reference(); // cc 2629 return this.request; 2630 } 2631 2632 public boolean hasRequest() { 2633 return this.request != null && !this.request.isEmpty(); 2634 } 2635 2636 /** 2637 * @param value {@link #request} (Reference to the original request resource.) 2638 */ 2639 public CoverageEligibilityResponse setRequest(Reference value) { 2640 this.request = value; 2641 return this; 2642 } 2643 2644 /** 2645 * @return {@link #outcome} (The outcome of the request processing.). This is the underlying object with id, value and extensions. The accessor "getOutcome" gives direct access to the value 2646 */ 2647 public Enumeration<RemittanceOutcome> getOutcomeElement() { 2648 if (this.outcome == null) 2649 if (Configuration.errorOnAutoCreate()) 2650 throw new Error("Attempt to auto-create CoverageEligibilityResponse.outcome"); 2651 else if (Configuration.doAutoCreate()) 2652 this.outcome = new Enumeration<RemittanceOutcome>(new RemittanceOutcomeEnumFactory()); // bb 2653 return this.outcome; 2654 } 2655 2656 public boolean hasOutcomeElement() { 2657 return this.outcome != null && !this.outcome.isEmpty(); 2658 } 2659 2660 public boolean hasOutcome() { 2661 return this.outcome != null && !this.outcome.isEmpty(); 2662 } 2663 2664 /** 2665 * @param value {@link #outcome} (The outcome of the request processing.). This is the underlying object with id, value and extensions. The accessor "getOutcome" gives direct access to the value 2666 */ 2667 public CoverageEligibilityResponse setOutcomeElement(Enumeration<RemittanceOutcome> value) { 2668 this.outcome = value; 2669 return this; 2670 } 2671 2672 /** 2673 * @return The outcome of the request processing. 2674 */ 2675 public RemittanceOutcome getOutcome() { 2676 return this.outcome == null ? null : this.outcome.getValue(); 2677 } 2678 2679 /** 2680 * @param value The outcome of the request processing. 2681 */ 2682 public CoverageEligibilityResponse setOutcome(RemittanceOutcome value) { 2683 if (this.outcome == null) 2684 this.outcome = new Enumeration<RemittanceOutcome>(new RemittanceOutcomeEnumFactory()); 2685 this.outcome.setValue(value); 2686 return this; 2687 } 2688 2689 /** 2690 * @return {@link #disposition} (A human readable description of the status of the adjudication.). This is the underlying object with id, value and extensions. The accessor "getDisposition" gives direct access to the value 2691 */ 2692 public StringType getDispositionElement() { 2693 if (this.disposition == null) 2694 if (Configuration.errorOnAutoCreate()) 2695 throw new Error("Attempt to auto-create CoverageEligibilityResponse.disposition"); 2696 else if (Configuration.doAutoCreate()) 2697 this.disposition = new StringType(); // bb 2698 return this.disposition; 2699 } 2700 2701 public boolean hasDispositionElement() { 2702 return this.disposition != null && !this.disposition.isEmpty(); 2703 } 2704 2705 public boolean hasDisposition() { 2706 return this.disposition != null && !this.disposition.isEmpty(); 2707 } 2708 2709 /** 2710 * @param value {@link #disposition} (A human readable description of the status of the adjudication.). This is the underlying object with id, value and extensions. The accessor "getDisposition" gives direct access to the value 2711 */ 2712 public CoverageEligibilityResponse setDispositionElement(StringType value) { 2713 this.disposition = value; 2714 return this; 2715 } 2716 2717 /** 2718 * @return A human readable description of the status of the adjudication. 2719 */ 2720 public String getDisposition() { 2721 return this.disposition == null ? null : this.disposition.getValue(); 2722 } 2723 2724 /** 2725 * @param value A human readable description of the status of the adjudication. 2726 */ 2727 public CoverageEligibilityResponse setDisposition(String value) { 2728 if (Utilities.noString(value)) 2729 this.disposition = null; 2730 else { 2731 if (this.disposition == null) 2732 this.disposition = new StringType(); 2733 this.disposition.setValue(value); 2734 } 2735 return this; 2736 } 2737 2738 /** 2739 * @return {@link #insurer} (The Insurer who issued the coverage in question and is the author of the response.) 2740 */ 2741 public Reference getInsurer() { 2742 if (this.insurer == null) 2743 if (Configuration.errorOnAutoCreate()) 2744 throw new Error("Attempt to auto-create CoverageEligibilityResponse.insurer"); 2745 else if (Configuration.doAutoCreate()) 2746 this.insurer = new Reference(); // cc 2747 return this.insurer; 2748 } 2749 2750 public boolean hasInsurer() { 2751 return this.insurer != null && !this.insurer.isEmpty(); 2752 } 2753 2754 /** 2755 * @param value {@link #insurer} (The Insurer who issued the coverage in question and is the author of the response.) 2756 */ 2757 public CoverageEligibilityResponse setInsurer(Reference value) { 2758 this.insurer = value; 2759 return this; 2760 } 2761 2762 /** 2763 * @return {@link #insurance} (Financial instruments for reimbursement for the health care products and services.) 2764 */ 2765 public List<InsuranceComponent> getInsurance() { 2766 if (this.insurance == null) 2767 this.insurance = new ArrayList<InsuranceComponent>(); 2768 return this.insurance; 2769 } 2770 2771 /** 2772 * @return Returns a reference to <code>this</code> for easy method chaining 2773 */ 2774 public CoverageEligibilityResponse setInsurance(List<InsuranceComponent> theInsurance) { 2775 this.insurance = theInsurance; 2776 return this; 2777 } 2778 2779 public boolean hasInsurance() { 2780 if (this.insurance == null) 2781 return false; 2782 for (InsuranceComponent item : this.insurance) 2783 if (!item.isEmpty()) 2784 return true; 2785 return false; 2786 } 2787 2788 public InsuranceComponent addInsurance() { //3 2789 InsuranceComponent t = new InsuranceComponent(); 2790 if (this.insurance == null) 2791 this.insurance = new ArrayList<InsuranceComponent>(); 2792 this.insurance.add(t); 2793 return t; 2794 } 2795 2796 public CoverageEligibilityResponse addInsurance(InsuranceComponent t) { //3 2797 if (t == null) 2798 return this; 2799 if (this.insurance == null) 2800 this.insurance = new ArrayList<InsuranceComponent>(); 2801 this.insurance.add(t); 2802 return this; 2803 } 2804 2805 /** 2806 * @return The first repetition of repeating field {@link #insurance}, creating it if it does not already exist 2807 */ 2808 public InsuranceComponent getInsuranceFirstRep() { 2809 if (getInsurance().isEmpty()) { 2810 addInsurance(); 2811 } 2812 return getInsurance().get(0); 2813 } 2814 2815 /** 2816 * @return {@link #preAuthRef} (A reference from the Insurer to which these services pertain to be used on further communication and as proof that the request occurred.). This is the underlying object with id, value and extensions. The accessor "getPreAuthRef" gives direct access to the value 2817 */ 2818 public StringType getPreAuthRefElement() { 2819 if (this.preAuthRef == null) 2820 if (Configuration.errorOnAutoCreate()) 2821 throw new Error("Attempt to auto-create CoverageEligibilityResponse.preAuthRef"); 2822 else if (Configuration.doAutoCreate()) 2823 this.preAuthRef = new StringType(); // bb 2824 return this.preAuthRef; 2825 } 2826 2827 public boolean hasPreAuthRefElement() { 2828 return this.preAuthRef != null && !this.preAuthRef.isEmpty(); 2829 } 2830 2831 public boolean hasPreAuthRef() { 2832 return this.preAuthRef != null && !this.preAuthRef.isEmpty(); 2833 } 2834 2835 /** 2836 * @param value {@link #preAuthRef} (A reference from the Insurer to which these services pertain to be used on further communication and as proof that the request occurred.). This is the underlying object with id, value and extensions. The accessor "getPreAuthRef" gives direct access to the value 2837 */ 2838 public CoverageEligibilityResponse setPreAuthRefElement(StringType value) { 2839 this.preAuthRef = value; 2840 return this; 2841 } 2842 2843 /** 2844 * @return A reference from the Insurer to which these services pertain to be used on further communication and as proof that the request occurred. 2845 */ 2846 public String getPreAuthRef() { 2847 return this.preAuthRef == null ? null : this.preAuthRef.getValue(); 2848 } 2849 2850 /** 2851 * @param value A reference from the Insurer to which these services pertain to be used on further communication and as proof that the request occurred. 2852 */ 2853 public CoverageEligibilityResponse setPreAuthRef(String value) { 2854 if (Utilities.noString(value)) 2855 this.preAuthRef = null; 2856 else { 2857 if (this.preAuthRef == null) 2858 this.preAuthRef = new StringType(); 2859 this.preAuthRef.setValue(value); 2860 } 2861 return this; 2862 } 2863 2864 /** 2865 * @return {@link #form} (A code for the form to be used for printing the content.) 2866 */ 2867 public CodeableConcept getForm() { 2868 if (this.form == null) 2869 if (Configuration.errorOnAutoCreate()) 2870 throw new Error("Attempt to auto-create CoverageEligibilityResponse.form"); 2871 else if (Configuration.doAutoCreate()) 2872 this.form = new CodeableConcept(); // cc 2873 return this.form; 2874 } 2875 2876 public boolean hasForm() { 2877 return this.form != null && !this.form.isEmpty(); 2878 } 2879 2880 /** 2881 * @param value {@link #form} (A code for the form to be used for printing the content.) 2882 */ 2883 public CoverageEligibilityResponse setForm(CodeableConcept value) { 2884 this.form = value; 2885 return this; 2886 } 2887 2888 /** 2889 * @return {@link #error} (Errors encountered during the processing of the request.) 2890 */ 2891 public List<ErrorsComponent> getError() { 2892 if (this.error == null) 2893 this.error = new ArrayList<ErrorsComponent>(); 2894 return this.error; 2895 } 2896 2897 /** 2898 * @return Returns a reference to <code>this</code> for easy method chaining 2899 */ 2900 public CoverageEligibilityResponse setError(List<ErrorsComponent> theError) { 2901 this.error = theError; 2902 return this; 2903 } 2904 2905 public boolean hasError() { 2906 if (this.error == null) 2907 return false; 2908 for (ErrorsComponent item : this.error) 2909 if (!item.isEmpty()) 2910 return true; 2911 return false; 2912 } 2913 2914 public ErrorsComponent addError() { //3 2915 ErrorsComponent t = new ErrorsComponent(); 2916 if (this.error == null) 2917 this.error = new ArrayList<ErrorsComponent>(); 2918 this.error.add(t); 2919 return t; 2920 } 2921 2922 public CoverageEligibilityResponse addError(ErrorsComponent t) { //3 2923 if (t == null) 2924 return this; 2925 if (this.error == null) 2926 this.error = new ArrayList<ErrorsComponent>(); 2927 this.error.add(t); 2928 return this; 2929 } 2930 2931 /** 2932 * @return The first repetition of repeating field {@link #error}, creating it if it does not already exist 2933 */ 2934 public ErrorsComponent getErrorFirstRep() { 2935 if (getError().isEmpty()) { 2936 addError(); 2937 } 2938 return getError().get(0); 2939 } 2940 2941 protected void listChildren(List<Property> children) { 2942 super.listChildren(children); 2943 children.add(new Property("identifier", "Identifier", "A unique identifier assigned to this coverage eligiblity request.", 0, java.lang.Integer.MAX_VALUE, identifier)); 2944 children.add(new Property("status", "code", "The status of the resource instance.", 0, 1, status)); 2945 children.add(new Property("purpose", "code", "Code to specify whether requesting: prior authorization requirements for some service categories or billing codes; benefits for coverages specified or discovered; discovery and return of coverages for the patient; and/or validation that the specified coverage is in-force at the date/period specified or 'now' if not specified.", 0, java.lang.Integer.MAX_VALUE, purpose)); 2946 children.add(new Property("patient", "Reference(Patient)", "The party who is the beneficiary of the supplied coverage and for whom eligibility is sought.", 0, 1, patient)); 2947 children.add(new Property("serviced[x]", "date|Period", "The date or dates when the enclosed suite of services were performed or completed.", 0, 1, serviced)); 2948 children.add(new Property("created", "dateTime", "The date this resource was created.", 0, 1, created)); 2949 children.add(new Property("requestor", "Reference(Practitioner|PractitionerRole|Organization)", "The provider which is responsible for the request.", 0, 1, requestor)); 2950 children.add(new Property("request", "Reference(CoverageEligibilityRequest)", "Reference to the original request resource.", 0, 1, request)); 2951 children.add(new Property("outcome", "code", "The outcome of the request processing.", 0, 1, outcome)); 2952 children.add(new Property("disposition", "string", "A human readable description of the status of the adjudication.", 0, 1, disposition)); 2953 children.add(new Property("insurer", "Reference(Organization)", "The Insurer who issued the coverage in question and is the author of the response.", 0, 1, insurer)); 2954 children.add(new Property("insurance", "", "Financial instruments for reimbursement for the health care products and services.", 0, java.lang.Integer.MAX_VALUE, insurance)); 2955 children.add(new Property("preAuthRef", "string", "A reference from the Insurer to which these services pertain to be used on further communication and as proof that the request occurred.", 0, 1, preAuthRef)); 2956 children.add(new Property("form", "CodeableConcept", "A code for the form to be used for printing the content.", 0, 1, form)); 2957 children.add(new Property("error", "", "Errors encountered during the processing of the request.", 0, java.lang.Integer.MAX_VALUE, error)); 2958 } 2959 2960 @Override 2961 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2962 switch (_hash) { 2963 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "A unique identifier assigned to this coverage eligiblity request.", 0, java.lang.Integer.MAX_VALUE, identifier); 2964 case -892481550: /*status*/ return new Property("status", "code", "The status of the resource instance.", 0, 1, status); 2965 case -220463842: /*purpose*/ return new Property("purpose", "code", "Code to specify whether requesting: prior authorization requirements for some service categories or billing codes; benefits for coverages specified or discovered; discovery and return of coverages for the patient; and/or validation that the specified coverage is in-force at the date/period specified or 'now' if not specified.", 0, java.lang.Integer.MAX_VALUE, purpose); 2966 case -791418107: /*patient*/ return new Property("patient", "Reference(Patient)", "The party who is the beneficiary of the supplied coverage and for whom eligibility is sought.", 0, 1, patient); 2967 case -1927922223: /*serviced[x]*/ return new Property("serviced[x]", "date|Period", "The date or dates when the enclosed suite of services were performed or completed.", 0, 1, serviced); 2968 case 1379209295: /*serviced*/ return new Property("serviced[x]", "date|Period", "The date or dates when the enclosed suite of services were performed or completed.", 0, 1, serviced); 2969 case 363246749: /*servicedDate*/ return new Property("serviced[x]", "date|Period", "The date or dates when the enclosed suite of services were performed or completed.", 0, 1, serviced); 2970 case 1534966512: /*servicedPeriod*/ return new Property("serviced[x]", "date|Period", "The date or dates when the enclosed suite of services were performed or completed.", 0, 1, serviced); 2971 case 1028554472: /*created*/ return new Property("created", "dateTime", "The date this resource was created.", 0, 1, created); 2972 case 693934258: /*requestor*/ return new Property("requestor", "Reference(Practitioner|PractitionerRole|Organization)", "The provider which is responsible for the request.", 0, 1, requestor); 2973 case 1095692943: /*request*/ return new Property("request", "Reference(CoverageEligibilityRequest)", "Reference to the original request resource.", 0, 1, request); 2974 case -1106507950: /*outcome*/ return new Property("outcome", "code", "The outcome of the request processing.", 0, 1, outcome); 2975 case 583380919: /*disposition*/ return new Property("disposition", "string", "A human readable description of the status of the adjudication.", 0, 1, disposition); 2976 case 1957615864: /*insurer*/ return new Property("insurer", "Reference(Organization)", "The Insurer who issued the coverage in question and is the author of the response.", 0, 1, insurer); 2977 case 73049818: /*insurance*/ return new Property("insurance", "", "Financial instruments for reimbursement for the health care products and services.", 0, java.lang.Integer.MAX_VALUE, insurance); 2978 case 522246568: /*preAuthRef*/ return new Property("preAuthRef", "string", "A reference from the Insurer to which these services pertain to be used on further communication and as proof that the request occurred.", 0, 1, preAuthRef); 2979 case 3148996: /*form*/ return new Property("form", "CodeableConcept", "A code for the form to be used for printing the content.", 0, 1, form); 2980 case 96784904: /*error*/ return new Property("error", "", "Errors encountered during the processing of the request.", 0, java.lang.Integer.MAX_VALUE, error); 2981 default: return super.getNamedProperty(_hash, _name, _checkValid); 2982 } 2983 2984 } 2985 2986 @Override 2987 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2988 switch (hash) { 2989 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 2990 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<EligibilityResponseStatus> 2991 case -220463842: /*purpose*/ return this.purpose == null ? new Base[0] : this.purpose.toArray(new Base[this.purpose.size()]); // Enumeration<EligibilityResponsePurpose> 2992 case -791418107: /*patient*/ return this.patient == null ? new Base[0] : new Base[] {this.patient}; // Reference 2993 case 1379209295: /*serviced*/ return this.serviced == null ? new Base[0] : new Base[] {this.serviced}; // Type 2994 case 1028554472: /*created*/ return this.created == null ? new Base[0] : new Base[] {this.created}; // DateTimeType 2995 case 693934258: /*requestor*/ return this.requestor == null ? new Base[0] : new Base[] {this.requestor}; // Reference 2996 case 1095692943: /*request*/ return this.request == null ? new Base[0] : new Base[] {this.request}; // Reference 2997 case -1106507950: /*outcome*/ return this.outcome == null ? new Base[0] : new Base[] {this.outcome}; // Enumeration<RemittanceOutcome> 2998 case 583380919: /*disposition*/ return this.disposition == null ? new Base[0] : new Base[] {this.disposition}; // StringType 2999 case 1957615864: /*insurer*/ return this.insurer == null ? new Base[0] : new Base[] {this.insurer}; // Reference 3000 case 73049818: /*insurance*/ return this.insurance == null ? new Base[0] : this.insurance.toArray(new Base[this.insurance.size()]); // InsuranceComponent 3001 case 522246568: /*preAuthRef*/ return this.preAuthRef == null ? new Base[0] : new Base[] {this.preAuthRef}; // StringType 3002 case 3148996: /*form*/ return this.form == null ? new Base[0] : new Base[] {this.form}; // CodeableConcept 3003 case 96784904: /*error*/ return this.error == null ? new Base[0] : this.error.toArray(new Base[this.error.size()]); // ErrorsComponent 3004 default: return super.getProperty(hash, name, checkValid); 3005 } 3006 3007 } 3008 3009 @Override 3010 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3011 switch (hash) { 3012 case -1618432855: // identifier 3013 this.getIdentifier().add(castToIdentifier(value)); // Identifier 3014 return value; 3015 case -892481550: // status 3016 value = new EligibilityResponseStatusEnumFactory().fromType(castToCode(value)); 3017 this.status = (Enumeration) value; // Enumeration<EligibilityResponseStatus> 3018 return value; 3019 case -220463842: // purpose 3020 value = new EligibilityResponsePurposeEnumFactory().fromType(castToCode(value)); 3021 this.getPurpose().add((Enumeration) value); // Enumeration<EligibilityResponsePurpose> 3022 return value; 3023 case -791418107: // patient 3024 this.patient = castToReference(value); // Reference 3025 return value; 3026 case 1379209295: // serviced 3027 this.serviced = castToType(value); // Type 3028 return value; 3029 case 1028554472: // created 3030 this.created = castToDateTime(value); // DateTimeType 3031 return value; 3032 case 693934258: // requestor 3033 this.requestor = castToReference(value); // Reference 3034 return value; 3035 case 1095692943: // request 3036 this.request = castToReference(value); // Reference 3037 return value; 3038 case -1106507950: // outcome 3039 value = new RemittanceOutcomeEnumFactory().fromType(castToCode(value)); 3040 this.outcome = (Enumeration) value; // Enumeration<RemittanceOutcome> 3041 return value; 3042 case 583380919: // disposition 3043 this.disposition = castToString(value); // StringType 3044 return value; 3045 case 1957615864: // insurer 3046 this.insurer = castToReference(value); // Reference 3047 return value; 3048 case 73049818: // insurance 3049 this.getInsurance().add((InsuranceComponent) value); // InsuranceComponent 3050 return value; 3051 case 522246568: // preAuthRef 3052 this.preAuthRef = castToString(value); // StringType 3053 return value; 3054 case 3148996: // form 3055 this.form = castToCodeableConcept(value); // CodeableConcept 3056 return value; 3057 case 96784904: // error 3058 this.getError().add((ErrorsComponent) value); // ErrorsComponent 3059 return value; 3060 default: return super.setProperty(hash, name, value); 3061 } 3062 3063 } 3064 3065 @Override 3066 public Base setProperty(String name, Base value) throws FHIRException { 3067 if (name.equals("identifier")) { 3068 this.getIdentifier().add(castToIdentifier(value)); 3069 } else if (name.equals("status")) { 3070 value = new EligibilityResponseStatusEnumFactory().fromType(castToCode(value)); 3071 this.status = (Enumeration) value; // Enumeration<EligibilityResponseStatus> 3072 } else if (name.equals("purpose")) { 3073 value = new EligibilityResponsePurposeEnumFactory().fromType(castToCode(value)); 3074 this.getPurpose().add((Enumeration) value); 3075 } else if (name.equals("patient")) { 3076 this.patient = castToReference(value); // Reference 3077 } else if (name.equals("serviced[x]")) { 3078 this.serviced = castToType(value); // Type 3079 } else if (name.equals("created")) { 3080 this.created = castToDateTime(value); // DateTimeType 3081 } else if (name.equals("requestor")) { 3082 this.requestor = castToReference(value); // Reference 3083 } else if (name.equals("request")) { 3084 this.request = castToReference(value); // Reference 3085 } else if (name.equals("outcome")) { 3086 value = new RemittanceOutcomeEnumFactory().fromType(castToCode(value)); 3087 this.outcome = (Enumeration) value; // Enumeration<RemittanceOutcome> 3088 } else if (name.equals("disposition")) { 3089 this.disposition = castToString(value); // StringType 3090 } else if (name.equals("insurer")) { 3091 this.insurer = castToReference(value); // Reference 3092 } else if (name.equals("insurance")) { 3093 this.getInsurance().add((InsuranceComponent) value); 3094 } else if (name.equals("preAuthRef")) { 3095 this.preAuthRef = castToString(value); // StringType 3096 } else if (name.equals("form")) { 3097 this.form = castToCodeableConcept(value); // CodeableConcept 3098 } else if (name.equals("error")) { 3099 this.getError().add((ErrorsComponent) value); 3100 } else 3101 return super.setProperty(name, value); 3102 return value; 3103 } 3104 3105 @Override 3106 public Base makeProperty(int hash, String name) throws FHIRException { 3107 switch (hash) { 3108 case -1618432855: return addIdentifier(); 3109 case -892481550: return getStatusElement(); 3110 case -220463842: return addPurposeElement(); 3111 case -791418107: return getPatient(); 3112 case -1927922223: return getServiced(); 3113 case 1379209295: return getServiced(); 3114 case 1028554472: return getCreatedElement(); 3115 case 693934258: return getRequestor(); 3116 case 1095692943: return getRequest(); 3117 case -1106507950: return getOutcomeElement(); 3118 case 583380919: return getDispositionElement(); 3119 case 1957615864: return getInsurer(); 3120 case 73049818: return addInsurance(); 3121 case 522246568: return getPreAuthRefElement(); 3122 case 3148996: return getForm(); 3123 case 96784904: return addError(); 3124 default: return super.makeProperty(hash, name); 3125 } 3126 3127 } 3128 3129 @Override 3130 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 3131 switch (hash) { 3132 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 3133 case -892481550: /*status*/ return new String[] {"code"}; 3134 case -220463842: /*purpose*/ return new String[] {"code"}; 3135 case -791418107: /*patient*/ return new String[] {"Reference"}; 3136 case 1379209295: /*serviced*/ return new String[] {"date", "Period"}; 3137 case 1028554472: /*created*/ return new String[] {"dateTime"}; 3138 case 693934258: /*requestor*/ return new String[] {"Reference"}; 3139 case 1095692943: /*request*/ return new String[] {"Reference"}; 3140 case -1106507950: /*outcome*/ return new String[] {"code"}; 3141 case 583380919: /*disposition*/ return new String[] {"string"}; 3142 case 1957615864: /*insurer*/ return new String[] {"Reference"}; 3143 case 73049818: /*insurance*/ return new String[] {}; 3144 case 522246568: /*preAuthRef*/ return new String[] {"string"}; 3145 case 3148996: /*form*/ return new String[] {"CodeableConcept"}; 3146 case 96784904: /*error*/ return new String[] {}; 3147 default: return super.getTypesForProperty(hash, name); 3148 } 3149 3150 } 3151 3152 @Override 3153 public Base addChild(String name) throws FHIRException { 3154 if (name.equals("identifier")) { 3155 return addIdentifier(); 3156 } 3157 else if (name.equals("status")) { 3158 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.status"); 3159 } 3160 else if (name.equals("purpose")) { 3161 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.purpose"); 3162 } 3163 else if (name.equals("patient")) { 3164 this.patient = new Reference(); 3165 return this.patient; 3166 } 3167 else if (name.equals("servicedDate")) { 3168 this.serviced = new DateType(); 3169 return this.serviced; 3170 } 3171 else if (name.equals("servicedPeriod")) { 3172 this.serviced = new Period(); 3173 return this.serviced; 3174 } 3175 else if (name.equals("created")) { 3176 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.created"); 3177 } 3178 else if (name.equals("requestor")) { 3179 this.requestor = new Reference(); 3180 return this.requestor; 3181 } 3182 else if (name.equals("request")) { 3183 this.request = new Reference(); 3184 return this.request; 3185 } 3186 else if (name.equals("outcome")) { 3187 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.outcome"); 3188 } 3189 else if (name.equals("disposition")) { 3190 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.disposition"); 3191 } 3192 else if (name.equals("insurer")) { 3193 this.insurer = new Reference(); 3194 return this.insurer; 3195 } 3196 else if (name.equals("insurance")) { 3197 return addInsurance(); 3198 } 3199 else if (name.equals("preAuthRef")) { 3200 throw new FHIRException("Cannot call addChild on a primitive type CoverageEligibilityResponse.preAuthRef"); 3201 } 3202 else if (name.equals("form")) { 3203 this.form = new CodeableConcept(); 3204 return this.form; 3205 } 3206 else if (name.equals("error")) { 3207 return addError(); 3208 } 3209 else 3210 return super.addChild(name); 3211 } 3212 3213 public String fhirType() { 3214 return "CoverageEligibilityResponse"; 3215 3216 } 3217 3218 public CoverageEligibilityResponse copy() { 3219 CoverageEligibilityResponse dst = new CoverageEligibilityResponse(); 3220 copyValues(dst); 3221 return dst; 3222 } 3223 3224 public void copyValues(CoverageEligibilityResponse dst) { 3225 super.copyValues(dst); 3226 if (identifier != null) { 3227 dst.identifier = new ArrayList<Identifier>(); 3228 for (Identifier i : identifier) 3229 dst.identifier.add(i.copy()); 3230 }; 3231 dst.status = status == null ? null : status.copy(); 3232 if (purpose != null) { 3233 dst.purpose = new ArrayList<Enumeration<EligibilityResponsePurpose>>(); 3234 for (Enumeration<EligibilityResponsePurpose> i : purpose) 3235 dst.purpose.add(i.copy()); 3236 }; 3237 dst.patient = patient == null ? null : patient.copy(); 3238 dst.serviced = serviced == null ? null : serviced.copy(); 3239 dst.created = created == null ? null : created.copy(); 3240 dst.requestor = requestor == null ? null : requestor.copy(); 3241 dst.request = request == null ? null : request.copy(); 3242 dst.outcome = outcome == null ? null : outcome.copy(); 3243 dst.disposition = disposition == null ? null : disposition.copy(); 3244 dst.insurer = insurer == null ? null : insurer.copy(); 3245 if (insurance != null) { 3246 dst.insurance = new ArrayList<InsuranceComponent>(); 3247 for (InsuranceComponent i : insurance) 3248 dst.insurance.add(i.copy()); 3249 }; 3250 dst.preAuthRef = preAuthRef == null ? null : preAuthRef.copy(); 3251 dst.form = form == null ? null : form.copy(); 3252 if (error != null) { 3253 dst.error = new ArrayList<ErrorsComponent>(); 3254 for (ErrorsComponent i : error) 3255 dst.error.add(i.copy()); 3256 }; 3257 } 3258 3259 protected CoverageEligibilityResponse typedCopy() { 3260 return copy(); 3261 } 3262 3263 @Override 3264 public boolean equalsDeep(Base other_) { 3265 if (!super.equalsDeep(other_)) 3266 return false; 3267 if (!(other_ instanceof CoverageEligibilityResponse)) 3268 return false; 3269 CoverageEligibilityResponse o = (CoverageEligibilityResponse) other_; 3270 return compareDeep(identifier, o.identifier, true) && compareDeep(status, o.status, true) && compareDeep(purpose, o.purpose, true) 3271 && compareDeep(patient, o.patient, true) && compareDeep(serviced, o.serviced, true) && compareDeep(created, o.created, true) 3272 && compareDeep(requestor, o.requestor, true) && compareDeep(request, o.request, true) && compareDeep(outcome, o.outcome, true) 3273 && compareDeep(disposition, o.disposition, true) && compareDeep(insurer, o.insurer, true) && compareDeep(insurance, o.insurance, true) 3274 && compareDeep(preAuthRef, o.preAuthRef, true) && compareDeep(form, o.form, true) && compareDeep(error, o.error, true) 3275 ; 3276 } 3277 3278 @Override 3279 public boolean equalsShallow(Base other_) { 3280 if (!super.equalsShallow(other_)) 3281 return false; 3282 if (!(other_ instanceof CoverageEligibilityResponse)) 3283 return false; 3284 CoverageEligibilityResponse o = (CoverageEligibilityResponse) other_; 3285 return compareValues(status, o.status, true) && compareValues(purpose, o.purpose, true) && compareValues(created, o.created, true) 3286 && compareValues(outcome, o.outcome, true) && compareValues(disposition, o.disposition, true) && compareValues(preAuthRef, o.preAuthRef, true) 3287 ; 3288 } 3289 3290 public boolean isEmpty() { 3291 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, status, purpose 3292 , patient, serviced, created, requestor, request, outcome, disposition, insurer 3293 , insurance, preAuthRef, form, error); 3294 } 3295 3296 @Override 3297 public ResourceType getResourceType() { 3298 return ResourceType.CoverageEligibilityResponse; 3299 } 3300 3301 /** 3302 * Search parameter: <b>identifier</b> 3303 * <p> 3304 * Description: <b>The business identifier</b><br> 3305 * Type: <b>token</b><br> 3306 * Path: <b>CoverageEligibilityResponse.identifier</b><br> 3307 * </p> 3308 */ 3309 @SearchParamDefinition(name="identifier", path="CoverageEligibilityResponse.identifier", description="The business identifier", type="token" ) 3310 public static final String SP_IDENTIFIER = "identifier"; 3311 /** 3312 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 3313 * <p> 3314 * Description: <b>The business identifier</b><br> 3315 * Type: <b>token</b><br> 3316 * Path: <b>CoverageEligibilityResponse.identifier</b><br> 3317 * </p> 3318 */ 3319 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 3320 3321 /** 3322 * Search parameter: <b>request</b> 3323 * <p> 3324 * Description: <b>The EligibilityRequest reference</b><br> 3325 * Type: <b>reference</b><br> 3326 * Path: <b>CoverageEligibilityResponse.request</b><br> 3327 * </p> 3328 */ 3329 @SearchParamDefinition(name="request", path="CoverageEligibilityResponse.request", description="The EligibilityRequest reference", type="reference", target={CoverageEligibilityRequest.class } ) 3330 public static final String SP_REQUEST = "request"; 3331 /** 3332 * <b>Fluent Client</b> search parameter constant for <b>request</b> 3333 * <p> 3334 * Description: <b>The EligibilityRequest reference</b><br> 3335 * Type: <b>reference</b><br> 3336 * Path: <b>CoverageEligibilityResponse.request</b><br> 3337 * </p> 3338 */ 3339 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam REQUEST = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_REQUEST); 3340 3341/** 3342 * Constant for fluent queries to be used to add include statements. Specifies 3343 * the path value of "<b>CoverageEligibilityResponse:request</b>". 3344 */ 3345 public static final ca.uhn.fhir.model.api.Include INCLUDE_REQUEST = new ca.uhn.fhir.model.api.Include("CoverageEligibilityResponse:request").toLocked(); 3346 3347 /** 3348 * Search parameter: <b>disposition</b> 3349 * <p> 3350 * Description: <b>The contents of the disposition message</b><br> 3351 * Type: <b>string</b><br> 3352 * Path: <b>CoverageEligibilityResponse.disposition</b><br> 3353 * </p> 3354 */ 3355 @SearchParamDefinition(name="disposition", path="CoverageEligibilityResponse.disposition", description="The contents of the disposition message", type="string" ) 3356 public static final String SP_DISPOSITION = "disposition"; 3357 /** 3358 * <b>Fluent Client</b> search parameter constant for <b>disposition</b> 3359 * <p> 3360 * Description: <b>The contents of the disposition message</b><br> 3361 * Type: <b>string</b><br> 3362 * Path: <b>CoverageEligibilityResponse.disposition</b><br> 3363 * </p> 3364 */ 3365 public static final ca.uhn.fhir.rest.gclient.StringClientParam DISPOSITION = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_DISPOSITION); 3366 3367 /** 3368 * Search parameter: <b>patient</b> 3369 * <p> 3370 * Description: <b>The reference to the patient</b><br> 3371 * Type: <b>reference</b><br> 3372 * Path: <b>CoverageEligibilityResponse.patient</b><br> 3373 * </p> 3374 */ 3375 @SearchParamDefinition(name="patient", path="CoverageEligibilityResponse.patient", description="The reference to the patient", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Patient") }, target={Patient.class } ) 3376 public static final String SP_PATIENT = "patient"; 3377 /** 3378 * <b>Fluent Client</b> search parameter constant for <b>patient</b> 3379 * <p> 3380 * Description: <b>The reference to the patient</b><br> 3381 * Type: <b>reference</b><br> 3382 * Path: <b>CoverageEligibilityResponse.patient</b><br> 3383 * </p> 3384 */ 3385 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT); 3386 3387/** 3388 * Constant for fluent queries to be used to add include statements. Specifies 3389 * the path value of "<b>CoverageEligibilityResponse:patient</b>". 3390 */ 3391 public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("CoverageEligibilityResponse:patient").toLocked(); 3392 3393 /** 3394 * Search parameter: <b>insurer</b> 3395 * <p> 3396 * Description: <b>The organization which generated this resource</b><br> 3397 * Type: <b>reference</b><br> 3398 * Path: <b>CoverageEligibilityResponse.insurer</b><br> 3399 * </p> 3400 */ 3401 @SearchParamDefinition(name="insurer", path="CoverageEligibilityResponse.insurer", description="The organization which generated this resource", type="reference", target={Organization.class } ) 3402 public static final String SP_INSURER = "insurer"; 3403 /** 3404 * <b>Fluent Client</b> search parameter constant for <b>insurer</b> 3405 * <p> 3406 * Description: <b>The organization which generated this resource</b><br> 3407 * Type: <b>reference</b><br> 3408 * Path: <b>CoverageEligibilityResponse.insurer</b><br> 3409 * </p> 3410 */ 3411 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam INSURER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_INSURER); 3412 3413/** 3414 * Constant for fluent queries to be used to add include statements. Specifies 3415 * the path value of "<b>CoverageEligibilityResponse:insurer</b>". 3416 */ 3417 public static final ca.uhn.fhir.model.api.Include INCLUDE_INSURER = new ca.uhn.fhir.model.api.Include("CoverageEligibilityResponse:insurer").toLocked(); 3418 3419 /** 3420 * Search parameter: <b>created</b> 3421 * <p> 3422 * Description: <b>The creation date</b><br> 3423 * Type: <b>date</b><br> 3424 * Path: <b>CoverageEligibilityResponse.created</b><br> 3425 * </p> 3426 */ 3427 @SearchParamDefinition(name="created", path="CoverageEligibilityResponse.created", description="The creation date", type="date" ) 3428 public static final String SP_CREATED = "created"; 3429 /** 3430 * <b>Fluent Client</b> search parameter constant for <b>created</b> 3431 * <p> 3432 * Description: <b>The creation date</b><br> 3433 * Type: <b>date</b><br> 3434 * Path: <b>CoverageEligibilityResponse.created</b><br> 3435 * </p> 3436 */ 3437 public static final ca.uhn.fhir.rest.gclient.DateClientParam CREATED = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_CREATED); 3438 3439 /** 3440 * Search parameter: <b>outcome</b> 3441 * <p> 3442 * Description: <b>The processing outcome</b><br> 3443 * Type: <b>token</b><br> 3444 * Path: <b>CoverageEligibilityResponse.outcome</b><br> 3445 * </p> 3446 */ 3447 @SearchParamDefinition(name="outcome", path="CoverageEligibilityResponse.outcome", description="The processing outcome", type="token" ) 3448 public static final String SP_OUTCOME = "outcome"; 3449 /** 3450 * <b>Fluent Client</b> search parameter constant for <b>outcome</b> 3451 * <p> 3452 * Description: <b>The processing outcome</b><br> 3453 * Type: <b>token</b><br> 3454 * Path: <b>CoverageEligibilityResponse.outcome</b><br> 3455 * </p> 3456 */ 3457 public static final ca.uhn.fhir.rest.gclient.TokenClientParam OUTCOME = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_OUTCOME); 3458 3459 /** 3460 * Search parameter: <b>requestor</b> 3461 * <p> 3462 * Description: <b>The EligibilityRequest provider</b><br> 3463 * Type: <b>reference</b><br> 3464 * Path: <b>CoverageEligibilityResponse.requestor</b><br> 3465 * </p> 3466 */ 3467 @SearchParamDefinition(name="requestor", path="CoverageEligibilityResponse.requestor", description="The EligibilityRequest provider", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Practitioner") }, target={Organization.class, Practitioner.class, PractitionerRole.class } ) 3468 public static final String SP_REQUESTOR = "requestor"; 3469 /** 3470 * <b>Fluent Client</b> search parameter constant for <b>requestor</b> 3471 * <p> 3472 * Description: <b>The EligibilityRequest provider</b><br> 3473 * Type: <b>reference</b><br> 3474 * Path: <b>CoverageEligibilityResponse.requestor</b><br> 3475 * </p> 3476 */ 3477 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam REQUESTOR = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_REQUESTOR); 3478 3479/** 3480 * Constant for fluent queries to be used to add include statements. Specifies 3481 * the path value of "<b>CoverageEligibilityResponse:requestor</b>". 3482 */ 3483 public static final ca.uhn.fhir.model.api.Include INCLUDE_REQUESTOR = new ca.uhn.fhir.model.api.Include("CoverageEligibilityResponse:requestor").toLocked(); 3484 3485 /** 3486 * Search parameter: <b>status</b> 3487 * <p> 3488 * Description: <b>The EligibilityRequest status</b><br> 3489 * Type: <b>token</b><br> 3490 * Path: <b>CoverageEligibilityResponse.status</b><br> 3491 * </p> 3492 */ 3493 @SearchParamDefinition(name="status", path="CoverageEligibilityResponse.status", description="The EligibilityRequest status", type="token" ) 3494 public static final String SP_STATUS = "status"; 3495 /** 3496 * <b>Fluent Client</b> search parameter constant for <b>status</b> 3497 * <p> 3498 * Description: <b>The EligibilityRequest status</b><br> 3499 * Type: <b>token</b><br> 3500 * Path: <b>CoverageEligibilityResponse.status</b><br> 3501 * </p> 3502 */ 3503 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 3504 3505 3506} 3507