001package org.hl7.fhir.r4.model;
002
003
004
005/*
006  Copyright (c) 2011+, HL7, Inc.
007  All rights reserved.
008  
009  Redistribution and use in source and binary forms, with or without modification, 
010  are permitted provided that the following conditions are met:
011  
012   * Redistributions of source code must retain the above copyright notice, this 
013     list of conditions and the following disclaimer.
014   * Redistributions in binary form must reproduce the above copyright notice, 
015     this list of conditions and the following disclaimer in the documentation 
016     and/or other materials provided with the distribution.
017   * Neither the name of HL7 nor the names of its contributors may be used to 
018     endorse or promote products derived from this software without specific 
019     prior written permission.
020  
021  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 
022  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 
023  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 
024  IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 
025  INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 
026  NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 
027  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 
028  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 
029  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
030  POSSIBILITY OF SUCH DAMAGE.
031  
032*/
033
034
035// Generated on Tue, May 12, 2020 07:26+1000 for FHIR v4.0.1
036
037import java.util.*;
038
039import org.hl7.fhir.utilities.Utilities;
040import org.hl7.fhir.r4.model.Enumerations.*;
041import ca.uhn.fhir.model.api.annotation.ResourceDef;
042import ca.uhn.fhir.model.api.annotation.SearchParamDefinition;
043import ca.uhn.fhir.model.api.annotation.Child;
044import ca.uhn.fhir.model.api.annotation.ChildOrder;
045import ca.uhn.fhir.model.api.annotation.Description;
046import ca.uhn.fhir.model.api.annotation.Block;
047import org.hl7.fhir.instance.model.api.*;
048import org.hl7.fhir.exceptions.FHIRException;
049/**
050 * This resource provides the details including amount of a payment and allocates the payment items being paid.
051 */
052@ResourceDef(name="PaymentReconciliation", profile="http://hl7.org/fhir/StructureDefinition/PaymentReconciliation")
053public class PaymentReconciliation extends DomainResource {
054
055    public enum PaymentReconciliationStatus {
056        /**
057         * The instance is currently in-force.
058         */
059        ACTIVE, 
060        /**
061         * The instance is withdrawn, rescinded or reversed.
062         */
063        CANCELLED, 
064        /**
065         * A new instance the contents of which is not complete.
066         */
067        DRAFT, 
068        /**
069         * The instance was entered in error.
070         */
071        ENTEREDINERROR, 
072        /**
073         * added to help the parsers with the generic types
074         */
075        NULL;
076        public static PaymentReconciliationStatus fromCode(String codeString) throws FHIRException {
077            if (codeString == null || "".equals(codeString))
078                return null;
079        if ("active".equals(codeString))
080          return ACTIVE;
081        if ("cancelled".equals(codeString))
082          return CANCELLED;
083        if ("draft".equals(codeString))
084          return DRAFT;
085        if ("entered-in-error".equals(codeString))
086          return ENTEREDINERROR;
087        if (Configuration.isAcceptInvalidEnums())
088          return null;
089        else
090          throw new FHIRException("Unknown PaymentReconciliationStatus code '"+codeString+"'");
091        }
092        public String toCode() {
093          switch (this) {
094            case ACTIVE: return "active";
095            case CANCELLED: return "cancelled";
096            case DRAFT: return "draft";
097            case ENTEREDINERROR: return "entered-in-error";
098            case NULL: return null;
099            default: return "?";
100          }
101        }
102        public String getSystem() {
103          switch (this) {
104            case ACTIVE: return "http://hl7.org/fhir/fm-status";
105            case CANCELLED: return "http://hl7.org/fhir/fm-status";
106            case DRAFT: return "http://hl7.org/fhir/fm-status";
107            case ENTEREDINERROR: return "http://hl7.org/fhir/fm-status";
108            case NULL: return null;
109            default: return "?";
110          }
111        }
112        public String getDefinition() {
113          switch (this) {
114            case ACTIVE: return "The instance is currently in-force.";
115            case CANCELLED: return "The instance is withdrawn, rescinded or reversed.";
116            case DRAFT: return "A new instance the contents of which is not complete.";
117            case ENTEREDINERROR: return "The instance was entered in error.";
118            case NULL: return null;
119            default: return "?";
120          }
121        }
122        public String getDisplay() {
123          switch (this) {
124            case ACTIVE: return "Active";
125            case CANCELLED: return "Cancelled";
126            case DRAFT: return "Draft";
127            case ENTEREDINERROR: return "Entered in Error";
128            case NULL: return null;
129            default: return "?";
130          }
131        }
132    }
133
134  public static class PaymentReconciliationStatusEnumFactory implements EnumFactory<PaymentReconciliationStatus> {
135    public PaymentReconciliationStatus fromCode(String codeString) throws IllegalArgumentException {
136      if (codeString == null || "".equals(codeString))
137            if (codeString == null || "".equals(codeString))
138                return null;
139        if ("active".equals(codeString))
140          return PaymentReconciliationStatus.ACTIVE;
141        if ("cancelled".equals(codeString))
142          return PaymentReconciliationStatus.CANCELLED;
143        if ("draft".equals(codeString))
144          return PaymentReconciliationStatus.DRAFT;
145        if ("entered-in-error".equals(codeString))
146          return PaymentReconciliationStatus.ENTEREDINERROR;
147        throw new IllegalArgumentException("Unknown PaymentReconciliationStatus code '"+codeString+"'");
148        }
149        public Enumeration<PaymentReconciliationStatus> fromType(Base code) throws FHIRException {
150          if (code == null)
151            return null;
152          if (code.isEmpty())
153            return new Enumeration<PaymentReconciliationStatus>(this);
154          String codeString = ((PrimitiveType) code).asStringValue();
155          if (codeString == null || "".equals(codeString))
156            return null;
157        if ("active".equals(codeString))
158          return new Enumeration<PaymentReconciliationStatus>(this, PaymentReconciliationStatus.ACTIVE);
159        if ("cancelled".equals(codeString))
160          return new Enumeration<PaymentReconciliationStatus>(this, PaymentReconciliationStatus.CANCELLED);
161        if ("draft".equals(codeString))
162          return new Enumeration<PaymentReconciliationStatus>(this, PaymentReconciliationStatus.DRAFT);
163        if ("entered-in-error".equals(codeString))
164          return new Enumeration<PaymentReconciliationStatus>(this, PaymentReconciliationStatus.ENTEREDINERROR);
165        throw new FHIRException("Unknown PaymentReconciliationStatus code '"+codeString+"'");
166        }
167    public String toCode(PaymentReconciliationStatus code) {
168      if (code == PaymentReconciliationStatus.ACTIVE)
169        return "active";
170      if (code == PaymentReconciliationStatus.CANCELLED)
171        return "cancelled";
172      if (code == PaymentReconciliationStatus.DRAFT)
173        return "draft";
174      if (code == PaymentReconciliationStatus.ENTEREDINERROR)
175        return "entered-in-error";
176      return "?";
177      }
178    public String toSystem(PaymentReconciliationStatus code) {
179      return code.getSystem();
180      }
181    }
182
183    @Block()
184    public static class DetailsComponent extends BackboneElement implements IBaseBackboneElement {
185        /**
186         * Unique identifier for the current payment item for the referenced payable.
187         */
188        @Child(name = "identifier", type = {Identifier.class}, order=1, min=0, max=1, modifier=false, summary=false)
189        @Description(shortDefinition="Business identifier of the payment detail", formalDefinition="Unique identifier for the current payment item for the referenced payable." )
190        protected Identifier identifier;
191
192        /**
193         * Unique identifier for the prior payment item for the referenced payable.
194         */
195        @Child(name = "predecessor", type = {Identifier.class}, order=2, min=0, max=1, modifier=false, summary=false)
196        @Description(shortDefinition="Business identifier of the prior payment detail", formalDefinition="Unique identifier for the prior payment item for the referenced payable." )
197        protected Identifier predecessor;
198
199        /**
200         * Code to indicate the nature of the payment.
201         */
202        @Child(name = "type", type = {CodeableConcept.class}, order=3, min=1, max=1, modifier=false, summary=false)
203        @Description(shortDefinition="Category of payment", formalDefinition="Code to indicate the nature of the payment." )
204        @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/payment-type")
205        protected CodeableConcept type;
206
207        /**
208         * A resource, such as a Claim, the evaluation of which could lead to payment.
209         */
210        @Child(name = "request", type = {Reference.class}, order=4, min=0, max=1, modifier=false, summary=false)
211        @Description(shortDefinition="Request giving rise to the payment", formalDefinition="A resource, such as a Claim, the evaluation of which could lead to payment." )
212        protected Reference request;
213
214        /**
215         * The actual object that is the target of the reference (A resource, such as a Claim, the evaluation of which could lead to payment.)
216         */
217        protected Resource requestTarget;
218
219        /**
220         * The party which submitted the claim or financial transaction.
221         */
222        @Child(name = "submitter", type = {Practitioner.class, PractitionerRole.class, Organization.class}, order=5, min=0, max=1, modifier=false, summary=false)
223        @Description(shortDefinition="Submitter of the request", formalDefinition="The party which submitted the claim or financial transaction." )
224        protected Reference submitter;
225
226        /**
227         * The actual object that is the target of the reference (The party which submitted the claim or financial transaction.)
228         */
229        protected Resource submitterTarget;
230
231        /**
232         * A resource, such as a ClaimResponse, which contains a commitment to payment.
233         */
234        @Child(name = "response", type = {Reference.class}, order=6, min=0, max=1, modifier=false, summary=false)
235        @Description(shortDefinition="Response committing to a payment", formalDefinition="A resource, such as a ClaimResponse, which contains a commitment to payment." )
236        protected Reference response;
237
238        /**
239         * The actual object that is the target of the reference (A resource, such as a ClaimResponse, which contains a commitment to payment.)
240         */
241        protected Resource responseTarget;
242
243        /**
244         * The date from the response resource containing a commitment to pay.
245         */
246        @Child(name = "date", type = {DateType.class}, order=7, min=0, max=1, modifier=false, summary=false)
247        @Description(shortDefinition="Date of commitment to pay", formalDefinition="The date from the response resource containing a commitment to pay." )
248        protected DateType date;
249
250        /**
251         * A reference to the individual who is responsible for inquiries regarding the response and its payment.
252         */
253        @Child(name = "responsible", type = {PractitionerRole.class}, order=8, min=0, max=1, modifier=false, summary=false)
254        @Description(shortDefinition="Contact for the response", formalDefinition="A reference to the individual who is responsible for inquiries regarding the response and its payment." )
255        protected Reference responsible;
256
257        /**
258         * The actual object that is the target of the reference (A reference to the individual who is responsible for inquiries regarding the response and its payment.)
259         */
260        protected PractitionerRole responsibleTarget;
261
262        /**
263         * The party which is receiving the payment.
264         */
265        @Child(name = "payee", type = {Practitioner.class, PractitionerRole.class, Organization.class}, order=9, min=0, max=1, modifier=false, summary=false)
266        @Description(shortDefinition="Recipient of the payment", formalDefinition="The party which is receiving the payment." )
267        protected Reference payee;
268
269        /**
270         * The actual object that is the target of the reference (The party which is receiving the payment.)
271         */
272        protected Resource payeeTarget;
273
274        /**
275         * The monetary amount allocated from the total payment to the payable.
276         */
277        @Child(name = "amount", type = {Money.class}, order=10, min=0, max=1, modifier=false, summary=false)
278        @Description(shortDefinition="Amount allocated to this payable", formalDefinition="The monetary amount allocated from the total payment to the payable." )
279        protected Money amount;
280
281        private static final long serialVersionUID = -1361848619L;
282
283    /**
284     * Constructor
285     */
286      public DetailsComponent() {
287        super();
288      }
289
290    /**
291     * Constructor
292     */
293      public DetailsComponent(CodeableConcept type) {
294        super();
295        this.type = type;
296      }
297
298        /**
299         * @return {@link #identifier} (Unique identifier for the current payment item for the referenced payable.)
300         */
301        public Identifier getIdentifier() { 
302          if (this.identifier == null)
303            if (Configuration.errorOnAutoCreate())
304              throw new Error("Attempt to auto-create DetailsComponent.identifier");
305            else if (Configuration.doAutoCreate())
306              this.identifier = new Identifier(); // cc
307          return this.identifier;
308        }
309
310        public boolean hasIdentifier() { 
311          return this.identifier != null && !this.identifier.isEmpty();
312        }
313
314        /**
315         * @param value {@link #identifier} (Unique identifier for the current payment item for the referenced payable.)
316         */
317        public DetailsComponent setIdentifier(Identifier value) { 
318          this.identifier = value;
319          return this;
320        }
321
322        /**
323         * @return {@link #predecessor} (Unique identifier for the prior payment item for the referenced payable.)
324         */
325        public Identifier getPredecessor() { 
326          if (this.predecessor == null)
327            if (Configuration.errorOnAutoCreate())
328              throw new Error("Attempt to auto-create DetailsComponent.predecessor");
329            else if (Configuration.doAutoCreate())
330              this.predecessor = new Identifier(); // cc
331          return this.predecessor;
332        }
333
334        public boolean hasPredecessor() { 
335          return this.predecessor != null && !this.predecessor.isEmpty();
336        }
337
338        /**
339         * @param value {@link #predecessor} (Unique identifier for the prior payment item for the referenced payable.)
340         */
341        public DetailsComponent setPredecessor(Identifier value) { 
342          this.predecessor = value;
343          return this;
344        }
345
346        /**
347         * @return {@link #type} (Code to indicate the nature of the payment.)
348         */
349        public CodeableConcept getType() { 
350          if (this.type == null)
351            if (Configuration.errorOnAutoCreate())
352              throw new Error("Attempt to auto-create DetailsComponent.type");
353            else if (Configuration.doAutoCreate())
354              this.type = new CodeableConcept(); // cc
355          return this.type;
356        }
357
358        public boolean hasType() { 
359          return this.type != null && !this.type.isEmpty();
360        }
361
362        /**
363         * @param value {@link #type} (Code to indicate the nature of the payment.)
364         */
365        public DetailsComponent setType(CodeableConcept value) { 
366          this.type = value;
367          return this;
368        }
369
370        /**
371         * @return {@link #request} (A resource, such as a Claim, the evaluation of which could lead to payment.)
372         */
373        public Reference getRequest() { 
374          if (this.request == null)
375            if (Configuration.errorOnAutoCreate())
376              throw new Error("Attempt to auto-create DetailsComponent.request");
377            else if (Configuration.doAutoCreate())
378              this.request = new Reference(); // cc
379          return this.request;
380        }
381
382        public boolean hasRequest() { 
383          return this.request != null && !this.request.isEmpty();
384        }
385
386        /**
387         * @param value {@link #request} (A resource, such as a Claim, the evaluation of which could lead to payment.)
388         */
389        public DetailsComponent setRequest(Reference value) { 
390          this.request = value;
391          return this;
392        }
393
394        /**
395         * @return {@link #request} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (A resource, such as a Claim, the evaluation of which could lead to payment.)
396         */
397        public Resource getRequestTarget() { 
398          return this.requestTarget;
399        }
400
401        /**
402         * @param value {@link #request} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (A resource, such as a Claim, the evaluation of which could lead to payment.)
403         */
404        public DetailsComponent setRequestTarget(Resource value) { 
405          this.requestTarget = value;
406          return this;
407        }
408
409        /**
410         * @return {@link #submitter} (The party which submitted the claim or financial transaction.)
411         */
412        public Reference getSubmitter() { 
413          if (this.submitter == null)
414            if (Configuration.errorOnAutoCreate())
415              throw new Error("Attempt to auto-create DetailsComponent.submitter");
416            else if (Configuration.doAutoCreate())
417              this.submitter = new Reference(); // cc
418          return this.submitter;
419        }
420
421        public boolean hasSubmitter() { 
422          return this.submitter != null && !this.submitter.isEmpty();
423        }
424
425        /**
426         * @param value {@link #submitter} (The party which submitted the claim or financial transaction.)
427         */
428        public DetailsComponent setSubmitter(Reference value) { 
429          this.submitter = value;
430          return this;
431        }
432
433        /**
434         * @return {@link #submitter} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (The party which submitted the claim or financial transaction.)
435         */
436        public Resource getSubmitterTarget() { 
437          return this.submitterTarget;
438        }
439
440        /**
441         * @param value {@link #submitter} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (The party which submitted the claim or financial transaction.)
442         */
443        public DetailsComponent setSubmitterTarget(Resource value) { 
444          this.submitterTarget = value;
445          return this;
446        }
447
448        /**
449         * @return {@link #response} (A resource, such as a ClaimResponse, which contains a commitment to payment.)
450         */
451        public Reference getResponse() { 
452          if (this.response == null)
453            if (Configuration.errorOnAutoCreate())
454              throw new Error("Attempt to auto-create DetailsComponent.response");
455            else if (Configuration.doAutoCreate())
456              this.response = new Reference(); // cc
457          return this.response;
458        }
459
460        public boolean hasResponse() { 
461          return this.response != null && !this.response.isEmpty();
462        }
463
464        /**
465         * @param value {@link #response} (A resource, such as a ClaimResponse, which contains a commitment to payment.)
466         */
467        public DetailsComponent setResponse(Reference value) { 
468          this.response = value;
469          return this;
470        }
471
472        /**
473         * @return {@link #response} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (A resource, such as a ClaimResponse, which contains a commitment to payment.)
474         */
475        public Resource getResponseTarget() { 
476          return this.responseTarget;
477        }
478
479        /**
480         * @param value {@link #response} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (A resource, such as a ClaimResponse, which contains a commitment to payment.)
481         */
482        public DetailsComponent setResponseTarget(Resource value) { 
483          this.responseTarget = value;
484          return this;
485        }
486
487        /**
488         * @return {@link #date} (The date from the response resource containing a commitment to pay.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value
489         */
490        public DateType getDateElement() { 
491          if (this.date == null)
492            if (Configuration.errorOnAutoCreate())
493              throw new Error("Attempt to auto-create DetailsComponent.date");
494            else if (Configuration.doAutoCreate())
495              this.date = new DateType(); // bb
496          return this.date;
497        }
498
499        public boolean hasDateElement() { 
500          return this.date != null && !this.date.isEmpty();
501        }
502
503        public boolean hasDate() { 
504          return this.date != null && !this.date.isEmpty();
505        }
506
507        /**
508         * @param value {@link #date} (The date from the response resource containing a commitment to pay.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value
509         */
510        public DetailsComponent setDateElement(DateType value) { 
511          this.date = value;
512          return this;
513        }
514
515        /**
516         * @return The date from the response resource containing a commitment to pay.
517         */
518        public Date getDate() { 
519          return this.date == null ? null : this.date.getValue();
520        }
521
522        /**
523         * @param value The date from the response resource containing a commitment to pay.
524         */
525        public DetailsComponent setDate(Date value) { 
526          if (value == null)
527            this.date = null;
528          else {
529            if (this.date == null)
530              this.date = new DateType();
531            this.date.setValue(value);
532          }
533          return this;
534        }
535
536        /**
537         * @return {@link #responsible} (A reference to the individual who is responsible for inquiries regarding the response and its payment.)
538         */
539        public Reference getResponsible() { 
540          if (this.responsible == null)
541            if (Configuration.errorOnAutoCreate())
542              throw new Error("Attempt to auto-create DetailsComponent.responsible");
543            else if (Configuration.doAutoCreate())
544              this.responsible = new Reference(); // cc
545          return this.responsible;
546        }
547
548        public boolean hasResponsible() { 
549          return this.responsible != null && !this.responsible.isEmpty();
550        }
551
552        /**
553         * @param value {@link #responsible} (A reference to the individual who is responsible for inquiries regarding the response and its payment.)
554         */
555        public DetailsComponent setResponsible(Reference value) { 
556          this.responsible = value;
557          return this;
558        }
559
560        /**
561         * @return {@link #responsible} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (A reference to the individual who is responsible for inquiries regarding the response and its payment.)
562         */
563        public PractitionerRole getResponsibleTarget() { 
564          if (this.responsibleTarget == null)
565            if (Configuration.errorOnAutoCreate())
566              throw new Error("Attempt to auto-create DetailsComponent.responsible");
567            else if (Configuration.doAutoCreate())
568              this.responsibleTarget = new PractitionerRole(); // aa
569          return this.responsibleTarget;
570        }
571
572        /**
573         * @param value {@link #responsible} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (A reference to the individual who is responsible for inquiries regarding the response and its payment.)
574         */
575        public DetailsComponent setResponsibleTarget(PractitionerRole value) { 
576          this.responsibleTarget = value;
577          return this;
578        }
579
580        /**
581         * @return {@link #payee} (The party which is receiving the payment.)
582         */
583        public Reference getPayee() { 
584          if (this.payee == null)
585            if (Configuration.errorOnAutoCreate())
586              throw new Error("Attempt to auto-create DetailsComponent.payee");
587            else if (Configuration.doAutoCreate())
588              this.payee = new Reference(); // cc
589          return this.payee;
590        }
591
592        public boolean hasPayee() { 
593          return this.payee != null && !this.payee.isEmpty();
594        }
595
596        /**
597         * @param value {@link #payee} (The party which is receiving the payment.)
598         */
599        public DetailsComponent setPayee(Reference value) { 
600          this.payee = value;
601          return this;
602        }
603
604        /**
605         * @return {@link #payee} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (The party which is receiving the payment.)
606         */
607        public Resource getPayeeTarget() { 
608          return this.payeeTarget;
609        }
610
611        /**
612         * @param value {@link #payee} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (The party which is receiving the payment.)
613         */
614        public DetailsComponent setPayeeTarget(Resource value) { 
615          this.payeeTarget = value;
616          return this;
617        }
618
619        /**
620         * @return {@link #amount} (The monetary amount allocated from the total payment to the payable.)
621         */
622        public Money getAmount() { 
623          if (this.amount == null)
624            if (Configuration.errorOnAutoCreate())
625              throw new Error("Attempt to auto-create DetailsComponent.amount");
626            else if (Configuration.doAutoCreate())
627              this.amount = new Money(); // cc
628          return this.amount;
629        }
630
631        public boolean hasAmount() { 
632          return this.amount != null && !this.amount.isEmpty();
633        }
634
635        /**
636         * @param value {@link #amount} (The monetary amount allocated from the total payment to the payable.)
637         */
638        public DetailsComponent setAmount(Money value) { 
639          this.amount = value;
640          return this;
641        }
642
643        protected void listChildren(List<Property> children) {
644          super.listChildren(children);
645          children.add(new Property("identifier", "Identifier", "Unique identifier for the current payment item for the referenced payable.", 0, 1, identifier));
646          children.add(new Property("predecessor", "Identifier", "Unique identifier for the prior payment item for the referenced payable.", 0, 1, predecessor));
647          children.add(new Property("type", "CodeableConcept", "Code to indicate the nature of the payment.", 0, 1, type));
648          children.add(new Property("request", "Reference(Any)", "A resource, such as a Claim, the evaluation of which could lead to payment.", 0, 1, request));
649          children.add(new Property("submitter", "Reference(Practitioner|PractitionerRole|Organization)", "The party which submitted the claim or financial transaction.", 0, 1, submitter));
650          children.add(new Property("response", "Reference(Any)", "A resource, such as a ClaimResponse, which contains a commitment to payment.", 0, 1, response));
651          children.add(new Property("date", "date", "The date from the response resource containing a commitment to pay.", 0, 1, date));
652          children.add(new Property("responsible", "Reference(PractitionerRole)", "A reference to the individual who is responsible for inquiries regarding the response and its payment.", 0, 1, responsible));
653          children.add(new Property("payee", "Reference(Practitioner|PractitionerRole|Organization)", "The party which is receiving the payment.", 0, 1, payee));
654          children.add(new Property("amount", "Money", "The monetary amount allocated from the total payment to the payable.", 0, 1, amount));
655        }
656
657        @Override
658        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
659          switch (_hash) {
660          case -1618432855: /*identifier*/  return new Property("identifier", "Identifier", "Unique identifier for the current payment item for the referenced payable.", 0, 1, identifier);
661          case -1925032183: /*predecessor*/  return new Property("predecessor", "Identifier", "Unique identifier for the prior payment item for the referenced payable.", 0, 1, predecessor);
662          case 3575610: /*type*/  return new Property("type", "CodeableConcept", "Code to indicate the nature of the payment.", 0, 1, type);
663          case 1095692943: /*request*/  return new Property("request", "Reference(Any)", "A resource, such as a Claim, the evaluation of which could lead to payment.", 0, 1, request);
664          case 348678409: /*submitter*/  return new Property("submitter", "Reference(Practitioner|PractitionerRole|Organization)", "The party which submitted the claim or financial transaction.", 0, 1, submitter);
665          case -340323263: /*response*/  return new Property("response", "Reference(Any)", "A resource, such as a ClaimResponse, which contains a commitment to payment.", 0, 1, response);
666          case 3076014: /*date*/  return new Property("date", "date", "The date from the response resource containing a commitment to pay.", 0, 1, date);
667          case 1847674614: /*responsible*/  return new Property("responsible", "Reference(PractitionerRole)", "A reference to the individual who is responsible for inquiries regarding the response and its payment.", 0, 1, responsible);
668          case 106443592: /*payee*/  return new Property("payee", "Reference(Practitioner|PractitionerRole|Organization)", "The party which is receiving the payment.", 0, 1, payee);
669          case -1413853096: /*amount*/  return new Property("amount", "Money", "The monetary amount allocated from the total payment to the payable.", 0, 1, amount);
670          default: return super.getNamedProperty(_hash, _name, _checkValid);
671          }
672
673        }
674
675      @Override
676      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
677        switch (hash) {
678        case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : new Base[] {this.identifier}; // Identifier
679        case -1925032183: /*predecessor*/ return this.predecessor == null ? new Base[0] : new Base[] {this.predecessor}; // Identifier
680        case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept
681        case 1095692943: /*request*/ return this.request == null ? new Base[0] : new Base[] {this.request}; // Reference
682        case 348678409: /*submitter*/ return this.submitter == null ? new Base[0] : new Base[] {this.submitter}; // Reference
683        case -340323263: /*response*/ return this.response == null ? new Base[0] : new Base[] {this.response}; // Reference
684        case 3076014: /*date*/ return this.date == null ? new Base[0] : new Base[] {this.date}; // DateType
685        case 1847674614: /*responsible*/ return this.responsible == null ? new Base[0] : new Base[] {this.responsible}; // Reference
686        case 106443592: /*payee*/ return this.payee == null ? new Base[0] : new Base[] {this.payee}; // Reference
687        case -1413853096: /*amount*/ return this.amount == null ? new Base[0] : new Base[] {this.amount}; // Money
688        default: return super.getProperty(hash, name, checkValid);
689        }
690
691      }
692
693      @Override
694      public Base setProperty(int hash, String name, Base value) throws FHIRException {
695        switch (hash) {
696        case -1618432855: // identifier
697          this.identifier = castToIdentifier(value); // Identifier
698          return value;
699        case -1925032183: // predecessor
700          this.predecessor = castToIdentifier(value); // Identifier
701          return value;
702        case 3575610: // type
703          this.type = castToCodeableConcept(value); // CodeableConcept
704          return value;
705        case 1095692943: // request
706          this.request = castToReference(value); // Reference
707          return value;
708        case 348678409: // submitter
709          this.submitter = castToReference(value); // Reference
710          return value;
711        case -340323263: // response
712          this.response = castToReference(value); // Reference
713          return value;
714        case 3076014: // date
715          this.date = castToDate(value); // DateType
716          return value;
717        case 1847674614: // responsible
718          this.responsible = castToReference(value); // Reference
719          return value;
720        case 106443592: // payee
721          this.payee = castToReference(value); // Reference
722          return value;
723        case -1413853096: // amount
724          this.amount = castToMoney(value); // Money
725          return value;
726        default: return super.setProperty(hash, name, value);
727        }
728
729      }
730
731      @Override
732      public Base setProperty(String name, Base value) throws FHIRException {
733        if (name.equals("identifier")) {
734          this.identifier = castToIdentifier(value); // Identifier
735        } else if (name.equals("predecessor")) {
736          this.predecessor = castToIdentifier(value); // Identifier
737        } else if (name.equals("type")) {
738          this.type = castToCodeableConcept(value); // CodeableConcept
739        } else if (name.equals("request")) {
740          this.request = castToReference(value); // Reference
741        } else if (name.equals("submitter")) {
742          this.submitter = castToReference(value); // Reference
743        } else if (name.equals("response")) {
744          this.response = castToReference(value); // Reference
745        } else if (name.equals("date")) {
746          this.date = castToDate(value); // DateType
747        } else if (name.equals("responsible")) {
748          this.responsible = castToReference(value); // Reference
749        } else if (name.equals("payee")) {
750          this.payee = castToReference(value); // Reference
751        } else if (name.equals("amount")) {
752          this.amount = castToMoney(value); // Money
753        } else
754          return super.setProperty(name, value);
755        return value;
756      }
757
758      @Override
759      public Base makeProperty(int hash, String name) throws FHIRException {
760        switch (hash) {
761        case -1618432855:  return getIdentifier(); 
762        case -1925032183:  return getPredecessor(); 
763        case 3575610:  return getType(); 
764        case 1095692943:  return getRequest(); 
765        case 348678409:  return getSubmitter(); 
766        case -340323263:  return getResponse(); 
767        case 3076014:  return getDateElement();
768        case 1847674614:  return getResponsible(); 
769        case 106443592:  return getPayee(); 
770        case -1413853096:  return getAmount(); 
771        default: return super.makeProperty(hash, name);
772        }
773
774      }
775
776      @Override
777      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
778        switch (hash) {
779        case -1618432855: /*identifier*/ return new String[] {"Identifier"};
780        case -1925032183: /*predecessor*/ return new String[] {"Identifier"};
781        case 3575610: /*type*/ return new String[] {"CodeableConcept"};
782        case 1095692943: /*request*/ return new String[] {"Reference"};
783        case 348678409: /*submitter*/ return new String[] {"Reference"};
784        case -340323263: /*response*/ return new String[] {"Reference"};
785        case 3076014: /*date*/ return new String[] {"date"};
786        case 1847674614: /*responsible*/ return new String[] {"Reference"};
787        case 106443592: /*payee*/ return new String[] {"Reference"};
788        case -1413853096: /*amount*/ return new String[] {"Money"};
789        default: return super.getTypesForProperty(hash, name);
790        }
791
792      }
793
794      @Override
795      public Base addChild(String name) throws FHIRException {
796        if (name.equals("identifier")) {
797          this.identifier = new Identifier();
798          return this.identifier;
799        }
800        else if (name.equals("predecessor")) {
801          this.predecessor = new Identifier();
802          return this.predecessor;
803        }
804        else if (name.equals("type")) {
805          this.type = new CodeableConcept();
806          return this.type;
807        }
808        else if (name.equals("request")) {
809          this.request = new Reference();
810          return this.request;
811        }
812        else if (name.equals("submitter")) {
813          this.submitter = new Reference();
814          return this.submitter;
815        }
816        else if (name.equals("response")) {
817          this.response = new Reference();
818          return this.response;
819        }
820        else if (name.equals("date")) {
821          throw new FHIRException("Cannot call addChild on a primitive type PaymentReconciliation.date");
822        }
823        else if (name.equals("responsible")) {
824          this.responsible = new Reference();
825          return this.responsible;
826        }
827        else if (name.equals("payee")) {
828          this.payee = new Reference();
829          return this.payee;
830        }
831        else if (name.equals("amount")) {
832          this.amount = new Money();
833          return this.amount;
834        }
835        else
836          return super.addChild(name);
837      }
838
839      public DetailsComponent copy() {
840        DetailsComponent dst = new DetailsComponent();
841        copyValues(dst);
842        return dst;
843      }
844
845      public void copyValues(DetailsComponent dst) {
846        super.copyValues(dst);
847        dst.identifier = identifier == null ? null : identifier.copy();
848        dst.predecessor = predecessor == null ? null : predecessor.copy();
849        dst.type = type == null ? null : type.copy();
850        dst.request = request == null ? null : request.copy();
851        dst.submitter = submitter == null ? null : submitter.copy();
852        dst.response = response == null ? null : response.copy();
853        dst.date = date == null ? null : date.copy();
854        dst.responsible = responsible == null ? null : responsible.copy();
855        dst.payee = payee == null ? null : payee.copy();
856        dst.amount = amount == null ? null : amount.copy();
857      }
858
859      @Override
860      public boolean equalsDeep(Base other_) {
861        if (!super.equalsDeep(other_))
862          return false;
863        if (!(other_ instanceof DetailsComponent))
864          return false;
865        DetailsComponent o = (DetailsComponent) other_;
866        return compareDeep(identifier, o.identifier, true) && compareDeep(predecessor, o.predecessor, true)
867           && compareDeep(type, o.type, true) && compareDeep(request, o.request, true) && compareDeep(submitter, o.submitter, true)
868           && compareDeep(response, o.response, true) && compareDeep(date, o.date, true) && compareDeep(responsible, o.responsible, true)
869           && compareDeep(payee, o.payee, true) && compareDeep(amount, o.amount, true);
870      }
871
872      @Override
873      public boolean equalsShallow(Base other_) {
874        if (!super.equalsShallow(other_))
875          return false;
876        if (!(other_ instanceof DetailsComponent))
877          return false;
878        DetailsComponent o = (DetailsComponent) other_;
879        return compareValues(date, o.date, true);
880      }
881
882      public boolean isEmpty() {
883        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, predecessor, type
884          , request, submitter, response, date, responsible, payee, amount);
885      }
886
887  public String fhirType() {
888    return "PaymentReconciliation.detail";
889
890  }
891
892  }
893
894    @Block()
895    public static class NotesComponent extends BackboneElement implements IBaseBackboneElement {
896        /**
897         * The business purpose of the note text.
898         */
899        @Child(name = "type", type = {CodeType.class}, order=1, min=0, max=1, modifier=false, summary=false)
900        @Description(shortDefinition="display | print | printoper", formalDefinition="The business purpose of the note text." )
901        @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/note-type")
902        protected Enumeration<NoteType> type;
903
904        /**
905         * The explanation or description associated with the processing.
906         */
907        @Child(name = "text", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false)
908        @Description(shortDefinition="Note explanatory text", formalDefinition="The explanation or description associated with the processing." )
909        protected StringType text;
910
911        private static final long serialVersionUID = 529250161L;
912
913    /**
914     * Constructor
915     */
916      public NotesComponent() {
917        super();
918      }
919
920        /**
921         * @return {@link #type} (The business purpose of the note text.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value
922         */
923        public Enumeration<NoteType> getTypeElement() { 
924          if (this.type == null)
925            if (Configuration.errorOnAutoCreate())
926              throw new Error("Attempt to auto-create NotesComponent.type");
927            else if (Configuration.doAutoCreate())
928              this.type = new Enumeration<NoteType>(new NoteTypeEnumFactory()); // bb
929          return this.type;
930        }
931
932        public boolean hasTypeElement() { 
933          return this.type != null && !this.type.isEmpty();
934        }
935
936        public boolean hasType() { 
937          return this.type != null && !this.type.isEmpty();
938        }
939
940        /**
941         * @param value {@link #type} (The business purpose of the note text.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value
942         */
943        public NotesComponent setTypeElement(Enumeration<NoteType> value) { 
944          this.type = value;
945          return this;
946        }
947
948        /**
949         * @return The business purpose of the note text.
950         */
951        public NoteType getType() { 
952          return this.type == null ? null : this.type.getValue();
953        }
954
955        /**
956         * @param value The business purpose of the note text.
957         */
958        public NotesComponent setType(NoteType value) { 
959          if (value == null)
960            this.type = null;
961          else {
962            if (this.type == null)
963              this.type = new Enumeration<NoteType>(new NoteTypeEnumFactory());
964            this.type.setValue(value);
965          }
966          return this;
967        }
968
969        /**
970         * @return {@link #text} (The explanation or description associated with the processing.). This is the underlying object with id, value and extensions. The accessor "getText" gives direct access to the value
971         */
972        public StringType getTextElement() { 
973          if (this.text == null)
974            if (Configuration.errorOnAutoCreate())
975              throw new Error("Attempt to auto-create NotesComponent.text");
976            else if (Configuration.doAutoCreate())
977              this.text = new StringType(); // bb
978          return this.text;
979        }
980
981        public boolean hasTextElement() { 
982          return this.text != null && !this.text.isEmpty();
983        }
984
985        public boolean hasText() { 
986          return this.text != null && !this.text.isEmpty();
987        }
988
989        /**
990         * @param value {@link #text} (The explanation or description associated with the processing.). This is the underlying object with id, value and extensions. The accessor "getText" gives direct access to the value
991         */
992        public NotesComponent setTextElement(StringType value) { 
993          this.text = value;
994          return this;
995        }
996
997        /**
998         * @return The explanation or description associated with the processing.
999         */
1000        public String getText() { 
1001          return this.text == null ? null : this.text.getValue();
1002        }
1003
1004        /**
1005         * @param value The explanation or description associated with the processing.
1006         */
1007        public NotesComponent setText(String value) { 
1008          if (Utilities.noString(value))
1009            this.text = null;
1010          else {
1011            if (this.text == null)
1012              this.text = new StringType();
1013            this.text.setValue(value);
1014          }
1015          return this;
1016        }
1017
1018        protected void listChildren(List<Property> children) {
1019          super.listChildren(children);
1020          children.add(new Property("type", "code", "The business purpose of the note text.", 0, 1, type));
1021          children.add(new Property("text", "string", "The explanation or description associated with the processing.", 0, 1, text));
1022        }
1023
1024        @Override
1025        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
1026          switch (_hash) {
1027          case 3575610: /*type*/  return new Property("type", "code", "The business purpose of the note text.", 0, 1, type);
1028          case 3556653: /*text*/  return new Property("text", "string", "The explanation or description associated with the processing.", 0, 1, text);
1029          default: return super.getNamedProperty(_hash, _name, _checkValid);
1030          }
1031
1032        }
1033
1034      @Override
1035      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
1036        switch (hash) {
1037        case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // Enumeration<NoteType>
1038        case 3556653: /*text*/ return this.text == null ? new Base[0] : new Base[] {this.text}; // StringType
1039        default: return super.getProperty(hash, name, checkValid);
1040        }
1041
1042      }
1043
1044      @Override
1045      public Base setProperty(int hash, String name, Base value) throws FHIRException {
1046        switch (hash) {
1047        case 3575610: // type
1048          value = new NoteTypeEnumFactory().fromType(castToCode(value));
1049          this.type = (Enumeration) value; // Enumeration<NoteType>
1050          return value;
1051        case 3556653: // text
1052          this.text = castToString(value); // StringType
1053          return value;
1054        default: return super.setProperty(hash, name, value);
1055        }
1056
1057      }
1058
1059      @Override
1060      public Base setProperty(String name, Base value) throws FHIRException {
1061        if (name.equals("type")) {
1062          value = new NoteTypeEnumFactory().fromType(castToCode(value));
1063          this.type = (Enumeration) value; // Enumeration<NoteType>
1064        } else if (name.equals("text")) {
1065          this.text = castToString(value); // StringType
1066        } else
1067          return super.setProperty(name, value);
1068        return value;
1069      }
1070
1071      @Override
1072      public Base makeProperty(int hash, String name) throws FHIRException {
1073        switch (hash) {
1074        case 3575610:  return getTypeElement();
1075        case 3556653:  return getTextElement();
1076        default: return super.makeProperty(hash, name);
1077        }
1078
1079      }
1080
1081      @Override
1082      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
1083        switch (hash) {
1084        case 3575610: /*type*/ return new String[] {"code"};
1085        case 3556653: /*text*/ return new String[] {"string"};
1086        default: return super.getTypesForProperty(hash, name);
1087        }
1088
1089      }
1090
1091      @Override
1092      public Base addChild(String name) throws FHIRException {
1093        if (name.equals("type")) {
1094          throw new FHIRException("Cannot call addChild on a primitive type PaymentReconciliation.type");
1095        }
1096        else if (name.equals("text")) {
1097          throw new FHIRException("Cannot call addChild on a primitive type PaymentReconciliation.text");
1098        }
1099        else
1100          return super.addChild(name);
1101      }
1102
1103      public NotesComponent copy() {
1104        NotesComponent dst = new NotesComponent();
1105        copyValues(dst);
1106        return dst;
1107      }
1108
1109      public void copyValues(NotesComponent dst) {
1110        super.copyValues(dst);
1111        dst.type = type == null ? null : type.copy();
1112        dst.text = text == null ? null : text.copy();
1113      }
1114
1115      @Override
1116      public boolean equalsDeep(Base other_) {
1117        if (!super.equalsDeep(other_))
1118          return false;
1119        if (!(other_ instanceof NotesComponent))
1120          return false;
1121        NotesComponent o = (NotesComponent) other_;
1122        return compareDeep(type, o.type, true) && compareDeep(text, o.text, true);
1123      }
1124
1125      @Override
1126      public boolean equalsShallow(Base other_) {
1127        if (!super.equalsShallow(other_))
1128          return false;
1129        if (!(other_ instanceof NotesComponent))
1130          return false;
1131        NotesComponent o = (NotesComponent) other_;
1132        return compareValues(type, o.type, true) && compareValues(text, o.text, true);
1133      }
1134
1135      public boolean isEmpty() {
1136        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, text);
1137      }
1138
1139  public String fhirType() {
1140    return "PaymentReconciliation.processNote";
1141
1142  }
1143
1144  }
1145
1146    /**
1147     * A unique identifier assigned to this payment reconciliation.
1148     */
1149    @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1150    @Description(shortDefinition="Business Identifier for a payment reconciliation", formalDefinition="A unique identifier assigned to this payment reconciliation." )
1151    protected List<Identifier> identifier;
1152
1153    /**
1154     * The status of the resource instance.
1155     */
1156    @Child(name = "status", type = {CodeType.class}, order=1, min=1, max=1, modifier=true, summary=true)
1157    @Description(shortDefinition="active | cancelled | draft | entered-in-error", formalDefinition="The status of the resource instance." )
1158    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/fm-status")
1159    protected Enumeration<PaymentReconciliationStatus> status;
1160
1161    /**
1162     * The period of time for which payments have been gathered into this bulk payment for settlement.
1163     */
1164    @Child(name = "period", type = {Period.class}, order=2, min=0, max=1, modifier=false, summary=true)
1165    @Description(shortDefinition="Period covered", formalDefinition="The period of time for which payments have been gathered into this bulk payment for settlement." )
1166    protected Period period;
1167
1168    /**
1169     * The date when the resource was created.
1170     */
1171    @Child(name = "created", type = {DateTimeType.class}, order=3, min=1, max=1, modifier=false, summary=true)
1172    @Description(shortDefinition="Creation date", formalDefinition="The date when the resource was created." )
1173    protected DateTimeType created;
1174
1175    /**
1176     * The party who generated the payment.
1177     */
1178    @Child(name = "paymentIssuer", type = {Organization.class}, order=4, min=0, max=1, modifier=false, summary=true)
1179    @Description(shortDefinition="Party generating payment", formalDefinition="The party who generated the payment." )
1180    protected Reference paymentIssuer;
1181
1182    /**
1183     * The actual object that is the target of the reference (The party who generated the payment.)
1184     */
1185    protected Organization paymentIssuerTarget;
1186
1187    /**
1188     * Original request resource reference.
1189     */
1190    @Child(name = "request", type = {Task.class}, order=5, min=0, max=1, modifier=false, summary=false)
1191    @Description(shortDefinition="Reference to requesting resource", formalDefinition="Original request resource reference." )
1192    protected Reference request;
1193
1194    /**
1195     * The actual object that is the target of the reference (Original request resource reference.)
1196     */
1197    protected Task requestTarget;
1198
1199    /**
1200     * The practitioner who is responsible for the services rendered to the patient.
1201     */
1202    @Child(name = "requestor", type = {Practitioner.class, PractitionerRole.class, Organization.class}, order=6, min=0, max=1, modifier=false, summary=false)
1203    @Description(shortDefinition="Responsible practitioner", formalDefinition="The practitioner who is responsible for the services rendered to the patient." )
1204    protected Reference requestor;
1205
1206    /**
1207     * The actual object that is the target of the reference (The practitioner who is responsible for the services rendered to the patient.)
1208     */
1209    protected Resource requestorTarget;
1210
1211    /**
1212     * The outcome of a request for a reconciliation.
1213     */
1214    @Child(name = "outcome", type = {CodeType.class}, order=7, min=0, max=1, modifier=false, summary=false)
1215    @Description(shortDefinition="queued | complete | error | partial", formalDefinition="The outcome of a request for a reconciliation." )
1216    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/remittance-outcome")
1217    protected Enumeration<RemittanceOutcome> outcome;
1218
1219    /**
1220     * A human readable description of the status of the request for the reconciliation.
1221     */
1222    @Child(name = "disposition", type = {StringType.class}, order=8, min=0, max=1, modifier=false, summary=false)
1223    @Description(shortDefinition="Disposition message", formalDefinition="A human readable description of the status of the request for the reconciliation." )
1224    protected StringType disposition;
1225
1226    /**
1227     * The date of payment as indicated on the financial instrument.
1228     */
1229    @Child(name = "paymentDate", type = {DateType.class}, order=9, min=1, max=1, modifier=false, summary=true)
1230    @Description(shortDefinition="When payment issued", formalDefinition="The date of payment as indicated on the financial instrument." )
1231    protected DateType paymentDate;
1232
1233    /**
1234     * Total payment amount as indicated on the financial instrument.
1235     */
1236    @Child(name = "paymentAmount", type = {Money.class}, order=10, min=1, max=1, modifier=false, summary=true)
1237    @Description(shortDefinition="Total amount of Payment", formalDefinition="Total payment amount as indicated on the financial instrument." )
1238    protected Money paymentAmount;
1239
1240    /**
1241     * Issuer's unique identifier for the payment instrument.
1242     */
1243    @Child(name = "paymentIdentifier", type = {Identifier.class}, order=11, min=0, max=1, modifier=false, summary=false)
1244    @Description(shortDefinition="Business identifier for the payment", formalDefinition="Issuer's unique identifier for the payment instrument." )
1245    protected Identifier paymentIdentifier;
1246
1247    /**
1248     * Distribution of the payment amount for a previously acknowledged payable.
1249     */
1250    @Child(name = "detail", type = {}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1251    @Description(shortDefinition="Settlement particulars", formalDefinition="Distribution of the payment amount for a previously acknowledged payable." )
1252    protected List<DetailsComponent> detail;
1253
1254    /**
1255     * A code for the form to be used for printing the content.
1256     */
1257    @Child(name = "formCode", type = {CodeableConcept.class}, order=13, min=0, max=1, modifier=false, summary=false)
1258    @Description(shortDefinition="Printed form identifier", formalDefinition="A code for the form to be used for printing the content." )
1259    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/forms")
1260    protected CodeableConcept formCode;
1261
1262    /**
1263     * A note that describes or explains the processing in a human readable form.
1264     */
1265    @Child(name = "processNote", type = {}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1266    @Description(shortDefinition="Note concerning processing", formalDefinition="A note that describes or explains the processing in a human readable form." )
1267    protected List<NotesComponent> processNote;
1268
1269    private static final long serialVersionUID = -1620965037L;
1270
1271  /**
1272   * Constructor
1273   */
1274    public PaymentReconciliation() {
1275      super();
1276    }
1277
1278  /**
1279   * Constructor
1280   */
1281    public PaymentReconciliation(Enumeration<PaymentReconciliationStatus> status, DateTimeType created, DateType paymentDate, Money paymentAmount) {
1282      super();
1283      this.status = status;
1284      this.created = created;
1285      this.paymentDate = paymentDate;
1286      this.paymentAmount = paymentAmount;
1287    }
1288
1289    /**
1290     * @return {@link #identifier} (A unique identifier assigned to this payment reconciliation.)
1291     */
1292    public List<Identifier> getIdentifier() { 
1293      if (this.identifier == null)
1294        this.identifier = new ArrayList<Identifier>();
1295      return this.identifier;
1296    }
1297
1298    /**
1299     * @return Returns a reference to <code>this</code> for easy method chaining
1300     */
1301    public PaymentReconciliation setIdentifier(List<Identifier> theIdentifier) { 
1302      this.identifier = theIdentifier;
1303      return this;
1304    }
1305
1306    public boolean hasIdentifier() { 
1307      if (this.identifier == null)
1308        return false;
1309      for (Identifier item : this.identifier)
1310        if (!item.isEmpty())
1311          return true;
1312      return false;
1313    }
1314
1315    public Identifier addIdentifier() { //3
1316      Identifier t = new Identifier();
1317      if (this.identifier == null)
1318        this.identifier = new ArrayList<Identifier>();
1319      this.identifier.add(t);
1320      return t;
1321    }
1322
1323    public PaymentReconciliation addIdentifier(Identifier t) { //3
1324      if (t == null)
1325        return this;
1326      if (this.identifier == null)
1327        this.identifier = new ArrayList<Identifier>();
1328      this.identifier.add(t);
1329      return this;
1330    }
1331
1332    /**
1333     * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist
1334     */
1335    public Identifier getIdentifierFirstRep() { 
1336      if (getIdentifier().isEmpty()) {
1337        addIdentifier();
1338      }
1339      return getIdentifier().get(0);
1340    }
1341
1342    /**
1343     * @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
1344     */
1345    public Enumeration<PaymentReconciliationStatus> getStatusElement() { 
1346      if (this.status == null)
1347        if (Configuration.errorOnAutoCreate())
1348          throw new Error("Attempt to auto-create PaymentReconciliation.status");
1349        else if (Configuration.doAutoCreate())
1350          this.status = new Enumeration<PaymentReconciliationStatus>(new PaymentReconciliationStatusEnumFactory()); // bb
1351      return this.status;
1352    }
1353
1354    public boolean hasStatusElement() { 
1355      return this.status != null && !this.status.isEmpty();
1356    }
1357
1358    public boolean hasStatus() { 
1359      return this.status != null && !this.status.isEmpty();
1360    }
1361
1362    /**
1363     * @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
1364     */
1365    public PaymentReconciliation setStatusElement(Enumeration<PaymentReconciliationStatus> value) { 
1366      this.status = value;
1367      return this;
1368    }
1369
1370    /**
1371     * @return The status of the resource instance.
1372     */
1373    public PaymentReconciliationStatus getStatus() { 
1374      return this.status == null ? null : this.status.getValue();
1375    }
1376
1377    /**
1378     * @param value The status of the resource instance.
1379     */
1380    public PaymentReconciliation setStatus(PaymentReconciliationStatus value) { 
1381        if (this.status == null)
1382          this.status = new Enumeration<PaymentReconciliationStatus>(new PaymentReconciliationStatusEnumFactory());
1383        this.status.setValue(value);
1384      return this;
1385    }
1386
1387    /**
1388     * @return {@link #period} (The period of time for which payments have been gathered into this bulk payment for settlement.)
1389     */
1390    public Period getPeriod() { 
1391      if (this.period == null)
1392        if (Configuration.errorOnAutoCreate())
1393          throw new Error("Attempt to auto-create PaymentReconciliation.period");
1394        else if (Configuration.doAutoCreate())
1395          this.period = new Period(); // cc
1396      return this.period;
1397    }
1398
1399    public boolean hasPeriod() { 
1400      return this.period != null && !this.period.isEmpty();
1401    }
1402
1403    /**
1404     * @param value {@link #period} (The period of time for which payments have been gathered into this bulk payment for settlement.)
1405     */
1406    public PaymentReconciliation setPeriod(Period value) { 
1407      this.period = value;
1408      return this;
1409    }
1410
1411    /**
1412     * @return {@link #created} (The date when the resource was created.). This is the underlying object with id, value and extensions. The accessor "getCreated" gives direct access to the value
1413     */
1414    public DateTimeType getCreatedElement() { 
1415      if (this.created == null)
1416        if (Configuration.errorOnAutoCreate())
1417          throw new Error("Attempt to auto-create PaymentReconciliation.created");
1418        else if (Configuration.doAutoCreate())
1419          this.created = new DateTimeType(); // bb
1420      return this.created;
1421    }
1422
1423    public boolean hasCreatedElement() { 
1424      return this.created != null && !this.created.isEmpty();
1425    }
1426
1427    public boolean hasCreated() { 
1428      return this.created != null && !this.created.isEmpty();
1429    }
1430
1431    /**
1432     * @param value {@link #created} (The date when the resource was created.). This is the underlying object with id, value and extensions. The accessor "getCreated" gives direct access to the value
1433     */
1434    public PaymentReconciliation setCreatedElement(DateTimeType value) { 
1435      this.created = value;
1436      return this;
1437    }
1438
1439    /**
1440     * @return The date when the resource was created.
1441     */
1442    public Date getCreated() { 
1443      return this.created == null ? null : this.created.getValue();
1444    }
1445
1446    /**
1447     * @param value The date when the resource was created.
1448     */
1449    public PaymentReconciliation setCreated(Date value) { 
1450        if (this.created == null)
1451          this.created = new DateTimeType();
1452        this.created.setValue(value);
1453      return this;
1454    }
1455
1456    /**
1457     * @return {@link #paymentIssuer} (The party who generated the payment.)
1458     */
1459    public Reference getPaymentIssuer() { 
1460      if (this.paymentIssuer == null)
1461        if (Configuration.errorOnAutoCreate())
1462          throw new Error("Attempt to auto-create PaymentReconciliation.paymentIssuer");
1463        else if (Configuration.doAutoCreate())
1464          this.paymentIssuer = new Reference(); // cc
1465      return this.paymentIssuer;
1466    }
1467
1468    public boolean hasPaymentIssuer() { 
1469      return this.paymentIssuer != null && !this.paymentIssuer.isEmpty();
1470    }
1471
1472    /**
1473     * @param value {@link #paymentIssuer} (The party who generated the payment.)
1474     */
1475    public PaymentReconciliation setPaymentIssuer(Reference value) { 
1476      this.paymentIssuer = value;
1477      return this;
1478    }
1479
1480    /**
1481     * @return {@link #paymentIssuer} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (The party who generated the payment.)
1482     */
1483    public Organization getPaymentIssuerTarget() { 
1484      if (this.paymentIssuerTarget == null)
1485        if (Configuration.errorOnAutoCreate())
1486          throw new Error("Attempt to auto-create PaymentReconciliation.paymentIssuer");
1487        else if (Configuration.doAutoCreate())
1488          this.paymentIssuerTarget = new Organization(); // aa
1489      return this.paymentIssuerTarget;
1490    }
1491
1492    /**
1493     * @param value {@link #paymentIssuer} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (The party who generated the payment.)
1494     */
1495    public PaymentReconciliation setPaymentIssuerTarget(Organization value) { 
1496      this.paymentIssuerTarget = value;
1497      return this;
1498    }
1499
1500    /**
1501     * @return {@link #request} (Original request resource reference.)
1502     */
1503    public Reference getRequest() { 
1504      if (this.request == null)
1505        if (Configuration.errorOnAutoCreate())
1506          throw new Error("Attempt to auto-create PaymentReconciliation.request");
1507        else if (Configuration.doAutoCreate())
1508          this.request = new Reference(); // cc
1509      return this.request;
1510    }
1511
1512    public boolean hasRequest() { 
1513      return this.request != null && !this.request.isEmpty();
1514    }
1515
1516    /**
1517     * @param value {@link #request} (Original request resource reference.)
1518     */
1519    public PaymentReconciliation setRequest(Reference value) { 
1520      this.request = value;
1521      return this;
1522    }
1523
1524    /**
1525     * @return {@link #request} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (Original request resource reference.)
1526     */
1527    public Task getRequestTarget() { 
1528      if (this.requestTarget == null)
1529        if (Configuration.errorOnAutoCreate())
1530          throw new Error("Attempt to auto-create PaymentReconciliation.request");
1531        else if (Configuration.doAutoCreate())
1532          this.requestTarget = new Task(); // aa
1533      return this.requestTarget;
1534    }
1535
1536    /**
1537     * @param value {@link #request} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (Original request resource reference.)
1538     */
1539    public PaymentReconciliation setRequestTarget(Task value) { 
1540      this.requestTarget = value;
1541      return this;
1542    }
1543
1544    /**
1545     * @return {@link #requestor} (The practitioner who is responsible for the services rendered to the patient.)
1546     */
1547    public Reference getRequestor() { 
1548      if (this.requestor == null)
1549        if (Configuration.errorOnAutoCreate())
1550          throw new Error("Attempt to auto-create PaymentReconciliation.requestor");
1551        else if (Configuration.doAutoCreate())
1552          this.requestor = new Reference(); // cc
1553      return this.requestor;
1554    }
1555
1556    public boolean hasRequestor() { 
1557      return this.requestor != null && !this.requestor.isEmpty();
1558    }
1559
1560    /**
1561     * @param value {@link #requestor} (The practitioner who is responsible for the services rendered to the patient.)
1562     */
1563    public PaymentReconciliation setRequestor(Reference value) { 
1564      this.requestor = value;
1565      return this;
1566    }
1567
1568    /**
1569     * @return {@link #requestor} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (The practitioner who is responsible for the services rendered to the patient.)
1570     */
1571    public Resource getRequestorTarget() { 
1572      return this.requestorTarget;
1573    }
1574
1575    /**
1576     * @param value {@link #requestor} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (The practitioner who is responsible for the services rendered to the patient.)
1577     */
1578    public PaymentReconciliation setRequestorTarget(Resource value) { 
1579      this.requestorTarget = value;
1580      return this;
1581    }
1582
1583    /**
1584     * @return {@link #outcome} (The outcome of a request for a reconciliation.). This is the underlying object with id, value and extensions. The accessor "getOutcome" gives direct access to the value
1585     */
1586    public Enumeration<RemittanceOutcome> getOutcomeElement() { 
1587      if (this.outcome == null)
1588        if (Configuration.errorOnAutoCreate())
1589          throw new Error("Attempt to auto-create PaymentReconciliation.outcome");
1590        else if (Configuration.doAutoCreate())
1591          this.outcome = new Enumeration<RemittanceOutcome>(new RemittanceOutcomeEnumFactory()); // bb
1592      return this.outcome;
1593    }
1594
1595    public boolean hasOutcomeElement() { 
1596      return this.outcome != null && !this.outcome.isEmpty();
1597    }
1598
1599    public boolean hasOutcome() { 
1600      return this.outcome != null && !this.outcome.isEmpty();
1601    }
1602
1603    /**
1604     * @param value {@link #outcome} (The outcome of a request for a reconciliation.). This is the underlying object with id, value and extensions. The accessor "getOutcome" gives direct access to the value
1605     */
1606    public PaymentReconciliation setOutcomeElement(Enumeration<RemittanceOutcome> value) { 
1607      this.outcome = value;
1608      return this;
1609    }
1610
1611    /**
1612     * @return The outcome of a request for a reconciliation.
1613     */
1614    public RemittanceOutcome getOutcome() { 
1615      return this.outcome == null ? null : this.outcome.getValue();
1616    }
1617
1618    /**
1619     * @param value The outcome of a request for a reconciliation.
1620     */
1621    public PaymentReconciliation setOutcome(RemittanceOutcome value) { 
1622      if (value == null)
1623        this.outcome = null;
1624      else {
1625        if (this.outcome == null)
1626          this.outcome = new Enumeration<RemittanceOutcome>(new RemittanceOutcomeEnumFactory());
1627        this.outcome.setValue(value);
1628      }
1629      return this;
1630    }
1631
1632    /**
1633     * @return {@link #disposition} (A human readable description of the status of the request for the reconciliation.). This is the underlying object with id, value and extensions. The accessor "getDisposition" gives direct access to the value
1634     */
1635    public StringType getDispositionElement() { 
1636      if (this.disposition == null)
1637        if (Configuration.errorOnAutoCreate())
1638          throw new Error("Attempt to auto-create PaymentReconciliation.disposition");
1639        else if (Configuration.doAutoCreate())
1640          this.disposition = new StringType(); // bb
1641      return this.disposition;
1642    }
1643
1644    public boolean hasDispositionElement() { 
1645      return this.disposition != null && !this.disposition.isEmpty();
1646    }
1647
1648    public boolean hasDisposition() { 
1649      return this.disposition != null && !this.disposition.isEmpty();
1650    }
1651
1652    /**
1653     * @param value {@link #disposition} (A human readable description of the status of the request for the reconciliation.). This is the underlying object with id, value and extensions. The accessor "getDisposition" gives direct access to the value
1654     */
1655    public PaymentReconciliation setDispositionElement(StringType value) { 
1656      this.disposition = value;
1657      return this;
1658    }
1659
1660    /**
1661     * @return A human readable description of the status of the request for the reconciliation.
1662     */
1663    public String getDisposition() { 
1664      return this.disposition == null ? null : this.disposition.getValue();
1665    }
1666
1667    /**
1668     * @param value A human readable description of the status of the request for the reconciliation.
1669     */
1670    public PaymentReconciliation setDisposition(String value) { 
1671      if (Utilities.noString(value))
1672        this.disposition = null;
1673      else {
1674        if (this.disposition == null)
1675          this.disposition = new StringType();
1676        this.disposition.setValue(value);
1677      }
1678      return this;
1679    }
1680
1681    /**
1682     * @return {@link #paymentDate} (The date of payment as indicated on the financial instrument.). This is the underlying object with id, value and extensions. The accessor "getPaymentDate" gives direct access to the value
1683     */
1684    public DateType getPaymentDateElement() { 
1685      if (this.paymentDate == null)
1686        if (Configuration.errorOnAutoCreate())
1687          throw new Error("Attempt to auto-create PaymentReconciliation.paymentDate");
1688        else if (Configuration.doAutoCreate())
1689          this.paymentDate = new DateType(); // bb
1690      return this.paymentDate;
1691    }
1692
1693    public boolean hasPaymentDateElement() { 
1694      return this.paymentDate != null && !this.paymentDate.isEmpty();
1695    }
1696
1697    public boolean hasPaymentDate() { 
1698      return this.paymentDate != null && !this.paymentDate.isEmpty();
1699    }
1700
1701    /**
1702     * @param value {@link #paymentDate} (The date of payment as indicated on the financial instrument.). This is the underlying object with id, value and extensions. The accessor "getPaymentDate" gives direct access to the value
1703     */
1704    public PaymentReconciliation setPaymentDateElement(DateType value) { 
1705      this.paymentDate = value;
1706      return this;
1707    }
1708
1709    /**
1710     * @return The date of payment as indicated on the financial instrument.
1711     */
1712    public Date getPaymentDate() { 
1713      return this.paymentDate == null ? null : this.paymentDate.getValue();
1714    }
1715
1716    /**
1717     * @param value The date of payment as indicated on the financial instrument.
1718     */
1719    public PaymentReconciliation setPaymentDate(Date value) { 
1720        if (this.paymentDate == null)
1721          this.paymentDate = new DateType();
1722        this.paymentDate.setValue(value);
1723      return this;
1724    }
1725
1726    /**
1727     * @return {@link #paymentAmount} (Total payment amount as indicated on the financial instrument.)
1728     */
1729    public Money getPaymentAmount() { 
1730      if (this.paymentAmount == null)
1731        if (Configuration.errorOnAutoCreate())
1732          throw new Error("Attempt to auto-create PaymentReconciliation.paymentAmount");
1733        else if (Configuration.doAutoCreate())
1734          this.paymentAmount = new Money(); // cc
1735      return this.paymentAmount;
1736    }
1737
1738    public boolean hasPaymentAmount() { 
1739      return this.paymentAmount != null && !this.paymentAmount.isEmpty();
1740    }
1741
1742    /**
1743     * @param value {@link #paymentAmount} (Total payment amount as indicated on the financial instrument.)
1744     */
1745    public PaymentReconciliation setPaymentAmount(Money value) { 
1746      this.paymentAmount = value;
1747      return this;
1748    }
1749
1750    /**
1751     * @return {@link #paymentIdentifier} (Issuer's unique identifier for the payment instrument.)
1752     */
1753    public Identifier getPaymentIdentifier() { 
1754      if (this.paymentIdentifier == null)
1755        if (Configuration.errorOnAutoCreate())
1756          throw new Error("Attempt to auto-create PaymentReconciliation.paymentIdentifier");
1757        else if (Configuration.doAutoCreate())
1758          this.paymentIdentifier = new Identifier(); // cc
1759      return this.paymentIdentifier;
1760    }
1761
1762    public boolean hasPaymentIdentifier() { 
1763      return this.paymentIdentifier != null && !this.paymentIdentifier.isEmpty();
1764    }
1765
1766    /**
1767     * @param value {@link #paymentIdentifier} (Issuer's unique identifier for the payment instrument.)
1768     */
1769    public PaymentReconciliation setPaymentIdentifier(Identifier value) { 
1770      this.paymentIdentifier = value;
1771      return this;
1772    }
1773
1774    /**
1775     * @return {@link #detail} (Distribution of the payment amount for a previously acknowledged payable.)
1776     */
1777    public List<DetailsComponent> getDetail() { 
1778      if (this.detail == null)
1779        this.detail = new ArrayList<DetailsComponent>();
1780      return this.detail;
1781    }
1782
1783    /**
1784     * @return Returns a reference to <code>this</code> for easy method chaining
1785     */
1786    public PaymentReconciliation setDetail(List<DetailsComponent> theDetail) { 
1787      this.detail = theDetail;
1788      return this;
1789    }
1790
1791    public boolean hasDetail() { 
1792      if (this.detail == null)
1793        return false;
1794      for (DetailsComponent item : this.detail)
1795        if (!item.isEmpty())
1796          return true;
1797      return false;
1798    }
1799
1800    public DetailsComponent addDetail() { //3
1801      DetailsComponent t = new DetailsComponent();
1802      if (this.detail == null)
1803        this.detail = new ArrayList<DetailsComponent>();
1804      this.detail.add(t);
1805      return t;
1806    }
1807
1808    public PaymentReconciliation addDetail(DetailsComponent t) { //3
1809      if (t == null)
1810        return this;
1811      if (this.detail == null)
1812        this.detail = new ArrayList<DetailsComponent>();
1813      this.detail.add(t);
1814      return this;
1815    }
1816
1817    /**
1818     * @return The first repetition of repeating field {@link #detail}, creating it if it does not already exist
1819     */
1820    public DetailsComponent getDetailFirstRep() { 
1821      if (getDetail().isEmpty()) {
1822        addDetail();
1823      }
1824      return getDetail().get(0);
1825    }
1826
1827    /**
1828     * @return {@link #formCode} (A code for the form to be used for printing the content.)
1829     */
1830    public CodeableConcept getFormCode() { 
1831      if (this.formCode == null)
1832        if (Configuration.errorOnAutoCreate())
1833          throw new Error("Attempt to auto-create PaymentReconciliation.formCode");
1834        else if (Configuration.doAutoCreate())
1835          this.formCode = new CodeableConcept(); // cc
1836      return this.formCode;
1837    }
1838
1839    public boolean hasFormCode() { 
1840      return this.formCode != null && !this.formCode.isEmpty();
1841    }
1842
1843    /**
1844     * @param value {@link #formCode} (A code for the form to be used for printing the content.)
1845     */
1846    public PaymentReconciliation setFormCode(CodeableConcept value) { 
1847      this.formCode = value;
1848      return this;
1849    }
1850
1851    /**
1852     * @return {@link #processNote} (A note that describes or explains the processing in a human readable form.)
1853     */
1854    public List<NotesComponent> getProcessNote() { 
1855      if (this.processNote == null)
1856        this.processNote = new ArrayList<NotesComponent>();
1857      return this.processNote;
1858    }
1859
1860    /**
1861     * @return Returns a reference to <code>this</code> for easy method chaining
1862     */
1863    public PaymentReconciliation setProcessNote(List<NotesComponent> theProcessNote) { 
1864      this.processNote = theProcessNote;
1865      return this;
1866    }
1867
1868    public boolean hasProcessNote() { 
1869      if (this.processNote == null)
1870        return false;
1871      for (NotesComponent item : this.processNote)
1872        if (!item.isEmpty())
1873          return true;
1874      return false;
1875    }
1876
1877    public NotesComponent addProcessNote() { //3
1878      NotesComponent t = new NotesComponent();
1879      if (this.processNote == null)
1880        this.processNote = new ArrayList<NotesComponent>();
1881      this.processNote.add(t);
1882      return t;
1883    }
1884
1885    public PaymentReconciliation addProcessNote(NotesComponent t) { //3
1886      if (t == null)
1887        return this;
1888      if (this.processNote == null)
1889        this.processNote = new ArrayList<NotesComponent>();
1890      this.processNote.add(t);
1891      return this;
1892    }
1893
1894    /**
1895     * @return The first repetition of repeating field {@link #processNote}, creating it if it does not already exist
1896     */
1897    public NotesComponent getProcessNoteFirstRep() { 
1898      if (getProcessNote().isEmpty()) {
1899        addProcessNote();
1900      }
1901      return getProcessNote().get(0);
1902    }
1903
1904      protected void listChildren(List<Property> children) {
1905        super.listChildren(children);
1906        children.add(new Property("identifier", "Identifier", "A unique identifier assigned to this payment reconciliation.", 0, java.lang.Integer.MAX_VALUE, identifier));
1907        children.add(new Property("status", "code", "The status of the resource instance.", 0, 1, status));
1908        children.add(new Property("period", "Period", "The period of time for which payments have been gathered into this bulk payment for settlement.", 0, 1, period));
1909        children.add(new Property("created", "dateTime", "The date when the resource was created.", 0, 1, created));
1910        children.add(new Property("paymentIssuer", "Reference(Organization)", "The party who generated the payment.", 0, 1, paymentIssuer));
1911        children.add(new Property("request", "Reference(Task)", "Original request resource reference.", 0, 1, request));
1912        children.add(new Property("requestor", "Reference(Practitioner|PractitionerRole|Organization)", "The practitioner who is responsible for the services rendered to the patient.", 0, 1, requestor));
1913        children.add(new Property("outcome", "code", "The outcome of a request for a reconciliation.", 0, 1, outcome));
1914        children.add(new Property("disposition", "string", "A human readable description of the status of the request for the reconciliation.", 0, 1, disposition));
1915        children.add(new Property("paymentDate", "date", "The date of payment as indicated on the financial instrument.", 0, 1, paymentDate));
1916        children.add(new Property("paymentAmount", "Money", "Total payment amount as indicated on the financial instrument.", 0, 1, paymentAmount));
1917        children.add(new Property("paymentIdentifier", "Identifier", "Issuer's unique identifier for the payment instrument.", 0, 1, paymentIdentifier));
1918        children.add(new Property("detail", "", "Distribution of the payment amount for a previously acknowledged payable.", 0, java.lang.Integer.MAX_VALUE, detail));
1919        children.add(new Property("formCode", "CodeableConcept", "A code for the form to be used for printing the content.", 0, 1, formCode));
1920        children.add(new Property("processNote", "", "A note that describes or explains the processing in a human readable form.", 0, java.lang.Integer.MAX_VALUE, processNote));
1921      }
1922
1923      @Override
1924      public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
1925        switch (_hash) {
1926        case -1618432855: /*identifier*/  return new Property("identifier", "Identifier", "A unique identifier assigned to this payment reconciliation.", 0, java.lang.Integer.MAX_VALUE, identifier);
1927        case -892481550: /*status*/  return new Property("status", "code", "The status of the resource instance.", 0, 1, status);
1928        case -991726143: /*period*/  return new Property("period", "Period", "The period of time for which payments have been gathered into this bulk payment for settlement.", 0, 1, period);
1929        case 1028554472: /*created*/  return new Property("created", "dateTime", "The date when the resource was created.", 0, 1, created);
1930        case 1144026207: /*paymentIssuer*/  return new Property("paymentIssuer", "Reference(Organization)", "The party who generated the payment.", 0, 1, paymentIssuer);
1931        case 1095692943: /*request*/  return new Property("request", "Reference(Task)", "Original request resource reference.", 0, 1, request);
1932        case 693934258: /*requestor*/  return new Property("requestor", "Reference(Practitioner|PractitionerRole|Organization)", "The practitioner who is responsible for the services rendered to the patient.", 0, 1, requestor);
1933        case -1106507950: /*outcome*/  return new Property("outcome", "code", "The outcome of a request for a reconciliation.", 0, 1, outcome);
1934        case 583380919: /*disposition*/  return new Property("disposition", "string", "A human readable description of the status of the request for the reconciliation.", 0, 1, disposition);
1935        case -1540873516: /*paymentDate*/  return new Property("paymentDate", "date", "The date of payment as indicated on the financial instrument.", 0, 1, paymentDate);
1936        case 909332990: /*paymentAmount*/  return new Property("paymentAmount", "Money", "Total payment amount as indicated on the financial instrument.", 0, 1, paymentAmount);
1937        case 1555852111: /*paymentIdentifier*/  return new Property("paymentIdentifier", "Identifier", "Issuer's unique identifier for the payment instrument.", 0, 1, paymentIdentifier);
1938        case -1335224239: /*detail*/  return new Property("detail", "", "Distribution of the payment amount for a previously acknowledged payable.", 0, java.lang.Integer.MAX_VALUE, detail);
1939        case 473181393: /*formCode*/  return new Property("formCode", "CodeableConcept", "A code for the form to be used for printing the content.", 0, 1, formCode);
1940        case 202339073: /*processNote*/  return new Property("processNote", "", "A note that describes or explains the processing in a human readable form.", 0, java.lang.Integer.MAX_VALUE, processNote);
1941        default: return super.getNamedProperty(_hash, _name, _checkValid);
1942        }
1943
1944      }
1945
1946      @Override
1947      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
1948        switch (hash) {
1949        case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier
1950        case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<PaymentReconciliationStatus>
1951        case -991726143: /*period*/ return this.period == null ? new Base[0] : new Base[] {this.period}; // Period
1952        case 1028554472: /*created*/ return this.created == null ? new Base[0] : new Base[] {this.created}; // DateTimeType
1953        case 1144026207: /*paymentIssuer*/ return this.paymentIssuer == null ? new Base[0] : new Base[] {this.paymentIssuer}; // Reference
1954        case 1095692943: /*request*/ return this.request == null ? new Base[0] : new Base[] {this.request}; // Reference
1955        case 693934258: /*requestor*/ return this.requestor == null ? new Base[0] : new Base[] {this.requestor}; // Reference
1956        case -1106507950: /*outcome*/ return this.outcome == null ? new Base[0] : new Base[] {this.outcome}; // Enumeration<RemittanceOutcome>
1957        case 583380919: /*disposition*/ return this.disposition == null ? new Base[0] : new Base[] {this.disposition}; // StringType
1958        case -1540873516: /*paymentDate*/ return this.paymentDate == null ? new Base[0] : new Base[] {this.paymentDate}; // DateType
1959        case 909332990: /*paymentAmount*/ return this.paymentAmount == null ? new Base[0] : new Base[] {this.paymentAmount}; // Money
1960        case 1555852111: /*paymentIdentifier*/ return this.paymentIdentifier == null ? new Base[0] : new Base[] {this.paymentIdentifier}; // Identifier
1961        case -1335224239: /*detail*/ return this.detail == null ? new Base[0] : this.detail.toArray(new Base[this.detail.size()]); // DetailsComponent
1962        case 473181393: /*formCode*/ return this.formCode == null ? new Base[0] : new Base[] {this.formCode}; // CodeableConcept
1963        case 202339073: /*processNote*/ return this.processNote == null ? new Base[0] : this.processNote.toArray(new Base[this.processNote.size()]); // NotesComponent
1964        default: return super.getProperty(hash, name, checkValid);
1965        }
1966
1967      }
1968
1969      @Override
1970      public Base setProperty(int hash, String name, Base value) throws FHIRException {
1971        switch (hash) {
1972        case -1618432855: // identifier
1973          this.getIdentifier().add(castToIdentifier(value)); // Identifier
1974          return value;
1975        case -892481550: // status
1976          value = new PaymentReconciliationStatusEnumFactory().fromType(castToCode(value));
1977          this.status = (Enumeration) value; // Enumeration<PaymentReconciliationStatus>
1978          return value;
1979        case -991726143: // period
1980          this.period = castToPeriod(value); // Period
1981          return value;
1982        case 1028554472: // created
1983          this.created = castToDateTime(value); // DateTimeType
1984          return value;
1985        case 1144026207: // paymentIssuer
1986          this.paymentIssuer = castToReference(value); // Reference
1987          return value;
1988        case 1095692943: // request
1989          this.request = castToReference(value); // Reference
1990          return value;
1991        case 693934258: // requestor
1992          this.requestor = castToReference(value); // Reference
1993          return value;
1994        case -1106507950: // outcome
1995          value = new RemittanceOutcomeEnumFactory().fromType(castToCode(value));
1996          this.outcome = (Enumeration) value; // Enumeration<RemittanceOutcome>
1997          return value;
1998        case 583380919: // disposition
1999          this.disposition = castToString(value); // StringType
2000          return value;
2001        case -1540873516: // paymentDate
2002          this.paymentDate = castToDate(value); // DateType
2003          return value;
2004        case 909332990: // paymentAmount
2005          this.paymentAmount = castToMoney(value); // Money
2006          return value;
2007        case 1555852111: // paymentIdentifier
2008          this.paymentIdentifier = castToIdentifier(value); // Identifier
2009          return value;
2010        case -1335224239: // detail
2011          this.getDetail().add((DetailsComponent) value); // DetailsComponent
2012          return value;
2013        case 473181393: // formCode
2014          this.formCode = castToCodeableConcept(value); // CodeableConcept
2015          return value;
2016        case 202339073: // processNote
2017          this.getProcessNote().add((NotesComponent) value); // NotesComponent
2018          return value;
2019        default: return super.setProperty(hash, name, value);
2020        }
2021
2022      }
2023
2024      @Override
2025      public Base setProperty(String name, Base value) throws FHIRException {
2026        if (name.equals("identifier")) {
2027          this.getIdentifier().add(castToIdentifier(value));
2028        } else if (name.equals("status")) {
2029          value = new PaymentReconciliationStatusEnumFactory().fromType(castToCode(value));
2030          this.status = (Enumeration) value; // Enumeration<PaymentReconciliationStatus>
2031        } else if (name.equals("period")) {
2032          this.period = castToPeriod(value); // Period
2033        } else if (name.equals("created")) {
2034          this.created = castToDateTime(value); // DateTimeType
2035        } else if (name.equals("paymentIssuer")) {
2036          this.paymentIssuer = castToReference(value); // Reference
2037        } else if (name.equals("request")) {
2038          this.request = castToReference(value); // Reference
2039        } else if (name.equals("requestor")) {
2040          this.requestor = castToReference(value); // Reference
2041        } else if (name.equals("outcome")) {
2042          value = new RemittanceOutcomeEnumFactory().fromType(castToCode(value));
2043          this.outcome = (Enumeration) value; // Enumeration<RemittanceOutcome>
2044        } else if (name.equals("disposition")) {
2045          this.disposition = castToString(value); // StringType
2046        } else if (name.equals("paymentDate")) {
2047          this.paymentDate = castToDate(value); // DateType
2048        } else if (name.equals("paymentAmount")) {
2049          this.paymentAmount = castToMoney(value); // Money
2050        } else if (name.equals("paymentIdentifier")) {
2051          this.paymentIdentifier = castToIdentifier(value); // Identifier
2052        } else if (name.equals("detail")) {
2053          this.getDetail().add((DetailsComponent) value);
2054        } else if (name.equals("formCode")) {
2055          this.formCode = castToCodeableConcept(value); // CodeableConcept
2056        } else if (name.equals("processNote")) {
2057          this.getProcessNote().add((NotesComponent) value);
2058        } else
2059          return super.setProperty(name, value);
2060        return value;
2061      }
2062
2063      @Override
2064      public Base makeProperty(int hash, String name) throws FHIRException {
2065        switch (hash) {
2066        case -1618432855:  return addIdentifier(); 
2067        case -892481550:  return getStatusElement();
2068        case -991726143:  return getPeriod(); 
2069        case 1028554472:  return getCreatedElement();
2070        case 1144026207:  return getPaymentIssuer(); 
2071        case 1095692943:  return getRequest(); 
2072        case 693934258:  return getRequestor(); 
2073        case -1106507950:  return getOutcomeElement();
2074        case 583380919:  return getDispositionElement();
2075        case -1540873516:  return getPaymentDateElement();
2076        case 909332990:  return getPaymentAmount(); 
2077        case 1555852111:  return getPaymentIdentifier(); 
2078        case -1335224239:  return addDetail(); 
2079        case 473181393:  return getFormCode(); 
2080        case 202339073:  return addProcessNote(); 
2081        default: return super.makeProperty(hash, name);
2082        }
2083
2084      }
2085
2086      @Override
2087      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
2088        switch (hash) {
2089        case -1618432855: /*identifier*/ return new String[] {"Identifier"};
2090        case -892481550: /*status*/ return new String[] {"code"};
2091        case -991726143: /*period*/ return new String[] {"Period"};
2092        case 1028554472: /*created*/ return new String[] {"dateTime"};
2093        case 1144026207: /*paymentIssuer*/ return new String[] {"Reference"};
2094        case 1095692943: /*request*/ return new String[] {"Reference"};
2095        case 693934258: /*requestor*/ return new String[] {"Reference"};
2096        case -1106507950: /*outcome*/ return new String[] {"code"};
2097        case 583380919: /*disposition*/ return new String[] {"string"};
2098        case -1540873516: /*paymentDate*/ return new String[] {"date"};
2099        case 909332990: /*paymentAmount*/ return new String[] {"Money"};
2100        case 1555852111: /*paymentIdentifier*/ return new String[] {"Identifier"};
2101        case -1335224239: /*detail*/ return new String[] {};
2102        case 473181393: /*formCode*/ return new String[] {"CodeableConcept"};
2103        case 202339073: /*processNote*/ return new String[] {};
2104        default: return super.getTypesForProperty(hash, name);
2105        }
2106
2107      }
2108
2109      @Override
2110      public Base addChild(String name) throws FHIRException {
2111        if (name.equals("identifier")) {
2112          return addIdentifier();
2113        }
2114        else if (name.equals("status")) {
2115          throw new FHIRException("Cannot call addChild on a primitive type PaymentReconciliation.status");
2116        }
2117        else if (name.equals("period")) {
2118          this.period = new Period();
2119          return this.period;
2120        }
2121        else if (name.equals("created")) {
2122          throw new FHIRException("Cannot call addChild on a primitive type PaymentReconciliation.created");
2123        }
2124        else if (name.equals("paymentIssuer")) {
2125          this.paymentIssuer = new Reference();
2126          return this.paymentIssuer;
2127        }
2128        else if (name.equals("request")) {
2129          this.request = new Reference();
2130          return this.request;
2131        }
2132        else if (name.equals("requestor")) {
2133          this.requestor = new Reference();
2134          return this.requestor;
2135        }
2136        else if (name.equals("outcome")) {
2137          throw new FHIRException("Cannot call addChild on a primitive type PaymentReconciliation.outcome");
2138        }
2139        else if (name.equals("disposition")) {
2140          throw new FHIRException("Cannot call addChild on a primitive type PaymentReconciliation.disposition");
2141        }
2142        else if (name.equals("paymentDate")) {
2143          throw new FHIRException("Cannot call addChild on a primitive type PaymentReconciliation.paymentDate");
2144        }
2145        else if (name.equals("paymentAmount")) {
2146          this.paymentAmount = new Money();
2147          return this.paymentAmount;
2148        }
2149        else if (name.equals("paymentIdentifier")) {
2150          this.paymentIdentifier = new Identifier();
2151          return this.paymentIdentifier;
2152        }
2153        else if (name.equals("detail")) {
2154          return addDetail();
2155        }
2156        else if (name.equals("formCode")) {
2157          this.formCode = new CodeableConcept();
2158          return this.formCode;
2159        }
2160        else if (name.equals("processNote")) {
2161          return addProcessNote();
2162        }
2163        else
2164          return super.addChild(name);
2165      }
2166
2167  public String fhirType() {
2168    return "PaymentReconciliation";
2169
2170  }
2171
2172      public PaymentReconciliation copy() {
2173        PaymentReconciliation dst = new PaymentReconciliation();
2174        copyValues(dst);
2175        return dst;
2176      }
2177
2178      public void copyValues(PaymentReconciliation dst) {
2179        super.copyValues(dst);
2180        if (identifier != null) {
2181          dst.identifier = new ArrayList<Identifier>();
2182          for (Identifier i : identifier)
2183            dst.identifier.add(i.copy());
2184        };
2185        dst.status = status == null ? null : status.copy();
2186        dst.period = period == null ? null : period.copy();
2187        dst.created = created == null ? null : created.copy();
2188        dst.paymentIssuer = paymentIssuer == null ? null : paymentIssuer.copy();
2189        dst.request = request == null ? null : request.copy();
2190        dst.requestor = requestor == null ? null : requestor.copy();
2191        dst.outcome = outcome == null ? null : outcome.copy();
2192        dst.disposition = disposition == null ? null : disposition.copy();
2193        dst.paymentDate = paymentDate == null ? null : paymentDate.copy();
2194        dst.paymentAmount = paymentAmount == null ? null : paymentAmount.copy();
2195        dst.paymentIdentifier = paymentIdentifier == null ? null : paymentIdentifier.copy();
2196        if (detail != null) {
2197          dst.detail = new ArrayList<DetailsComponent>();
2198          for (DetailsComponent i : detail)
2199            dst.detail.add(i.copy());
2200        };
2201        dst.formCode = formCode == null ? null : formCode.copy();
2202        if (processNote != null) {
2203          dst.processNote = new ArrayList<NotesComponent>();
2204          for (NotesComponent i : processNote)
2205            dst.processNote.add(i.copy());
2206        };
2207      }
2208
2209      protected PaymentReconciliation typedCopy() {
2210        return copy();
2211      }
2212
2213      @Override
2214      public boolean equalsDeep(Base other_) {
2215        if (!super.equalsDeep(other_))
2216          return false;
2217        if (!(other_ instanceof PaymentReconciliation))
2218          return false;
2219        PaymentReconciliation o = (PaymentReconciliation) other_;
2220        return compareDeep(identifier, o.identifier, true) && compareDeep(status, o.status, true) && compareDeep(period, o.period, true)
2221           && compareDeep(created, o.created, true) && compareDeep(paymentIssuer, o.paymentIssuer, true) && compareDeep(request, o.request, true)
2222           && compareDeep(requestor, o.requestor, true) && compareDeep(outcome, o.outcome, true) && compareDeep(disposition, o.disposition, true)
2223           && compareDeep(paymentDate, o.paymentDate, true) && compareDeep(paymentAmount, o.paymentAmount, true)
2224           && compareDeep(paymentIdentifier, o.paymentIdentifier, true) && compareDeep(detail, o.detail, true)
2225           && compareDeep(formCode, o.formCode, true) && compareDeep(processNote, o.processNote, true);
2226      }
2227
2228      @Override
2229      public boolean equalsShallow(Base other_) {
2230        if (!super.equalsShallow(other_))
2231          return false;
2232        if (!(other_ instanceof PaymentReconciliation))
2233          return false;
2234        PaymentReconciliation o = (PaymentReconciliation) other_;
2235        return compareValues(status, o.status, true) && compareValues(created, o.created, true) && compareValues(outcome, o.outcome, true)
2236           && compareValues(disposition, o.disposition, true) && compareValues(paymentDate, o.paymentDate, true)
2237          ;
2238      }
2239
2240      public boolean isEmpty() {
2241        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, status, period
2242          , created, paymentIssuer, request, requestor, outcome, disposition, paymentDate
2243          , paymentAmount, paymentIdentifier, detail, formCode, processNote);
2244      }
2245
2246  @Override
2247  public ResourceType getResourceType() {
2248    return ResourceType.PaymentReconciliation;
2249   }
2250
2251 /**
2252   * Search parameter: <b>identifier</b>
2253   * <p>
2254   * Description: <b>The business identifier of the ExplanationOfBenefit</b><br>
2255   * Type: <b>token</b><br>
2256   * Path: <b>PaymentReconciliation.identifier</b><br>
2257   * </p>
2258   */
2259  @SearchParamDefinition(name="identifier", path="PaymentReconciliation.identifier", description="The business identifier of the ExplanationOfBenefit", type="token" )
2260  public static final String SP_IDENTIFIER = "identifier";
2261 /**
2262   * <b>Fluent Client</b> search parameter constant for <b>identifier</b>
2263   * <p>
2264   * Description: <b>The business identifier of the ExplanationOfBenefit</b><br>
2265   * Type: <b>token</b><br>
2266   * Path: <b>PaymentReconciliation.identifier</b><br>
2267   * </p>
2268   */
2269  public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER);
2270
2271 /**
2272   * Search parameter: <b>request</b>
2273   * <p>
2274   * Description: <b>The reference to the claim</b><br>
2275   * Type: <b>reference</b><br>
2276   * Path: <b>PaymentReconciliation.request</b><br>
2277   * </p>
2278   */
2279  @SearchParamDefinition(name="request", path="PaymentReconciliation.request", description="The reference to the claim", type="reference", target={Task.class } )
2280  public static final String SP_REQUEST = "request";
2281 /**
2282   * <b>Fluent Client</b> search parameter constant for <b>request</b>
2283   * <p>
2284   * Description: <b>The reference to the claim</b><br>
2285   * Type: <b>reference</b><br>
2286   * Path: <b>PaymentReconciliation.request</b><br>
2287   * </p>
2288   */
2289  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam REQUEST = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_REQUEST);
2290
2291/**
2292   * Constant for fluent queries to be used to add include statements. Specifies
2293   * the path value of "<b>PaymentReconciliation:request</b>".
2294   */
2295  public static final ca.uhn.fhir.model.api.Include INCLUDE_REQUEST = new ca.uhn.fhir.model.api.Include("PaymentReconciliation:request").toLocked();
2296
2297 /**
2298   * Search parameter: <b>disposition</b>
2299   * <p>
2300   * Description: <b>The contents of the disposition message</b><br>
2301   * Type: <b>string</b><br>
2302   * Path: <b>PaymentReconciliation.disposition</b><br>
2303   * </p>
2304   */
2305  @SearchParamDefinition(name="disposition", path="PaymentReconciliation.disposition", description="The contents of the disposition message", type="string" )
2306  public static final String SP_DISPOSITION = "disposition";
2307 /**
2308   * <b>Fluent Client</b> search parameter constant for <b>disposition</b>
2309   * <p>
2310   * Description: <b>The contents of the disposition message</b><br>
2311   * Type: <b>string</b><br>
2312   * Path: <b>PaymentReconciliation.disposition</b><br>
2313   * </p>
2314   */
2315  public static final ca.uhn.fhir.rest.gclient.StringClientParam DISPOSITION = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_DISPOSITION);
2316
2317 /**
2318   * Search parameter: <b>created</b>
2319   * <p>
2320   * Description: <b>The creation date</b><br>
2321   * Type: <b>date</b><br>
2322   * Path: <b>PaymentReconciliation.created</b><br>
2323   * </p>
2324   */
2325  @SearchParamDefinition(name="created", path="PaymentReconciliation.created", description="The creation date", type="date" )
2326  public static final String SP_CREATED = "created";
2327 /**
2328   * <b>Fluent Client</b> search parameter constant for <b>created</b>
2329   * <p>
2330   * Description: <b>The creation date</b><br>
2331   * Type: <b>date</b><br>
2332   * Path: <b>PaymentReconciliation.created</b><br>
2333   * </p>
2334   */
2335  public static final ca.uhn.fhir.rest.gclient.DateClientParam CREATED = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_CREATED);
2336
2337 /**
2338   * Search parameter: <b>payment-issuer</b>
2339   * <p>
2340   * Description: <b>The organization which generated this resource</b><br>
2341   * Type: <b>reference</b><br>
2342   * Path: <b>PaymentReconciliation.paymentIssuer</b><br>
2343   * </p>
2344   */
2345  @SearchParamDefinition(name="payment-issuer", path="PaymentReconciliation.paymentIssuer", description="The organization which generated this resource", type="reference", target={Organization.class } )
2346  public static final String SP_PAYMENT_ISSUER = "payment-issuer";
2347 /**
2348   * <b>Fluent Client</b> search parameter constant for <b>payment-issuer</b>
2349   * <p>
2350   * Description: <b>The organization which generated this resource</b><br>
2351   * Type: <b>reference</b><br>
2352   * Path: <b>PaymentReconciliation.paymentIssuer</b><br>
2353   * </p>
2354   */
2355  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PAYMENT_ISSUER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PAYMENT_ISSUER);
2356
2357/**
2358   * Constant for fluent queries to be used to add include statements. Specifies
2359   * the path value of "<b>PaymentReconciliation:payment-issuer</b>".
2360   */
2361  public static final ca.uhn.fhir.model.api.Include INCLUDE_PAYMENT_ISSUER = new ca.uhn.fhir.model.api.Include("PaymentReconciliation:payment-issuer").toLocked();
2362
2363 /**
2364   * Search parameter: <b>outcome</b>
2365   * <p>
2366   * Description: <b>The processing outcome</b><br>
2367   * Type: <b>token</b><br>
2368   * Path: <b>PaymentReconciliation.outcome</b><br>
2369   * </p>
2370   */
2371  @SearchParamDefinition(name="outcome", path="PaymentReconciliation.outcome", description="The processing outcome", type="token" )
2372  public static final String SP_OUTCOME = "outcome";
2373 /**
2374   * <b>Fluent Client</b> search parameter constant for <b>outcome</b>
2375   * <p>
2376   * Description: <b>The processing outcome</b><br>
2377   * Type: <b>token</b><br>
2378   * Path: <b>PaymentReconciliation.outcome</b><br>
2379   * </p>
2380   */
2381  public static final ca.uhn.fhir.rest.gclient.TokenClientParam OUTCOME = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_OUTCOME);
2382
2383 /**
2384   * Search parameter: <b>requestor</b>
2385   * <p>
2386   * Description: <b>The reference to the provider who submitted the claim</b><br>
2387   * Type: <b>reference</b><br>
2388   * Path: <b>PaymentReconciliation.requestor</b><br>
2389   * </p>
2390   */
2391  @SearchParamDefinition(name="requestor", path="PaymentReconciliation.requestor", description="The reference to the provider who submitted the claim", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Practitioner") }, target={Organization.class, Practitioner.class, PractitionerRole.class } )
2392  public static final String SP_REQUESTOR = "requestor";
2393 /**
2394   * <b>Fluent Client</b> search parameter constant for <b>requestor</b>
2395   * <p>
2396   * Description: <b>The reference to the provider who submitted the claim</b><br>
2397   * Type: <b>reference</b><br>
2398   * Path: <b>PaymentReconciliation.requestor</b><br>
2399   * </p>
2400   */
2401  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam REQUESTOR = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_REQUESTOR);
2402
2403/**
2404   * Constant for fluent queries to be used to add include statements. Specifies
2405   * the path value of "<b>PaymentReconciliation:requestor</b>".
2406   */
2407  public static final ca.uhn.fhir.model.api.Include INCLUDE_REQUESTOR = new ca.uhn.fhir.model.api.Include("PaymentReconciliation:requestor").toLocked();
2408
2409 /**
2410   * Search parameter: <b>status</b>
2411   * <p>
2412   * Description: <b>The status of the payment reconciliation</b><br>
2413   * Type: <b>token</b><br>
2414   * Path: <b>PaymentReconciliation.status</b><br>
2415   * </p>
2416   */
2417  @SearchParamDefinition(name="status", path="PaymentReconciliation.status", description="The status of the payment reconciliation", type="token" )
2418  public static final String SP_STATUS = "status";
2419 /**
2420   * <b>Fluent Client</b> search parameter constant for <b>status</b>
2421   * <p>
2422   * Description: <b>The status of the payment reconciliation</b><br>
2423   * Type: <b>token</b><br>
2424   * Path: <b>PaymentReconciliation.status</b><br>
2425   * </p>
2426   */
2427  public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS);
2428
2429
2430}