001package org.hl7.fhir.r4.model;
002
003/*-
004 * #%L
005 * org.hl7.fhir.r4
006 * %%
007 * Copyright (C) 2014 - 2019 Health Level 7
008 * %%
009 * Licensed under the Apache License, Version 2.0 (the "License");
010 * you may not use this file except in compliance with the License.
011 * You may obtain a copy of the License at
012 * 
013 *      http://www.apache.org/licenses/LICENSE-2.0
014 * 
015 * Unless required by applicable law or agreed to in writing, software
016 * distributed under the License is distributed on an "AS IS" BASIS,
017 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
018 * See the License for the specific language governing permissions and
019 * limitations under the License.
020 * #L%
021 */
022
023/*
024  Copyright (c) 2011+, HL7, Inc.
025  All rights reserved.
026  
027  Redistribution and use in source and binary forms, with or without modification, 
028  are permitted provided that the following conditions are met:
029  
030   * Redistributions of source code must retain the above copyright notice, this 
031     list of conditions and the following disclaimer.
032   * Redistributions in binary form must reproduce the above copyright notice, 
033     this list of conditions and the following disclaimer in the documentation 
034     and/or other materials provided with the distribution.
035   * Neither the name of HL7 nor the names of its contributors may be used to 
036     endorse or promote products derived from this software without specific 
037     prior written permission.
038  
039  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 
040  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 
041  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 
042  IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 
043  INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 
044  NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 
045  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 
046  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 
047  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
048  POSSIBILITY OF SUCH DAMAGE.
049  
050*/
051
052// Generated on Thu, Dec 13, 2018 14:07+1100 for FHIR v4.0.0
053import java.util.ArrayList;
054import java.util.Date;
055import java.util.List;
056
057import org.hl7.fhir.exceptions.FHIRException;
058import org.hl7.fhir.instance.model.api.IBaseBackboneElement;
059
060import ca.uhn.fhir.model.api.annotation.Block;
061import ca.uhn.fhir.model.api.annotation.Child;
062import ca.uhn.fhir.model.api.annotation.Description;
063import ca.uhn.fhir.model.api.annotation.ResourceDef;
064import ca.uhn.fhir.model.api.annotation.SearchParamDefinition;
065/**
066 * A request to convey information; e.g. the CDS system proposes that an alert be sent to a responsible provider, the CDS system proposes that the public health agency be notified about a reportable condition.
067 */
068@ResourceDef(name="CommunicationRequest", profile="http://hl7.org/fhir/StructureDefinition/CommunicationRequest")
069public class CommunicationRequest extends DomainResource {
070
071    public enum CommunicationRequestStatus {
072        /**
073         * The request has been created but is not yet complete or ready for action.
074         */
075        DRAFT, 
076        /**
077         * The request is in force and ready to be acted upon.
078         */
079        ACTIVE, 
080        /**
081         * The request (and any implicit authorization to act) has been temporarily withdrawn but is expected to resume in the future.
082         */
083        ONHOLD, 
084        /**
085         * The request (and any implicit authorization to act) has been terminated prior to the known full completion of the intended actions.  No further activity should occur.
086         */
087        REVOKED, 
088        /**
089         * The activity described by the request has been fully performed.  No further activity will occur.
090         */
091        COMPLETED, 
092        /**
093         * This request should never have existed and should be considered 'void'.  (It is possible that real-world decisions were based on it.  If real-world activity has occurred, the status should be "cancelled" rather than "entered-in-error".).
094         */
095        ENTEREDINERROR, 
096        /**
097         * The authoring/source system does not know which of the status values currently applies for this request.  Note: This concept is not to be used for "other" - one of the listed statuses is presumed to apply,  but the authoring/source system does not know which.
098         */
099        UNKNOWN, 
100        /**
101         * added to help the parsers with the generic types
102         */
103        NULL;
104        public static CommunicationRequestStatus fromCode(String codeString) throws FHIRException {
105            if (codeString == null || "".equals(codeString))
106                return null;
107        if ("draft".equals(codeString))
108          return DRAFT;
109        if ("active".equals(codeString))
110          return ACTIVE;
111        if ("on-hold".equals(codeString))
112          return ONHOLD;
113        if ("revoked".equals(codeString))
114          return REVOKED;
115        if ("completed".equals(codeString))
116          return COMPLETED;
117        if ("entered-in-error".equals(codeString))
118          return ENTEREDINERROR;
119        if ("unknown".equals(codeString))
120          return UNKNOWN;
121        if (Configuration.isAcceptInvalidEnums())
122          return null;
123        else
124          throw new FHIRException("Unknown CommunicationRequestStatus code '"+codeString+"'");
125        }
126        public String toCode() {
127          switch (this) {
128            case DRAFT: return "draft";
129            case ACTIVE: return "active";
130            case ONHOLD: return "on-hold";
131            case REVOKED: return "revoked";
132            case COMPLETED: return "completed";
133            case ENTEREDINERROR: return "entered-in-error";
134            case UNKNOWN: return "unknown";
135            default: return "?";
136          }
137        }
138        public String getSystem() {
139          switch (this) {
140            case DRAFT: return "http://hl7.org/fhir/request-status";
141            case ACTIVE: return "http://hl7.org/fhir/request-status";
142            case ONHOLD: return "http://hl7.org/fhir/request-status";
143            case REVOKED: return "http://hl7.org/fhir/request-status";
144            case COMPLETED: return "http://hl7.org/fhir/request-status";
145            case ENTEREDINERROR: return "http://hl7.org/fhir/request-status";
146            case UNKNOWN: return "http://hl7.org/fhir/request-status";
147            default: return "?";
148          }
149        }
150        public String getDefinition() {
151          switch (this) {
152            case DRAFT: return "The request has been created but is not yet complete or ready for action.";
153            case ACTIVE: return "The request is in force and ready to be acted upon.";
154            case ONHOLD: return "The request (and any implicit authorization to act) has been temporarily withdrawn but is expected to resume in the future.";
155            case REVOKED: return "The request (and any implicit authorization to act) has been terminated prior to the known full completion of the intended actions.  No further activity should occur.";
156            case COMPLETED: return "The activity described by the request has been fully performed.  No further activity will occur.";
157            case ENTEREDINERROR: return "This request should never have existed and should be considered 'void'.  (It is possible that real-world decisions were based on it.  If real-world activity has occurred, the status should be \"cancelled\" rather than \"entered-in-error\".).";
158            case UNKNOWN: return "The authoring/source system does not know which of the status values currently applies for this request.  Note: This concept is not to be used for \"other\" - one of the listed statuses is presumed to apply,  but the authoring/source system does not know which.";
159            default: return "?";
160          }
161        }
162        public String getDisplay() {
163          switch (this) {
164            case DRAFT: return "Draft";
165            case ACTIVE: return "Active";
166            case ONHOLD: return "On Hold";
167            case REVOKED: return "Revoked";
168            case COMPLETED: return "Completed";
169            case ENTEREDINERROR: return "Entered in Error";
170            case UNKNOWN: return "Unknown";
171            default: return "?";
172          }
173        }
174    }
175
176  public static class CommunicationRequestStatusEnumFactory implements EnumFactory<CommunicationRequestStatus> {
177    public CommunicationRequestStatus fromCode(String codeString) throws IllegalArgumentException {
178      if (codeString == null || "".equals(codeString))
179            if (codeString == null || "".equals(codeString))
180                return null;
181        if ("draft".equals(codeString))
182          return CommunicationRequestStatus.DRAFT;
183        if ("active".equals(codeString))
184          return CommunicationRequestStatus.ACTIVE;
185        if ("on-hold".equals(codeString))
186          return CommunicationRequestStatus.ONHOLD;
187        if ("revoked".equals(codeString))
188          return CommunicationRequestStatus.REVOKED;
189        if ("completed".equals(codeString))
190          return CommunicationRequestStatus.COMPLETED;
191        if ("entered-in-error".equals(codeString))
192          return CommunicationRequestStatus.ENTEREDINERROR;
193        if ("unknown".equals(codeString))
194          return CommunicationRequestStatus.UNKNOWN;
195        throw new IllegalArgumentException("Unknown CommunicationRequestStatus code '"+codeString+"'");
196        }
197        public Enumeration<CommunicationRequestStatus> fromType(Base code) throws FHIRException {
198          if (code == null)
199            return null;
200          if (code.isEmpty())
201            return new Enumeration<CommunicationRequestStatus>(this);
202          String codeString = ((PrimitiveType) code).asStringValue();
203          if (codeString == null || "".equals(codeString))
204            return null;
205        if ("draft".equals(codeString))
206          return new Enumeration<CommunicationRequestStatus>(this, CommunicationRequestStatus.DRAFT);
207        if ("active".equals(codeString))
208          return new Enumeration<CommunicationRequestStatus>(this, CommunicationRequestStatus.ACTIVE);
209        if ("on-hold".equals(codeString))
210          return new Enumeration<CommunicationRequestStatus>(this, CommunicationRequestStatus.ONHOLD);
211        if ("revoked".equals(codeString))
212          return new Enumeration<CommunicationRequestStatus>(this, CommunicationRequestStatus.REVOKED);
213        if ("completed".equals(codeString))
214          return new Enumeration<CommunicationRequestStatus>(this, CommunicationRequestStatus.COMPLETED);
215        if ("entered-in-error".equals(codeString))
216          return new Enumeration<CommunicationRequestStatus>(this, CommunicationRequestStatus.ENTEREDINERROR);
217        if ("unknown".equals(codeString))
218          return new Enumeration<CommunicationRequestStatus>(this, CommunicationRequestStatus.UNKNOWN);
219        throw new FHIRException("Unknown CommunicationRequestStatus code '"+codeString+"'");
220        }
221    public String toCode(CommunicationRequestStatus code) {
222      if (code == CommunicationRequestStatus.DRAFT)
223        return "draft";
224      if (code == CommunicationRequestStatus.ACTIVE)
225        return "active";
226      if (code == CommunicationRequestStatus.ONHOLD)
227        return "on-hold";
228      if (code == CommunicationRequestStatus.REVOKED)
229        return "revoked";
230      if (code == CommunicationRequestStatus.COMPLETED)
231        return "completed";
232      if (code == CommunicationRequestStatus.ENTEREDINERROR)
233        return "entered-in-error";
234      if (code == CommunicationRequestStatus.UNKNOWN)
235        return "unknown";
236      return "?";
237      }
238    public String toSystem(CommunicationRequestStatus code) {
239      return code.getSystem();
240      }
241    }
242
243    public enum CommunicationPriority {
244        /**
245         * The request has normal priority.
246         */
247        ROUTINE, 
248        /**
249         * The request should be actioned promptly - higher priority than routine.
250         */
251        URGENT, 
252        /**
253         * The request should be actioned as soon as possible - higher priority than urgent.
254         */
255        ASAP, 
256        /**
257         * The request should be actioned immediately - highest possible priority.  E.g. an emergency.
258         */
259        STAT, 
260        /**
261         * added to help the parsers with the generic types
262         */
263        NULL;
264        public static CommunicationPriority fromCode(String codeString) throws FHIRException {
265            if (codeString == null || "".equals(codeString))
266                return null;
267        if ("routine".equals(codeString))
268          return ROUTINE;
269        if ("urgent".equals(codeString))
270          return URGENT;
271        if ("asap".equals(codeString))
272          return ASAP;
273        if ("stat".equals(codeString))
274          return STAT;
275        if (Configuration.isAcceptInvalidEnums())
276          return null;
277        else
278          throw new FHIRException("Unknown CommunicationPriority code '"+codeString+"'");
279        }
280        public String toCode() {
281          switch (this) {
282            case ROUTINE: return "routine";
283            case URGENT: return "urgent";
284            case ASAP: return "asap";
285            case STAT: return "stat";
286            default: return "?";
287          }
288        }
289        public String getSystem() {
290          switch (this) {
291            case ROUTINE: return "http://hl7.org/fhir/request-priority";
292            case URGENT: return "http://hl7.org/fhir/request-priority";
293            case ASAP: return "http://hl7.org/fhir/request-priority";
294            case STAT: return "http://hl7.org/fhir/request-priority";
295            default: return "?";
296          }
297        }
298        public String getDefinition() {
299          switch (this) {
300            case ROUTINE: return "The request has normal priority.";
301            case URGENT: return "The request should be actioned promptly - higher priority than routine.";
302            case ASAP: return "The request should be actioned as soon as possible - higher priority than urgent.";
303            case STAT: return "The request should be actioned immediately - highest possible priority.  E.g. an emergency.";
304            default: return "?";
305          }
306        }
307        public String getDisplay() {
308          switch (this) {
309            case ROUTINE: return "Routine";
310            case URGENT: return "Urgent";
311            case ASAP: return "ASAP";
312            case STAT: return "STAT";
313            default: return "?";
314          }
315        }
316    }
317
318  public static class CommunicationPriorityEnumFactory implements EnumFactory<CommunicationPriority> {
319    public CommunicationPriority fromCode(String codeString) throws IllegalArgumentException {
320      if (codeString == null || "".equals(codeString))
321            if (codeString == null || "".equals(codeString))
322                return null;
323        if ("routine".equals(codeString))
324          return CommunicationPriority.ROUTINE;
325        if ("urgent".equals(codeString))
326          return CommunicationPriority.URGENT;
327        if ("asap".equals(codeString))
328          return CommunicationPriority.ASAP;
329        if ("stat".equals(codeString))
330          return CommunicationPriority.STAT;
331        throw new IllegalArgumentException("Unknown CommunicationPriority code '"+codeString+"'");
332        }
333        public Enumeration<CommunicationPriority> fromType(Base code) throws FHIRException {
334          if (code == null)
335            return null;
336          if (code.isEmpty())
337            return new Enumeration<CommunicationPriority>(this);
338          String codeString = ((PrimitiveType) code).asStringValue();
339          if (codeString == null || "".equals(codeString))
340            return null;
341        if ("routine".equals(codeString))
342          return new Enumeration<CommunicationPriority>(this, CommunicationPriority.ROUTINE);
343        if ("urgent".equals(codeString))
344          return new Enumeration<CommunicationPriority>(this, CommunicationPriority.URGENT);
345        if ("asap".equals(codeString))
346          return new Enumeration<CommunicationPriority>(this, CommunicationPriority.ASAP);
347        if ("stat".equals(codeString))
348          return new Enumeration<CommunicationPriority>(this, CommunicationPriority.STAT);
349        throw new FHIRException("Unknown CommunicationPriority code '"+codeString+"'");
350        }
351    public String toCode(CommunicationPriority code) {
352      if (code == CommunicationPriority.ROUTINE)
353        return "routine";
354      if (code == CommunicationPriority.URGENT)
355        return "urgent";
356      if (code == CommunicationPriority.ASAP)
357        return "asap";
358      if (code == CommunicationPriority.STAT)
359        return "stat";
360      return "?";
361      }
362    public String toSystem(CommunicationPriority code) {
363      return code.getSystem();
364      }
365    }
366
367    @Block()
368    public static class CommunicationRequestPayloadComponent extends BackboneElement implements IBaseBackboneElement {
369        /**
370         * The communicated content (or for multi-part communications, one portion of the communication).
371         */
372        @Child(name = "content", type = {StringType.class, Attachment.class, Reference.class}, order=1, min=1, max=1, modifier=false, summary=false)
373        @Description(shortDefinition="Message part content", formalDefinition="The communicated content (or for multi-part communications, one portion of the communication)." )
374        protected Type content;
375
376        private static final long serialVersionUID = -1763459053L;
377
378    /**
379     * Constructor
380     */
381      public CommunicationRequestPayloadComponent() {
382        super();
383      }
384
385    /**
386     * Constructor
387     */
388      public CommunicationRequestPayloadComponent(Type content) {
389        super();
390        this.content = content;
391      }
392
393        /**
394         * @return {@link #content} (The communicated content (or for multi-part communications, one portion of the communication).)
395         */
396        public Type getContent() { 
397          return this.content;
398        }
399
400        /**
401         * @return {@link #content} (The communicated content (or for multi-part communications, one portion of the communication).)
402         */
403        public StringType getContentStringType() throws FHIRException { 
404          if (this.content == null)
405            this.content = new StringType();
406          if (!(this.content instanceof StringType))
407            throw new FHIRException("Type mismatch: the type StringType was expected, but "+this.content.getClass().getName()+" was encountered");
408          return (StringType) this.content;
409        }
410
411        public boolean hasContentStringType() { 
412          return this != null && this.content instanceof StringType;
413        }
414
415        /**
416         * @return {@link #content} (The communicated content (or for multi-part communications, one portion of the communication).)
417         */
418        public Attachment getContentAttachment() throws FHIRException { 
419          if (this.content == null)
420            this.content = new Attachment();
421          if (!(this.content instanceof Attachment))
422            throw new FHIRException("Type mismatch: the type Attachment was expected, but "+this.content.getClass().getName()+" was encountered");
423          return (Attachment) this.content;
424        }
425
426        public boolean hasContentAttachment() { 
427          return this != null && this.content instanceof Attachment;
428        }
429
430        /**
431         * @return {@link #content} (The communicated content (or for multi-part communications, one portion of the communication).)
432         */
433        public Reference getContentReference() throws FHIRException { 
434          if (this.content == null)
435            this.content = new Reference();
436          if (!(this.content instanceof Reference))
437            throw new FHIRException("Type mismatch: the type Reference was expected, but "+this.content.getClass().getName()+" was encountered");
438          return (Reference) this.content;
439        }
440
441        public boolean hasContentReference() { 
442          return this != null && this.content instanceof Reference;
443        }
444
445        public boolean hasContent() { 
446          return this.content != null && !this.content.isEmpty();
447        }
448
449        /**
450         * @param value {@link #content} (The communicated content (or for multi-part communications, one portion of the communication).)
451         */
452        public CommunicationRequestPayloadComponent setContent(Type value) { 
453          if (value != null && !(value instanceof StringType || value instanceof Attachment || value instanceof Reference))
454            throw new Error("Not the right type for CommunicationRequest.payload.content[x]: "+value.fhirType());
455          this.content = value;
456          return this;
457        }
458
459        protected void listChildren(List<Property> children) {
460          super.listChildren(children);
461          children.add(new Property("content[x]", "string|Attachment|Reference(Any)", "The communicated content (or for multi-part communications, one portion of the communication).", 0, 1, content));
462        }
463
464        @Override
465        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
466          switch (_hash) {
467          case 264548711: /*content[x]*/  return new Property("content[x]", "string|Attachment|Reference(Any)", "The communicated content (or for multi-part communications, one portion of the communication).", 0, 1, content);
468          case 951530617: /*content*/  return new Property("content[x]", "string|Attachment|Reference(Any)", "The communicated content (or for multi-part communications, one portion of the communication).", 0, 1, content);
469          case -326336022: /*contentString*/  return new Property("content[x]", "string|Attachment|Reference(Any)", "The communicated content (or for multi-part communications, one portion of the communication).", 0, 1, content);
470          case -702028164: /*contentAttachment*/  return new Property("content[x]", "string|Attachment|Reference(Any)", "The communicated content (or for multi-part communications, one portion of the communication).", 0, 1, content);
471          case 1193747154: /*contentReference*/  return new Property("content[x]", "string|Attachment|Reference(Any)", "The communicated content (or for multi-part communications, one portion of the communication).", 0, 1, content);
472          default: return super.getNamedProperty(_hash, _name, _checkValid);
473          }
474
475        }
476
477      @Override
478      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
479        switch (hash) {
480        case 951530617: /*content*/ return this.content == null ? new Base[0] : new Base[] {this.content}; // Type
481        default: return super.getProperty(hash, name, checkValid);
482        }
483
484      }
485
486      @Override
487      public Base setProperty(int hash, String name, Base value) throws FHIRException {
488        switch (hash) {
489        case 951530617: // content
490          this.content = castToType(value); // Type
491          return value;
492        default: return super.setProperty(hash, name, value);
493        }
494
495      }
496
497      @Override
498      public Base setProperty(String name, Base value) throws FHIRException {
499        if (name.equals("content[x]")) {
500          this.content = castToType(value); // Type
501        } else
502          return super.setProperty(name, value);
503        return value;
504      }
505
506      @Override
507      public Base makeProperty(int hash, String name) throws FHIRException {
508        switch (hash) {
509        case 264548711:  return getContent(); 
510        case 951530617:  return getContent(); 
511        default: return super.makeProperty(hash, name);
512        }
513
514      }
515
516      @Override
517      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
518        switch (hash) {
519        case 951530617: /*content*/ return new String[] {"string", "Attachment", "Reference"};
520        default: return super.getTypesForProperty(hash, name);
521        }
522
523      }
524
525      @Override
526      public Base addChild(String name) throws FHIRException {
527        if (name.equals("contentString")) {
528          this.content = new StringType();
529          return this.content;
530        }
531        else if (name.equals("contentAttachment")) {
532          this.content = new Attachment();
533          return this.content;
534        }
535        else if (name.equals("contentReference")) {
536          this.content = new Reference();
537          return this.content;
538        }
539        else
540          return super.addChild(name);
541      }
542
543      public CommunicationRequestPayloadComponent copy() {
544        CommunicationRequestPayloadComponent dst = new CommunicationRequestPayloadComponent();
545        copyValues(dst);
546        dst.content = content == null ? null : content.copy();
547        return dst;
548      }
549
550      @Override
551      public boolean equalsDeep(Base other_) {
552        if (!super.equalsDeep(other_))
553          return false;
554        if (!(other_ instanceof CommunicationRequestPayloadComponent))
555          return false;
556        CommunicationRequestPayloadComponent o = (CommunicationRequestPayloadComponent) other_;
557        return compareDeep(content, o.content, true);
558      }
559
560      @Override
561      public boolean equalsShallow(Base other_) {
562        if (!super.equalsShallow(other_))
563          return false;
564        if (!(other_ instanceof CommunicationRequestPayloadComponent))
565          return false;
566        CommunicationRequestPayloadComponent o = (CommunicationRequestPayloadComponent) other_;
567        return true;
568      }
569
570      public boolean isEmpty() {
571        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(content);
572      }
573
574  public String fhirType() {
575    return "CommunicationRequest.payload";
576
577  }
578
579  }
580
581    /**
582     * Business identifiers assigned to this communication request by the performer or other systems which remain constant as the resource is updated and propagates from server to server.
583     */
584    @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true)
585    @Description(shortDefinition="Unique identifier", formalDefinition="Business identifiers assigned to this communication request by the performer or other systems which remain constant as the resource is updated and propagates from server to server." )
586    protected List<Identifier> identifier;
587
588    /**
589     * A plan or proposal that is fulfilled in whole or in part by this request.
590     */
591    @Child(name = "basedOn", type = {Reference.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true)
592    @Description(shortDefinition="Fulfills plan or proposal", formalDefinition="A plan or proposal that is fulfilled in whole or in part by this request." )
593    protected List<Reference> basedOn;
594    /**
595     * The actual objects that are the target of the reference (A plan or proposal that is fulfilled in whole or in part by this request.)
596     */
597    protected List<Resource> basedOnTarget;
598
599
600    /**
601     * Completed or terminated request(s) whose function is taken by this new request.
602     */
603    @Child(name = "replaces", type = {CommunicationRequest.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true)
604    @Description(shortDefinition="Request(s) replaced by this request", formalDefinition="Completed or terminated request(s) whose function is taken by this new request." )
605    protected List<Reference> replaces;
606    /**
607     * The actual objects that are the target of the reference (Completed or terminated request(s) whose function is taken by this new request.)
608     */
609    protected List<CommunicationRequest> replacesTarget;
610
611
612    /**
613     * A shared identifier common to all requests that were authorized more or less simultaneously by a single author, representing the identifier of the requisition, prescription or similar form.
614     */
615    @Child(name = "groupIdentifier", type = {Identifier.class}, order=3, min=0, max=1, modifier=false, summary=true)
616    @Description(shortDefinition="Composite request this is part of", formalDefinition="A shared identifier common to all requests that were authorized more or less simultaneously by a single author, representing the identifier of the requisition, prescription or similar form." )
617    protected Identifier groupIdentifier;
618
619    /**
620     * The status of the proposal or order.
621     */
622    @Child(name = "status", type = {CodeType.class}, order=4, min=1, max=1, modifier=true, summary=true)
623    @Description(shortDefinition="draft | active | suspended | cancelled | completed | entered-in-error | unknown", formalDefinition="The status of the proposal or order." )
624    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/request-status")
625    protected Enumeration<CommunicationRequestStatus> status;
626
627    /**
628     * Captures the reason for the current state of the CommunicationRequest.
629     */
630    @Child(name = "statusReason", type = {CodeableConcept.class}, order=5, min=0, max=1, modifier=false, summary=false)
631    @Description(shortDefinition="Reason for current status", formalDefinition="Captures the reason for the current state of the CommunicationRequest." )
632    protected CodeableConcept statusReason;
633
634    /**
635     * The type of message to be sent such as alert, notification, reminder, instruction, etc.
636     */
637    @Child(name = "category", type = {CodeableConcept.class}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
638    @Description(shortDefinition="Message category", formalDefinition="The type of message to be sent such as alert, notification, reminder, instruction, etc." )
639    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/communication-category")
640    protected List<CodeableConcept> category;
641
642    /**
643     * Characterizes how quickly the proposed act must be initiated. Includes concepts such as stat, urgent, routine.
644     */
645    @Child(name = "priority", type = {CodeType.class}, order=7, min=0, max=1, modifier=false, summary=true)
646    @Description(shortDefinition="Message urgency", formalDefinition="Characterizes how quickly the proposed act must be initiated. Includes concepts such as stat, urgent, routine." )
647    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/request-priority")
648    protected Enumeration<CommunicationPriority> priority;
649
650    /**
651     * If true indicates that the CommunicationRequest is asking for the specified action to *not* occur.
652     */
653    @Child(name = "doNotPerform", type = {BooleanType.class}, order=8, min=0, max=1, modifier=true, summary=true)
654    @Description(shortDefinition="True if request is prohibiting action", formalDefinition="If true indicates that the CommunicationRequest is asking for the specified action to *not* occur." )
655    protected BooleanType doNotPerform;
656
657    /**
658     * A channel that was used for this communication (e.g. email, fax).
659     */
660    @Child(name = "medium", type = {CodeableConcept.class}, order=9, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
661    @Description(shortDefinition="A channel of communication", formalDefinition="A channel that was used for this communication (e.g. email, fax)." )
662    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://terminology.hl7.org/ValueSet/v3-ParticipationMode")
663    protected List<CodeableConcept> medium;
664
665    /**
666     * The patient or group that is the focus of this communication request.
667     */
668    @Child(name = "subject", type = {Patient.class, Group.class}, order=10, min=0, max=1, modifier=false, summary=false)
669    @Description(shortDefinition="Focus of message", formalDefinition="The patient or group that is the focus of this communication request." )
670    protected Reference subject;
671
672    /**
673     * The actual object that is the target of the reference (The patient or group that is the focus of this communication request.)
674     */
675    protected Resource subjectTarget;
676
677    /**
678     * Other resources that pertain to this communication request and to which this communication request should be associated.
679     */
680    @Child(name = "about", type = {Reference.class}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
681    @Description(shortDefinition="Resources that pertain to this communication request", formalDefinition="Other resources that pertain to this communication request and to which this communication request should be associated." )
682    protected List<Reference> about;
683    /**
684     * The actual objects that are the target of the reference (Other resources that pertain to this communication request and to which this communication request should be associated.)
685     */
686    protected List<Resource> aboutTarget;
687
688
689    /**
690     * The Encounter during which this CommunicationRequest was created or to which the creation of this record is tightly associated.
691     */
692    @Child(name = "encounter", type = {Encounter.class}, order=12, min=0, max=1, modifier=false, summary=true)
693    @Description(shortDefinition="Encounter created as part of", formalDefinition="The Encounter during which this CommunicationRequest was created or to which the creation of this record is tightly associated." )
694    protected Reference encounter;
695
696    /**
697     * The actual object that is the target of the reference (The Encounter during which this CommunicationRequest was created or to which the creation of this record is tightly associated.)
698     */
699    protected Encounter encounterTarget;
700
701    /**
702     * Text, attachment(s), or resource(s) to be communicated to the recipient.
703     */
704    @Child(name = "payload", type = {}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
705    @Description(shortDefinition="Message payload", formalDefinition="Text, attachment(s), or resource(s) to be communicated to the recipient." )
706    protected List<CommunicationRequestPayloadComponent> payload;
707
708    /**
709     * The time when this communication is to occur.
710     */
711    @Child(name = "occurrence", type = {DateTimeType.class, Period.class}, order=14, min=0, max=1, modifier=false, summary=true)
712    @Description(shortDefinition="When scheduled", formalDefinition="The time when this communication is to occur." )
713    protected Type occurrence;
714
715    /**
716     * For draft requests, indicates the date of initial creation.  For requests with other statuses, indicates the date of activation.
717     */
718    @Child(name = "authoredOn", type = {DateTimeType.class}, order=15, min=0, max=1, modifier=false, summary=true)
719    @Description(shortDefinition="When request transitioned to being actionable", formalDefinition="For draft requests, indicates the date of initial creation.  For requests with other statuses, indicates the date of activation." )
720    protected DateTimeType authoredOn;
721
722    /**
723     * The device, individual, or organization who initiated the request and has responsibility for its activation.
724     */
725    @Child(name = "requester", type = {Practitioner.class, PractitionerRole.class, Organization.class, Patient.class, RelatedPerson.class, Device.class}, order=16, min=0, max=1, modifier=false, summary=true)
726    @Description(shortDefinition="Who/what is requesting service", formalDefinition="The device, individual, or organization who initiated the request and has responsibility for its activation." )
727    protected Reference requester;
728
729    /**
730     * The actual object that is the target of the reference (The device, individual, or organization who initiated the request and has responsibility for its activation.)
731     */
732    protected Resource requesterTarget;
733
734    /**
735     * The entity (e.g. person, organization, clinical information system, device, group, or care team) which is the intended target of the communication.
736     */
737    @Child(name = "recipient", type = {Device.class, Organization.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class, Group.class, CareTeam.class, HealthcareService.class}, order=17, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
738    @Description(shortDefinition="Message recipient", formalDefinition="The entity (e.g. person, organization, clinical information system, device, group, or care team) which is the intended target of the communication." )
739    protected List<Reference> recipient;
740    /**
741     * The actual objects that are the target of the reference (The entity (e.g. person, organization, clinical information system, device, group, or care team) which is the intended target of the communication.)
742     */
743    protected List<Resource> recipientTarget;
744
745
746    /**
747     * The entity (e.g. person, organization, clinical information system, or device) which is to be the source of the communication.
748     */
749    @Child(name = "sender", type = {Device.class, Organization.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class, HealthcareService.class}, order=18, min=0, max=1, modifier=false, summary=true)
750    @Description(shortDefinition="Message sender", formalDefinition="The entity (e.g. person, organization, clinical information system, or device) which is to be the source of the communication." )
751    protected Reference sender;
752
753    /**
754     * The actual object that is the target of the reference (The entity (e.g. person, organization, clinical information system, or device) which is to be the source of the communication.)
755     */
756    protected Resource senderTarget;
757
758    /**
759     * Describes why the request is being made in coded or textual form.
760     */
761    @Child(name = "reasonCode", type = {CodeableConcept.class}, order=19, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true)
762    @Description(shortDefinition="Why is communication needed?", formalDefinition="Describes why the request is being made in coded or textual form." )
763    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://terminology.hl7.org/ValueSet/v3-ActReason")
764    protected List<CodeableConcept> reasonCode;
765
766    /**
767     * Indicates another resource whose existence justifies this request.
768     */
769    @Child(name = "reasonReference", type = {Condition.class, Observation.class, DiagnosticReport.class, DocumentReference.class}, order=20, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true)
770    @Description(shortDefinition="Why is communication needed?", formalDefinition="Indicates another resource whose existence justifies this request." )
771    protected List<Reference> reasonReference;
772    /**
773     * The actual objects that are the target of the reference (Indicates another resource whose existence justifies this request.)
774     */
775    protected List<Resource> reasonReferenceTarget;
776
777
778    /**
779     * Comments made about the request by the requester, sender, recipient, subject or other participants.
780     */
781    @Child(name = "note", type = {Annotation.class}, order=21, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
782    @Description(shortDefinition="Comments made about communication request", formalDefinition="Comments made about the request by the requester, sender, recipient, subject or other participants." )
783    protected List<Annotation> note;
784
785    private static final long serialVersionUID = 2131096857L;
786
787  /**
788   * Constructor
789   */
790    public CommunicationRequest() {
791      super();
792    }
793
794  /**
795   * Constructor
796   */
797    public CommunicationRequest(Enumeration<CommunicationRequestStatus> status) {
798      super();
799      this.status = status;
800    }
801
802    /**
803     * @return {@link #identifier} (Business identifiers assigned to this communication request by the performer or other systems which remain constant as the resource is updated and propagates from server to server.)
804     */
805    public List<Identifier> getIdentifier() { 
806      if (this.identifier == null)
807        this.identifier = new ArrayList<Identifier>();
808      return this.identifier;
809    }
810
811    /**
812     * @return Returns a reference to <code>this</code> for easy method chaining
813     */
814    public CommunicationRequest setIdentifier(List<Identifier> theIdentifier) { 
815      this.identifier = theIdentifier;
816      return this;
817    }
818
819    public boolean hasIdentifier() { 
820      if (this.identifier == null)
821        return false;
822      for (Identifier item : this.identifier)
823        if (!item.isEmpty())
824          return true;
825      return false;
826    }
827
828    public Identifier addIdentifier() { //3
829      Identifier t = new Identifier();
830      if (this.identifier == null)
831        this.identifier = new ArrayList<Identifier>();
832      this.identifier.add(t);
833      return t;
834    }
835
836    public CommunicationRequest addIdentifier(Identifier t) { //3
837      if (t == null)
838        return this;
839      if (this.identifier == null)
840        this.identifier = new ArrayList<Identifier>();
841      this.identifier.add(t);
842      return this;
843    }
844
845    /**
846     * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist
847     */
848    public Identifier getIdentifierFirstRep() { 
849      if (getIdentifier().isEmpty()) {
850        addIdentifier();
851      }
852      return getIdentifier().get(0);
853    }
854
855    /**
856     * @return {@link #basedOn} (A plan or proposal that is fulfilled in whole or in part by this request.)
857     */
858    public List<Reference> getBasedOn() { 
859      if (this.basedOn == null)
860        this.basedOn = new ArrayList<Reference>();
861      return this.basedOn;
862    }
863
864    /**
865     * @return Returns a reference to <code>this</code> for easy method chaining
866     */
867    public CommunicationRequest setBasedOn(List<Reference> theBasedOn) { 
868      this.basedOn = theBasedOn;
869      return this;
870    }
871
872    public boolean hasBasedOn() { 
873      if (this.basedOn == null)
874        return false;
875      for (Reference item : this.basedOn)
876        if (!item.isEmpty())
877          return true;
878      return false;
879    }
880
881    public Reference addBasedOn() { //3
882      Reference t = new Reference();
883      if (this.basedOn == null)
884        this.basedOn = new ArrayList<Reference>();
885      this.basedOn.add(t);
886      return t;
887    }
888
889    public CommunicationRequest addBasedOn(Reference t) { //3
890      if (t == null)
891        return this;
892      if (this.basedOn == null)
893        this.basedOn = new ArrayList<Reference>();
894      this.basedOn.add(t);
895      return this;
896    }
897
898    /**
899     * @return The first repetition of repeating field {@link #basedOn}, creating it if it does not already exist
900     */
901    public Reference getBasedOnFirstRep() { 
902      if (getBasedOn().isEmpty()) {
903        addBasedOn();
904      }
905      return getBasedOn().get(0);
906    }
907
908    /**
909     * @deprecated Use Reference#setResource(IBaseResource) instead
910     */
911    @Deprecated
912    public List<Resource> getBasedOnTarget() { 
913      if (this.basedOnTarget == null)
914        this.basedOnTarget = new ArrayList<Resource>();
915      return this.basedOnTarget;
916    }
917
918    /**
919     * @return {@link #replaces} (Completed or terminated request(s) whose function is taken by this new request.)
920     */
921    public List<Reference> getReplaces() { 
922      if (this.replaces == null)
923        this.replaces = new ArrayList<Reference>();
924      return this.replaces;
925    }
926
927    /**
928     * @return Returns a reference to <code>this</code> for easy method chaining
929     */
930    public CommunicationRequest setReplaces(List<Reference> theReplaces) { 
931      this.replaces = theReplaces;
932      return this;
933    }
934
935    public boolean hasReplaces() { 
936      if (this.replaces == null)
937        return false;
938      for (Reference item : this.replaces)
939        if (!item.isEmpty())
940          return true;
941      return false;
942    }
943
944    public Reference addReplaces() { //3
945      Reference t = new Reference();
946      if (this.replaces == null)
947        this.replaces = new ArrayList<Reference>();
948      this.replaces.add(t);
949      return t;
950    }
951
952    public CommunicationRequest addReplaces(Reference t) { //3
953      if (t == null)
954        return this;
955      if (this.replaces == null)
956        this.replaces = new ArrayList<Reference>();
957      this.replaces.add(t);
958      return this;
959    }
960
961    /**
962     * @return The first repetition of repeating field {@link #replaces}, creating it if it does not already exist
963     */
964    public Reference getReplacesFirstRep() { 
965      if (getReplaces().isEmpty()) {
966        addReplaces();
967      }
968      return getReplaces().get(0);
969    }
970
971    /**
972     * @deprecated Use Reference#setResource(IBaseResource) instead
973     */
974    @Deprecated
975    public List<CommunicationRequest> getReplacesTarget() { 
976      if (this.replacesTarget == null)
977        this.replacesTarget = new ArrayList<CommunicationRequest>();
978      return this.replacesTarget;
979    }
980
981    /**
982     * @deprecated Use Reference#setResource(IBaseResource) instead
983     */
984    @Deprecated
985    public CommunicationRequest addReplacesTarget() { 
986      CommunicationRequest r = new CommunicationRequest();
987      if (this.replacesTarget == null)
988        this.replacesTarget = new ArrayList<CommunicationRequest>();
989      this.replacesTarget.add(r);
990      return r;
991    }
992
993    /**
994     * @return {@link #groupIdentifier} (A shared identifier common to all requests that were authorized more or less simultaneously by a single author, representing the identifier of the requisition, prescription or similar form.)
995     */
996    public Identifier getGroupIdentifier() { 
997      if (this.groupIdentifier == null)
998        if (Configuration.errorOnAutoCreate())
999          throw new Error("Attempt to auto-create CommunicationRequest.groupIdentifier");
1000        else if (Configuration.doAutoCreate())
1001          this.groupIdentifier = new Identifier(); // cc
1002      return this.groupIdentifier;
1003    }
1004
1005    public boolean hasGroupIdentifier() { 
1006      return this.groupIdentifier != null && !this.groupIdentifier.isEmpty();
1007    }
1008
1009    /**
1010     * @param value {@link #groupIdentifier} (A shared identifier common to all requests that were authorized more or less simultaneously by a single author, representing the identifier of the requisition, prescription or similar form.)
1011     */
1012    public CommunicationRequest setGroupIdentifier(Identifier value) { 
1013      this.groupIdentifier = value;
1014      return this;
1015    }
1016
1017    /**
1018     * @return {@link #status} (The status of the proposal or order.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value
1019     */
1020    public Enumeration<CommunicationRequestStatus> getStatusElement() { 
1021      if (this.status == null)
1022        if (Configuration.errorOnAutoCreate())
1023          throw new Error("Attempt to auto-create CommunicationRequest.status");
1024        else if (Configuration.doAutoCreate())
1025          this.status = new Enumeration<CommunicationRequestStatus>(new CommunicationRequestStatusEnumFactory()); // bb
1026      return this.status;
1027    }
1028
1029    public boolean hasStatusElement() { 
1030      return this.status != null && !this.status.isEmpty();
1031    }
1032
1033    public boolean hasStatus() { 
1034      return this.status != null && !this.status.isEmpty();
1035    }
1036
1037    /**
1038     * @param value {@link #status} (The status of the proposal or order.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value
1039     */
1040    public CommunicationRequest setStatusElement(Enumeration<CommunicationRequestStatus> value) { 
1041      this.status = value;
1042      return this;
1043    }
1044
1045    /**
1046     * @return The status of the proposal or order.
1047     */
1048    public CommunicationRequestStatus getStatus() { 
1049      return this.status == null ? null : this.status.getValue();
1050    }
1051
1052    /**
1053     * @param value The status of the proposal or order.
1054     */
1055    public CommunicationRequest setStatus(CommunicationRequestStatus value) { 
1056        if (this.status == null)
1057          this.status = new Enumeration<CommunicationRequestStatus>(new CommunicationRequestStatusEnumFactory());
1058        this.status.setValue(value);
1059      return this;
1060    }
1061
1062    /**
1063     * @return {@link #statusReason} (Captures the reason for the current state of the CommunicationRequest.)
1064     */
1065    public CodeableConcept getStatusReason() { 
1066      if (this.statusReason == null)
1067        if (Configuration.errorOnAutoCreate())
1068          throw new Error("Attempt to auto-create CommunicationRequest.statusReason");
1069        else if (Configuration.doAutoCreate())
1070          this.statusReason = new CodeableConcept(); // cc
1071      return this.statusReason;
1072    }
1073
1074    public boolean hasStatusReason() { 
1075      return this.statusReason != null && !this.statusReason.isEmpty();
1076    }
1077
1078    /**
1079     * @param value {@link #statusReason} (Captures the reason for the current state of the CommunicationRequest.)
1080     */
1081    public CommunicationRequest setStatusReason(CodeableConcept value) { 
1082      this.statusReason = value;
1083      return this;
1084    }
1085
1086    /**
1087     * @return {@link #category} (The type of message to be sent such as alert, notification, reminder, instruction, etc.)
1088     */
1089    public List<CodeableConcept> getCategory() { 
1090      if (this.category == null)
1091        this.category = new ArrayList<CodeableConcept>();
1092      return this.category;
1093    }
1094
1095    /**
1096     * @return Returns a reference to <code>this</code> for easy method chaining
1097     */
1098    public CommunicationRequest setCategory(List<CodeableConcept> theCategory) { 
1099      this.category = theCategory;
1100      return this;
1101    }
1102
1103    public boolean hasCategory() { 
1104      if (this.category == null)
1105        return false;
1106      for (CodeableConcept item : this.category)
1107        if (!item.isEmpty())
1108          return true;
1109      return false;
1110    }
1111
1112    public CodeableConcept addCategory() { //3
1113      CodeableConcept t = new CodeableConcept();
1114      if (this.category == null)
1115        this.category = new ArrayList<CodeableConcept>();
1116      this.category.add(t);
1117      return t;
1118    }
1119
1120    public CommunicationRequest addCategory(CodeableConcept t) { //3
1121      if (t == null)
1122        return this;
1123      if (this.category == null)
1124        this.category = new ArrayList<CodeableConcept>();
1125      this.category.add(t);
1126      return this;
1127    }
1128
1129    /**
1130     * @return The first repetition of repeating field {@link #category}, creating it if it does not already exist
1131     */
1132    public CodeableConcept getCategoryFirstRep() { 
1133      if (getCategory().isEmpty()) {
1134        addCategory();
1135      }
1136      return getCategory().get(0);
1137    }
1138
1139    /**
1140     * @return {@link #priority} (Characterizes how quickly the proposed act must be initiated. Includes concepts such as stat, urgent, routine.). This is the underlying object with id, value and extensions. The accessor "getPriority" gives direct access to the value
1141     */
1142    public Enumeration<CommunicationPriority> getPriorityElement() { 
1143      if (this.priority == null)
1144        if (Configuration.errorOnAutoCreate())
1145          throw new Error("Attempt to auto-create CommunicationRequest.priority");
1146        else if (Configuration.doAutoCreate())
1147          this.priority = new Enumeration<CommunicationPriority>(new CommunicationPriorityEnumFactory()); // bb
1148      return this.priority;
1149    }
1150
1151    public boolean hasPriorityElement() { 
1152      return this.priority != null && !this.priority.isEmpty();
1153    }
1154
1155    public boolean hasPriority() { 
1156      return this.priority != null && !this.priority.isEmpty();
1157    }
1158
1159    /**
1160     * @param value {@link #priority} (Characterizes how quickly the proposed act must be initiated. Includes concepts such as stat, urgent, routine.). This is the underlying object with id, value and extensions. The accessor "getPriority" gives direct access to the value
1161     */
1162    public CommunicationRequest setPriorityElement(Enumeration<CommunicationPriority> value) { 
1163      this.priority = value;
1164      return this;
1165    }
1166
1167    /**
1168     * @return Characterizes how quickly the proposed act must be initiated. Includes concepts such as stat, urgent, routine.
1169     */
1170    public CommunicationPriority getPriority() { 
1171      return this.priority == null ? null : this.priority.getValue();
1172    }
1173
1174    /**
1175     * @param value Characterizes how quickly the proposed act must be initiated. Includes concepts such as stat, urgent, routine.
1176     */
1177    public CommunicationRequest setPriority(CommunicationPriority value) { 
1178      if (value == null)
1179        this.priority = null;
1180      else {
1181        if (this.priority == null)
1182          this.priority = new Enumeration<CommunicationPriority>(new CommunicationPriorityEnumFactory());
1183        this.priority.setValue(value);
1184      }
1185      return this;
1186    }
1187
1188    /**
1189     * @return {@link #doNotPerform} (If true indicates that the CommunicationRequest is asking for the specified action to *not* occur.). This is the underlying object with id, value and extensions. The accessor "getDoNotPerform" gives direct access to the value
1190     */
1191    public BooleanType getDoNotPerformElement() { 
1192      if (this.doNotPerform == null)
1193        if (Configuration.errorOnAutoCreate())
1194          throw new Error("Attempt to auto-create CommunicationRequest.doNotPerform");
1195        else if (Configuration.doAutoCreate())
1196          this.doNotPerform = new BooleanType(); // bb
1197      return this.doNotPerform;
1198    }
1199
1200    public boolean hasDoNotPerformElement() { 
1201      return this.doNotPerform != null && !this.doNotPerform.isEmpty();
1202    }
1203
1204    public boolean hasDoNotPerform() { 
1205      return this.doNotPerform != null && !this.doNotPerform.isEmpty();
1206    }
1207
1208    /**
1209     * @param value {@link #doNotPerform} (If true indicates that the CommunicationRequest is asking for the specified action to *not* occur.). This is the underlying object with id, value and extensions. The accessor "getDoNotPerform" gives direct access to the value
1210     */
1211    public CommunicationRequest setDoNotPerformElement(BooleanType value) { 
1212      this.doNotPerform = value;
1213      return this;
1214    }
1215
1216    /**
1217     * @return If true indicates that the CommunicationRequest is asking for the specified action to *not* occur.
1218     */
1219    public boolean getDoNotPerform() { 
1220      return this.doNotPerform == null || this.doNotPerform.isEmpty() ? false : this.doNotPerform.getValue();
1221    }
1222
1223    /**
1224     * @param value If true indicates that the CommunicationRequest is asking for the specified action to *not* occur.
1225     */
1226    public CommunicationRequest setDoNotPerform(boolean value) { 
1227        if (this.doNotPerform == null)
1228          this.doNotPerform = new BooleanType();
1229        this.doNotPerform.setValue(value);
1230      return this;
1231    }
1232
1233    /**
1234     * @return {@link #medium} (A channel that was used for this communication (e.g. email, fax).)
1235     */
1236    public List<CodeableConcept> getMedium() { 
1237      if (this.medium == null)
1238        this.medium = new ArrayList<CodeableConcept>();
1239      return this.medium;
1240    }
1241
1242    /**
1243     * @return Returns a reference to <code>this</code> for easy method chaining
1244     */
1245    public CommunicationRequest setMedium(List<CodeableConcept> theMedium) { 
1246      this.medium = theMedium;
1247      return this;
1248    }
1249
1250    public boolean hasMedium() { 
1251      if (this.medium == null)
1252        return false;
1253      for (CodeableConcept item : this.medium)
1254        if (!item.isEmpty())
1255          return true;
1256      return false;
1257    }
1258
1259    public CodeableConcept addMedium() { //3
1260      CodeableConcept t = new CodeableConcept();
1261      if (this.medium == null)
1262        this.medium = new ArrayList<CodeableConcept>();
1263      this.medium.add(t);
1264      return t;
1265    }
1266
1267    public CommunicationRequest addMedium(CodeableConcept t) { //3
1268      if (t == null)
1269        return this;
1270      if (this.medium == null)
1271        this.medium = new ArrayList<CodeableConcept>();
1272      this.medium.add(t);
1273      return this;
1274    }
1275
1276    /**
1277     * @return The first repetition of repeating field {@link #medium}, creating it if it does not already exist
1278     */
1279    public CodeableConcept getMediumFirstRep() { 
1280      if (getMedium().isEmpty()) {
1281        addMedium();
1282      }
1283      return getMedium().get(0);
1284    }
1285
1286    /**
1287     * @return {@link #subject} (The patient or group that is the focus of this communication request.)
1288     */
1289    public Reference getSubject() { 
1290      if (this.subject == null)
1291        if (Configuration.errorOnAutoCreate())
1292          throw new Error("Attempt to auto-create CommunicationRequest.subject");
1293        else if (Configuration.doAutoCreate())
1294          this.subject = new Reference(); // cc
1295      return this.subject;
1296    }
1297
1298    public boolean hasSubject() { 
1299      return this.subject != null && !this.subject.isEmpty();
1300    }
1301
1302    /**
1303     * @param value {@link #subject} (The patient or group that is the focus of this communication request.)
1304     */
1305    public CommunicationRequest setSubject(Reference value) { 
1306      this.subject = value;
1307      return this;
1308    }
1309
1310    /**
1311     * @return {@link #subject} 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 patient or group that is the focus of this communication request.)
1312     */
1313    public Resource getSubjectTarget() { 
1314      return this.subjectTarget;
1315    }
1316
1317    /**
1318     * @param value {@link #subject} 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 patient or group that is the focus of this communication request.)
1319     */
1320    public CommunicationRequest setSubjectTarget(Resource value) { 
1321      this.subjectTarget = value;
1322      return this;
1323    }
1324
1325    /**
1326     * @return {@link #about} (Other resources that pertain to this communication request and to which this communication request should be associated.)
1327     */
1328    public List<Reference> getAbout() { 
1329      if (this.about == null)
1330        this.about = new ArrayList<Reference>();
1331      return this.about;
1332    }
1333
1334    /**
1335     * @return Returns a reference to <code>this</code> for easy method chaining
1336     */
1337    public CommunicationRequest setAbout(List<Reference> theAbout) { 
1338      this.about = theAbout;
1339      return this;
1340    }
1341
1342    public boolean hasAbout() { 
1343      if (this.about == null)
1344        return false;
1345      for (Reference item : this.about)
1346        if (!item.isEmpty())
1347          return true;
1348      return false;
1349    }
1350
1351    public Reference addAbout() { //3
1352      Reference t = new Reference();
1353      if (this.about == null)
1354        this.about = new ArrayList<Reference>();
1355      this.about.add(t);
1356      return t;
1357    }
1358
1359    public CommunicationRequest addAbout(Reference t) { //3
1360      if (t == null)
1361        return this;
1362      if (this.about == null)
1363        this.about = new ArrayList<Reference>();
1364      this.about.add(t);
1365      return this;
1366    }
1367
1368    /**
1369     * @return The first repetition of repeating field {@link #about}, creating it if it does not already exist
1370     */
1371    public Reference getAboutFirstRep() { 
1372      if (getAbout().isEmpty()) {
1373        addAbout();
1374      }
1375      return getAbout().get(0);
1376    }
1377
1378    /**
1379     * @deprecated Use Reference#setResource(IBaseResource) instead
1380     */
1381    @Deprecated
1382    public List<Resource> getAboutTarget() { 
1383      if (this.aboutTarget == null)
1384        this.aboutTarget = new ArrayList<Resource>();
1385      return this.aboutTarget;
1386    }
1387
1388    /**
1389     * @return {@link #encounter} (The Encounter during which this CommunicationRequest was created or to which the creation of this record is tightly associated.)
1390     */
1391    public Reference getEncounter() { 
1392      if (this.encounter == null)
1393        if (Configuration.errorOnAutoCreate())
1394          throw new Error("Attempt to auto-create CommunicationRequest.encounter");
1395        else if (Configuration.doAutoCreate())
1396          this.encounter = new Reference(); // cc
1397      return this.encounter;
1398    }
1399
1400    public boolean hasEncounter() { 
1401      return this.encounter != null && !this.encounter.isEmpty();
1402    }
1403
1404    /**
1405     * @param value {@link #encounter} (The Encounter during which this CommunicationRequest was created or to which the creation of this record is tightly associated.)
1406     */
1407    public CommunicationRequest setEncounter(Reference value) { 
1408      this.encounter = value;
1409      return this;
1410    }
1411
1412    /**
1413     * @return {@link #encounter} 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 Encounter during which this CommunicationRequest was created or to which the creation of this record is tightly associated.)
1414     */
1415    public Encounter getEncounterTarget() { 
1416      if (this.encounterTarget == null)
1417        if (Configuration.errorOnAutoCreate())
1418          throw new Error("Attempt to auto-create CommunicationRequest.encounter");
1419        else if (Configuration.doAutoCreate())
1420          this.encounterTarget = new Encounter(); // aa
1421      return this.encounterTarget;
1422    }
1423
1424    /**
1425     * @param value {@link #encounter} 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 Encounter during which this CommunicationRequest was created or to which the creation of this record is tightly associated.)
1426     */
1427    public CommunicationRequest setEncounterTarget(Encounter value) { 
1428      this.encounterTarget = value;
1429      return this;
1430    }
1431
1432    /**
1433     * @return {@link #payload} (Text, attachment(s), or resource(s) to be communicated to the recipient.)
1434     */
1435    public List<CommunicationRequestPayloadComponent> getPayload() { 
1436      if (this.payload == null)
1437        this.payload = new ArrayList<CommunicationRequestPayloadComponent>();
1438      return this.payload;
1439    }
1440
1441    /**
1442     * @return Returns a reference to <code>this</code> for easy method chaining
1443     */
1444    public CommunicationRequest setPayload(List<CommunicationRequestPayloadComponent> thePayload) { 
1445      this.payload = thePayload;
1446      return this;
1447    }
1448
1449    public boolean hasPayload() { 
1450      if (this.payload == null)
1451        return false;
1452      for (CommunicationRequestPayloadComponent item : this.payload)
1453        if (!item.isEmpty())
1454          return true;
1455      return false;
1456    }
1457
1458    public CommunicationRequestPayloadComponent addPayload() { //3
1459      CommunicationRequestPayloadComponent t = new CommunicationRequestPayloadComponent();
1460      if (this.payload == null)
1461        this.payload = new ArrayList<CommunicationRequestPayloadComponent>();
1462      this.payload.add(t);
1463      return t;
1464    }
1465
1466    public CommunicationRequest addPayload(CommunicationRequestPayloadComponent t) { //3
1467      if (t == null)
1468        return this;
1469      if (this.payload == null)
1470        this.payload = new ArrayList<CommunicationRequestPayloadComponent>();
1471      this.payload.add(t);
1472      return this;
1473    }
1474
1475    /**
1476     * @return The first repetition of repeating field {@link #payload}, creating it if it does not already exist
1477     */
1478    public CommunicationRequestPayloadComponent getPayloadFirstRep() { 
1479      if (getPayload().isEmpty()) {
1480        addPayload();
1481      }
1482      return getPayload().get(0);
1483    }
1484
1485    /**
1486     * @return {@link #occurrence} (The time when this communication is to occur.)
1487     */
1488    public Type getOccurrence() { 
1489      return this.occurrence;
1490    }
1491
1492    /**
1493     * @return {@link #occurrence} (The time when this communication is to occur.)
1494     */
1495    public DateTimeType getOccurrenceDateTimeType() throws FHIRException { 
1496      if (this.occurrence == null)
1497        this.occurrence = new DateTimeType();
1498      if (!(this.occurrence instanceof DateTimeType))
1499        throw new FHIRException("Type mismatch: the type DateTimeType was expected, but "+this.occurrence.getClass().getName()+" was encountered");
1500      return (DateTimeType) this.occurrence;
1501    }
1502
1503    public boolean hasOccurrenceDateTimeType() { 
1504      return this != null && this.occurrence instanceof DateTimeType;
1505    }
1506
1507    /**
1508     * @return {@link #occurrence} (The time when this communication is to occur.)
1509     */
1510    public Period getOccurrencePeriod() throws FHIRException { 
1511      if (this.occurrence == null)
1512        this.occurrence = new Period();
1513      if (!(this.occurrence instanceof Period))
1514        throw new FHIRException("Type mismatch: the type Period was expected, but "+this.occurrence.getClass().getName()+" was encountered");
1515      return (Period) this.occurrence;
1516    }
1517
1518    public boolean hasOccurrencePeriod() { 
1519      return this != null && this.occurrence instanceof Period;
1520    }
1521
1522    public boolean hasOccurrence() { 
1523      return this.occurrence != null && !this.occurrence.isEmpty();
1524    }
1525
1526    /**
1527     * @param value {@link #occurrence} (The time when this communication is to occur.)
1528     */
1529    public CommunicationRequest setOccurrence(Type value) { 
1530      if (value != null && !(value instanceof DateTimeType || value instanceof Period))
1531        throw new Error("Not the right type for CommunicationRequest.occurrence[x]: "+value.fhirType());
1532      this.occurrence = value;
1533      return this;
1534    }
1535
1536    /**
1537     * @return {@link #authoredOn} (For draft requests, indicates the date of initial creation.  For requests with other statuses, indicates the date of activation.). This is the underlying object with id, value and extensions. The accessor "getAuthoredOn" gives direct access to the value
1538     */
1539    public DateTimeType getAuthoredOnElement() { 
1540      if (this.authoredOn == null)
1541        if (Configuration.errorOnAutoCreate())
1542          throw new Error("Attempt to auto-create CommunicationRequest.authoredOn");
1543        else if (Configuration.doAutoCreate())
1544          this.authoredOn = new DateTimeType(); // bb
1545      return this.authoredOn;
1546    }
1547
1548    public boolean hasAuthoredOnElement() { 
1549      return this.authoredOn != null && !this.authoredOn.isEmpty();
1550    }
1551
1552    public boolean hasAuthoredOn() { 
1553      return this.authoredOn != null && !this.authoredOn.isEmpty();
1554    }
1555
1556    /**
1557     * @param value {@link #authoredOn} (For draft requests, indicates the date of initial creation.  For requests with other statuses, indicates the date of activation.). This is the underlying object with id, value and extensions. The accessor "getAuthoredOn" gives direct access to the value
1558     */
1559    public CommunicationRequest setAuthoredOnElement(DateTimeType value) { 
1560      this.authoredOn = value;
1561      return this;
1562    }
1563
1564    /**
1565     * @return For draft requests, indicates the date of initial creation.  For requests with other statuses, indicates the date of activation.
1566     */
1567    public Date getAuthoredOn() { 
1568      return this.authoredOn == null ? null : this.authoredOn.getValue();
1569    }
1570
1571    /**
1572     * @param value For draft requests, indicates the date of initial creation.  For requests with other statuses, indicates the date of activation.
1573     */
1574    public CommunicationRequest setAuthoredOn(Date value) { 
1575      if (value == null)
1576        this.authoredOn = null;
1577      else {
1578        if (this.authoredOn == null)
1579          this.authoredOn = new DateTimeType();
1580        this.authoredOn.setValue(value);
1581      }
1582      return this;
1583    }
1584
1585    /**
1586     * @return {@link #requester} (The device, individual, or organization who initiated the request and has responsibility for its activation.)
1587     */
1588    public Reference getRequester() { 
1589      if (this.requester == null)
1590        if (Configuration.errorOnAutoCreate())
1591          throw new Error("Attempt to auto-create CommunicationRequest.requester");
1592        else if (Configuration.doAutoCreate())
1593          this.requester = new Reference(); // cc
1594      return this.requester;
1595    }
1596
1597    public boolean hasRequester() { 
1598      return this.requester != null && !this.requester.isEmpty();
1599    }
1600
1601    /**
1602     * @param value {@link #requester} (The device, individual, or organization who initiated the request and has responsibility for its activation.)
1603     */
1604    public CommunicationRequest setRequester(Reference value) { 
1605      this.requester = value;
1606      return this;
1607    }
1608
1609    /**
1610     * @return {@link #requester} 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 device, individual, or organization who initiated the request and has responsibility for its activation.)
1611     */
1612    public Resource getRequesterTarget() { 
1613      return this.requesterTarget;
1614    }
1615
1616    /**
1617     * @param value {@link #requester} 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 device, individual, or organization who initiated the request and has responsibility for its activation.)
1618     */
1619    public CommunicationRequest setRequesterTarget(Resource value) { 
1620      this.requesterTarget = value;
1621      return this;
1622    }
1623
1624    /**
1625     * @return {@link #recipient} (The entity (e.g. person, organization, clinical information system, device, group, or care team) which is the intended target of the communication.)
1626     */
1627    public List<Reference> getRecipient() { 
1628      if (this.recipient == null)
1629        this.recipient = new ArrayList<Reference>();
1630      return this.recipient;
1631    }
1632
1633    /**
1634     * @return Returns a reference to <code>this</code> for easy method chaining
1635     */
1636    public CommunicationRequest setRecipient(List<Reference> theRecipient) { 
1637      this.recipient = theRecipient;
1638      return this;
1639    }
1640
1641    public boolean hasRecipient() { 
1642      if (this.recipient == null)
1643        return false;
1644      for (Reference item : this.recipient)
1645        if (!item.isEmpty())
1646          return true;
1647      return false;
1648    }
1649
1650    public Reference addRecipient() { //3
1651      Reference t = new Reference();
1652      if (this.recipient == null)
1653        this.recipient = new ArrayList<Reference>();
1654      this.recipient.add(t);
1655      return t;
1656    }
1657
1658    public CommunicationRequest addRecipient(Reference t) { //3
1659      if (t == null)
1660        return this;
1661      if (this.recipient == null)
1662        this.recipient = new ArrayList<Reference>();
1663      this.recipient.add(t);
1664      return this;
1665    }
1666
1667    /**
1668     * @return The first repetition of repeating field {@link #recipient}, creating it if it does not already exist
1669     */
1670    public Reference getRecipientFirstRep() { 
1671      if (getRecipient().isEmpty()) {
1672        addRecipient();
1673      }
1674      return getRecipient().get(0);
1675    }
1676
1677    /**
1678     * @deprecated Use Reference#setResource(IBaseResource) instead
1679     */
1680    @Deprecated
1681    public List<Resource> getRecipientTarget() { 
1682      if (this.recipientTarget == null)
1683        this.recipientTarget = new ArrayList<Resource>();
1684      return this.recipientTarget;
1685    }
1686
1687    /**
1688     * @return {@link #sender} (The entity (e.g. person, organization, clinical information system, or device) which is to be the source of the communication.)
1689     */
1690    public Reference getSender() { 
1691      if (this.sender == null)
1692        if (Configuration.errorOnAutoCreate())
1693          throw new Error("Attempt to auto-create CommunicationRequest.sender");
1694        else if (Configuration.doAutoCreate())
1695          this.sender = new Reference(); // cc
1696      return this.sender;
1697    }
1698
1699    public boolean hasSender() { 
1700      return this.sender != null && !this.sender.isEmpty();
1701    }
1702
1703    /**
1704     * @param value {@link #sender} (The entity (e.g. person, organization, clinical information system, or device) which is to be the source of the communication.)
1705     */
1706    public CommunicationRequest setSender(Reference value) { 
1707      this.sender = value;
1708      return this;
1709    }
1710
1711    /**
1712     * @return {@link #sender} 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 entity (e.g. person, organization, clinical information system, or device) which is to be the source of the communication.)
1713     */
1714    public Resource getSenderTarget() { 
1715      return this.senderTarget;
1716    }
1717
1718    /**
1719     * @param value {@link #sender} 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 entity (e.g. person, organization, clinical information system, or device) which is to be the source of the communication.)
1720     */
1721    public CommunicationRequest setSenderTarget(Resource value) { 
1722      this.senderTarget = value;
1723      return this;
1724    }
1725
1726    /**
1727     * @return {@link #reasonCode} (Describes why the request is being made in coded or textual form.)
1728     */
1729    public List<CodeableConcept> getReasonCode() { 
1730      if (this.reasonCode == null)
1731        this.reasonCode = new ArrayList<CodeableConcept>();
1732      return this.reasonCode;
1733    }
1734
1735    /**
1736     * @return Returns a reference to <code>this</code> for easy method chaining
1737     */
1738    public CommunicationRequest setReasonCode(List<CodeableConcept> theReasonCode) { 
1739      this.reasonCode = theReasonCode;
1740      return this;
1741    }
1742
1743    public boolean hasReasonCode() { 
1744      if (this.reasonCode == null)
1745        return false;
1746      for (CodeableConcept item : this.reasonCode)
1747        if (!item.isEmpty())
1748          return true;
1749      return false;
1750    }
1751
1752    public CodeableConcept addReasonCode() { //3
1753      CodeableConcept t = new CodeableConcept();
1754      if (this.reasonCode == null)
1755        this.reasonCode = new ArrayList<CodeableConcept>();
1756      this.reasonCode.add(t);
1757      return t;
1758    }
1759
1760    public CommunicationRequest addReasonCode(CodeableConcept t) { //3
1761      if (t == null)
1762        return this;
1763      if (this.reasonCode == null)
1764        this.reasonCode = new ArrayList<CodeableConcept>();
1765      this.reasonCode.add(t);
1766      return this;
1767    }
1768
1769    /**
1770     * @return The first repetition of repeating field {@link #reasonCode}, creating it if it does not already exist
1771     */
1772    public CodeableConcept getReasonCodeFirstRep() { 
1773      if (getReasonCode().isEmpty()) {
1774        addReasonCode();
1775      }
1776      return getReasonCode().get(0);
1777    }
1778
1779    /**
1780     * @return {@link #reasonReference} (Indicates another resource whose existence justifies this request.)
1781     */
1782    public List<Reference> getReasonReference() { 
1783      if (this.reasonReference == null)
1784        this.reasonReference = new ArrayList<Reference>();
1785      return this.reasonReference;
1786    }
1787
1788    /**
1789     * @return Returns a reference to <code>this</code> for easy method chaining
1790     */
1791    public CommunicationRequest setReasonReference(List<Reference> theReasonReference) { 
1792      this.reasonReference = theReasonReference;
1793      return this;
1794    }
1795
1796    public boolean hasReasonReference() { 
1797      if (this.reasonReference == null)
1798        return false;
1799      for (Reference item : this.reasonReference)
1800        if (!item.isEmpty())
1801          return true;
1802      return false;
1803    }
1804
1805    public Reference addReasonReference() { //3
1806      Reference t = new Reference();
1807      if (this.reasonReference == null)
1808        this.reasonReference = new ArrayList<Reference>();
1809      this.reasonReference.add(t);
1810      return t;
1811    }
1812
1813    public CommunicationRequest addReasonReference(Reference t) { //3
1814      if (t == null)
1815        return this;
1816      if (this.reasonReference == null)
1817        this.reasonReference = new ArrayList<Reference>();
1818      this.reasonReference.add(t);
1819      return this;
1820    }
1821
1822    /**
1823     * @return The first repetition of repeating field {@link #reasonReference}, creating it if it does not already exist
1824     */
1825    public Reference getReasonReferenceFirstRep() { 
1826      if (getReasonReference().isEmpty()) {
1827        addReasonReference();
1828      }
1829      return getReasonReference().get(0);
1830    }
1831
1832    /**
1833     * @deprecated Use Reference#setResource(IBaseResource) instead
1834     */
1835    @Deprecated
1836    public List<Resource> getReasonReferenceTarget() { 
1837      if (this.reasonReferenceTarget == null)
1838        this.reasonReferenceTarget = new ArrayList<Resource>();
1839      return this.reasonReferenceTarget;
1840    }
1841
1842    /**
1843     * @return {@link #note} (Comments made about the request by the requester, sender, recipient, subject or other participants.)
1844     */
1845    public List<Annotation> getNote() { 
1846      if (this.note == null)
1847        this.note = new ArrayList<Annotation>();
1848      return this.note;
1849    }
1850
1851    /**
1852     * @return Returns a reference to <code>this</code> for easy method chaining
1853     */
1854    public CommunicationRequest setNote(List<Annotation> theNote) { 
1855      this.note = theNote;
1856      return this;
1857    }
1858
1859    public boolean hasNote() { 
1860      if (this.note == null)
1861        return false;
1862      for (Annotation item : this.note)
1863        if (!item.isEmpty())
1864          return true;
1865      return false;
1866    }
1867
1868    public Annotation addNote() { //3
1869      Annotation t = new Annotation();
1870      if (this.note == null)
1871        this.note = new ArrayList<Annotation>();
1872      this.note.add(t);
1873      return t;
1874    }
1875
1876    public CommunicationRequest addNote(Annotation t) { //3
1877      if (t == null)
1878        return this;
1879      if (this.note == null)
1880        this.note = new ArrayList<Annotation>();
1881      this.note.add(t);
1882      return this;
1883    }
1884
1885    /**
1886     * @return The first repetition of repeating field {@link #note}, creating it if it does not already exist
1887     */
1888    public Annotation getNoteFirstRep() { 
1889      if (getNote().isEmpty()) {
1890        addNote();
1891      }
1892      return getNote().get(0);
1893    }
1894
1895      protected void listChildren(List<Property> children) {
1896        super.listChildren(children);
1897        children.add(new Property("identifier", "Identifier", "Business identifiers assigned to this communication request by the performer or other systems which remain constant as the resource is updated and propagates from server to server.", 0, java.lang.Integer.MAX_VALUE, identifier));
1898        children.add(new Property("basedOn", "Reference(Any)", "A plan or proposal that is fulfilled in whole or in part by this request.", 0, java.lang.Integer.MAX_VALUE, basedOn));
1899        children.add(new Property("replaces", "Reference(CommunicationRequest)", "Completed or terminated request(s) whose function is taken by this new request.", 0, java.lang.Integer.MAX_VALUE, replaces));
1900        children.add(new Property("groupIdentifier", "Identifier", "A shared identifier common to all requests that were authorized more or less simultaneously by a single author, representing the identifier of the requisition, prescription or similar form.", 0, 1, groupIdentifier));
1901        children.add(new Property("status", "code", "The status of the proposal or order.", 0, 1, status));
1902        children.add(new Property("statusReason", "CodeableConcept", "Captures the reason for the current state of the CommunicationRequest.", 0, 1, statusReason));
1903        children.add(new Property("category", "CodeableConcept", "The type of message to be sent such as alert, notification, reminder, instruction, etc.", 0, java.lang.Integer.MAX_VALUE, category));
1904        children.add(new Property("priority", "code", "Characterizes how quickly the proposed act must be initiated. Includes concepts such as stat, urgent, routine.", 0, 1, priority));
1905        children.add(new Property("doNotPerform", "boolean", "If true indicates that the CommunicationRequest is asking for the specified action to *not* occur.", 0, 1, doNotPerform));
1906        children.add(new Property("medium", "CodeableConcept", "A channel that was used for this communication (e.g. email, fax).", 0, java.lang.Integer.MAX_VALUE, medium));
1907        children.add(new Property("subject", "Reference(Patient|Group)", "The patient or group that is the focus of this communication request.", 0, 1, subject));
1908        children.add(new Property("about", "Reference(Any)", "Other resources that pertain to this communication request and to which this communication request should be associated.", 0, java.lang.Integer.MAX_VALUE, about));
1909        children.add(new Property("encounter", "Reference(Encounter)", "The Encounter during which this CommunicationRequest was created or to which the creation of this record is tightly associated.", 0, 1, encounter));
1910        children.add(new Property("payload", "", "Text, attachment(s), or resource(s) to be communicated to the recipient.", 0, java.lang.Integer.MAX_VALUE, payload));
1911        children.add(new Property("occurrence[x]", "dateTime|Period", "The time when this communication is to occur.", 0, 1, occurrence));
1912        children.add(new Property("authoredOn", "dateTime", "For draft requests, indicates the date of initial creation.  For requests with other statuses, indicates the date of activation.", 0, 1, authoredOn));
1913        children.add(new Property("requester", "Reference(Practitioner|PractitionerRole|Organization|Patient|RelatedPerson|Device)", "The device, individual, or organization who initiated the request and has responsibility for its activation.", 0, 1, requester));
1914        children.add(new Property("recipient", "Reference(Device|Organization|Patient|Practitioner|PractitionerRole|RelatedPerson|Group|CareTeam|HealthcareService)", "The entity (e.g. person, organization, clinical information system, device, group, or care team) which is the intended target of the communication.", 0, java.lang.Integer.MAX_VALUE, recipient));
1915        children.add(new Property("sender", "Reference(Device|Organization|Patient|Practitioner|PractitionerRole|RelatedPerson|HealthcareService)", "The entity (e.g. person, organization, clinical information system, or device) which is to be the source of the communication.", 0, 1, sender));
1916        children.add(new Property("reasonCode", "CodeableConcept", "Describes why the request is being made in coded or textual form.", 0, java.lang.Integer.MAX_VALUE, reasonCode));
1917        children.add(new Property("reasonReference", "Reference(Condition|Observation|DiagnosticReport|DocumentReference)", "Indicates another resource whose existence justifies this request.", 0, java.lang.Integer.MAX_VALUE, reasonReference));
1918        children.add(new Property("note", "Annotation", "Comments made about the request by the requester, sender, recipient, subject or other participants.", 0, java.lang.Integer.MAX_VALUE, note));
1919      }
1920
1921      @Override
1922      public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
1923        switch (_hash) {
1924        case -1618432855: /*identifier*/  return new Property("identifier", "Identifier", "Business identifiers assigned to this communication request by the performer or other systems which remain constant as the resource is updated and propagates from server to server.", 0, java.lang.Integer.MAX_VALUE, identifier);
1925        case -332612366: /*basedOn*/  return new Property("basedOn", "Reference(Any)", "A plan or proposal that is fulfilled in whole or in part by this request.", 0, java.lang.Integer.MAX_VALUE, basedOn);
1926        case -430332865: /*replaces*/  return new Property("replaces", "Reference(CommunicationRequest)", "Completed or terminated request(s) whose function is taken by this new request.", 0, java.lang.Integer.MAX_VALUE, replaces);
1927        case -445338488: /*groupIdentifier*/  return new Property("groupIdentifier", "Identifier", "A shared identifier common to all requests that were authorized more or less simultaneously by a single author, representing the identifier of the requisition, prescription or similar form.", 0, 1, groupIdentifier);
1928        case -892481550: /*status*/  return new Property("status", "code", "The status of the proposal or order.", 0, 1, status);
1929        case 2051346646: /*statusReason*/  return new Property("statusReason", "CodeableConcept", "Captures the reason for the current state of the CommunicationRequest.", 0, 1, statusReason);
1930        case 50511102: /*category*/  return new Property("category", "CodeableConcept", "The type of message to be sent such as alert, notification, reminder, instruction, etc.", 0, java.lang.Integer.MAX_VALUE, category);
1931        case -1165461084: /*priority*/  return new Property("priority", "code", "Characterizes how quickly the proposed act must be initiated. Includes concepts such as stat, urgent, routine.", 0, 1, priority);
1932        case -1788508167: /*doNotPerform*/  return new Property("doNotPerform", "boolean", "If true indicates that the CommunicationRequest is asking for the specified action to *not* occur.", 0, 1, doNotPerform);
1933        case -1078030475: /*medium*/  return new Property("medium", "CodeableConcept", "A channel that was used for this communication (e.g. email, fax).", 0, java.lang.Integer.MAX_VALUE, medium);
1934        case -1867885268: /*subject*/  return new Property("subject", "Reference(Patient|Group)", "The patient or group that is the focus of this communication request.", 0, 1, subject);
1935        case 92611469: /*about*/  return new Property("about", "Reference(Any)", "Other resources that pertain to this communication request and to which this communication request should be associated.", 0, java.lang.Integer.MAX_VALUE, about);
1936        case 1524132147: /*encounter*/  return new Property("encounter", "Reference(Encounter)", "The Encounter during which this CommunicationRequest was created or to which the creation of this record is tightly associated.", 0, 1, encounter);
1937        case -786701938: /*payload*/  return new Property("payload", "", "Text, attachment(s), or resource(s) to be communicated to the recipient.", 0, java.lang.Integer.MAX_VALUE, payload);
1938        case -2022646513: /*occurrence[x]*/  return new Property("occurrence[x]", "dateTime|Period", "The time when this communication is to occur.", 0, 1, occurrence);
1939        case 1687874001: /*occurrence*/  return new Property("occurrence[x]", "dateTime|Period", "The time when this communication is to occur.", 0, 1, occurrence);
1940        case -298443636: /*occurrenceDateTime*/  return new Property("occurrence[x]", "dateTime|Period", "The time when this communication is to occur.", 0, 1, occurrence);
1941        case 1397156594: /*occurrencePeriod*/  return new Property("occurrence[x]", "dateTime|Period", "The time when this communication is to occur.", 0, 1, occurrence);
1942        case -1500852503: /*authoredOn*/  return new Property("authoredOn", "dateTime", "For draft requests, indicates the date of initial creation.  For requests with other statuses, indicates the date of activation.", 0, 1, authoredOn);
1943        case 693933948: /*requester*/  return new Property("requester", "Reference(Practitioner|PractitionerRole|Organization|Patient|RelatedPerson|Device)", "The device, individual, or organization who initiated the request and has responsibility for its activation.", 0, 1, requester);
1944        case 820081177: /*recipient*/  return new Property("recipient", "Reference(Device|Organization|Patient|Practitioner|PractitionerRole|RelatedPerson|Group|CareTeam|HealthcareService)", "The entity (e.g. person, organization, clinical information system, device, group, or care team) which is the intended target of the communication.", 0, java.lang.Integer.MAX_VALUE, recipient);
1945        case -905962955: /*sender*/  return new Property("sender", "Reference(Device|Organization|Patient|Practitioner|PractitionerRole|RelatedPerson|HealthcareService)", "The entity (e.g. person, organization, clinical information system, or device) which is to be the source of the communication.", 0, 1, sender);
1946        case 722137681: /*reasonCode*/  return new Property("reasonCode", "CodeableConcept", "Describes why the request is being made in coded or textual form.", 0, java.lang.Integer.MAX_VALUE, reasonCode);
1947        case -1146218137: /*reasonReference*/  return new Property("reasonReference", "Reference(Condition|Observation|DiagnosticReport|DocumentReference)", "Indicates another resource whose existence justifies this request.", 0, java.lang.Integer.MAX_VALUE, reasonReference);
1948        case 3387378: /*note*/  return new Property("note", "Annotation", "Comments made about the request by the requester, sender, recipient, subject or other participants.", 0, java.lang.Integer.MAX_VALUE, note);
1949        default: return super.getNamedProperty(_hash, _name, _checkValid);
1950        }
1951
1952      }
1953
1954      @Override
1955      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
1956        switch (hash) {
1957        case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier
1958        case -332612366: /*basedOn*/ return this.basedOn == null ? new Base[0] : this.basedOn.toArray(new Base[this.basedOn.size()]); // Reference
1959        case -430332865: /*replaces*/ return this.replaces == null ? new Base[0] : this.replaces.toArray(new Base[this.replaces.size()]); // Reference
1960        case -445338488: /*groupIdentifier*/ return this.groupIdentifier == null ? new Base[0] : new Base[] {this.groupIdentifier}; // Identifier
1961        case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<CommunicationRequestStatus>
1962        case 2051346646: /*statusReason*/ return this.statusReason == null ? new Base[0] : new Base[] {this.statusReason}; // CodeableConcept
1963        case 50511102: /*category*/ return this.category == null ? new Base[0] : this.category.toArray(new Base[this.category.size()]); // CodeableConcept
1964        case -1165461084: /*priority*/ return this.priority == null ? new Base[0] : new Base[] {this.priority}; // Enumeration<CommunicationPriority>
1965        case -1788508167: /*doNotPerform*/ return this.doNotPerform == null ? new Base[0] : new Base[] {this.doNotPerform}; // BooleanType
1966        case -1078030475: /*medium*/ return this.medium == null ? new Base[0] : this.medium.toArray(new Base[this.medium.size()]); // CodeableConcept
1967        case -1867885268: /*subject*/ return this.subject == null ? new Base[0] : new Base[] {this.subject}; // Reference
1968        case 92611469: /*about*/ return this.about == null ? new Base[0] : this.about.toArray(new Base[this.about.size()]); // Reference
1969        case 1524132147: /*encounter*/ return this.encounter == null ? new Base[0] : new Base[] {this.encounter}; // Reference
1970        case -786701938: /*payload*/ return this.payload == null ? new Base[0] : this.payload.toArray(new Base[this.payload.size()]); // CommunicationRequestPayloadComponent
1971        case 1687874001: /*occurrence*/ return this.occurrence == null ? new Base[0] : new Base[] {this.occurrence}; // Type
1972        case -1500852503: /*authoredOn*/ return this.authoredOn == null ? new Base[0] : new Base[] {this.authoredOn}; // DateTimeType
1973        case 693933948: /*requester*/ return this.requester == null ? new Base[0] : new Base[] {this.requester}; // Reference
1974        case 820081177: /*recipient*/ return this.recipient == null ? new Base[0] : this.recipient.toArray(new Base[this.recipient.size()]); // Reference
1975        case -905962955: /*sender*/ return this.sender == null ? new Base[0] : new Base[] {this.sender}; // Reference
1976        case 722137681: /*reasonCode*/ return this.reasonCode == null ? new Base[0] : this.reasonCode.toArray(new Base[this.reasonCode.size()]); // CodeableConcept
1977        case -1146218137: /*reasonReference*/ return this.reasonReference == null ? new Base[0] : this.reasonReference.toArray(new Base[this.reasonReference.size()]); // Reference
1978        case 3387378: /*note*/ return this.note == null ? new Base[0] : this.note.toArray(new Base[this.note.size()]); // Annotation
1979        default: return super.getProperty(hash, name, checkValid);
1980        }
1981
1982      }
1983
1984      @Override
1985      public Base setProperty(int hash, String name, Base value) throws FHIRException {
1986        switch (hash) {
1987        case -1618432855: // identifier
1988          this.getIdentifier().add(castToIdentifier(value)); // Identifier
1989          return value;
1990        case -332612366: // basedOn
1991          this.getBasedOn().add(castToReference(value)); // Reference
1992          return value;
1993        case -430332865: // replaces
1994          this.getReplaces().add(castToReference(value)); // Reference
1995          return value;
1996        case -445338488: // groupIdentifier
1997          this.groupIdentifier = castToIdentifier(value); // Identifier
1998          return value;
1999        case -892481550: // status
2000          value = new CommunicationRequestStatusEnumFactory().fromType(castToCode(value));
2001          this.status = (Enumeration) value; // Enumeration<CommunicationRequestStatus>
2002          return value;
2003        case 2051346646: // statusReason
2004          this.statusReason = castToCodeableConcept(value); // CodeableConcept
2005          return value;
2006        case 50511102: // category
2007          this.getCategory().add(castToCodeableConcept(value)); // CodeableConcept
2008          return value;
2009        case -1165461084: // priority
2010          value = new CommunicationPriorityEnumFactory().fromType(castToCode(value));
2011          this.priority = (Enumeration) value; // Enumeration<CommunicationPriority>
2012          return value;
2013        case -1788508167: // doNotPerform
2014          this.doNotPerform = castToBoolean(value); // BooleanType
2015          return value;
2016        case -1078030475: // medium
2017          this.getMedium().add(castToCodeableConcept(value)); // CodeableConcept
2018          return value;
2019        case -1867885268: // subject
2020          this.subject = castToReference(value); // Reference
2021          return value;
2022        case 92611469: // about
2023          this.getAbout().add(castToReference(value)); // Reference
2024          return value;
2025        case 1524132147: // encounter
2026          this.encounter = castToReference(value); // Reference
2027          return value;
2028        case -786701938: // payload
2029          this.getPayload().add((CommunicationRequestPayloadComponent) value); // CommunicationRequestPayloadComponent
2030          return value;
2031        case 1687874001: // occurrence
2032          this.occurrence = castToType(value); // Type
2033          return value;
2034        case -1500852503: // authoredOn
2035          this.authoredOn = castToDateTime(value); // DateTimeType
2036          return value;
2037        case 693933948: // requester
2038          this.requester = castToReference(value); // Reference
2039          return value;
2040        case 820081177: // recipient
2041          this.getRecipient().add(castToReference(value)); // Reference
2042          return value;
2043        case -905962955: // sender
2044          this.sender = castToReference(value); // Reference
2045          return value;
2046        case 722137681: // reasonCode
2047          this.getReasonCode().add(castToCodeableConcept(value)); // CodeableConcept
2048          return value;
2049        case -1146218137: // reasonReference
2050          this.getReasonReference().add(castToReference(value)); // Reference
2051          return value;
2052        case 3387378: // note
2053          this.getNote().add(castToAnnotation(value)); // Annotation
2054          return value;
2055        default: return super.setProperty(hash, name, value);
2056        }
2057
2058      }
2059
2060      @Override
2061      public Base setProperty(String name, Base value) throws FHIRException {
2062        if (name.equals("identifier")) {
2063          this.getIdentifier().add(castToIdentifier(value));
2064        } else if (name.equals("basedOn")) {
2065          this.getBasedOn().add(castToReference(value));
2066        } else if (name.equals("replaces")) {
2067          this.getReplaces().add(castToReference(value));
2068        } else if (name.equals("groupIdentifier")) {
2069          this.groupIdentifier = castToIdentifier(value); // Identifier
2070        } else if (name.equals("status")) {
2071          value = new CommunicationRequestStatusEnumFactory().fromType(castToCode(value));
2072          this.status = (Enumeration) value; // Enumeration<CommunicationRequestStatus>
2073        } else if (name.equals("statusReason")) {
2074          this.statusReason = castToCodeableConcept(value); // CodeableConcept
2075        } else if (name.equals("category")) {
2076          this.getCategory().add(castToCodeableConcept(value));
2077        } else if (name.equals("priority")) {
2078          value = new CommunicationPriorityEnumFactory().fromType(castToCode(value));
2079          this.priority = (Enumeration) value; // Enumeration<CommunicationPriority>
2080        } else if (name.equals("doNotPerform")) {
2081          this.doNotPerform = castToBoolean(value); // BooleanType
2082        } else if (name.equals("medium")) {
2083          this.getMedium().add(castToCodeableConcept(value));
2084        } else if (name.equals("subject")) {
2085          this.subject = castToReference(value); // Reference
2086        } else if (name.equals("about")) {
2087          this.getAbout().add(castToReference(value));
2088        } else if (name.equals("encounter")) {
2089          this.encounter = castToReference(value); // Reference
2090        } else if (name.equals("payload")) {
2091          this.getPayload().add((CommunicationRequestPayloadComponent) value);
2092        } else if (name.equals("occurrence[x]")) {
2093          this.occurrence = castToType(value); // Type
2094        } else if (name.equals("authoredOn")) {
2095          this.authoredOn = castToDateTime(value); // DateTimeType
2096        } else if (name.equals("requester")) {
2097          this.requester = castToReference(value); // Reference
2098        } else if (name.equals("recipient")) {
2099          this.getRecipient().add(castToReference(value));
2100        } else if (name.equals("sender")) {
2101          this.sender = castToReference(value); // Reference
2102        } else if (name.equals("reasonCode")) {
2103          this.getReasonCode().add(castToCodeableConcept(value));
2104        } else if (name.equals("reasonReference")) {
2105          this.getReasonReference().add(castToReference(value));
2106        } else if (name.equals("note")) {
2107          this.getNote().add(castToAnnotation(value));
2108        } else
2109          return super.setProperty(name, value);
2110        return value;
2111      }
2112
2113      @Override
2114      public Base makeProperty(int hash, String name) throws FHIRException {
2115        switch (hash) {
2116        case -1618432855:  return addIdentifier(); 
2117        case -332612366:  return addBasedOn(); 
2118        case -430332865:  return addReplaces(); 
2119        case -445338488:  return getGroupIdentifier(); 
2120        case -892481550:  return getStatusElement();
2121        case 2051346646:  return getStatusReason(); 
2122        case 50511102:  return addCategory(); 
2123        case -1165461084:  return getPriorityElement();
2124        case -1788508167:  return getDoNotPerformElement();
2125        case -1078030475:  return addMedium(); 
2126        case -1867885268:  return getSubject(); 
2127        case 92611469:  return addAbout(); 
2128        case 1524132147:  return getEncounter(); 
2129        case -786701938:  return addPayload(); 
2130        case -2022646513:  return getOccurrence(); 
2131        case 1687874001:  return getOccurrence(); 
2132        case -1500852503:  return getAuthoredOnElement();
2133        case 693933948:  return getRequester(); 
2134        case 820081177:  return addRecipient(); 
2135        case -905962955:  return getSender(); 
2136        case 722137681:  return addReasonCode(); 
2137        case -1146218137:  return addReasonReference(); 
2138        case 3387378:  return addNote(); 
2139        default: return super.makeProperty(hash, name);
2140        }
2141
2142      }
2143
2144      @Override
2145      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
2146        switch (hash) {
2147        case -1618432855: /*identifier*/ return new String[] {"Identifier"};
2148        case -332612366: /*basedOn*/ return new String[] {"Reference"};
2149        case -430332865: /*replaces*/ return new String[] {"Reference"};
2150        case -445338488: /*groupIdentifier*/ return new String[] {"Identifier"};
2151        case -892481550: /*status*/ return new String[] {"code"};
2152        case 2051346646: /*statusReason*/ return new String[] {"CodeableConcept"};
2153        case 50511102: /*category*/ return new String[] {"CodeableConcept"};
2154        case -1165461084: /*priority*/ return new String[] {"code"};
2155        case -1788508167: /*doNotPerform*/ return new String[] {"boolean"};
2156        case -1078030475: /*medium*/ return new String[] {"CodeableConcept"};
2157        case -1867885268: /*subject*/ return new String[] {"Reference"};
2158        case 92611469: /*about*/ return new String[] {"Reference"};
2159        case 1524132147: /*encounter*/ return new String[] {"Reference"};
2160        case -786701938: /*payload*/ return new String[] {};
2161        case 1687874001: /*occurrence*/ return new String[] {"dateTime", "Period"};
2162        case -1500852503: /*authoredOn*/ return new String[] {"dateTime"};
2163        case 693933948: /*requester*/ return new String[] {"Reference"};
2164        case 820081177: /*recipient*/ return new String[] {"Reference"};
2165        case -905962955: /*sender*/ return new String[] {"Reference"};
2166        case 722137681: /*reasonCode*/ return new String[] {"CodeableConcept"};
2167        case -1146218137: /*reasonReference*/ return new String[] {"Reference"};
2168        case 3387378: /*note*/ return new String[] {"Annotation"};
2169        default: return super.getTypesForProperty(hash, name);
2170        }
2171
2172      }
2173
2174      @Override
2175      public Base addChild(String name) throws FHIRException {
2176        if (name.equals("identifier")) {
2177          return addIdentifier();
2178        }
2179        else if (name.equals("basedOn")) {
2180          return addBasedOn();
2181        }
2182        else if (name.equals("replaces")) {
2183          return addReplaces();
2184        }
2185        else if (name.equals("groupIdentifier")) {
2186          this.groupIdentifier = new Identifier();
2187          return this.groupIdentifier;
2188        }
2189        else if (name.equals("status")) {
2190          throw new FHIRException("Cannot call addChild on a primitive type CommunicationRequest.status");
2191        }
2192        else if (name.equals("statusReason")) {
2193          this.statusReason = new CodeableConcept();
2194          return this.statusReason;
2195        }
2196        else if (name.equals("category")) {
2197          return addCategory();
2198        }
2199        else if (name.equals("priority")) {
2200          throw new FHIRException("Cannot call addChild on a primitive type CommunicationRequest.priority");
2201        }
2202        else if (name.equals("doNotPerform")) {
2203          throw new FHIRException("Cannot call addChild on a primitive type CommunicationRequest.doNotPerform");
2204        }
2205        else if (name.equals("medium")) {
2206          return addMedium();
2207        }
2208        else if (name.equals("subject")) {
2209          this.subject = new Reference();
2210          return this.subject;
2211        }
2212        else if (name.equals("about")) {
2213          return addAbout();
2214        }
2215        else if (name.equals("encounter")) {
2216          this.encounter = new Reference();
2217          return this.encounter;
2218        }
2219        else if (name.equals("payload")) {
2220          return addPayload();
2221        }
2222        else if (name.equals("occurrenceDateTime")) {
2223          this.occurrence = new DateTimeType();
2224          return this.occurrence;
2225        }
2226        else if (name.equals("occurrencePeriod")) {
2227          this.occurrence = new Period();
2228          return this.occurrence;
2229        }
2230        else if (name.equals("authoredOn")) {
2231          throw new FHIRException("Cannot call addChild on a primitive type CommunicationRequest.authoredOn");
2232        }
2233        else if (name.equals("requester")) {
2234          this.requester = new Reference();
2235          return this.requester;
2236        }
2237        else if (name.equals("recipient")) {
2238          return addRecipient();
2239        }
2240        else if (name.equals("sender")) {
2241          this.sender = new Reference();
2242          return this.sender;
2243        }
2244        else if (name.equals("reasonCode")) {
2245          return addReasonCode();
2246        }
2247        else if (name.equals("reasonReference")) {
2248          return addReasonReference();
2249        }
2250        else if (name.equals("note")) {
2251          return addNote();
2252        }
2253        else
2254          return super.addChild(name);
2255      }
2256
2257  public String fhirType() {
2258    return "CommunicationRequest";
2259
2260  }
2261
2262      public CommunicationRequest copy() {
2263        CommunicationRequest dst = new CommunicationRequest();
2264        copyValues(dst);
2265        if (identifier != null) {
2266          dst.identifier = new ArrayList<Identifier>();
2267          for (Identifier i : identifier)
2268            dst.identifier.add(i.copy());
2269        };
2270        if (basedOn != null) {
2271          dst.basedOn = new ArrayList<Reference>();
2272          for (Reference i : basedOn)
2273            dst.basedOn.add(i.copy());
2274        };
2275        if (replaces != null) {
2276          dst.replaces = new ArrayList<Reference>();
2277          for (Reference i : replaces)
2278            dst.replaces.add(i.copy());
2279        };
2280        dst.groupIdentifier = groupIdentifier == null ? null : groupIdentifier.copy();
2281        dst.status = status == null ? null : status.copy();
2282        dst.statusReason = statusReason == null ? null : statusReason.copy();
2283        if (category != null) {
2284          dst.category = new ArrayList<CodeableConcept>();
2285          for (CodeableConcept i : category)
2286            dst.category.add(i.copy());
2287        };
2288        dst.priority = priority == null ? null : priority.copy();
2289        dst.doNotPerform = doNotPerform == null ? null : doNotPerform.copy();
2290        if (medium != null) {
2291          dst.medium = new ArrayList<CodeableConcept>();
2292          for (CodeableConcept i : medium)
2293            dst.medium.add(i.copy());
2294        };
2295        dst.subject = subject == null ? null : subject.copy();
2296        if (about != null) {
2297          dst.about = new ArrayList<Reference>();
2298          for (Reference i : about)
2299            dst.about.add(i.copy());
2300        };
2301        dst.encounter = encounter == null ? null : encounter.copy();
2302        if (payload != null) {
2303          dst.payload = new ArrayList<CommunicationRequestPayloadComponent>();
2304          for (CommunicationRequestPayloadComponent i : payload)
2305            dst.payload.add(i.copy());
2306        };
2307        dst.occurrence = occurrence == null ? null : occurrence.copy();
2308        dst.authoredOn = authoredOn == null ? null : authoredOn.copy();
2309        dst.requester = requester == null ? null : requester.copy();
2310        if (recipient != null) {
2311          dst.recipient = new ArrayList<Reference>();
2312          for (Reference i : recipient)
2313            dst.recipient.add(i.copy());
2314        };
2315        dst.sender = sender == null ? null : sender.copy();
2316        if (reasonCode != null) {
2317          dst.reasonCode = new ArrayList<CodeableConcept>();
2318          for (CodeableConcept i : reasonCode)
2319            dst.reasonCode.add(i.copy());
2320        };
2321        if (reasonReference != null) {
2322          dst.reasonReference = new ArrayList<Reference>();
2323          for (Reference i : reasonReference)
2324            dst.reasonReference.add(i.copy());
2325        };
2326        if (note != null) {
2327          dst.note = new ArrayList<Annotation>();
2328          for (Annotation i : note)
2329            dst.note.add(i.copy());
2330        };
2331        return dst;
2332      }
2333
2334      protected CommunicationRequest typedCopy() {
2335        return copy();
2336      }
2337
2338      @Override
2339      public boolean equalsDeep(Base other_) {
2340        if (!super.equalsDeep(other_))
2341          return false;
2342        if (!(other_ instanceof CommunicationRequest))
2343          return false;
2344        CommunicationRequest o = (CommunicationRequest) other_;
2345        return compareDeep(identifier, o.identifier, true) && compareDeep(basedOn, o.basedOn, true) && compareDeep(replaces, o.replaces, true)
2346           && compareDeep(groupIdentifier, o.groupIdentifier, true) && compareDeep(status, o.status, true)
2347           && compareDeep(statusReason, o.statusReason, true) && compareDeep(category, o.category, true) && compareDeep(priority, o.priority, true)
2348           && compareDeep(doNotPerform, o.doNotPerform, true) && compareDeep(medium, o.medium, true) && compareDeep(subject, o.subject, true)
2349           && compareDeep(about, o.about, true) && compareDeep(encounter, o.encounter, true) && compareDeep(payload, o.payload, true)
2350           && compareDeep(occurrence, o.occurrence, true) && compareDeep(authoredOn, o.authoredOn, true) && compareDeep(requester, o.requester, true)
2351           && compareDeep(recipient, o.recipient, true) && compareDeep(sender, o.sender, true) && compareDeep(reasonCode, o.reasonCode, true)
2352           && compareDeep(reasonReference, o.reasonReference, true) && compareDeep(note, o.note, true);
2353      }
2354
2355      @Override
2356      public boolean equalsShallow(Base other_) {
2357        if (!super.equalsShallow(other_))
2358          return false;
2359        if (!(other_ instanceof CommunicationRequest))
2360          return false;
2361        CommunicationRequest o = (CommunicationRequest) other_;
2362        return compareValues(status, o.status, true) && compareValues(priority, o.priority, true) && compareValues(doNotPerform, o.doNotPerform, true)
2363           && compareValues(authoredOn, o.authoredOn, true);
2364      }
2365
2366      public boolean isEmpty() {
2367        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, basedOn, replaces
2368          , groupIdentifier, status, statusReason, category, priority, doNotPerform, medium
2369          , subject, about, encounter, payload, occurrence, authoredOn, requester, recipient
2370          , sender, reasonCode, reasonReference, note);
2371      }
2372
2373  @Override
2374  public ResourceType getResourceType() {
2375    return ResourceType.CommunicationRequest;
2376   }
2377
2378 /**
2379   * Search parameter: <b>requester</b>
2380   * <p>
2381   * Description: <b>Who/what is requesting service</b><br>
2382   * Type: <b>reference</b><br>
2383   * Path: <b>CommunicationRequest.requester</b><br>
2384   * </p>
2385   */
2386  @SearchParamDefinition(name="requester", path="CommunicationRequest.requester", description="Who/what is requesting service", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Patient"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Practitioner"), @ca.uhn.fhir.model.api.annotation.Compartment(name="RelatedPerson") }, target={Device.class, Organization.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } )
2387  public static final String SP_REQUESTER = "requester";
2388 /**
2389   * <b>Fluent Client</b> search parameter constant for <b>requester</b>
2390   * <p>
2391   * Description: <b>Who/what is requesting service</b><br>
2392   * Type: <b>reference</b><br>
2393   * Path: <b>CommunicationRequest.requester</b><br>
2394   * </p>
2395   */
2396  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam REQUESTER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_REQUESTER);
2397
2398/**
2399   * Constant for fluent queries to be used to add include statements. Specifies
2400   * the path value of "<b>CommunicationRequest:requester</b>".
2401   */
2402  public static final ca.uhn.fhir.model.api.Include INCLUDE_REQUESTER = new ca.uhn.fhir.model.api.Include("CommunicationRequest:requester").toLocked();
2403
2404 /**
2405   * Search parameter: <b>authored</b>
2406   * <p>
2407   * Description: <b>When request transitioned to being actionable</b><br>
2408   * Type: <b>date</b><br>
2409   * Path: <b>CommunicationRequest.authoredOn</b><br>
2410   * </p>
2411   */
2412  @SearchParamDefinition(name="authored", path="CommunicationRequest.authoredOn", description="When request transitioned to being actionable", type="date" )
2413  public static final String SP_AUTHORED = "authored";
2414 /**
2415   * <b>Fluent Client</b> search parameter constant for <b>authored</b>
2416   * <p>
2417   * Description: <b>When request transitioned to being actionable</b><br>
2418   * Type: <b>date</b><br>
2419   * Path: <b>CommunicationRequest.authoredOn</b><br>
2420   * </p>
2421   */
2422  public static final ca.uhn.fhir.rest.gclient.DateClientParam AUTHORED = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_AUTHORED);
2423
2424 /**
2425   * Search parameter: <b>identifier</b>
2426   * <p>
2427   * Description: <b>Unique identifier</b><br>
2428   * Type: <b>token</b><br>
2429   * Path: <b>CommunicationRequest.identifier</b><br>
2430   * </p>
2431   */
2432  @SearchParamDefinition(name="identifier", path="CommunicationRequest.identifier", description="Unique identifier", type="token" )
2433  public static final String SP_IDENTIFIER = "identifier";
2434 /**
2435   * <b>Fluent Client</b> search parameter constant for <b>identifier</b>
2436   * <p>
2437   * Description: <b>Unique identifier</b><br>
2438   * Type: <b>token</b><br>
2439   * Path: <b>CommunicationRequest.identifier</b><br>
2440   * </p>
2441   */
2442  public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER);
2443
2444 /**
2445   * Search parameter: <b>subject</b>
2446   * <p>
2447   * Description: <b>Focus of message</b><br>
2448   * Type: <b>reference</b><br>
2449   * Path: <b>CommunicationRequest.subject</b><br>
2450   * </p>
2451   */
2452  @SearchParamDefinition(name="subject", path="CommunicationRequest.subject", description="Focus of message", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Patient") }, target={Group.class, Patient.class } )
2453  public static final String SP_SUBJECT = "subject";
2454 /**
2455   * <b>Fluent Client</b> search parameter constant for <b>subject</b>
2456   * <p>
2457   * Description: <b>Focus of message</b><br>
2458   * Type: <b>reference</b><br>
2459   * Path: <b>CommunicationRequest.subject</b><br>
2460   * </p>
2461   */
2462  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SUBJECT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SUBJECT);
2463
2464/**
2465   * Constant for fluent queries to be used to add include statements. Specifies
2466   * the path value of "<b>CommunicationRequest:subject</b>".
2467   */
2468  public static final ca.uhn.fhir.model.api.Include INCLUDE_SUBJECT = new ca.uhn.fhir.model.api.Include("CommunicationRequest:subject").toLocked();
2469
2470 /**
2471   * Search parameter: <b>replaces</b>
2472   * <p>
2473   * Description: <b>Request(s) replaced by this request</b><br>
2474   * Type: <b>reference</b><br>
2475   * Path: <b>CommunicationRequest.replaces</b><br>
2476   * </p>
2477   */
2478  @SearchParamDefinition(name="replaces", path="CommunicationRequest.replaces", description="Request(s) replaced by this request", type="reference", target={CommunicationRequest.class } )
2479  public static final String SP_REPLACES = "replaces";
2480 /**
2481   * <b>Fluent Client</b> search parameter constant for <b>replaces</b>
2482   * <p>
2483   * Description: <b>Request(s) replaced by this request</b><br>
2484   * Type: <b>reference</b><br>
2485   * Path: <b>CommunicationRequest.replaces</b><br>
2486   * </p>
2487   */
2488  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam REPLACES = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_REPLACES);
2489
2490/**
2491   * Constant for fluent queries to be used to add include statements. Specifies
2492   * the path value of "<b>CommunicationRequest:replaces</b>".
2493   */
2494  public static final ca.uhn.fhir.model.api.Include INCLUDE_REPLACES = new ca.uhn.fhir.model.api.Include("CommunicationRequest:replaces").toLocked();
2495
2496 /**
2497   * Search parameter: <b>medium</b>
2498   * <p>
2499   * Description: <b>A channel of communication</b><br>
2500   * Type: <b>token</b><br>
2501   * Path: <b>CommunicationRequest.medium</b><br>
2502   * </p>
2503   */
2504  @SearchParamDefinition(name="medium", path="CommunicationRequest.medium", description="A channel of communication", type="token" )
2505  public static final String SP_MEDIUM = "medium";
2506 /**
2507   * <b>Fluent Client</b> search parameter constant for <b>medium</b>
2508   * <p>
2509   * Description: <b>A channel of communication</b><br>
2510   * Type: <b>token</b><br>
2511   * Path: <b>CommunicationRequest.medium</b><br>
2512   * </p>
2513   */
2514  public static final ca.uhn.fhir.rest.gclient.TokenClientParam MEDIUM = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_MEDIUM);
2515
2516 /**
2517   * Search parameter: <b>encounter</b>
2518   * <p>
2519   * Description: <b>Encounter created as part of</b><br>
2520   * Type: <b>reference</b><br>
2521   * Path: <b>CommunicationRequest.encounter</b><br>
2522   * </p>
2523   */
2524  @SearchParamDefinition(name="encounter", path="CommunicationRequest.encounter", description="Encounter created as part of", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Encounter") }, target={Encounter.class } )
2525  public static final String SP_ENCOUNTER = "encounter";
2526 /**
2527   * <b>Fluent Client</b> search parameter constant for <b>encounter</b>
2528   * <p>
2529   * Description: <b>Encounter created as part of</b><br>
2530   * Type: <b>reference</b><br>
2531   * Path: <b>CommunicationRequest.encounter</b><br>
2532   * </p>
2533   */
2534  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ENCOUNTER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ENCOUNTER);
2535
2536/**
2537   * Constant for fluent queries to be used to add include statements. Specifies
2538   * the path value of "<b>CommunicationRequest:encounter</b>".
2539   */
2540  public static final ca.uhn.fhir.model.api.Include INCLUDE_ENCOUNTER = new ca.uhn.fhir.model.api.Include("CommunicationRequest:encounter").toLocked();
2541
2542 /**
2543   * Search parameter: <b>occurrence</b>
2544   * <p>
2545   * Description: <b>When scheduled</b><br>
2546   * Type: <b>date</b><br>
2547   * Path: <b>CommunicationRequest.occurrenceDateTime</b><br>
2548   * </p>
2549   */
2550  @SearchParamDefinition(name="occurrence", path="(CommunicationRequest.occurrence as dateTime)", description="When scheduled", type="date" )
2551  public static final String SP_OCCURRENCE = "occurrence";
2552 /**
2553   * <b>Fluent Client</b> search parameter constant for <b>occurrence</b>
2554   * <p>
2555   * Description: <b>When scheduled</b><br>
2556   * Type: <b>date</b><br>
2557   * Path: <b>CommunicationRequest.occurrenceDateTime</b><br>
2558   * </p>
2559   */
2560  public static final ca.uhn.fhir.rest.gclient.DateClientParam OCCURRENCE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_OCCURRENCE);
2561
2562 /**
2563   * Search parameter: <b>priority</b>
2564   * <p>
2565   * Description: <b>Message urgency</b><br>
2566   * Type: <b>token</b><br>
2567   * Path: <b>CommunicationRequest.priority</b><br>
2568   * </p>
2569   */
2570  @SearchParamDefinition(name="priority", path="CommunicationRequest.priority", description="Message urgency", type="token" )
2571  public static final String SP_PRIORITY = "priority";
2572 /**
2573   * <b>Fluent Client</b> search parameter constant for <b>priority</b>
2574   * <p>
2575   * Description: <b>Message urgency</b><br>
2576   * Type: <b>token</b><br>
2577   * Path: <b>CommunicationRequest.priority</b><br>
2578   * </p>
2579   */
2580  public static final ca.uhn.fhir.rest.gclient.TokenClientParam PRIORITY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_PRIORITY);
2581
2582 /**
2583   * Search parameter: <b>group-identifier</b>
2584   * <p>
2585   * Description: <b>Composite request this is part of</b><br>
2586   * Type: <b>token</b><br>
2587   * Path: <b>CommunicationRequest.groupIdentifier</b><br>
2588   * </p>
2589   */
2590  @SearchParamDefinition(name="group-identifier", path="CommunicationRequest.groupIdentifier", description="Composite request this is part of", type="token" )
2591  public static final String SP_GROUP_IDENTIFIER = "group-identifier";
2592 /**
2593   * <b>Fluent Client</b> search parameter constant for <b>group-identifier</b>
2594   * <p>
2595   * Description: <b>Composite request this is part of</b><br>
2596   * Type: <b>token</b><br>
2597   * Path: <b>CommunicationRequest.groupIdentifier</b><br>
2598   * </p>
2599   */
2600  public static final ca.uhn.fhir.rest.gclient.TokenClientParam GROUP_IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_GROUP_IDENTIFIER);
2601
2602 /**
2603   * Search parameter: <b>based-on</b>
2604   * <p>
2605   * Description: <b>Fulfills plan or proposal</b><br>
2606   * Type: <b>reference</b><br>
2607   * Path: <b>CommunicationRequest.basedOn</b><br>
2608   * </p>
2609   */
2610  @SearchParamDefinition(name="based-on", path="CommunicationRequest.basedOn", description="Fulfills plan or proposal", type="reference" )
2611  public static final String SP_BASED_ON = "based-on";
2612 /**
2613   * <b>Fluent Client</b> search parameter constant for <b>based-on</b>
2614   * <p>
2615   * Description: <b>Fulfills plan or proposal</b><br>
2616   * Type: <b>reference</b><br>
2617   * Path: <b>CommunicationRequest.basedOn</b><br>
2618   * </p>
2619   */
2620  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam BASED_ON = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_BASED_ON);
2621
2622/**
2623   * Constant for fluent queries to be used to add include statements. Specifies
2624   * the path value of "<b>CommunicationRequest:based-on</b>".
2625   */
2626  public static final ca.uhn.fhir.model.api.Include INCLUDE_BASED_ON = new ca.uhn.fhir.model.api.Include("CommunicationRequest:based-on").toLocked();
2627
2628 /**
2629   * Search parameter: <b>sender</b>
2630   * <p>
2631   * Description: <b>Message sender</b><br>
2632   * Type: <b>reference</b><br>
2633   * Path: <b>CommunicationRequest.sender</b><br>
2634   * </p>
2635   */
2636  @SearchParamDefinition(name="sender", path="CommunicationRequest.sender", description="Message sender", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Device"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Patient"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Practitioner"), @ca.uhn.fhir.model.api.annotation.Compartment(name="RelatedPerson") }, target={Device.class, HealthcareService.class, Organization.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } )
2637  public static final String SP_SENDER = "sender";
2638 /**
2639   * <b>Fluent Client</b> search parameter constant for <b>sender</b>
2640   * <p>
2641   * Description: <b>Message sender</b><br>
2642   * Type: <b>reference</b><br>
2643   * Path: <b>CommunicationRequest.sender</b><br>
2644   * </p>
2645   */
2646  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SENDER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SENDER);
2647
2648/**
2649   * Constant for fluent queries to be used to add include statements. Specifies
2650   * the path value of "<b>CommunicationRequest:sender</b>".
2651   */
2652  public static final ca.uhn.fhir.model.api.Include INCLUDE_SENDER = new ca.uhn.fhir.model.api.Include("CommunicationRequest:sender").toLocked();
2653
2654 /**
2655   * Search parameter: <b>patient</b>
2656   * <p>
2657   * Description: <b>Focus of message</b><br>
2658   * Type: <b>reference</b><br>
2659   * Path: <b>CommunicationRequest.subject</b><br>
2660   * </p>
2661   */
2662  @SearchParamDefinition(name="patient", path="CommunicationRequest.subject.where(resolve() is Patient)", description="Focus of message", type="reference", target={Patient.class } )
2663  public static final String SP_PATIENT = "patient";
2664 /**
2665   * <b>Fluent Client</b> search parameter constant for <b>patient</b>
2666   * <p>
2667   * Description: <b>Focus of message</b><br>
2668   * Type: <b>reference</b><br>
2669   * Path: <b>CommunicationRequest.subject</b><br>
2670   * </p>
2671   */
2672  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT);
2673
2674/**
2675   * Constant for fluent queries to be used to add include statements. Specifies
2676   * the path value of "<b>CommunicationRequest:patient</b>".
2677   */
2678  public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("CommunicationRequest:patient").toLocked();
2679
2680 /**
2681   * Search parameter: <b>recipient</b>
2682   * <p>
2683   * Description: <b>Message recipient</b><br>
2684   * Type: <b>reference</b><br>
2685   * Path: <b>CommunicationRequest.recipient</b><br>
2686   * </p>
2687   */
2688  @SearchParamDefinition(name="recipient", path="CommunicationRequest.recipient", description="Message recipient", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Device"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Patient"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Practitioner"), @ca.uhn.fhir.model.api.annotation.Compartment(name="RelatedPerson") }, target={CareTeam.class, Device.class, Group.class, HealthcareService.class, Organization.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } )
2689  public static final String SP_RECIPIENT = "recipient";
2690 /**
2691   * <b>Fluent Client</b> search parameter constant for <b>recipient</b>
2692   * <p>
2693   * Description: <b>Message recipient</b><br>
2694   * Type: <b>reference</b><br>
2695   * Path: <b>CommunicationRequest.recipient</b><br>
2696   * </p>
2697   */
2698  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam RECIPIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_RECIPIENT);
2699
2700/**
2701   * Constant for fluent queries to be used to add include statements. Specifies
2702   * the path value of "<b>CommunicationRequest:recipient</b>".
2703   */
2704  public static final ca.uhn.fhir.model.api.Include INCLUDE_RECIPIENT = new ca.uhn.fhir.model.api.Include("CommunicationRequest:recipient").toLocked();
2705
2706 /**
2707   * Search parameter: <b>category</b>
2708   * <p>
2709   * Description: <b>Message category</b><br>
2710   * Type: <b>token</b><br>
2711   * Path: <b>CommunicationRequest.category</b><br>
2712   * </p>
2713   */
2714  @SearchParamDefinition(name="category", path="CommunicationRequest.category", description="Message category", type="token" )
2715  public static final String SP_CATEGORY = "category";
2716 /**
2717   * <b>Fluent Client</b> search parameter constant for <b>category</b>
2718   * <p>
2719   * Description: <b>Message category</b><br>
2720   * Type: <b>token</b><br>
2721   * Path: <b>CommunicationRequest.category</b><br>
2722   * </p>
2723   */
2724  public static final ca.uhn.fhir.rest.gclient.TokenClientParam CATEGORY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CATEGORY);
2725
2726 /**
2727   * Search parameter: <b>status</b>
2728   * <p>
2729   * Description: <b>draft | active | suspended | cancelled | completed | entered-in-error | unknown</b><br>
2730   * Type: <b>token</b><br>
2731   * Path: <b>CommunicationRequest.status</b><br>
2732   * </p>
2733   */
2734  @SearchParamDefinition(name="status", path="CommunicationRequest.status", description="draft | active | suspended | cancelled | completed | entered-in-error | unknown", type="token" )
2735  public static final String SP_STATUS = "status";
2736 /**
2737   * <b>Fluent Client</b> search parameter constant for <b>status</b>
2738   * <p>
2739   * Description: <b>draft | active | suspended | cancelled | completed | entered-in-error | unknown</b><br>
2740   * Type: <b>token</b><br>
2741   * Path: <b>CommunicationRequest.status</b><br>
2742   * </p>
2743   */
2744  public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS);
2745
2746
2747}
2748