001package org.hl7.fhir.r5.model;
002
003/*-
004 * #%L
005 * org.hl7.fhir.r5
006 * %%
007 * Copyright (C) 2014 - 2019 Health Level 7
008 * %%
009 * Licensed under the Apache License, Version 2.0 (the "License");
010 * you may not use this file except in compliance with the License.
011 * You may obtain a copy of the License at
012 * 
013 *      http://www.apache.org/licenses/LICENSE-2.0
014 * 
015 * Unless required by applicable law or agreed to in writing, software
016 * distributed under the License is distributed on an "AS IS" BASIS,
017 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
018 * See the License for the specific language governing permissions and
019 * limitations under the License.
020 * #L%
021 */
022
023/*
024  Copyright (c) 2011+, HL7, Inc.
025  All rights reserved.
026  
027  Redistribution and use in source and binary forms, with or without modification, 
028  are permitted provided that the following conditions are met:
029  
030   * Redistributions of source code must retain the above copyright notice, this 
031     list of conditions and the following disclaimer.
032   * Redistributions in binary form must reproduce the above copyright notice, 
033     this list of conditions and the following disclaimer in the documentation 
034     and/or other materials provided with the distribution.
035   * Neither the name of HL7 nor the names of its contributors may be used to 
036     endorse or promote products derived from this software without specific 
037     prior written permission.
038  
039  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 
040  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 
041  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 
042  IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 
043  INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 
044  NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 
045  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 
046  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 
047  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
048  POSSIBILITY OF SUCH DAMAGE.
049  
050*/
051
052// Generated on Thu, Dec 13, 2018 14:07+1100 for FHIR v4.0.0
053import java.util.ArrayList;
054import java.util.Date;
055import java.util.List;
056import org.hl7.fhir.exceptions.FHIRException;
057import org.hl7.fhir.instance.model.api.ICompositeType;
058
059import org.hl7.fhir.instance.model.api.IBaseDatatypeElement;
060import org.hl7.fhir.utilities.Utilities;
061import org.hl7.fhir.r5.model.Enumerations.*;
062import ca.uhn.fhir.model.api.annotation.ResourceDef;
063import ca.uhn.fhir.model.api.annotation.SearchParamDefinition;
064import org.hl7.fhir.instance.model.api.IBaseBackboneElement;
065import ca.uhn.fhir.model.api.annotation.Child;
066import ca.uhn.fhir.model.api.annotation.ChildOrder;
067import ca.uhn.fhir.model.api.annotation.Description;
068import ca.uhn.fhir.model.api.annotation.Block;
069/**
070 * Example of workflow instance.
071 */
072@ResourceDef(name="ExampleScenario", profile="http://hl7.org/fhir/StructureDefinition/ExampleScenario")
073@ChildOrder(names={"url", "identifier", "version", "name", "status", "experimental", "date", "publisher", "contact", "useContext", "jurisdiction", "copyright", "purpose", "actor", "instance", "process", "workflow"})
074public class ExampleScenario extends MetadataResource {
075
076    public enum ExampleScenarioActorType {
077        /**
078         * A person.
079         */
080        PERSON, 
081        /**
082         * A system.
083         */
084        ENTITY, 
085        /**
086         * added to help the parsers with the generic types
087         */
088        NULL;
089        public static ExampleScenarioActorType fromCode(String codeString) throws FHIRException {
090            if (codeString == null || "".equals(codeString))
091                return null;
092        if ("person".equals(codeString))
093          return PERSON;
094        if ("entity".equals(codeString))
095          return ENTITY;
096        if (Configuration.isAcceptInvalidEnums())
097          return null;
098        else
099          throw new FHIRException("Unknown ExampleScenarioActorType code '"+codeString+"'");
100        }
101        public String toCode() {
102          switch (this) {
103            case PERSON: return "person";
104            case ENTITY: return "entity";
105            default: return "?";
106          }
107        }
108        public String getSystem() {
109          switch (this) {
110            case PERSON: return "http://hl7.org/fhir/examplescenario-actor-type";
111            case ENTITY: return "http://hl7.org/fhir/examplescenario-actor-type";
112            default: return "?";
113          }
114        }
115        public String getDefinition() {
116          switch (this) {
117            case PERSON: return "A person.";
118            case ENTITY: return "A system.";
119            default: return "?";
120          }
121        }
122        public String getDisplay() {
123          switch (this) {
124            case PERSON: return "Person";
125            case ENTITY: return "System";
126            default: return "?";
127          }
128        }
129    }
130
131  public static class ExampleScenarioActorTypeEnumFactory implements EnumFactory<ExampleScenarioActorType> {
132    public ExampleScenarioActorType fromCode(String codeString) throws IllegalArgumentException {
133      if (codeString == null || "".equals(codeString))
134            if (codeString == null || "".equals(codeString))
135                return null;
136        if ("person".equals(codeString))
137          return ExampleScenarioActorType.PERSON;
138        if ("entity".equals(codeString))
139          return ExampleScenarioActorType.ENTITY;
140        throw new IllegalArgumentException("Unknown ExampleScenarioActorType code '"+codeString+"'");
141        }
142        public Enumeration<ExampleScenarioActorType> fromType(Base code) throws FHIRException {
143          if (code == null)
144            return null;
145          if (code.isEmpty())
146            return new Enumeration<ExampleScenarioActorType>(this);
147          String codeString = ((PrimitiveType) code).asStringValue();
148          if (codeString == null || "".equals(codeString))
149            return null;
150        if ("person".equals(codeString))
151          return new Enumeration<ExampleScenarioActorType>(this, ExampleScenarioActorType.PERSON);
152        if ("entity".equals(codeString))
153          return new Enumeration<ExampleScenarioActorType>(this, ExampleScenarioActorType.ENTITY);
154        throw new FHIRException("Unknown ExampleScenarioActorType code '"+codeString+"'");
155        }
156    public String toCode(ExampleScenarioActorType code) {
157      if (code == ExampleScenarioActorType.PERSON)
158        return "person";
159      if (code == ExampleScenarioActorType.ENTITY)
160        return "entity";
161      return "?";
162      }
163    public String toSystem(ExampleScenarioActorType code) {
164      return code.getSystem();
165      }
166    }
167
168    public enum FHIRResourceType {
169        /**
170         * A financial tool for tracking value accrued for a particular purpose.  In the healthcare field, used to track charges for a patient, cost centers, etc.
171         */
172        ACCOUNT, 
173        /**
174         * This resource allows for the definition of some activity to be performed, independent of a particular patient, practitioner, or other performance context.
175         */
176        ACTIVITYDEFINITION, 
177        /**
178         * A pharmaceutical product described in terms of its composition and dose form.
179         */
180        ADMINISTRABLEPRODUCTDEFINITION, 
181        /**
182         * An event (i.e. any change to current patient status) that may be related to unintended effects on a patient or research subject.  The unintended effects may require additional monitoring, treatment or hospitalization or may result in death.  The AdverseEvent resource also extends to potential or avoided events that could have had such effects.
183         */
184        ADVERSEEVENT, 
185        /**
186         * Risk of harmful or undesirable, physiological response which is unique to an individual and associated with exposure to a substance.
187         */
188        ALLERGYINTOLERANCE, 
189        /**
190         * A booking of a healthcare event among patient(s), practitioner(s), related person(s) and/or device(s) for a specific date/time. This may result in one or more Encounter(s).
191         */
192        APPOINTMENT, 
193        /**
194         * A reply to an appointment request for a patient and/or practitioner(s), such as a confirmation or rejection.
195         */
196        APPOINTMENTRESPONSE, 
197        /**
198         * A record of an event relevant for purposes such as operations, privacy, security, maintenance, and performance analysis.
199         */
200        AUDITEVENT, 
201        /**
202         * Basic is used for handling concepts not yet defined in FHIR, narrative-only resources that don't map to an existing resource, and custom resources not appropriate for inclusion in the FHIR specification.
203         */
204        BASIC, 
205        /**
206         * A resource that represents the data of a single raw artifact as digital content accessible in its native format.  A Binary resource can contain any content, whether text, image, pdf, zip archive, etc.
207         */
208        BINARY, 
209        /**
210         * A material substance originating from a biological entity intended to be transplanted or infused
211into another (possibly the same) biological entity.
212         */
213        BIOLOGICALLYDERIVEDPRODUCT, 
214        /**
215         * Record details about an anatomical structure.  This resource may be used when a coded concept does not provide the necessary detail needed for the use case.
216         */
217        BODYSTRUCTURE, 
218        /**
219         * A container for a collection of resources.
220         */
221        BUNDLE, 
222        /**
223         * A Capability Statement documents a set of capabilities (behaviors) of a FHIR Server for a particular version of FHIR that may be used as a statement of actual server functionality or a statement of required or desired server implementation.
224         */
225        CAPABILITYSTATEMENT, 
226        /**
227         * A Capability Statement documents a set of capabilities (behaviors) of a FHIR Server for a particular version of FHIR that may be used as a statement of actual server functionality or a statement of required or desired server implementation.
228         */
229        CAPABILITYSTATEMENT2, 
230        /**
231         * Describes the intention of how one or more practitioners intend to deliver care for a particular patient, group or community for a period of time, possibly limited to care for a specific condition or set of conditions.
232         */
233        CAREPLAN, 
234        /**
235         * The Care Team includes all the people and organizations who plan to participate in the coordination and delivery of care.
236         */
237        CARETEAM, 
238        /**
239         * Catalog entries are wrappers that contextualize items included in a catalog.
240         */
241        CATALOGENTRY, 
242        /**
243         * The resource ChargeItem describes the provision of healthcare provider products for a certain patient, therefore referring not only to the product, but containing in addition details of the provision, like date, time, amounts and participating organizations and persons. Main Usage of the ChargeItem is to enable the billing process and internal cost allocation.
244         */
245        CHARGEITEM, 
246        /**
247         * The ChargeItemDefinition resource provides the properties that apply to the (billing) codes necessary to calculate costs and prices. The properties may differ largely depending on type and realm, therefore this resource gives only a rough structure and requires profiling for each type of billing code system.
248         */
249        CHARGEITEMDEFINITION, 
250        /**
251         * A provider issued list of professional services and products which have been provided, or are to be provided, to a patient which is sent to an insurer for reimbursement.
252         */
253        CLAIM, 
254        /**
255         * This resource provides the adjudication details from the processing of a Claim resource.
256         */
257        CLAIMRESPONSE, 
258        /**
259         * A record of a clinical assessment performed to determine what problem(s) may affect the patient and before planning the treatments or management strategies that are best to manage a patient's condition. Assessments are often 1:1 with a clinical consultation / encounter,  but this varies greatly depending on the clinical workflow. This resource is called "ClinicalImpression" rather than "ClinicalAssessment" to avoid confusion with the recording of assessment tools such as Apgar score.
260         */
261        CLINICALIMPRESSION, 
262        /**
263         * A single item of clinical particulars - an indication, contraindication, interaction etc. for a medicinal product.
264         */
265        CLINICALUSEISSUE, 
266        /**
267         * The CodeSystem resource is used to declare the existence of and describe a code system or code system supplement and its key properties, and optionally define a part or all of its content.
268         */
269        CODESYSTEM, 
270        /**
271         * An occurrence of information being transmitted; e.g. an alert that was sent to a responsible provider, a public health agency communication to a provider/reporter in response to a case report for a reportable condition.
272         */
273        COMMUNICATION, 
274        /**
275         * 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.
276         */
277        COMMUNICATIONREQUEST, 
278        /**
279         * A compartment definition that defines how resources are accessed on a server.
280         */
281        COMPARTMENTDEFINITION, 
282        /**
283         * A set of healthcare-related information that is assembled together into a single logical package that provides a single coherent statement of meaning, establishes its own context and that has clinical attestation with regard to who is making the statement. A Composition defines the structure and narrative content necessary for a document. However, a Composition alone does not constitute a document. Rather, the Composition must be the first entry in a Bundle where Bundle.type=document, and any other resources referenced from Composition must be included as subsequent entries in the Bundle (for example Patient, Practitioner, Encounter, etc.).
284         */
285        COMPOSITION, 
286        /**
287         * A statement of relationships from one set of concepts to one or more other concepts - either concepts in code systems, or data element/data element concepts, or classes in class models.
288         */
289        CONCEPTMAP, 
290        /**
291         * A clinical condition, problem, diagnosis, or other event, situation, issue, or clinical concept that has risen to a level of concern.
292         */
293        CONDITION, 
294        /**
295         * A definition of a condition and information relevant to managing it.
296         */
297        CONDITIONDEFINITION, 
298        /**
299         * A record of a healthcare consumer’s  choices  or choices made on their behalf by a third party, which permits or denies identified recipient(s) or recipient role(s) to perform one or more actions within a given policy context, for specific purposes and periods of time.
300         */
301        CONSENT, 
302        /**
303         * Legally enforceable, formally recorded unilateral or bilateral directive i.e., a policy or agreement.
304         */
305        CONTRACT, 
306        /**
307         * Financial instrument which may be used to reimburse or pay for health care products and services. Includes both insurance and self-payment.
308         */
309        COVERAGE, 
310        /**
311         * The CoverageEligibilityRequest provides patient and insurance coverage information to an insurer for them to respond, in the form of an CoverageEligibilityResponse, with information regarding whether the stated coverage is valid and in-force and optionally to provide the insurance details of the policy.
312         */
313        COVERAGEELIGIBILITYREQUEST, 
314        /**
315         * This resource provides eligibility and plan details from the processing of an CoverageEligibilityRequest resource.
316         */
317        COVERAGEELIGIBILITYRESPONSE, 
318        /**
319         * Indicates an actual or potential clinical issue with or between one or more active or proposed clinical actions for a patient; e.g. Drug-drug interaction, Ineffective treatment frequency, Procedure-condition conflict, etc.
320         */
321        DETECTEDISSUE, 
322        /**
323         * A type of a manufactured item that is used in the provision of healthcare without being substantially changed through that activity. The device may be a medical or non-medical device.
324         */
325        DEVICE, 
326        /**
327         * The characteristics, operational status and capabilities of a medical-related component of a medical device.
328         */
329        DEVICEDEFINITION, 
330        /**
331         * Describes a measurement, calculation or setting capability of a medical device.
332         */
333        DEVICEMETRIC, 
334        /**
335         * Represents a request for a patient to employ a medical device. The device may be an implantable device, or an external assistive device, such as a walker.
336         */
337        DEVICEREQUEST, 
338        /**
339         * A record of a device being used by a patient where the record is the result of a report from the patient or another clinician.
340         */
341        DEVICEUSESTATEMENT, 
342        /**
343         * The findings and interpretation of diagnostic  tests performed on patients, groups of patients, devices, and locations, and/or specimens derived from these. The report includes clinical context such as requesting and provider information, and some mix of atomic results, images, textual and coded interpretations, and formatted representation of diagnostic reports.
344         */
345        DIAGNOSTICREPORT, 
346        /**
347         * A collection of documents compiled for a purpose together with metadata that applies to the collection.
348         */
349        DOCUMENTMANIFEST, 
350        /**
351         * A reference to a document of any kind for any purpose. While the term “document” implies a more narrow focus, for this resource this "document" encompasses *any* seralized object with a mime-type, so includes formal patient centric documents (CDA), clniical notes, scanned paper, non-patient specific documents like policy text, as well as a photo, video, or audio recording acquired or used in healthcare.  The DocumentReference resource provides metadata about the document so that the document can be discovered and managed.  The actual content may be inline base64 encoded data or provided by direct reference.
352         */
353        DOCUMENTREFERENCE, 
354        /**
355         * A resource that includes narrative, extensions, and contained resources.
356         */
357        DOMAINRESOURCE, 
358        /**
359         * An interaction between a patient and healthcare provider(s) for the purpose of providing healthcare service(s) or assessing the health status of a patient.
360         */
361        ENCOUNTER, 
362        /**
363         * The technical details of an endpoint that can be used for electronic services, such as for web services providing XDS.b or a REST endpoint for another FHIR server. This may include any security context information.
364         */
365        ENDPOINT, 
366        /**
367         * This resource provides the insurance enrollment details to the insurer regarding a specified coverage.
368         */
369        ENROLLMENTREQUEST, 
370        /**
371         * This resource provides enrollment and plan details from the processing of an EnrollmentRequest resource.
372         */
373        ENROLLMENTRESPONSE, 
374        /**
375         * An association between a patient and an organization / healthcare provider(s) during which time encounters may occur. The managing organization assumes a level of responsibility for the patient during this time.
376         */
377        EPISODEOFCARE, 
378        /**
379         * The EventDefinition resource provides a reusable description of when a particular event can occur.
380         */
381        EVENTDEFINITION, 
382        /**
383         * This represents statistics, certainty, both the intended and actual population, and evidence variables.
384         */
385        EVIDENCE, 
386        /**
387         * The EvidenceVariable resource describes a "PICO" element that knowledge (evidence, assertion, recommendation) is about.
388         */
389        EVIDENCEVARIABLE, 
390        /**
391         * Example of workflow instance.
392         */
393        EXAMPLESCENARIO, 
394        /**
395         * This resource provides: the claim details; adjudication details from the processing of a Claim; and optionally account balance information, for informing the subscriber of the benefits provided.
396         */
397        EXPLANATIONOFBENEFIT, 
398        /**
399         * Significant health conditions for a person related to the patient relevant in the context of care for the patient.
400         */
401        FAMILYMEMBERHISTORY, 
402        /**
403         * Prospective warnings of potential issues when providing care to the patient.
404         */
405        FLAG, 
406        /**
407         * Describes the intended objective(s) for a patient, group or organization care, for example, weight loss, restoring an activity of daily living, obtaining herd immunity via immunization, meeting a process improvement objective, etc.
408         */
409        GOAL, 
410        /**
411         * A formal computable definition of a graph of resources - that is, a coherent set of resources that form a graph by following references. The Graph Definition resource defines a set and makes rules about the set.
412         */
413        GRAPHDEFINITION, 
414        /**
415         * Represents a defined collection of entities that may be discussed or acted upon collectively but which are not expected to act collectively, and are not formally or legally recognized; i.e. a collection of entities that isn't an Organization.
416         */
417        GROUP, 
418        /**
419         * A guidance response is the formal response to a guidance request, including any output parameters returned by the evaluation, as well as the description of any proposed actions to be taken.
420         */
421        GUIDANCERESPONSE, 
422        /**
423         * The details of a healthcare service available at a location.
424         */
425        HEALTHCARESERVICE, 
426        /**
427         * Representation of the content produced in a DICOM imaging study. A study comprises a set of series, each of which includes a set of Service-Object Pair Instances (SOP Instances - images or other data) acquired or produced in a common context.  A series is of only one modality (e.g. X-ray, CT, MR, ultrasound), but a study may have multiple series of different modalities.
428         */
429        IMAGINGSTUDY, 
430        /**
431         * Describes the event of a patient being administered a vaccine or a record of an immunization as reported by a patient, a clinician or another party.
432         */
433        IMMUNIZATION, 
434        /**
435         * Describes a comparison of an immunization event against published recommendations to determine if the administration is "valid" in relation to those  recommendations.
436         */
437        IMMUNIZATIONEVALUATION, 
438        /**
439         * A patient's point-in-time set of recommendations (i.e. forecasting) according to a published schedule with optional supporting justification.
440         */
441        IMMUNIZATIONRECOMMENDATION, 
442        /**
443         * A set of rules of how a particular interoperability or standards problem is solved - typically through the use of FHIR resources. This resource is used to gather all the parts of an implementation guide into a logical whole and to publish a computable definition of all the parts.
444         */
445        IMPLEMENTATIONGUIDE, 
446        /**
447         * An ingredient of a manufactured item or pharmaceutical product.
448         */
449        INGREDIENT, 
450        /**
451         * Details of a Health Insurance product/plan provided by an organization.
452         */
453        INSURANCEPLAN, 
454        /**
455         * Invoice containing collected ChargeItems from an Account with calculated individual and total price for Billing purpose.
456         */
457        INVOICE, 
458        /**
459         * The Library resource is a general-purpose container for knowledge asset definitions. It can be used to describe and expose existing knowledge assets such as logic libraries and information model descriptions, as well as to describe a collection of knowledge assets.
460         */
461        LIBRARY, 
462        /**
463         * Identifies two or more records (resource instances) that refer to the same real-world "occurrence".
464         */
465        LINKAGE, 
466        /**
467         * A list is a curated collection of resources.
468         */
469        LIST, 
470        /**
471         * Details and position information for a physical place where services are provided and resources and participants may be stored, found, contained, or accommodated.
472         */
473        LOCATION, 
474        /**
475         * The manufactured item as contained in the packaged medicinal product.
476         */
477        MANUFACTUREDITEMDEFINITION, 
478        /**
479         * The Measure resource provides the definition of a quality measure.
480         */
481        MEASURE, 
482        /**
483         * The MeasureReport resource contains the results of the calculation of a measure; and optionally a reference to the resources involved in that calculation.
484         */
485        MEASUREREPORT, 
486        /**
487         * This resource is primarily used for the identification and definition of a medication for the purposes of prescribing, dispensing, and administering a medication as well as for making statements about medication use.
488         */
489        MEDICATION, 
490        /**
491         * Describes the event of a patient consuming or otherwise being administered a medication.  This may be as simple as swallowing a tablet or it may be a long running infusion.  Related resources tie this event to the authorizing prescription, and the specific encounter between patient and health care practitioner.
492         */
493        MEDICATIONADMINISTRATION, 
494        /**
495         * Indicates that a medication product is to be or has been dispensed for a named person/patient.  This includes a description of the medication product (supply) provided and the instructions for administering the medication.  The medication dispense is the result of a pharmacy system responding to a medication order.
496         */
497        MEDICATIONDISPENSE, 
498        /**
499         * Information about a medication that is used to support knowledge.
500         */
501        MEDICATIONKNOWLEDGE, 
502        /**
503         * An order or request for both supply of the medication and the instructions for administration of the medication to a patient. The resource is called "MedicationRequest" rather than "MedicationPrescription" or "MedicationOrder" to generalize the use across inpatient and outpatient settings, including care plans, etc., and to harmonize with workflow patterns.
504         */
505        MEDICATIONREQUEST, 
506        /**
507         * A record of a medication that is being consumed by a patient.   A MedicationUsage may indicate that the patient may be taking the medication now or has taken the medication in the past or will be taking the medication in the future.  The source of this information can be the patient, significant other (such as a family member or spouse), or a clinician.  A common scenario where this information is captured is during the history taking process during a patient visit or stay.   The medication information may come from sources such as the patient's memory, from a prescription bottle,  or from a list of medications the patient, clinician or other party maintains. 
508
509The primary difference between a medicationusage and a medicationadministration is that the medication administration has complete administration information and is based on actual administration information from the person who administered the medication.  A medicationusage is often, if not always, less specific.  There is no required date/time when the medication was administered, in fact we only know that a source has reported the patient is taking this medication, where details such as time, quantity, or rate or even medication product may be incomplete or missing or less precise.  As stated earlier, the Medication Usage information may come from the patient's memory, from a prescription bottle or from a list of medications the patient, clinician or other party maintains.  Medication administration is more formal and is not missing detailed information.
510         */
511        MEDICATIONUSAGE, 
512        /**
513         * Detailed definition of a medicinal product, typically for uses other than direct patient care (e.g. regulatory use).
514         */
515        MEDICINALPRODUCTDEFINITION, 
516        /**
517         * Defines the characteristics of a message that can be shared between systems, including the type of event that initiates the message, the content to be transmitted and what response(s), if any, are permitted.
518         */
519        MESSAGEDEFINITION, 
520        /**
521         * The header for a message exchange that is either requesting or responding to an action.  The reference(s) that are the subject of the action as well as other information related to the action are typically transmitted in a bundle in which the MessageHeader resource instance is the first resource in the bundle.
522         */
523        MESSAGEHEADER, 
524        /**
525         * Raw data describing a biological sequence.
526         */
527        MOLECULARSEQUENCE, 
528        /**
529         * A curated namespace that issues unique symbols within that namespace for the identification of concepts, people, devices, etc.  Represents a "System" used within the Identifier and Coding data types.
530         */
531        NAMINGSYSTEM, 
532        /**
533         * A record of food or fluid that is being consumed by a patient.   A NutritionIntake may indicate that the patient may be consuming the food or fluid now or has consumed the food or fluid in the past.  The source of this information can be the patient, significant other (such as a family member or spouse), or a clinician.  A common scenario where this information is captured is during the history taking process during a patient visit or stay or through an app that tracks food or fluids consumed.   The consumption information may come from sources such as the patient's memory, from a nutrition label,  or from a clinician documenting observed intake.
534         */
535        NUTRITIONINTAKE, 
536        /**
537         * A request to supply a diet, formula feeding (enteral) or oral nutritional supplement to a patient/resident.
538         */
539        NUTRITIONORDER, 
540        /**
541         * Measurements and simple assertions made about a patient, device or other subject.
542         */
543        OBSERVATION, 
544        /**
545         * Set of definitional characteristics for a kind of observation or measurement produced or consumed by an orderable health care service.
546         */
547        OBSERVATIONDEFINITION, 
548        /**
549         * A formal computable definition of an operation (on the RESTful interface) or a named query (using the search interaction).
550         */
551        OPERATIONDEFINITION, 
552        /**
553         * A collection of error, warning, or information messages that result from a system action.
554         */
555        OPERATIONOUTCOME, 
556        /**
557         * A formally or informally recognized grouping of people or organizations formed for the purpose of achieving some form of collective action.  Includes companies, institutions, corporations, departments, community groups, healthcare practice groups, payer/insurer, etc.
558         */
559        ORGANIZATION, 
560        /**
561         * Defines an affiliation/assotiation/relationship between 2 distinct oganizations, that is not a part-of relationship/sub-division relationship.
562         */
563        ORGANIZATIONAFFILIATION, 
564        /**
565         * A medicinal product in a container or package.
566         */
567        PACKAGEDPRODUCTDEFINITION, 
568        /**
569         * This resource is a non-persisted resource used to pass information into and back from an [operation](operations.html). It has no other use, and there is no RESTful endpoint associated with it.
570         */
571        PARAMETERS, 
572        /**
573         * Demographics and other administrative information about an individual or animal receiving care or other health-related services.
574         */
575        PATIENT, 
576        /**
577         * This resource provides the status of the payment for goods and services rendered, and the request and response resource references.
578         */
579        PAYMENTNOTICE, 
580        /**
581         * This resource provides the details including amount of a payment and allocates the payment items being paid.
582         */
583        PAYMENTRECONCILIATION, 
584        /**
585         * Demographics and administrative information about a person independent of a specific health-related context.
586         */
587        PERSON, 
588        /**
589         * This resource allows for the definition of various types of plans as a sharable, consumable, and executable artifact. The resource is general enough to support the description of a broad range of clinical artifacts such as clinical decision support rules, order sets and protocols.
590         */
591        PLANDEFINITION, 
592        /**
593         * A person who is directly or indirectly involved in the provisioning of healthcare.
594         */
595        PRACTITIONER, 
596        /**
597         * A specific set of Roles/Locations/specialties/services that a practitioner may perform at an organization for a period of time.
598         */
599        PRACTITIONERROLE, 
600        /**
601         * An action that is or was performed on or for a patient. This can be a physical intervention like an operation, or less invasive like long term services, counseling, or hypnotherapy.
602         */
603        PROCEDURE, 
604        /**
605         * Provenance of a resource is a record that describes entities and processes involved in producing and delivering or otherwise influencing that resource. Provenance provides a critical foundation for assessing authenticity, enabling trust, and allowing reproducibility. Provenance assertions are a form of contextual metadata and can themselves become important records with their own provenance. Provenance statement indicates clinical significance in terms of confidence in authenticity, reliability, and trustworthiness, integrity, and stage in lifecycle (e.g. Document Completion - has the artifact been legally authenticated), all of which may impact security, privacy, and trust policies.
606         */
607        PROVENANCE, 
608        /**
609         * A structured set of questions intended to guide the collection of answers from end-users. Questionnaires provide detailed control over order, presentation, phraseology and grouping to allow coherent, consistent data collection.
610         */
611        QUESTIONNAIRE, 
612        /**
613         * A structured set of questions and their answers. The questions are ordered and grouped into coherent subsets, corresponding to the structure of the grouping of the questionnaire being responded to.
614         */
615        QUESTIONNAIRERESPONSE, 
616        /**
617         * The regulatory authorization of a medicinal product.
618         */
619        REGULATEDAUTHORIZATION, 
620        /**
621         * Information about a person that is involved in the care for a patient, but who is not the target of healthcare, nor has a formal responsibility in the care process.
622         */
623        RELATEDPERSON, 
624        /**
625         * A group of related requests that can be used to capture intended activities that have inter-dependencies such as "give this medication after that one".
626         */
627        REQUESTGROUP, 
628        /**
629         * A process where a researcher or organization plans and then executes a series of steps intended to increase the field of healthcare-related knowledge.  This includes studies of safety, efficacy, comparative effectiveness and other information about medications, devices, therapies and other interventional and investigative techniques.  A ResearchStudy involves the gathering of information about human or animal subjects.
630         */
631        RESEARCHSTUDY, 
632        /**
633         * A physical entity which is the primary unit of operational and/or administrative interest in a study.
634         */
635        RESEARCHSUBJECT, 
636        /**
637         * This is the base resource type for everything.
638         */
639        RESOURCE, 
640        /**
641         * An assessment of the likely outcome(s) for a patient or other subject as well as the likelihood of each outcome.
642         */
643        RISKASSESSMENT, 
644        /**
645         * A container for slots of time that may be available for booking appointments.
646         */
647        SCHEDULE, 
648        /**
649         * A search parameter that defines a named search item that can be used to search/filter on a resource.
650         */
651        SEARCHPARAMETER, 
652        /**
653         * A record of a request for service such as diagnostic investigations, treatments, or operations to be performed.
654         */
655        SERVICEREQUEST, 
656        /**
657         * A slot of time on a schedule that may be available for booking appointments.
658         */
659        SLOT, 
660        /**
661         * A sample to be used for analysis.
662         */
663        SPECIMEN, 
664        /**
665         * A kind of specimen with associated set of requirements.
666         */
667        SPECIMENDEFINITION, 
668        /**
669         * A definition of a FHIR structure. This resource is used to describe the underlying resources, data types defined in FHIR, and also for describing extensions and constraints on resources and data types.
670         */
671        STRUCTUREDEFINITION, 
672        /**
673         * A Map of relationships between 2 structures that can be used to transform data.
674         */
675        STRUCTUREMAP, 
676        /**
677         * The subscription resource describes a particular client's request to be notified about a Topic.
678         */
679        SUBSCRIPTION, 
680        /**
681         * A homogeneous material with a definite composition.
682         */
683        SUBSTANCE, 
684        /**
685         * The detailed description of a substance, typically at a level beyond what is used for prescribing.
686         */
687        SUBSTANCEDEFINITION, 
688        /**
689         * Nucleic acids are defined by three distinct elements: the base, sugar and linkage. Individual substance/moiety IDs will be created for each of these elements. The nucleotide sequence will be always entered in the 5’-3’ direction.
690         */
691        SUBSTANCENUCLEICACID, 
692        /**
693         * Todo.
694         */
695        SUBSTANCEPOLYMER, 
696        /**
697         * A SubstanceProtein is defined as a single unit of a linear amino acid sequence, or a combination of subunits that are either covalently linked or have a defined invariant stoichiometric relationship. This includes all synthetic, recombinant and purified SubstanceProteins of defined sequence, whether the use is therapeutic or prophylactic. This set of elements will be used to describe albumins, coagulation factors, cytokines, growth factors, peptide/SubstanceProtein hormones, enzymes, toxins, toxoids, recombinant vaccines, and immunomodulators.
698         */
699        SUBSTANCEPROTEIN, 
700        /**
701         * Todo.
702         */
703        SUBSTANCEREFERENCEINFORMATION, 
704        /**
705         * Source material shall capture information on the taxonomic and anatomical origins as well as the fraction of a material that can result in or can be modified to form a substance. This set of data elements shall be used to define polymer substances isolated from biological matrices. Taxonomic and anatomical origins shall be described using a controlled vocabulary as required. This information is captured for naturally derived polymers ( . starch) and structurally diverse substances. For Organisms belonging to the Kingdom Plantae the Substance level defines the fresh material of a single species or infraspecies, the Herbal Drug and the Herbal preparation. For Herbal preparations, the fraction information will be captured at the Substance information level and additional information for herbal extracts will be captured at the Specified Substance Group 1 information level. See for further explanation the Substance Class: Structurally Diverse and the herbal annex.
706         */
707        SUBSTANCESOURCEMATERIAL, 
708        /**
709         * Record of delivery of what is supplied.
710         */
711        SUPPLYDELIVERY, 
712        /**
713         * A record of a request for a medication, substance or device used in the healthcare setting.
714         */
715        SUPPLYREQUEST, 
716        /**
717         * A task to be performed.
718         */
719        TASK, 
720        /**
721         * A TerminologyCapabilities resource documents a set of capabilities (behaviors) of a FHIR Terminology Server that may be used as a statement of actual server functionality or a statement of required or desired server implementation.
722         */
723        TERMINOLOGYCAPABILITIES, 
724        /**
725         * A summary of information based on the results of executing a TestScript.
726         */
727        TESTREPORT, 
728        /**
729         * A structured set of tests against a FHIR server or client implementation to determine compliance against the FHIR specification.
730         */
731        TESTSCRIPT, 
732        /**
733         * Describes a stream of resource state changes identified by trigger criteria and annotated with labels useful to filter projections from this topic.
734         */
735        TOPIC, 
736        /**
737         * A ValueSet resource instance specifies a set of codes drawn from one or more code systems, intended for use in a particular context. Value sets link between [[[CodeSystem]]] definitions and their use in [coded elements](terminologies.html).
738         */
739        VALUESET, 
740        /**
741         * Describes validation requirements, source(s), status and dates for one or more elements.
742         */
743        VERIFICATIONRESULT, 
744        /**
745         * An authorization for the provision of glasses and/or contact lenses to a patient.
746         */
747        VISIONPRESCRIPTION, 
748        /**
749         * added to help the parsers with the generic types
750         */
751        NULL;
752        public static FHIRResourceType fromCode(String codeString) throws FHIRException {
753            if (codeString == null || "".equals(codeString))
754                return null;
755        if ("Account".equals(codeString))
756          return ACCOUNT;
757        if ("ActivityDefinition".equals(codeString))
758          return ACTIVITYDEFINITION;
759        if ("AdministrableProductDefinition".equals(codeString))
760          return ADMINISTRABLEPRODUCTDEFINITION;
761        if ("AdverseEvent".equals(codeString))
762          return ADVERSEEVENT;
763        if ("AllergyIntolerance".equals(codeString))
764          return ALLERGYINTOLERANCE;
765        if ("Appointment".equals(codeString))
766          return APPOINTMENT;
767        if ("AppointmentResponse".equals(codeString))
768          return APPOINTMENTRESPONSE;
769        if ("AuditEvent".equals(codeString))
770          return AUDITEVENT;
771        if ("Basic".equals(codeString))
772          return BASIC;
773        if ("Binary".equals(codeString))
774          return BINARY;
775        if ("BiologicallyDerivedProduct".equals(codeString))
776          return BIOLOGICALLYDERIVEDPRODUCT;
777        if ("BodyStructure".equals(codeString))
778          return BODYSTRUCTURE;
779        if ("Bundle".equals(codeString))
780          return BUNDLE;
781        if ("CapabilityStatement".equals(codeString))
782          return CAPABILITYSTATEMENT;
783        if ("CapabilityStatement2".equals(codeString))
784          return CAPABILITYSTATEMENT2;
785        if ("CarePlan".equals(codeString))
786          return CAREPLAN;
787        if ("CareTeam".equals(codeString))
788          return CARETEAM;
789        if ("CatalogEntry".equals(codeString))
790          return CATALOGENTRY;
791        if ("ChargeItem".equals(codeString))
792          return CHARGEITEM;
793        if ("ChargeItemDefinition".equals(codeString))
794          return CHARGEITEMDEFINITION;
795        if ("Claim".equals(codeString))
796          return CLAIM;
797        if ("ClaimResponse".equals(codeString))
798          return CLAIMRESPONSE;
799        if ("ClinicalImpression".equals(codeString))
800          return CLINICALIMPRESSION;
801        if ("ClinicalUseIssue".equals(codeString))
802          return CLINICALUSEISSUE;
803        if ("CodeSystem".equals(codeString))
804          return CODESYSTEM;
805        if ("Communication".equals(codeString))
806          return COMMUNICATION;
807        if ("CommunicationRequest".equals(codeString))
808          return COMMUNICATIONREQUEST;
809        if ("CompartmentDefinition".equals(codeString))
810          return COMPARTMENTDEFINITION;
811        if ("Composition".equals(codeString))
812          return COMPOSITION;
813        if ("ConceptMap".equals(codeString))
814          return CONCEPTMAP;
815        if ("Condition".equals(codeString))
816          return CONDITION;
817        if ("ConditionDefinition".equals(codeString))
818          return CONDITIONDEFINITION;
819        if ("Consent".equals(codeString))
820          return CONSENT;
821        if ("Contract".equals(codeString))
822          return CONTRACT;
823        if ("Coverage".equals(codeString))
824          return COVERAGE;
825        if ("CoverageEligibilityRequest".equals(codeString))
826          return COVERAGEELIGIBILITYREQUEST;
827        if ("CoverageEligibilityResponse".equals(codeString))
828          return COVERAGEELIGIBILITYRESPONSE;
829        if ("DetectedIssue".equals(codeString))
830          return DETECTEDISSUE;
831        if ("Device".equals(codeString))
832          return DEVICE;
833        if ("DeviceDefinition".equals(codeString))
834          return DEVICEDEFINITION;
835        if ("DeviceMetric".equals(codeString))
836          return DEVICEMETRIC;
837        if ("DeviceRequest".equals(codeString))
838          return DEVICEREQUEST;
839        if ("DeviceUseStatement".equals(codeString))
840          return DEVICEUSESTATEMENT;
841        if ("DiagnosticReport".equals(codeString))
842          return DIAGNOSTICREPORT;
843        if ("DocumentManifest".equals(codeString))
844          return DOCUMENTMANIFEST;
845        if ("DocumentReference".equals(codeString))
846          return DOCUMENTREFERENCE;
847        if ("DomainResource".equals(codeString))
848          return DOMAINRESOURCE;
849        if ("Encounter".equals(codeString))
850          return ENCOUNTER;
851        if ("Endpoint".equals(codeString))
852          return ENDPOINT;
853        if ("EnrollmentRequest".equals(codeString))
854          return ENROLLMENTREQUEST;
855        if ("EnrollmentResponse".equals(codeString))
856          return ENROLLMENTRESPONSE;
857        if ("EpisodeOfCare".equals(codeString))
858          return EPISODEOFCARE;
859        if ("EventDefinition".equals(codeString))
860          return EVENTDEFINITION;
861        if ("Evidence".equals(codeString))
862          return EVIDENCE;
863        if ("EvidenceVariable".equals(codeString))
864          return EVIDENCEVARIABLE;
865        if ("ExampleScenario".equals(codeString))
866          return EXAMPLESCENARIO;
867        if ("ExplanationOfBenefit".equals(codeString))
868          return EXPLANATIONOFBENEFIT;
869        if ("FamilyMemberHistory".equals(codeString))
870          return FAMILYMEMBERHISTORY;
871        if ("Flag".equals(codeString))
872          return FLAG;
873        if ("Goal".equals(codeString))
874          return GOAL;
875        if ("GraphDefinition".equals(codeString))
876          return GRAPHDEFINITION;
877        if ("Group".equals(codeString))
878          return GROUP;
879        if ("GuidanceResponse".equals(codeString))
880          return GUIDANCERESPONSE;
881        if ("HealthcareService".equals(codeString))
882          return HEALTHCARESERVICE;
883        if ("ImagingStudy".equals(codeString))
884          return IMAGINGSTUDY;
885        if ("Immunization".equals(codeString))
886          return IMMUNIZATION;
887        if ("ImmunizationEvaluation".equals(codeString))
888          return IMMUNIZATIONEVALUATION;
889        if ("ImmunizationRecommendation".equals(codeString))
890          return IMMUNIZATIONRECOMMENDATION;
891        if ("ImplementationGuide".equals(codeString))
892          return IMPLEMENTATIONGUIDE;
893        if ("Ingredient".equals(codeString))
894          return INGREDIENT;
895        if ("InsurancePlan".equals(codeString))
896          return INSURANCEPLAN;
897        if ("Invoice".equals(codeString))
898          return INVOICE;
899        if ("Library".equals(codeString))
900          return LIBRARY;
901        if ("Linkage".equals(codeString))
902          return LINKAGE;
903        if ("List".equals(codeString))
904          return LIST;
905        if ("Location".equals(codeString))
906          return LOCATION;
907        if ("ManufacturedItemDefinition".equals(codeString))
908          return MANUFACTUREDITEMDEFINITION;
909        if ("Measure".equals(codeString))
910          return MEASURE;
911        if ("MeasureReport".equals(codeString))
912          return MEASUREREPORT;
913        if ("Medication".equals(codeString))
914          return MEDICATION;
915        if ("MedicationAdministration".equals(codeString))
916          return MEDICATIONADMINISTRATION;
917        if ("MedicationDispense".equals(codeString))
918          return MEDICATIONDISPENSE;
919        if ("MedicationKnowledge".equals(codeString))
920          return MEDICATIONKNOWLEDGE;
921        if ("MedicationRequest".equals(codeString))
922          return MEDICATIONREQUEST;
923        if ("MedicationUsage".equals(codeString))
924          return MEDICATIONUSAGE;
925        if ("MedicinalProductDefinition".equals(codeString))
926          return MEDICINALPRODUCTDEFINITION;
927        if ("MessageDefinition".equals(codeString))
928          return MESSAGEDEFINITION;
929        if ("MessageHeader".equals(codeString))
930          return MESSAGEHEADER;
931        if ("MolecularSequence".equals(codeString))
932          return MOLECULARSEQUENCE;
933        if ("NamingSystem".equals(codeString))
934          return NAMINGSYSTEM;
935        if ("NutritionIntake".equals(codeString))
936          return NUTRITIONINTAKE;
937        if ("NutritionOrder".equals(codeString))
938          return NUTRITIONORDER;
939        if ("Observation".equals(codeString))
940          return OBSERVATION;
941        if ("ObservationDefinition".equals(codeString))
942          return OBSERVATIONDEFINITION;
943        if ("OperationDefinition".equals(codeString))
944          return OPERATIONDEFINITION;
945        if ("OperationOutcome".equals(codeString))
946          return OPERATIONOUTCOME;
947        if ("Organization".equals(codeString))
948          return ORGANIZATION;
949        if ("OrganizationAffiliation".equals(codeString))
950          return ORGANIZATIONAFFILIATION;
951        if ("PackagedProductDefinition".equals(codeString))
952          return PACKAGEDPRODUCTDEFINITION;
953        if ("Parameters".equals(codeString))
954          return PARAMETERS;
955        if ("Patient".equals(codeString))
956          return PATIENT;
957        if ("PaymentNotice".equals(codeString))
958          return PAYMENTNOTICE;
959        if ("PaymentReconciliation".equals(codeString))
960          return PAYMENTRECONCILIATION;
961        if ("Person".equals(codeString))
962          return PERSON;
963        if ("PlanDefinition".equals(codeString))
964          return PLANDEFINITION;
965        if ("Practitioner".equals(codeString))
966          return PRACTITIONER;
967        if ("PractitionerRole".equals(codeString))
968          return PRACTITIONERROLE;
969        if ("Procedure".equals(codeString))
970          return PROCEDURE;
971        if ("Provenance".equals(codeString))
972          return PROVENANCE;
973        if ("Questionnaire".equals(codeString))
974          return QUESTIONNAIRE;
975        if ("QuestionnaireResponse".equals(codeString))
976          return QUESTIONNAIRERESPONSE;
977        if ("RegulatedAuthorization".equals(codeString))
978          return REGULATEDAUTHORIZATION;
979        if ("RelatedPerson".equals(codeString))
980          return RELATEDPERSON;
981        if ("RequestGroup".equals(codeString))
982          return REQUESTGROUP;
983        if ("ResearchStudy".equals(codeString))
984          return RESEARCHSTUDY;
985        if ("ResearchSubject".equals(codeString))
986          return RESEARCHSUBJECT;
987        if ("Resource".equals(codeString))
988          return RESOURCE;
989        if ("RiskAssessment".equals(codeString))
990          return RISKASSESSMENT;
991        if ("Schedule".equals(codeString))
992          return SCHEDULE;
993        if ("SearchParameter".equals(codeString))
994          return SEARCHPARAMETER;
995        if ("ServiceRequest".equals(codeString))
996          return SERVICEREQUEST;
997        if ("Slot".equals(codeString))
998          return SLOT;
999        if ("Specimen".equals(codeString))
1000          return SPECIMEN;
1001        if ("SpecimenDefinition".equals(codeString))
1002          return SPECIMENDEFINITION;
1003        if ("StructureDefinition".equals(codeString))
1004          return STRUCTUREDEFINITION;
1005        if ("StructureMap".equals(codeString))
1006          return STRUCTUREMAP;
1007        if ("Subscription".equals(codeString))
1008          return SUBSCRIPTION;
1009        if ("Substance".equals(codeString))
1010          return SUBSTANCE;
1011        if ("SubstanceDefinition".equals(codeString))
1012          return SUBSTANCEDEFINITION;
1013        if ("SubstanceNucleicAcid".equals(codeString))
1014          return SUBSTANCENUCLEICACID;
1015        if ("SubstancePolymer".equals(codeString))
1016          return SUBSTANCEPOLYMER;
1017        if ("SubstanceProtein".equals(codeString))
1018          return SUBSTANCEPROTEIN;
1019        if ("SubstanceReferenceInformation".equals(codeString))
1020          return SUBSTANCEREFERENCEINFORMATION;
1021        if ("SubstanceSourceMaterial".equals(codeString))
1022          return SUBSTANCESOURCEMATERIAL;
1023        if ("SupplyDelivery".equals(codeString))
1024          return SUPPLYDELIVERY;
1025        if ("SupplyRequest".equals(codeString))
1026          return SUPPLYREQUEST;
1027        if ("Task".equals(codeString))
1028          return TASK;
1029        if ("TerminologyCapabilities".equals(codeString))
1030          return TERMINOLOGYCAPABILITIES;
1031        if ("TestReport".equals(codeString))
1032          return TESTREPORT;
1033        if ("TestScript".equals(codeString))
1034          return TESTSCRIPT;
1035        if ("Topic".equals(codeString))
1036          return TOPIC;
1037        if ("ValueSet".equals(codeString))
1038          return VALUESET;
1039        if ("VerificationResult".equals(codeString))
1040          return VERIFICATIONRESULT;
1041        if ("VisionPrescription".equals(codeString))
1042          return VISIONPRESCRIPTION;
1043        if (Configuration.isAcceptInvalidEnums())
1044          return null;
1045        else
1046          throw new FHIRException("Unknown FHIRResourceType code '"+codeString+"'");
1047        }
1048        public String toCode() {
1049          switch (this) {
1050            case ACCOUNT: return "Account";
1051            case ACTIVITYDEFINITION: return "ActivityDefinition";
1052            case ADMINISTRABLEPRODUCTDEFINITION: return "AdministrableProductDefinition";
1053            case ADVERSEEVENT: return "AdverseEvent";
1054            case ALLERGYINTOLERANCE: return "AllergyIntolerance";
1055            case APPOINTMENT: return "Appointment";
1056            case APPOINTMENTRESPONSE: return "AppointmentResponse";
1057            case AUDITEVENT: return "AuditEvent";
1058            case BASIC: return "Basic";
1059            case BINARY: return "Binary";
1060            case BIOLOGICALLYDERIVEDPRODUCT: return "BiologicallyDerivedProduct";
1061            case BODYSTRUCTURE: return "BodyStructure";
1062            case BUNDLE: return "Bundle";
1063            case CAPABILITYSTATEMENT: return "CapabilityStatement";
1064            case CAPABILITYSTATEMENT2: return "CapabilityStatement2";
1065            case CAREPLAN: return "CarePlan";
1066            case CARETEAM: return "CareTeam";
1067            case CATALOGENTRY: return "CatalogEntry";
1068            case CHARGEITEM: return "ChargeItem";
1069            case CHARGEITEMDEFINITION: return "ChargeItemDefinition";
1070            case CLAIM: return "Claim";
1071            case CLAIMRESPONSE: return "ClaimResponse";
1072            case CLINICALIMPRESSION: return "ClinicalImpression";
1073            case CLINICALUSEISSUE: return "ClinicalUseIssue";
1074            case CODESYSTEM: return "CodeSystem";
1075            case COMMUNICATION: return "Communication";
1076            case COMMUNICATIONREQUEST: return "CommunicationRequest";
1077            case COMPARTMENTDEFINITION: return "CompartmentDefinition";
1078            case COMPOSITION: return "Composition";
1079            case CONCEPTMAP: return "ConceptMap";
1080            case CONDITION: return "Condition";
1081            case CONDITIONDEFINITION: return "ConditionDefinition";
1082            case CONSENT: return "Consent";
1083            case CONTRACT: return "Contract";
1084            case COVERAGE: return "Coverage";
1085            case COVERAGEELIGIBILITYREQUEST: return "CoverageEligibilityRequest";
1086            case COVERAGEELIGIBILITYRESPONSE: return "CoverageEligibilityResponse";
1087            case DETECTEDISSUE: return "DetectedIssue";
1088            case DEVICE: return "Device";
1089            case DEVICEDEFINITION: return "DeviceDefinition";
1090            case DEVICEMETRIC: return "DeviceMetric";
1091            case DEVICEREQUEST: return "DeviceRequest";
1092            case DEVICEUSESTATEMENT: return "DeviceUseStatement";
1093            case DIAGNOSTICREPORT: return "DiagnosticReport";
1094            case DOCUMENTMANIFEST: return "DocumentManifest";
1095            case DOCUMENTREFERENCE: return "DocumentReference";
1096            case DOMAINRESOURCE: return "DomainResource";
1097            case ENCOUNTER: return "Encounter";
1098            case ENDPOINT: return "Endpoint";
1099            case ENROLLMENTREQUEST: return "EnrollmentRequest";
1100            case ENROLLMENTRESPONSE: return "EnrollmentResponse";
1101            case EPISODEOFCARE: return "EpisodeOfCare";
1102            case EVENTDEFINITION: return "EventDefinition";
1103            case EVIDENCE: return "Evidence";
1104            case EVIDENCEVARIABLE: return "EvidenceVariable";
1105            case EXAMPLESCENARIO: return "ExampleScenario";
1106            case EXPLANATIONOFBENEFIT: return "ExplanationOfBenefit";
1107            case FAMILYMEMBERHISTORY: return "FamilyMemberHistory";
1108            case FLAG: return "Flag";
1109            case GOAL: return "Goal";
1110            case GRAPHDEFINITION: return "GraphDefinition";
1111            case GROUP: return "Group";
1112            case GUIDANCERESPONSE: return "GuidanceResponse";
1113            case HEALTHCARESERVICE: return "HealthcareService";
1114            case IMAGINGSTUDY: return "ImagingStudy";
1115            case IMMUNIZATION: return "Immunization";
1116            case IMMUNIZATIONEVALUATION: return "ImmunizationEvaluation";
1117            case IMMUNIZATIONRECOMMENDATION: return "ImmunizationRecommendation";
1118            case IMPLEMENTATIONGUIDE: return "ImplementationGuide";
1119            case INGREDIENT: return "Ingredient";
1120            case INSURANCEPLAN: return "InsurancePlan";
1121            case INVOICE: return "Invoice";
1122            case LIBRARY: return "Library";
1123            case LINKAGE: return "Linkage";
1124            case LIST: return "List";
1125            case LOCATION: return "Location";
1126            case MANUFACTUREDITEMDEFINITION: return "ManufacturedItemDefinition";
1127            case MEASURE: return "Measure";
1128            case MEASUREREPORT: return "MeasureReport";
1129            case MEDICATION: return "Medication";
1130            case MEDICATIONADMINISTRATION: return "MedicationAdministration";
1131            case MEDICATIONDISPENSE: return "MedicationDispense";
1132            case MEDICATIONKNOWLEDGE: return "MedicationKnowledge";
1133            case MEDICATIONREQUEST: return "MedicationRequest";
1134            case MEDICATIONUSAGE: return "MedicationUsage";
1135            case MEDICINALPRODUCTDEFINITION: return "MedicinalProductDefinition";
1136            case MESSAGEDEFINITION: return "MessageDefinition";
1137            case MESSAGEHEADER: return "MessageHeader";
1138            case MOLECULARSEQUENCE: return "MolecularSequence";
1139            case NAMINGSYSTEM: return "NamingSystem";
1140            case NUTRITIONINTAKE: return "NutritionIntake";
1141            case NUTRITIONORDER: return "NutritionOrder";
1142            case OBSERVATION: return "Observation";
1143            case OBSERVATIONDEFINITION: return "ObservationDefinition";
1144            case OPERATIONDEFINITION: return "OperationDefinition";
1145            case OPERATIONOUTCOME: return "OperationOutcome";
1146            case ORGANIZATION: return "Organization";
1147            case ORGANIZATIONAFFILIATION: return "OrganizationAffiliation";
1148            case PACKAGEDPRODUCTDEFINITION: return "PackagedProductDefinition";
1149            case PARAMETERS: return "Parameters";
1150            case PATIENT: return "Patient";
1151            case PAYMENTNOTICE: return "PaymentNotice";
1152            case PAYMENTRECONCILIATION: return "PaymentReconciliation";
1153            case PERSON: return "Person";
1154            case PLANDEFINITION: return "PlanDefinition";
1155            case PRACTITIONER: return "Practitioner";
1156            case PRACTITIONERROLE: return "PractitionerRole";
1157            case PROCEDURE: return "Procedure";
1158            case PROVENANCE: return "Provenance";
1159            case QUESTIONNAIRE: return "Questionnaire";
1160            case QUESTIONNAIRERESPONSE: return "QuestionnaireResponse";
1161            case REGULATEDAUTHORIZATION: return "RegulatedAuthorization";
1162            case RELATEDPERSON: return "RelatedPerson";
1163            case REQUESTGROUP: return "RequestGroup";
1164            case RESEARCHSTUDY: return "ResearchStudy";
1165            case RESEARCHSUBJECT: return "ResearchSubject";
1166            case RESOURCE: return "Resource";
1167            case RISKASSESSMENT: return "RiskAssessment";
1168            case SCHEDULE: return "Schedule";
1169            case SEARCHPARAMETER: return "SearchParameter";
1170            case SERVICEREQUEST: return "ServiceRequest";
1171            case SLOT: return "Slot";
1172            case SPECIMEN: return "Specimen";
1173            case SPECIMENDEFINITION: return "SpecimenDefinition";
1174            case STRUCTUREDEFINITION: return "StructureDefinition";
1175            case STRUCTUREMAP: return "StructureMap";
1176            case SUBSCRIPTION: return "Subscription";
1177            case SUBSTANCE: return "Substance";
1178            case SUBSTANCEDEFINITION: return "SubstanceDefinition";
1179            case SUBSTANCENUCLEICACID: return "SubstanceNucleicAcid";
1180            case SUBSTANCEPOLYMER: return "SubstancePolymer";
1181            case SUBSTANCEPROTEIN: return "SubstanceProtein";
1182            case SUBSTANCEREFERENCEINFORMATION: return "SubstanceReferenceInformation";
1183            case SUBSTANCESOURCEMATERIAL: return "SubstanceSourceMaterial";
1184            case SUPPLYDELIVERY: return "SupplyDelivery";
1185            case SUPPLYREQUEST: return "SupplyRequest";
1186            case TASK: return "Task";
1187            case TERMINOLOGYCAPABILITIES: return "TerminologyCapabilities";
1188            case TESTREPORT: return "TestReport";
1189            case TESTSCRIPT: return "TestScript";
1190            case TOPIC: return "Topic";
1191            case VALUESET: return "ValueSet";
1192            case VERIFICATIONRESULT: return "VerificationResult";
1193            case VISIONPRESCRIPTION: return "VisionPrescription";
1194            default: return "?";
1195          }
1196        }
1197        public String getSystem() {
1198          switch (this) {
1199            case ACCOUNT: return "http://hl7.org/fhir/resource-types";
1200            case ACTIVITYDEFINITION: return "http://hl7.org/fhir/resource-types";
1201            case ADMINISTRABLEPRODUCTDEFINITION: return "http://hl7.org/fhir/resource-types";
1202            case ADVERSEEVENT: return "http://hl7.org/fhir/resource-types";
1203            case ALLERGYINTOLERANCE: return "http://hl7.org/fhir/resource-types";
1204            case APPOINTMENT: return "http://hl7.org/fhir/resource-types";
1205            case APPOINTMENTRESPONSE: return "http://hl7.org/fhir/resource-types";
1206            case AUDITEVENT: return "http://hl7.org/fhir/resource-types";
1207            case BASIC: return "http://hl7.org/fhir/resource-types";
1208            case BINARY: return "http://hl7.org/fhir/resource-types";
1209            case BIOLOGICALLYDERIVEDPRODUCT: return "http://hl7.org/fhir/resource-types";
1210            case BODYSTRUCTURE: return "http://hl7.org/fhir/resource-types";
1211            case BUNDLE: return "http://hl7.org/fhir/resource-types";
1212            case CAPABILITYSTATEMENT: return "http://hl7.org/fhir/resource-types";
1213            case CAPABILITYSTATEMENT2: return "http://hl7.org/fhir/resource-types";
1214            case CAREPLAN: return "http://hl7.org/fhir/resource-types";
1215            case CARETEAM: return "http://hl7.org/fhir/resource-types";
1216            case CATALOGENTRY: return "http://hl7.org/fhir/resource-types";
1217            case CHARGEITEM: return "http://hl7.org/fhir/resource-types";
1218            case CHARGEITEMDEFINITION: return "http://hl7.org/fhir/resource-types";
1219            case CLAIM: return "http://hl7.org/fhir/resource-types";
1220            case CLAIMRESPONSE: return "http://hl7.org/fhir/resource-types";
1221            case CLINICALIMPRESSION: return "http://hl7.org/fhir/resource-types";
1222            case CLINICALUSEISSUE: return "http://hl7.org/fhir/resource-types";
1223            case CODESYSTEM: return "http://hl7.org/fhir/resource-types";
1224            case COMMUNICATION: return "http://hl7.org/fhir/resource-types";
1225            case COMMUNICATIONREQUEST: return "http://hl7.org/fhir/resource-types";
1226            case COMPARTMENTDEFINITION: return "http://hl7.org/fhir/resource-types";
1227            case COMPOSITION: return "http://hl7.org/fhir/resource-types";
1228            case CONCEPTMAP: return "http://hl7.org/fhir/resource-types";
1229            case CONDITION: return "http://hl7.org/fhir/resource-types";
1230            case CONDITIONDEFINITION: return "http://hl7.org/fhir/resource-types";
1231            case CONSENT: return "http://hl7.org/fhir/resource-types";
1232            case CONTRACT: return "http://hl7.org/fhir/resource-types";
1233            case COVERAGE: return "http://hl7.org/fhir/resource-types";
1234            case COVERAGEELIGIBILITYREQUEST: return "http://hl7.org/fhir/resource-types";
1235            case COVERAGEELIGIBILITYRESPONSE: return "http://hl7.org/fhir/resource-types";
1236            case DETECTEDISSUE: return "http://hl7.org/fhir/resource-types";
1237            case DEVICE: return "http://hl7.org/fhir/resource-types";
1238            case DEVICEDEFINITION: return "http://hl7.org/fhir/resource-types";
1239            case DEVICEMETRIC: return "http://hl7.org/fhir/resource-types";
1240            case DEVICEREQUEST: return "http://hl7.org/fhir/resource-types";
1241            case DEVICEUSESTATEMENT: return "http://hl7.org/fhir/resource-types";
1242            case DIAGNOSTICREPORT: return "http://hl7.org/fhir/resource-types";
1243            case DOCUMENTMANIFEST: return "http://hl7.org/fhir/resource-types";
1244            case DOCUMENTREFERENCE: return "http://hl7.org/fhir/resource-types";
1245            case DOMAINRESOURCE: return "http://hl7.org/fhir/resource-types";
1246            case ENCOUNTER: return "http://hl7.org/fhir/resource-types";
1247            case ENDPOINT: return "http://hl7.org/fhir/resource-types";
1248            case ENROLLMENTREQUEST: return "http://hl7.org/fhir/resource-types";
1249            case ENROLLMENTRESPONSE: return "http://hl7.org/fhir/resource-types";
1250            case EPISODEOFCARE: return "http://hl7.org/fhir/resource-types";
1251            case EVENTDEFINITION: return "http://hl7.org/fhir/resource-types";
1252            case EVIDENCE: return "http://hl7.org/fhir/resource-types";
1253            case EVIDENCEVARIABLE: return "http://hl7.org/fhir/resource-types";
1254            case EXAMPLESCENARIO: return "http://hl7.org/fhir/resource-types";
1255            case EXPLANATIONOFBENEFIT: return "http://hl7.org/fhir/resource-types";
1256            case FAMILYMEMBERHISTORY: return "http://hl7.org/fhir/resource-types";
1257            case FLAG: return "http://hl7.org/fhir/resource-types";
1258            case GOAL: return "http://hl7.org/fhir/resource-types";
1259            case GRAPHDEFINITION: return "http://hl7.org/fhir/resource-types";
1260            case GROUP: return "http://hl7.org/fhir/resource-types";
1261            case GUIDANCERESPONSE: return "http://hl7.org/fhir/resource-types";
1262            case HEALTHCARESERVICE: return "http://hl7.org/fhir/resource-types";
1263            case IMAGINGSTUDY: return "http://hl7.org/fhir/resource-types";
1264            case IMMUNIZATION: return "http://hl7.org/fhir/resource-types";
1265            case IMMUNIZATIONEVALUATION: return "http://hl7.org/fhir/resource-types";
1266            case IMMUNIZATIONRECOMMENDATION: return "http://hl7.org/fhir/resource-types";
1267            case IMPLEMENTATIONGUIDE: return "http://hl7.org/fhir/resource-types";
1268            case INGREDIENT: return "http://hl7.org/fhir/resource-types";
1269            case INSURANCEPLAN: return "http://hl7.org/fhir/resource-types";
1270            case INVOICE: return "http://hl7.org/fhir/resource-types";
1271            case LIBRARY: return "http://hl7.org/fhir/resource-types";
1272            case LINKAGE: return "http://hl7.org/fhir/resource-types";
1273            case LIST: return "http://hl7.org/fhir/resource-types";
1274            case LOCATION: return "http://hl7.org/fhir/resource-types";
1275            case MANUFACTUREDITEMDEFINITION: return "http://hl7.org/fhir/resource-types";
1276            case MEASURE: return "http://hl7.org/fhir/resource-types";
1277            case MEASUREREPORT: return "http://hl7.org/fhir/resource-types";
1278            case MEDICATION: return "http://hl7.org/fhir/resource-types";
1279            case MEDICATIONADMINISTRATION: return "http://hl7.org/fhir/resource-types";
1280            case MEDICATIONDISPENSE: return "http://hl7.org/fhir/resource-types";
1281            case MEDICATIONKNOWLEDGE: return "http://hl7.org/fhir/resource-types";
1282            case MEDICATIONREQUEST: return "http://hl7.org/fhir/resource-types";
1283            case MEDICATIONUSAGE: return "http://hl7.org/fhir/resource-types";
1284            case MEDICINALPRODUCTDEFINITION: return "http://hl7.org/fhir/resource-types";
1285            case MESSAGEDEFINITION: return "http://hl7.org/fhir/resource-types";
1286            case MESSAGEHEADER: return "http://hl7.org/fhir/resource-types";
1287            case MOLECULARSEQUENCE: return "http://hl7.org/fhir/resource-types";
1288            case NAMINGSYSTEM: return "http://hl7.org/fhir/resource-types";
1289            case NUTRITIONINTAKE: return "http://hl7.org/fhir/resource-types";
1290            case NUTRITIONORDER: return "http://hl7.org/fhir/resource-types";
1291            case OBSERVATION: return "http://hl7.org/fhir/resource-types";
1292            case OBSERVATIONDEFINITION: return "http://hl7.org/fhir/resource-types";
1293            case OPERATIONDEFINITION: return "http://hl7.org/fhir/resource-types";
1294            case OPERATIONOUTCOME: return "http://hl7.org/fhir/resource-types";
1295            case ORGANIZATION: return "http://hl7.org/fhir/resource-types";
1296            case ORGANIZATIONAFFILIATION: return "http://hl7.org/fhir/resource-types";
1297            case PACKAGEDPRODUCTDEFINITION: return "http://hl7.org/fhir/resource-types";
1298            case PARAMETERS: return "http://hl7.org/fhir/resource-types";
1299            case PATIENT: return "http://hl7.org/fhir/resource-types";
1300            case PAYMENTNOTICE: return "http://hl7.org/fhir/resource-types";
1301            case PAYMENTRECONCILIATION: return "http://hl7.org/fhir/resource-types";
1302            case PERSON: return "http://hl7.org/fhir/resource-types";
1303            case PLANDEFINITION: return "http://hl7.org/fhir/resource-types";
1304            case PRACTITIONER: return "http://hl7.org/fhir/resource-types";
1305            case PRACTITIONERROLE: return "http://hl7.org/fhir/resource-types";
1306            case PROCEDURE: return "http://hl7.org/fhir/resource-types";
1307            case PROVENANCE: return "http://hl7.org/fhir/resource-types";
1308            case QUESTIONNAIRE: return "http://hl7.org/fhir/resource-types";
1309            case QUESTIONNAIRERESPONSE: return "http://hl7.org/fhir/resource-types";
1310            case REGULATEDAUTHORIZATION: return "http://hl7.org/fhir/resource-types";
1311            case RELATEDPERSON: return "http://hl7.org/fhir/resource-types";
1312            case REQUESTGROUP: return "http://hl7.org/fhir/resource-types";
1313            case RESEARCHSTUDY: return "http://hl7.org/fhir/resource-types";
1314            case RESEARCHSUBJECT: return "http://hl7.org/fhir/resource-types";
1315            case RESOURCE: return "http://hl7.org/fhir/resource-types";
1316            case RISKASSESSMENT: return "http://hl7.org/fhir/resource-types";
1317            case SCHEDULE: return "http://hl7.org/fhir/resource-types";
1318            case SEARCHPARAMETER: return "http://hl7.org/fhir/resource-types";
1319            case SERVICEREQUEST: return "http://hl7.org/fhir/resource-types";
1320            case SLOT: return "http://hl7.org/fhir/resource-types";
1321            case SPECIMEN: return "http://hl7.org/fhir/resource-types";
1322            case SPECIMENDEFINITION: return "http://hl7.org/fhir/resource-types";
1323            case STRUCTUREDEFINITION: return "http://hl7.org/fhir/resource-types";
1324            case STRUCTUREMAP: return "http://hl7.org/fhir/resource-types";
1325            case SUBSCRIPTION: return "http://hl7.org/fhir/resource-types";
1326            case SUBSTANCE: return "http://hl7.org/fhir/resource-types";
1327            case SUBSTANCEDEFINITION: return "http://hl7.org/fhir/resource-types";
1328            case SUBSTANCENUCLEICACID: return "http://hl7.org/fhir/resource-types";
1329            case SUBSTANCEPOLYMER: return "http://hl7.org/fhir/resource-types";
1330            case SUBSTANCEPROTEIN: return "http://hl7.org/fhir/resource-types";
1331            case SUBSTANCEREFERENCEINFORMATION: return "http://hl7.org/fhir/resource-types";
1332            case SUBSTANCESOURCEMATERIAL: return "http://hl7.org/fhir/resource-types";
1333            case SUPPLYDELIVERY: return "http://hl7.org/fhir/resource-types";
1334            case SUPPLYREQUEST: return "http://hl7.org/fhir/resource-types";
1335            case TASK: return "http://hl7.org/fhir/resource-types";
1336            case TERMINOLOGYCAPABILITIES: return "http://hl7.org/fhir/resource-types";
1337            case TESTREPORT: return "http://hl7.org/fhir/resource-types";
1338            case TESTSCRIPT: return "http://hl7.org/fhir/resource-types";
1339            case TOPIC: return "http://hl7.org/fhir/resource-types";
1340            case VALUESET: return "http://hl7.org/fhir/resource-types";
1341            case VERIFICATIONRESULT: return "http://hl7.org/fhir/resource-types";
1342            case VISIONPRESCRIPTION: return "http://hl7.org/fhir/resource-types";
1343            default: return "?";
1344          }
1345        }
1346        public String getDefinition() {
1347          switch (this) {
1348            case ACCOUNT: return "A financial tool for tracking value accrued for a particular purpose.  In the healthcare field, used to track charges for a patient, cost centers, etc.";
1349            case ACTIVITYDEFINITION: return "This resource allows for the definition of some activity to be performed, independent of a particular patient, practitioner, or other performance context.";
1350            case ADMINISTRABLEPRODUCTDEFINITION: return "A pharmaceutical product described in terms of its composition and dose form.";
1351            case ADVERSEEVENT: return "An event (i.e. any change to current patient status) that may be related to unintended effects on a patient or research subject.  The unintended effects may require additional monitoring, treatment or hospitalization or may result in death.  The AdverseEvent resource also extends to potential or avoided events that could have had such effects.";
1352            case ALLERGYINTOLERANCE: return "Risk of harmful or undesirable, physiological response which is unique to an individual and associated with exposure to a substance.";
1353            case APPOINTMENT: return "A booking of a healthcare event among patient(s), practitioner(s), related person(s) and/or device(s) for a specific date/time. This may result in one or more Encounter(s).";
1354            case APPOINTMENTRESPONSE: return "A reply to an appointment request for a patient and/or practitioner(s), such as a confirmation or rejection.";
1355            case AUDITEVENT: return "A record of an event relevant for purposes such as operations, privacy, security, maintenance, and performance analysis.";
1356            case BASIC: return "Basic is used for handling concepts not yet defined in FHIR, narrative-only resources that don't map to an existing resource, and custom resources not appropriate for inclusion in the FHIR specification.";
1357            case BINARY: return "A resource that represents the data of a single raw artifact as digital content accessible in its native format.  A Binary resource can contain any content, whether text, image, pdf, zip archive, etc.";
1358            case BIOLOGICALLYDERIVEDPRODUCT: return "A material substance originating from a biological entity intended to be transplanted or infused\ninto another (possibly the same) biological entity.";
1359            case BODYSTRUCTURE: return "Record details about an anatomical structure.  This resource may be used when a coded concept does not provide the necessary detail needed for the use case.";
1360            case BUNDLE: return "A container for a collection of resources.";
1361            case CAPABILITYSTATEMENT: return "A Capability Statement documents a set of capabilities (behaviors) of a FHIR Server for a particular version of FHIR that may be used as a statement of actual server functionality or a statement of required or desired server implementation.";
1362            case CAPABILITYSTATEMENT2: return "A Capability Statement documents a set of capabilities (behaviors) of a FHIR Server for a particular version of FHIR that may be used as a statement of actual server functionality or a statement of required or desired server implementation.";
1363            case CAREPLAN: return "Describes the intention of how one or more practitioners intend to deliver care for a particular patient, group or community for a period of time, possibly limited to care for a specific condition or set of conditions.";
1364            case CARETEAM: return "The Care Team includes all the people and organizations who plan to participate in the coordination and delivery of care.";
1365            case CATALOGENTRY: return "Catalog entries are wrappers that contextualize items included in a catalog.";
1366            case CHARGEITEM: return "The resource ChargeItem describes the provision of healthcare provider products for a certain patient, therefore referring not only to the product, but containing in addition details of the provision, like date, time, amounts and participating organizations and persons. Main Usage of the ChargeItem is to enable the billing process and internal cost allocation.";
1367            case CHARGEITEMDEFINITION: return "The ChargeItemDefinition resource provides the properties that apply to the (billing) codes necessary to calculate costs and prices. The properties may differ largely depending on type and realm, therefore this resource gives only a rough structure and requires profiling for each type of billing code system.";
1368            case CLAIM: return "A provider issued list of professional services and products which have been provided, or are to be provided, to a patient which is sent to an insurer for reimbursement.";
1369            case CLAIMRESPONSE: return "This resource provides the adjudication details from the processing of a Claim resource.";
1370            case CLINICALIMPRESSION: return "A record of a clinical assessment performed to determine what problem(s) may affect the patient and before planning the treatments or management strategies that are best to manage a patient's condition. Assessments are often 1:1 with a clinical consultation / encounter,  but this varies greatly depending on the clinical workflow. This resource is called \"ClinicalImpression\" rather than \"ClinicalAssessment\" to avoid confusion with the recording of assessment tools such as Apgar score.";
1371            case CLINICALUSEISSUE: return "A single item of clinical particulars - an indication, contraindication, interaction etc. for a medicinal product.";
1372            case CODESYSTEM: return "The CodeSystem resource is used to declare the existence of and describe a code system or code system supplement and its key properties, and optionally define a part or all of its content.";
1373            case COMMUNICATION: return "An occurrence of information being transmitted; e.g. an alert that was sent to a responsible provider, a public health agency communication to a provider/reporter in response to a case report for a reportable condition.";
1374            case COMMUNICATIONREQUEST: return "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.";
1375            case COMPARTMENTDEFINITION: return "A compartment definition that defines how resources are accessed on a server.";
1376            case COMPOSITION: return "A set of healthcare-related information that is assembled together into a single logical package that provides a single coherent statement of meaning, establishes its own context and that has clinical attestation with regard to who is making the statement. A Composition defines the structure and narrative content necessary for a document. However, a Composition alone does not constitute a document. Rather, the Composition must be the first entry in a Bundle where Bundle.type=document, and any other resources referenced from Composition must be included as subsequent entries in the Bundle (for example Patient, Practitioner, Encounter, etc.).";
1377            case CONCEPTMAP: return "A statement of relationships from one set of concepts to one or more other concepts - either concepts in code systems, or data element/data element concepts, or classes in class models.";
1378            case CONDITION: return "A clinical condition, problem, diagnosis, or other event, situation, issue, or clinical concept that has risen to a level of concern.";
1379            case CONDITIONDEFINITION: return "A definition of a condition and information relevant to managing it.";
1380            case CONSENT: return "A record of a healthcare consumer’s  choices  or choices made on their behalf by a third party, which permits or denies identified recipient(s) or recipient role(s) to perform one or more actions within a given policy context, for specific purposes and periods of time.";
1381            case CONTRACT: return "Legally enforceable, formally recorded unilateral or bilateral directive i.e., a policy or agreement.";
1382            case COVERAGE: return "Financial instrument which may be used to reimburse or pay for health care products and services. Includes both insurance and self-payment.";
1383            case COVERAGEELIGIBILITYREQUEST: return "The CoverageEligibilityRequest provides patient and insurance coverage information to an insurer for them to respond, in the form of an CoverageEligibilityResponse, with information regarding whether the stated coverage is valid and in-force and optionally to provide the insurance details of the policy.";
1384            case COVERAGEELIGIBILITYRESPONSE: return "This resource provides eligibility and plan details from the processing of an CoverageEligibilityRequest resource.";
1385            case DETECTEDISSUE: return "Indicates an actual or potential clinical issue with or between one or more active or proposed clinical actions for a patient; e.g. Drug-drug interaction, Ineffective treatment frequency, Procedure-condition conflict, etc.";
1386            case DEVICE: return "A type of a manufactured item that is used in the provision of healthcare without being substantially changed through that activity. The device may be a medical or non-medical device.";
1387            case DEVICEDEFINITION: return "The characteristics, operational status and capabilities of a medical-related component of a medical device.";
1388            case DEVICEMETRIC: return "Describes a measurement, calculation or setting capability of a medical device.";
1389            case DEVICEREQUEST: return "Represents a request for a patient to employ a medical device. The device may be an implantable device, or an external assistive device, such as a walker.";
1390            case DEVICEUSESTATEMENT: return "A record of a device being used by a patient where the record is the result of a report from the patient or another clinician.";
1391            case DIAGNOSTICREPORT: return "The findings and interpretation of diagnostic  tests performed on patients, groups of patients, devices, and locations, and/or specimens derived from these. The report includes clinical context such as requesting and provider information, and some mix of atomic results, images, textual and coded interpretations, and formatted representation of diagnostic reports.";
1392            case DOCUMENTMANIFEST: return "A collection of documents compiled for a purpose together with metadata that applies to the collection.";
1393            case DOCUMENTREFERENCE: return "A reference to a document of any kind for any purpose. While the term “document” implies a more narrow focus, for this resource this \"document\" encompasses *any* seralized object with a mime-type, so includes formal patient centric documents (CDA), clniical notes, scanned paper, non-patient specific documents like policy text, as well as a photo, video, or audio recording acquired or used in healthcare.  The DocumentReference resource provides metadata about the document so that the document can be discovered and managed.  The actual content may be inline base64 encoded data or provided by direct reference.";
1394            case DOMAINRESOURCE: return "A resource that includes narrative, extensions, and contained resources.";
1395            case ENCOUNTER: return "An interaction between a patient and healthcare provider(s) for the purpose of providing healthcare service(s) or assessing the health status of a patient.";
1396            case ENDPOINT: return "The technical details of an endpoint that can be used for electronic services, such as for web services providing XDS.b or a REST endpoint for another FHIR server. This may include any security context information.";
1397            case ENROLLMENTREQUEST: return "This resource provides the insurance enrollment details to the insurer regarding a specified coverage.";
1398            case ENROLLMENTRESPONSE: return "This resource provides enrollment and plan details from the processing of an EnrollmentRequest resource.";
1399            case EPISODEOFCARE: return "An association between a patient and an organization / healthcare provider(s) during which time encounters may occur. The managing organization assumes a level of responsibility for the patient during this time.";
1400            case EVENTDEFINITION: return "The EventDefinition resource provides a reusable description of when a particular event can occur.";
1401            case EVIDENCE: return "This represents statistics, certainty, both the intended and actual population, and evidence variables.";
1402            case EVIDENCEVARIABLE: return "The EvidenceVariable resource describes a \"PICO\" element that knowledge (evidence, assertion, recommendation) is about.";
1403            case EXAMPLESCENARIO: return "Example of workflow instance.";
1404            case EXPLANATIONOFBENEFIT: return "This resource provides: the claim details; adjudication details from the processing of a Claim; and optionally account balance information, for informing the subscriber of the benefits provided.";
1405            case FAMILYMEMBERHISTORY: return "Significant health conditions for a person related to the patient relevant in the context of care for the patient.";
1406            case FLAG: return "Prospective warnings of potential issues when providing care to the patient.";
1407            case GOAL: return "Describes the intended objective(s) for a patient, group or organization care, for example, weight loss, restoring an activity of daily living, obtaining herd immunity via immunization, meeting a process improvement objective, etc.";
1408            case GRAPHDEFINITION: return "A formal computable definition of a graph of resources - that is, a coherent set of resources that form a graph by following references. The Graph Definition resource defines a set and makes rules about the set.";
1409            case GROUP: return "Represents a defined collection of entities that may be discussed or acted upon collectively but which are not expected to act collectively, and are not formally or legally recognized; i.e. a collection of entities that isn't an Organization.";
1410            case GUIDANCERESPONSE: return "A guidance response is the formal response to a guidance request, including any output parameters returned by the evaluation, as well as the description of any proposed actions to be taken.";
1411            case HEALTHCARESERVICE: return "The details of a healthcare service available at a location.";
1412            case IMAGINGSTUDY: return "Representation of the content produced in a DICOM imaging study. A study comprises a set of series, each of which includes a set of Service-Object Pair Instances (SOP Instances - images or other data) acquired or produced in a common context.  A series is of only one modality (e.g. X-ray, CT, MR, ultrasound), but a study may have multiple series of different modalities.";
1413            case IMMUNIZATION: return "Describes the event of a patient being administered a vaccine or a record of an immunization as reported by a patient, a clinician or another party.";
1414            case IMMUNIZATIONEVALUATION: return "Describes a comparison of an immunization event against published recommendations to determine if the administration is \"valid\" in relation to those  recommendations.";
1415            case IMMUNIZATIONRECOMMENDATION: return "A patient's point-in-time set of recommendations (i.e. forecasting) according to a published schedule with optional supporting justification.";
1416            case IMPLEMENTATIONGUIDE: return "A set of rules of how a particular interoperability or standards problem is solved - typically through the use of FHIR resources. This resource is used to gather all the parts of an implementation guide into a logical whole and to publish a computable definition of all the parts.";
1417            case INGREDIENT: return "An ingredient of a manufactured item or pharmaceutical product.";
1418            case INSURANCEPLAN: return "Details of a Health Insurance product/plan provided by an organization.";
1419            case INVOICE: return "Invoice containing collected ChargeItems from an Account with calculated individual and total price for Billing purpose.";
1420            case LIBRARY: return "The Library resource is a general-purpose container for knowledge asset definitions. It can be used to describe and expose existing knowledge assets such as logic libraries and information model descriptions, as well as to describe a collection of knowledge assets.";
1421            case LINKAGE: return "Identifies two or more records (resource instances) that refer to the same real-world \"occurrence\".";
1422            case LIST: return "A list is a curated collection of resources.";
1423            case LOCATION: return "Details and position information for a physical place where services are provided and resources and participants may be stored, found, contained, or accommodated.";
1424            case MANUFACTUREDITEMDEFINITION: return "The manufactured item as contained in the packaged medicinal product.";
1425            case MEASURE: return "The Measure resource provides the definition of a quality measure.";
1426            case MEASUREREPORT: return "The MeasureReport resource contains the results of the calculation of a measure; and optionally a reference to the resources involved in that calculation.";
1427            case MEDICATION: return "This resource is primarily used for the identification and definition of a medication for the purposes of prescribing, dispensing, and administering a medication as well as for making statements about medication use.";
1428            case MEDICATIONADMINISTRATION: return "Describes the event of a patient consuming or otherwise being administered a medication.  This may be as simple as swallowing a tablet or it may be a long running infusion.  Related resources tie this event to the authorizing prescription, and the specific encounter between patient and health care practitioner.";
1429            case MEDICATIONDISPENSE: return "Indicates that a medication product is to be or has been dispensed for a named person/patient.  This includes a description of the medication product (supply) provided and the instructions for administering the medication.  The medication dispense is the result of a pharmacy system responding to a medication order.";
1430            case MEDICATIONKNOWLEDGE: return "Information about a medication that is used to support knowledge.";
1431            case MEDICATIONREQUEST: return "An order or request for both supply of the medication and the instructions for administration of the medication to a patient. The resource is called \"MedicationRequest\" rather than \"MedicationPrescription\" or \"MedicationOrder\" to generalize the use across inpatient and outpatient settings, including care plans, etc., and to harmonize with workflow patterns.";
1432            case MEDICATIONUSAGE: return "A record of a medication that is being consumed by a patient.   A MedicationUsage may indicate that the patient may be taking the medication now or has taken the medication in the past or will be taking the medication in the future.  The source of this information can be the patient, significant other (such as a family member or spouse), or a clinician.  A common scenario where this information is captured is during the history taking process during a patient visit or stay.   The medication information may come from sources such as the patient's memory, from a prescription bottle,  or from a list of medications the patient, clinician or other party maintains. \n\nThe primary difference between a medicationusage and a medicationadministration is that the medication administration has complete administration information and is based on actual administration information from the person who administered the medication.  A medicationusage is often, if not always, less specific.  There is no required date/time when the medication was administered, in fact we only know that a source has reported the patient is taking this medication, where details such as time, quantity, or rate or even medication product may be incomplete or missing or less precise.  As stated earlier, the Medication Usage information may come from the patient's memory, from a prescription bottle or from a list of medications the patient, clinician or other party maintains.  Medication administration is more formal and is not missing detailed information.";
1433            case MEDICINALPRODUCTDEFINITION: return "Detailed definition of a medicinal product, typically for uses other than direct patient care (e.g. regulatory use).";
1434            case MESSAGEDEFINITION: return "Defines the characteristics of a message that can be shared between systems, including the type of event that initiates the message, the content to be transmitted and what response(s), if any, are permitted.";
1435            case MESSAGEHEADER: return "The header for a message exchange that is either requesting or responding to an action.  The reference(s) that are the subject of the action as well as other information related to the action are typically transmitted in a bundle in which the MessageHeader resource instance is the first resource in the bundle.";
1436            case MOLECULARSEQUENCE: return "Raw data describing a biological sequence.";
1437            case NAMINGSYSTEM: return "A curated namespace that issues unique symbols within that namespace for the identification of concepts, people, devices, etc.  Represents a \"System\" used within the Identifier and Coding data types.";
1438            case NUTRITIONINTAKE: return "A record of food or fluid that is being consumed by a patient.   A NutritionIntake may indicate that the patient may be consuming the food or fluid now or has consumed the food or fluid in the past.  The source of this information can be the patient, significant other (such as a family member or spouse), or a clinician.  A common scenario where this information is captured is during the history taking process during a patient visit or stay or through an app that tracks food or fluids consumed.   The consumption information may come from sources such as the patient's memory, from a nutrition label,  or from a clinician documenting observed intake.";
1439            case NUTRITIONORDER: return "A request to supply a diet, formula feeding (enteral) or oral nutritional supplement to a patient/resident.";
1440            case OBSERVATION: return "Measurements and simple assertions made about a patient, device or other subject.";
1441            case OBSERVATIONDEFINITION: return "Set of definitional characteristics for a kind of observation or measurement produced or consumed by an orderable health care service.";
1442            case OPERATIONDEFINITION: return "A formal computable definition of an operation (on the RESTful interface) or a named query (using the search interaction).";
1443            case OPERATIONOUTCOME: return "A collection of error, warning, or information messages that result from a system action.";
1444            case ORGANIZATION: return "A formally or informally recognized grouping of people or organizations formed for the purpose of achieving some form of collective action.  Includes companies, institutions, corporations, departments, community groups, healthcare practice groups, payer/insurer, etc.";
1445            case ORGANIZATIONAFFILIATION: return "Defines an affiliation/assotiation/relationship between 2 distinct oganizations, that is not a part-of relationship/sub-division relationship.";
1446            case PACKAGEDPRODUCTDEFINITION: return "A medicinal product in a container or package.";
1447            case PARAMETERS: return "This resource is a non-persisted resource used to pass information into and back from an [operation](operations.html). It has no other use, and there is no RESTful endpoint associated with it.";
1448            case PATIENT: return "Demographics and other administrative information about an individual or animal receiving care or other health-related services.";
1449            case PAYMENTNOTICE: return "This resource provides the status of the payment for goods and services rendered, and the request and response resource references.";
1450            case PAYMENTRECONCILIATION: return "This resource provides the details including amount of a payment and allocates the payment items being paid.";
1451            case PERSON: return "Demographics and administrative information about a person independent of a specific health-related context.";
1452            case PLANDEFINITION: return "This resource allows for the definition of various types of plans as a sharable, consumable, and executable artifact. The resource is general enough to support the description of a broad range of clinical artifacts such as clinical decision support rules, order sets and protocols.";
1453            case PRACTITIONER: return "A person who is directly or indirectly involved in the provisioning of healthcare.";
1454            case PRACTITIONERROLE: return "A specific set of Roles/Locations/specialties/services that a practitioner may perform at an organization for a period of time.";
1455            case PROCEDURE: return "An action that is or was performed on or for a patient. This can be a physical intervention like an operation, or less invasive like long term services, counseling, or hypnotherapy.";
1456            case PROVENANCE: return "Provenance of a resource is a record that describes entities and processes involved in producing and delivering or otherwise influencing that resource. Provenance provides a critical foundation for assessing authenticity, enabling trust, and allowing reproducibility. Provenance assertions are a form of contextual metadata and can themselves become important records with their own provenance. Provenance statement indicates clinical significance in terms of confidence in authenticity, reliability, and trustworthiness, integrity, and stage in lifecycle (e.g. Document Completion - has the artifact been legally authenticated), all of which may impact security, privacy, and trust policies.";
1457            case QUESTIONNAIRE: return "A structured set of questions intended to guide the collection of answers from end-users. Questionnaires provide detailed control over order, presentation, phraseology and grouping to allow coherent, consistent data collection.";
1458            case QUESTIONNAIRERESPONSE: return "A structured set of questions and their answers. The questions are ordered and grouped into coherent subsets, corresponding to the structure of the grouping of the questionnaire being responded to.";
1459            case REGULATEDAUTHORIZATION: return "The regulatory authorization of a medicinal product.";
1460            case RELATEDPERSON: return "Information about a person that is involved in the care for a patient, but who is not the target of healthcare, nor has a formal responsibility in the care process.";
1461            case REQUESTGROUP: return "A group of related requests that can be used to capture intended activities that have inter-dependencies such as \"give this medication after that one\".";
1462            case RESEARCHSTUDY: return "A process where a researcher or organization plans and then executes a series of steps intended to increase the field of healthcare-related knowledge.  This includes studies of safety, efficacy, comparative effectiveness and other information about medications, devices, therapies and other interventional and investigative techniques.  A ResearchStudy involves the gathering of information about human or animal subjects.";
1463            case RESEARCHSUBJECT: return "A physical entity which is the primary unit of operational and/or administrative interest in a study.";
1464            case RESOURCE: return "This is the base resource type for everything.";
1465            case RISKASSESSMENT: return "An assessment of the likely outcome(s) for a patient or other subject as well as the likelihood of each outcome.";
1466            case SCHEDULE: return "A container for slots of time that may be available for booking appointments.";
1467            case SEARCHPARAMETER: return "A search parameter that defines a named search item that can be used to search/filter on a resource.";
1468            case SERVICEREQUEST: return "A record of a request for service such as diagnostic investigations, treatments, or operations to be performed.";
1469            case SLOT: return "A slot of time on a schedule that may be available for booking appointments.";
1470            case SPECIMEN: return "A sample to be used for analysis.";
1471            case SPECIMENDEFINITION: return "A kind of specimen with associated set of requirements.";
1472            case STRUCTUREDEFINITION: return "A definition of a FHIR structure. This resource is used to describe the underlying resources, data types defined in FHIR, and also for describing extensions and constraints on resources and data types.";
1473            case STRUCTUREMAP: return "A Map of relationships between 2 structures that can be used to transform data.";
1474            case SUBSCRIPTION: return "The subscription resource describes a particular client's request to be notified about a Topic.";
1475            case SUBSTANCE: return "A homogeneous material with a definite composition.";
1476            case SUBSTANCEDEFINITION: return "The detailed description of a substance, typically at a level beyond what is used for prescribing.";
1477            case SUBSTANCENUCLEICACID: return "Nucleic acids are defined by three distinct elements: the base, sugar and linkage. Individual substance/moiety IDs will be created for each of these elements. The nucleotide sequence will be always entered in the 5’-3’ direction.";
1478            case SUBSTANCEPOLYMER: return "Todo.";
1479            case SUBSTANCEPROTEIN: return "A SubstanceProtein is defined as a single unit of a linear amino acid sequence, or a combination of subunits that are either covalently linked or have a defined invariant stoichiometric relationship. This includes all synthetic, recombinant and purified SubstanceProteins of defined sequence, whether the use is therapeutic or prophylactic. This set of elements will be used to describe albumins, coagulation factors, cytokines, growth factors, peptide/SubstanceProtein hormones, enzymes, toxins, toxoids, recombinant vaccines, and immunomodulators.";
1480            case SUBSTANCEREFERENCEINFORMATION: return "Todo.";
1481            case SUBSTANCESOURCEMATERIAL: return "Source material shall capture information on the taxonomic and anatomical origins as well as the fraction of a material that can result in or can be modified to form a substance. This set of data elements shall be used to define polymer substances isolated from biological matrices. Taxonomic and anatomical origins shall be described using a controlled vocabulary as required. This information is captured for naturally derived polymers ( . starch) and structurally diverse substances. For Organisms belonging to the Kingdom Plantae the Substance level defines the fresh material of a single species or infraspecies, the Herbal Drug and the Herbal preparation. For Herbal preparations, the fraction information will be captured at the Substance information level and additional information for herbal extracts will be captured at the Specified Substance Group 1 information level. See for further explanation the Substance Class: Structurally Diverse and the herbal annex.";
1482            case SUPPLYDELIVERY: return "Record of delivery of what is supplied.";
1483            case SUPPLYREQUEST: return "A record of a request for a medication, substance or device used in the healthcare setting.";
1484            case TASK: return "A task to be performed.";
1485            case TERMINOLOGYCAPABILITIES: return "A TerminologyCapabilities resource documents a set of capabilities (behaviors) of a FHIR Terminology Server that may be used as a statement of actual server functionality or a statement of required or desired server implementation.";
1486            case TESTREPORT: return "A summary of information based on the results of executing a TestScript.";
1487            case TESTSCRIPT: return "A structured set of tests against a FHIR server or client implementation to determine compliance against the FHIR specification.";
1488            case TOPIC: return "Describes a stream of resource state changes identified by trigger criteria and annotated with labels useful to filter projections from this topic.";
1489            case VALUESET: return "A ValueSet resource instance specifies a set of codes drawn from one or more code systems, intended for use in a particular context. Value sets link between [[[CodeSystem]]] definitions and their use in [coded elements](terminologies.html).";
1490            case VERIFICATIONRESULT: return "Describes validation requirements, source(s), status and dates for one or more elements.";
1491            case VISIONPRESCRIPTION: return "An authorization for the provision of glasses and/or contact lenses to a patient.";
1492            default: return "?";
1493          }
1494        }
1495        public String getDisplay() {
1496          switch (this) {
1497            case ACCOUNT: return "Account";
1498            case ACTIVITYDEFINITION: return "ActivityDefinition";
1499            case ADMINISTRABLEPRODUCTDEFINITION: return "AdministrableProductDefinition";
1500            case ADVERSEEVENT: return "AdverseEvent";
1501            case ALLERGYINTOLERANCE: return "AllergyIntolerance";
1502            case APPOINTMENT: return "Appointment";
1503            case APPOINTMENTRESPONSE: return "AppointmentResponse";
1504            case AUDITEVENT: return "AuditEvent";
1505            case BASIC: return "Basic";
1506            case BINARY: return "Binary";
1507            case BIOLOGICALLYDERIVEDPRODUCT: return "BiologicallyDerivedProduct";
1508            case BODYSTRUCTURE: return "BodyStructure";
1509            case BUNDLE: return "Bundle";
1510            case CAPABILITYSTATEMENT: return "CapabilityStatement";
1511            case CAPABILITYSTATEMENT2: return "CapabilityStatement2";
1512            case CAREPLAN: return "CarePlan";
1513            case CARETEAM: return "CareTeam";
1514            case CATALOGENTRY: return "CatalogEntry";
1515            case CHARGEITEM: return "ChargeItem";
1516            case CHARGEITEMDEFINITION: return "ChargeItemDefinition";
1517            case CLAIM: return "Claim";
1518            case CLAIMRESPONSE: return "ClaimResponse";
1519            case CLINICALIMPRESSION: return "ClinicalImpression";
1520            case CLINICALUSEISSUE: return "ClinicalUseIssue";
1521            case CODESYSTEM: return "CodeSystem";
1522            case COMMUNICATION: return "Communication";
1523            case COMMUNICATIONREQUEST: return "CommunicationRequest";
1524            case COMPARTMENTDEFINITION: return "CompartmentDefinition";
1525            case COMPOSITION: return "Composition";
1526            case CONCEPTMAP: return "ConceptMap";
1527            case CONDITION: return "Condition";
1528            case CONDITIONDEFINITION: return "ConditionDefinition";
1529            case CONSENT: return "Consent";
1530            case CONTRACT: return "Contract";
1531            case COVERAGE: return "Coverage";
1532            case COVERAGEELIGIBILITYREQUEST: return "CoverageEligibilityRequest";
1533            case COVERAGEELIGIBILITYRESPONSE: return "CoverageEligibilityResponse";
1534            case DETECTEDISSUE: return "DetectedIssue";
1535            case DEVICE: return "Device";
1536            case DEVICEDEFINITION: return "DeviceDefinition";
1537            case DEVICEMETRIC: return "DeviceMetric";
1538            case DEVICEREQUEST: return "DeviceRequest";
1539            case DEVICEUSESTATEMENT: return "DeviceUseStatement";
1540            case DIAGNOSTICREPORT: return "DiagnosticReport";
1541            case DOCUMENTMANIFEST: return "DocumentManifest";
1542            case DOCUMENTREFERENCE: return "DocumentReference";
1543            case DOMAINRESOURCE: return "DomainResource";
1544            case ENCOUNTER: return "Encounter";
1545            case ENDPOINT: return "Endpoint";
1546            case ENROLLMENTREQUEST: return "EnrollmentRequest";
1547            case ENROLLMENTRESPONSE: return "EnrollmentResponse";
1548            case EPISODEOFCARE: return "EpisodeOfCare";
1549            case EVENTDEFINITION: return "EventDefinition";
1550            case EVIDENCE: return "Evidence";
1551            case EVIDENCEVARIABLE: return "EvidenceVariable";
1552            case EXAMPLESCENARIO: return "ExampleScenario";
1553            case EXPLANATIONOFBENEFIT: return "ExplanationOfBenefit";
1554            case FAMILYMEMBERHISTORY: return "FamilyMemberHistory";
1555            case FLAG: return "Flag";
1556            case GOAL: return "Goal";
1557            case GRAPHDEFINITION: return "GraphDefinition";
1558            case GROUP: return "Group";
1559            case GUIDANCERESPONSE: return "GuidanceResponse";
1560            case HEALTHCARESERVICE: return "HealthcareService";
1561            case IMAGINGSTUDY: return "ImagingStudy";
1562            case IMMUNIZATION: return "Immunization";
1563            case IMMUNIZATIONEVALUATION: return "ImmunizationEvaluation";
1564            case IMMUNIZATIONRECOMMENDATION: return "ImmunizationRecommendation";
1565            case IMPLEMENTATIONGUIDE: return "ImplementationGuide";
1566            case INGREDIENT: return "Ingredient";
1567            case INSURANCEPLAN: return "InsurancePlan";
1568            case INVOICE: return "Invoice";
1569            case LIBRARY: return "Library";
1570            case LINKAGE: return "Linkage";
1571            case LIST: return "List";
1572            case LOCATION: return "Location";
1573            case MANUFACTUREDITEMDEFINITION: return "ManufacturedItemDefinition";
1574            case MEASURE: return "Measure";
1575            case MEASUREREPORT: return "MeasureReport";
1576            case MEDICATION: return "Medication";
1577            case MEDICATIONADMINISTRATION: return "MedicationAdministration";
1578            case MEDICATIONDISPENSE: return "MedicationDispense";
1579            case MEDICATIONKNOWLEDGE: return "MedicationKnowledge";
1580            case MEDICATIONREQUEST: return "MedicationRequest";
1581            case MEDICATIONUSAGE: return "MedicationUsage";
1582            case MEDICINALPRODUCTDEFINITION: return "MedicinalProductDefinition";
1583            case MESSAGEDEFINITION: return "MessageDefinition";
1584            case MESSAGEHEADER: return "MessageHeader";
1585            case MOLECULARSEQUENCE: return "MolecularSequence";
1586            case NAMINGSYSTEM: return "NamingSystem";
1587            case NUTRITIONINTAKE: return "NutritionIntake";
1588            case NUTRITIONORDER: return "NutritionOrder";
1589            case OBSERVATION: return "Observation";
1590            case OBSERVATIONDEFINITION: return "ObservationDefinition";
1591            case OPERATIONDEFINITION: return "OperationDefinition";
1592            case OPERATIONOUTCOME: return "OperationOutcome";
1593            case ORGANIZATION: return "Organization";
1594            case ORGANIZATIONAFFILIATION: return "OrganizationAffiliation";
1595            case PACKAGEDPRODUCTDEFINITION: return "PackagedProductDefinition";
1596            case PARAMETERS: return "Parameters";
1597            case PATIENT: return "Patient";
1598            case PAYMENTNOTICE: return "PaymentNotice";
1599            case PAYMENTRECONCILIATION: return "PaymentReconciliation";
1600            case PERSON: return "Person";
1601            case PLANDEFINITION: return "PlanDefinition";
1602            case PRACTITIONER: return "Practitioner";
1603            case PRACTITIONERROLE: return "PractitionerRole";
1604            case PROCEDURE: return "Procedure";
1605            case PROVENANCE: return "Provenance";
1606            case QUESTIONNAIRE: return "Questionnaire";
1607            case QUESTIONNAIRERESPONSE: return "QuestionnaireResponse";
1608            case REGULATEDAUTHORIZATION: return "RegulatedAuthorization";
1609            case RELATEDPERSON: return "RelatedPerson";
1610            case REQUESTGROUP: return "RequestGroup";
1611            case RESEARCHSTUDY: return "ResearchStudy";
1612            case RESEARCHSUBJECT: return "ResearchSubject";
1613            case RESOURCE: return "Resource";
1614            case RISKASSESSMENT: return "RiskAssessment";
1615            case SCHEDULE: return "Schedule";
1616            case SEARCHPARAMETER: return "SearchParameter";
1617            case SERVICEREQUEST: return "ServiceRequest";
1618            case SLOT: return "Slot";
1619            case SPECIMEN: return "Specimen";
1620            case SPECIMENDEFINITION: return "SpecimenDefinition";
1621            case STRUCTUREDEFINITION: return "StructureDefinition";
1622            case STRUCTUREMAP: return "StructureMap";
1623            case SUBSCRIPTION: return "Subscription";
1624            case SUBSTANCE: return "Substance";
1625            case SUBSTANCEDEFINITION: return "SubstanceDefinition";
1626            case SUBSTANCENUCLEICACID: return "SubstanceNucleicAcid";
1627            case SUBSTANCEPOLYMER: return "SubstancePolymer";
1628            case SUBSTANCEPROTEIN: return "SubstanceProtein";
1629            case SUBSTANCEREFERENCEINFORMATION: return "SubstanceReferenceInformation";
1630            case SUBSTANCESOURCEMATERIAL: return "SubstanceSourceMaterial";
1631            case SUPPLYDELIVERY: return "SupplyDelivery";
1632            case SUPPLYREQUEST: return "SupplyRequest";
1633            case TASK: return "Task";
1634            case TERMINOLOGYCAPABILITIES: return "TerminologyCapabilities";
1635            case TESTREPORT: return "TestReport";
1636            case TESTSCRIPT: return "TestScript";
1637            case TOPIC: return "Topic";
1638            case VALUESET: return "ValueSet";
1639            case VERIFICATIONRESULT: return "VerificationResult";
1640            case VISIONPRESCRIPTION: return "VisionPrescription";
1641            default: return "?";
1642          }
1643        }
1644    }
1645
1646  public static class FHIRResourceTypeEnumFactory implements EnumFactory<FHIRResourceType> {
1647    public FHIRResourceType fromCode(String codeString) throws IllegalArgumentException {
1648      if (codeString == null || "".equals(codeString))
1649            if (codeString == null || "".equals(codeString))
1650                return null;
1651        if ("Account".equals(codeString))
1652          return FHIRResourceType.ACCOUNT;
1653        if ("ActivityDefinition".equals(codeString))
1654          return FHIRResourceType.ACTIVITYDEFINITION;
1655        if ("AdministrableProductDefinition".equals(codeString))
1656          return FHIRResourceType.ADMINISTRABLEPRODUCTDEFINITION;
1657        if ("AdverseEvent".equals(codeString))
1658          return FHIRResourceType.ADVERSEEVENT;
1659        if ("AllergyIntolerance".equals(codeString))
1660          return FHIRResourceType.ALLERGYINTOLERANCE;
1661        if ("Appointment".equals(codeString))
1662          return FHIRResourceType.APPOINTMENT;
1663        if ("AppointmentResponse".equals(codeString))
1664          return FHIRResourceType.APPOINTMENTRESPONSE;
1665        if ("AuditEvent".equals(codeString))
1666          return FHIRResourceType.AUDITEVENT;
1667        if ("Basic".equals(codeString))
1668          return FHIRResourceType.BASIC;
1669        if ("Binary".equals(codeString))
1670          return FHIRResourceType.BINARY;
1671        if ("BiologicallyDerivedProduct".equals(codeString))
1672          return FHIRResourceType.BIOLOGICALLYDERIVEDPRODUCT;
1673        if ("BodyStructure".equals(codeString))
1674          return FHIRResourceType.BODYSTRUCTURE;
1675        if ("Bundle".equals(codeString))
1676          return FHIRResourceType.BUNDLE;
1677        if ("CapabilityStatement".equals(codeString))
1678          return FHIRResourceType.CAPABILITYSTATEMENT;
1679        if ("CapabilityStatement2".equals(codeString))
1680          return FHIRResourceType.CAPABILITYSTATEMENT2;
1681        if ("CarePlan".equals(codeString))
1682          return FHIRResourceType.CAREPLAN;
1683        if ("CareTeam".equals(codeString))
1684          return FHIRResourceType.CARETEAM;
1685        if ("CatalogEntry".equals(codeString))
1686          return FHIRResourceType.CATALOGENTRY;
1687        if ("ChargeItem".equals(codeString))
1688          return FHIRResourceType.CHARGEITEM;
1689        if ("ChargeItemDefinition".equals(codeString))
1690          return FHIRResourceType.CHARGEITEMDEFINITION;
1691        if ("Claim".equals(codeString))
1692          return FHIRResourceType.CLAIM;
1693        if ("ClaimResponse".equals(codeString))
1694          return FHIRResourceType.CLAIMRESPONSE;
1695        if ("ClinicalImpression".equals(codeString))
1696          return FHIRResourceType.CLINICALIMPRESSION;
1697        if ("ClinicalUseIssue".equals(codeString))
1698          return FHIRResourceType.CLINICALUSEISSUE;
1699        if ("CodeSystem".equals(codeString))
1700          return FHIRResourceType.CODESYSTEM;
1701        if ("Communication".equals(codeString))
1702          return FHIRResourceType.COMMUNICATION;
1703        if ("CommunicationRequest".equals(codeString))
1704          return FHIRResourceType.COMMUNICATIONREQUEST;
1705        if ("CompartmentDefinition".equals(codeString))
1706          return FHIRResourceType.COMPARTMENTDEFINITION;
1707        if ("Composition".equals(codeString))
1708          return FHIRResourceType.COMPOSITION;
1709        if ("ConceptMap".equals(codeString))
1710          return FHIRResourceType.CONCEPTMAP;
1711        if ("Condition".equals(codeString))
1712          return FHIRResourceType.CONDITION;
1713        if ("ConditionDefinition".equals(codeString))
1714          return FHIRResourceType.CONDITIONDEFINITION;
1715        if ("Consent".equals(codeString))
1716          return FHIRResourceType.CONSENT;
1717        if ("Contract".equals(codeString))
1718          return FHIRResourceType.CONTRACT;
1719        if ("Coverage".equals(codeString))
1720          return FHIRResourceType.COVERAGE;
1721        if ("CoverageEligibilityRequest".equals(codeString))
1722          return FHIRResourceType.COVERAGEELIGIBILITYREQUEST;
1723        if ("CoverageEligibilityResponse".equals(codeString))
1724          return FHIRResourceType.COVERAGEELIGIBILITYRESPONSE;
1725        if ("DetectedIssue".equals(codeString))
1726          return FHIRResourceType.DETECTEDISSUE;
1727        if ("Device".equals(codeString))
1728          return FHIRResourceType.DEVICE;
1729        if ("DeviceDefinition".equals(codeString))
1730          return FHIRResourceType.DEVICEDEFINITION;
1731        if ("DeviceMetric".equals(codeString))
1732          return FHIRResourceType.DEVICEMETRIC;
1733        if ("DeviceRequest".equals(codeString))
1734          return FHIRResourceType.DEVICEREQUEST;
1735        if ("DeviceUseStatement".equals(codeString))
1736          return FHIRResourceType.DEVICEUSESTATEMENT;
1737        if ("DiagnosticReport".equals(codeString))
1738          return FHIRResourceType.DIAGNOSTICREPORT;
1739        if ("DocumentManifest".equals(codeString))
1740          return FHIRResourceType.DOCUMENTMANIFEST;
1741        if ("DocumentReference".equals(codeString))
1742          return FHIRResourceType.DOCUMENTREFERENCE;
1743        if ("DomainResource".equals(codeString))
1744          return FHIRResourceType.DOMAINRESOURCE;
1745        if ("Encounter".equals(codeString))
1746          return FHIRResourceType.ENCOUNTER;
1747        if ("Endpoint".equals(codeString))
1748          return FHIRResourceType.ENDPOINT;
1749        if ("EnrollmentRequest".equals(codeString))
1750          return FHIRResourceType.ENROLLMENTREQUEST;
1751        if ("EnrollmentResponse".equals(codeString))
1752          return FHIRResourceType.ENROLLMENTRESPONSE;
1753        if ("EpisodeOfCare".equals(codeString))
1754          return FHIRResourceType.EPISODEOFCARE;
1755        if ("EventDefinition".equals(codeString))
1756          return FHIRResourceType.EVENTDEFINITION;
1757        if ("Evidence".equals(codeString))
1758          return FHIRResourceType.EVIDENCE;
1759        if ("EvidenceVariable".equals(codeString))
1760          return FHIRResourceType.EVIDENCEVARIABLE;
1761        if ("ExampleScenario".equals(codeString))
1762          return FHIRResourceType.EXAMPLESCENARIO;
1763        if ("ExplanationOfBenefit".equals(codeString))
1764          return FHIRResourceType.EXPLANATIONOFBENEFIT;
1765        if ("FamilyMemberHistory".equals(codeString))
1766          return FHIRResourceType.FAMILYMEMBERHISTORY;
1767        if ("Flag".equals(codeString))
1768          return FHIRResourceType.FLAG;
1769        if ("Goal".equals(codeString))
1770          return FHIRResourceType.GOAL;
1771        if ("GraphDefinition".equals(codeString))
1772          return FHIRResourceType.GRAPHDEFINITION;
1773        if ("Group".equals(codeString))
1774          return FHIRResourceType.GROUP;
1775        if ("GuidanceResponse".equals(codeString))
1776          return FHIRResourceType.GUIDANCERESPONSE;
1777        if ("HealthcareService".equals(codeString))
1778          return FHIRResourceType.HEALTHCARESERVICE;
1779        if ("ImagingStudy".equals(codeString))
1780          return FHIRResourceType.IMAGINGSTUDY;
1781        if ("Immunization".equals(codeString))
1782          return FHIRResourceType.IMMUNIZATION;
1783        if ("ImmunizationEvaluation".equals(codeString))
1784          return FHIRResourceType.IMMUNIZATIONEVALUATION;
1785        if ("ImmunizationRecommendation".equals(codeString))
1786          return FHIRResourceType.IMMUNIZATIONRECOMMENDATION;
1787        if ("ImplementationGuide".equals(codeString))
1788          return FHIRResourceType.IMPLEMENTATIONGUIDE;
1789        if ("Ingredient".equals(codeString))
1790          return FHIRResourceType.INGREDIENT;
1791        if ("InsurancePlan".equals(codeString))
1792          return FHIRResourceType.INSURANCEPLAN;
1793        if ("Invoice".equals(codeString))
1794          return FHIRResourceType.INVOICE;
1795        if ("Library".equals(codeString))
1796          return FHIRResourceType.LIBRARY;
1797        if ("Linkage".equals(codeString))
1798          return FHIRResourceType.LINKAGE;
1799        if ("List".equals(codeString))
1800          return FHIRResourceType.LIST;
1801        if ("Location".equals(codeString))
1802          return FHIRResourceType.LOCATION;
1803        if ("ManufacturedItemDefinition".equals(codeString))
1804          return FHIRResourceType.MANUFACTUREDITEMDEFINITION;
1805        if ("Measure".equals(codeString))
1806          return FHIRResourceType.MEASURE;
1807        if ("MeasureReport".equals(codeString))
1808          return FHIRResourceType.MEASUREREPORT;
1809        if ("Medication".equals(codeString))
1810          return FHIRResourceType.MEDICATION;
1811        if ("MedicationAdministration".equals(codeString))
1812          return FHIRResourceType.MEDICATIONADMINISTRATION;
1813        if ("MedicationDispense".equals(codeString))
1814          return FHIRResourceType.MEDICATIONDISPENSE;
1815        if ("MedicationKnowledge".equals(codeString))
1816          return FHIRResourceType.MEDICATIONKNOWLEDGE;
1817        if ("MedicationRequest".equals(codeString))
1818          return FHIRResourceType.MEDICATIONREQUEST;
1819        if ("MedicationUsage".equals(codeString))
1820          return FHIRResourceType.MEDICATIONUSAGE;
1821        if ("MedicinalProductDefinition".equals(codeString))
1822          return FHIRResourceType.MEDICINALPRODUCTDEFINITION;
1823        if ("MessageDefinition".equals(codeString))
1824          return FHIRResourceType.MESSAGEDEFINITION;
1825        if ("MessageHeader".equals(codeString))
1826          return FHIRResourceType.MESSAGEHEADER;
1827        if ("MolecularSequence".equals(codeString))
1828          return FHIRResourceType.MOLECULARSEQUENCE;
1829        if ("NamingSystem".equals(codeString))
1830          return FHIRResourceType.NAMINGSYSTEM;
1831        if ("NutritionIntake".equals(codeString))
1832          return FHIRResourceType.NUTRITIONINTAKE;
1833        if ("NutritionOrder".equals(codeString))
1834          return FHIRResourceType.NUTRITIONORDER;
1835        if ("Observation".equals(codeString))
1836          return FHIRResourceType.OBSERVATION;
1837        if ("ObservationDefinition".equals(codeString))
1838          return FHIRResourceType.OBSERVATIONDEFINITION;
1839        if ("OperationDefinition".equals(codeString))
1840          return FHIRResourceType.OPERATIONDEFINITION;
1841        if ("OperationOutcome".equals(codeString))
1842          return FHIRResourceType.OPERATIONOUTCOME;
1843        if ("Organization".equals(codeString))
1844          return FHIRResourceType.ORGANIZATION;
1845        if ("OrganizationAffiliation".equals(codeString))
1846          return FHIRResourceType.ORGANIZATIONAFFILIATION;
1847        if ("PackagedProductDefinition".equals(codeString))
1848          return FHIRResourceType.PACKAGEDPRODUCTDEFINITION;
1849        if ("Parameters".equals(codeString))
1850          return FHIRResourceType.PARAMETERS;
1851        if ("Patient".equals(codeString))
1852          return FHIRResourceType.PATIENT;
1853        if ("PaymentNotice".equals(codeString))
1854          return FHIRResourceType.PAYMENTNOTICE;
1855        if ("PaymentReconciliation".equals(codeString))
1856          return FHIRResourceType.PAYMENTRECONCILIATION;
1857        if ("Person".equals(codeString))
1858          return FHIRResourceType.PERSON;
1859        if ("PlanDefinition".equals(codeString))
1860          return FHIRResourceType.PLANDEFINITION;
1861        if ("Practitioner".equals(codeString))
1862          return FHIRResourceType.PRACTITIONER;
1863        if ("PractitionerRole".equals(codeString))
1864          return FHIRResourceType.PRACTITIONERROLE;
1865        if ("Procedure".equals(codeString))
1866          return FHIRResourceType.PROCEDURE;
1867        if ("Provenance".equals(codeString))
1868          return FHIRResourceType.PROVENANCE;
1869        if ("Questionnaire".equals(codeString))
1870          return FHIRResourceType.QUESTIONNAIRE;
1871        if ("QuestionnaireResponse".equals(codeString))
1872          return FHIRResourceType.QUESTIONNAIRERESPONSE;
1873        if ("RegulatedAuthorization".equals(codeString))
1874          return FHIRResourceType.REGULATEDAUTHORIZATION;
1875        if ("RelatedPerson".equals(codeString))
1876          return FHIRResourceType.RELATEDPERSON;
1877        if ("RequestGroup".equals(codeString))
1878          return FHIRResourceType.REQUESTGROUP;
1879        if ("ResearchStudy".equals(codeString))
1880          return FHIRResourceType.RESEARCHSTUDY;
1881        if ("ResearchSubject".equals(codeString))
1882          return FHIRResourceType.RESEARCHSUBJECT;
1883        if ("Resource".equals(codeString))
1884          return FHIRResourceType.RESOURCE;
1885        if ("RiskAssessment".equals(codeString))
1886          return FHIRResourceType.RISKASSESSMENT;
1887        if ("Schedule".equals(codeString))
1888          return FHIRResourceType.SCHEDULE;
1889        if ("SearchParameter".equals(codeString))
1890          return FHIRResourceType.SEARCHPARAMETER;
1891        if ("ServiceRequest".equals(codeString))
1892          return FHIRResourceType.SERVICEREQUEST;
1893        if ("Slot".equals(codeString))
1894          return FHIRResourceType.SLOT;
1895        if ("Specimen".equals(codeString))
1896          return FHIRResourceType.SPECIMEN;
1897        if ("SpecimenDefinition".equals(codeString))
1898          return FHIRResourceType.SPECIMENDEFINITION;
1899        if ("StructureDefinition".equals(codeString))
1900          return FHIRResourceType.STRUCTUREDEFINITION;
1901        if ("StructureMap".equals(codeString))
1902          return FHIRResourceType.STRUCTUREMAP;
1903        if ("Subscription".equals(codeString))
1904          return FHIRResourceType.SUBSCRIPTION;
1905        if ("Substance".equals(codeString))
1906          return FHIRResourceType.SUBSTANCE;
1907        if ("SubstanceDefinition".equals(codeString))
1908          return FHIRResourceType.SUBSTANCEDEFINITION;
1909        if ("SubstanceNucleicAcid".equals(codeString))
1910          return FHIRResourceType.SUBSTANCENUCLEICACID;
1911        if ("SubstancePolymer".equals(codeString))
1912          return FHIRResourceType.SUBSTANCEPOLYMER;
1913        if ("SubstanceProtein".equals(codeString))
1914          return FHIRResourceType.SUBSTANCEPROTEIN;
1915        if ("SubstanceReferenceInformation".equals(codeString))
1916          return FHIRResourceType.SUBSTANCEREFERENCEINFORMATION;
1917        if ("SubstanceSourceMaterial".equals(codeString))
1918          return FHIRResourceType.SUBSTANCESOURCEMATERIAL;
1919        if ("SupplyDelivery".equals(codeString))
1920          return FHIRResourceType.SUPPLYDELIVERY;
1921        if ("SupplyRequest".equals(codeString))
1922          return FHIRResourceType.SUPPLYREQUEST;
1923        if ("Task".equals(codeString))
1924          return FHIRResourceType.TASK;
1925        if ("TerminologyCapabilities".equals(codeString))
1926          return FHIRResourceType.TERMINOLOGYCAPABILITIES;
1927        if ("TestReport".equals(codeString))
1928          return FHIRResourceType.TESTREPORT;
1929        if ("TestScript".equals(codeString))
1930          return FHIRResourceType.TESTSCRIPT;
1931        if ("Topic".equals(codeString))
1932          return FHIRResourceType.TOPIC;
1933        if ("ValueSet".equals(codeString))
1934          return FHIRResourceType.VALUESET;
1935        if ("VerificationResult".equals(codeString))
1936          return FHIRResourceType.VERIFICATIONRESULT;
1937        if ("VisionPrescription".equals(codeString))
1938          return FHIRResourceType.VISIONPRESCRIPTION;
1939        throw new IllegalArgumentException("Unknown FHIRResourceType code '"+codeString+"'");
1940        }
1941        public Enumeration<FHIRResourceType> fromType(Base code) throws FHIRException {
1942          if (code == null)
1943            return null;
1944          if (code.isEmpty())
1945            return new Enumeration<FHIRResourceType>(this);
1946          String codeString = ((PrimitiveType) code).asStringValue();
1947          if (codeString == null || "".equals(codeString))
1948            return null;
1949        if ("Account".equals(codeString))
1950          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ACCOUNT);
1951        if ("ActivityDefinition".equals(codeString))
1952          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ACTIVITYDEFINITION);
1953        if ("AdministrableProductDefinition".equals(codeString))
1954          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ADMINISTRABLEPRODUCTDEFINITION);
1955        if ("AdverseEvent".equals(codeString))
1956          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ADVERSEEVENT);
1957        if ("AllergyIntolerance".equals(codeString))
1958          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ALLERGYINTOLERANCE);
1959        if ("Appointment".equals(codeString))
1960          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.APPOINTMENT);
1961        if ("AppointmentResponse".equals(codeString))
1962          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.APPOINTMENTRESPONSE);
1963        if ("AuditEvent".equals(codeString))
1964          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.AUDITEVENT);
1965        if ("Basic".equals(codeString))
1966          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.BASIC);
1967        if ("Binary".equals(codeString))
1968          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.BINARY);
1969        if ("BiologicallyDerivedProduct".equals(codeString))
1970          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.BIOLOGICALLYDERIVEDPRODUCT);
1971        if ("BodyStructure".equals(codeString))
1972          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.BODYSTRUCTURE);
1973        if ("Bundle".equals(codeString))
1974          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.BUNDLE);
1975        if ("CapabilityStatement".equals(codeString))
1976          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CAPABILITYSTATEMENT);
1977        if ("CapabilityStatement2".equals(codeString))
1978          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CAPABILITYSTATEMENT2);
1979        if ("CarePlan".equals(codeString))
1980          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CAREPLAN);
1981        if ("CareTeam".equals(codeString))
1982          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CARETEAM);
1983        if ("CatalogEntry".equals(codeString))
1984          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CATALOGENTRY);
1985        if ("ChargeItem".equals(codeString))
1986          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CHARGEITEM);
1987        if ("ChargeItemDefinition".equals(codeString))
1988          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CHARGEITEMDEFINITION);
1989        if ("Claim".equals(codeString))
1990          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CLAIM);
1991        if ("ClaimResponse".equals(codeString))
1992          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CLAIMRESPONSE);
1993        if ("ClinicalImpression".equals(codeString))
1994          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CLINICALIMPRESSION);
1995        if ("ClinicalUseIssue".equals(codeString))
1996          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CLINICALUSEISSUE);
1997        if ("CodeSystem".equals(codeString))
1998          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CODESYSTEM);
1999        if ("Communication".equals(codeString))
2000          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.COMMUNICATION);
2001        if ("CommunicationRequest".equals(codeString))
2002          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.COMMUNICATIONREQUEST);
2003        if ("CompartmentDefinition".equals(codeString))
2004          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.COMPARTMENTDEFINITION);
2005        if ("Composition".equals(codeString))
2006          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.COMPOSITION);
2007        if ("ConceptMap".equals(codeString))
2008          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CONCEPTMAP);
2009        if ("Condition".equals(codeString))
2010          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CONDITION);
2011        if ("ConditionDefinition".equals(codeString))
2012          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CONDITIONDEFINITION);
2013        if ("Consent".equals(codeString))
2014          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CONSENT);
2015        if ("Contract".equals(codeString))
2016          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.CONTRACT);
2017        if ("Coverage".equals(codeString))
2018          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.COVERAGE);
2019        if ("CoverageEligibilityRequest".equals(codeString))
2020          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.COVERAGEELIGIBILITYREQUEST);
2021        if ("CoverageEligibilityResponse".equals(codeString))
2022          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.COVERAGEELIGIBILITYRESPONSE);
2023        if ("DetectedIssue".equals(codeString))
2024          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.DETECTEDISSUE);
2025        if ("Device".equals(codeString))
2026          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.DEVICE);
2027        if ("DeviceDefinition".equals(codeString))
2028          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.DEVICEDEFINITION);
2029        if ("DeviceMetric".equals(codeString))
2030          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.DEVICEMETRIC);
2031        if ("DeviceRequest".equals(codeString))
2032          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.DEVICEREQUEST);
2033        if ("DeviceUseStatement".equals(codeString))
2034          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.DEVICEUSESTATEMENT);
2035        if ("DiagnosticReport".equals(codeString))
2036          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.DIAGNOSTICREPORT);
2037        if ("DocumentManifest".equals(codeString))
2038          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.DOCUMENTMANIFEST);
2039        if ("DocumentReference".equals(codeString))
2040          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.DOCUMENTREFERENCE);
2041        if ("DomainResource".equals(codeString))
2042          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.DOMAINRESOURCE);
2043        if ("Encounter".equals(codeString))
2044          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ENCOUNTER);
2045        if ("Endpoint".equals(codeString))
2046          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ENDPOINT);
2047        if ("EnrollmentRequest".equals(codeString))
2048          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ENROLLMENTREQUEST);
2049        if ("EnrollmentResponse".equals(codeString))
2050          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ENROLLMENTRESPONSE);
2051        if ("EpisodeOfCare".equals(codeString))
2052          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.EPISODEOFCARE);
2053        if ("EventDefinition".equals(codeString))
2054          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.EVENTDEFINITION);
2055        if ("Evidence".equals(codeString))
2056          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.EVIDENCE);
2057        if ("EvidenceVariable".equals(codeString))
2058          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.EVIDENCEVARIABLE);
2059        if ("ExampleScenario".equals(codeString))
2060          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.EXAMPLESCENARIO);
2061        if ("ExplanationOfBenefit".equals(codeString))
2062          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.EXPLANATIONOFBENEFIT);
2063        if ("FamilyMemberHistory".equals(codeString))
2064          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.FAMILYMEMBERHISTORY);
2065        if ("Flag".equals(codeString))
2066          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.FLAG);
2067        if ("Goal".equals(codeString))
2068          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.GOAL);
2069        if ("GraphDefinition".equals(codeString))
2070          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.GRAPHDEFINITION);
2071        if ("Group".equals(codeString))
2072          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.GROUP);
2073        if ("GuidanceResponse".equals(codeString))
2074          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.GUIDANCERESPONSE);
2075        if ("HealthcareService".equals(codeString))
2076          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.HEALTHCARESERVICE);
2077        if ("ImagingStudy".equals(codeString))
2078          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.IMAGINGSTUDY);
2079        if ("Immunization".equals(codeString))
2080          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.IMMUNIZATION);
2081        if ("ImmunizationEvaluation".equals(codeString))
2082          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.IMMUNIZATIONEVALUATION);
2083        if ("ImmunizationRecommendation".equals(codeString))
2084          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.IMMUNIZATIONRECOMMENDATION);
2085        if ("ImplementationGuide".equals(codeString))
2086          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.IMPLEMENTATIONGUIDE);
2087        if ("Ingredient".equals(codeString))
2088          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.INGREDIENT);
2089        if ("InsurancePlan".equals(codeString))
2090          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.INSURANCEPLAN);
2091        if ("Invoice".equals(codeString))
2092          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.INVOICE);
2093        if ("Library".equals(codeString))
2094          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.LIBRARY);
2095        if ("Linkage".equals(codeString))
2096          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.LINKAGE);
2097        if ("List".equals(codeString))
2098          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.LIST);
2099        if ("Location".equals(codeString))
2100          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.LOCATION);
2101        if ("ManufacturedItemDefinition".equals(codeString))
2102          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MANUFACTUREDITEMDEFINITION);
2103        if ("Measure".equals(codeString))
2104          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MEASURE);
2105        if ("MeasureReport".equals(codeString))
2106          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MEASUREREPORT);
2107        if ("Medication".equals(codeString))
2108          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MEDICATION);
2109        if ("MedicationAdministration".equals(codeString))
2110          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MEDICATIONADMINISTRATION);
2111        if ("MedicationDispense".equals(codeString))
2112          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MEDICATIONDISPENSE);
2113        if ("MedicationKnowledge".equals(codeString))
2114          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MEDICATIONKNOWLEDGE);
2115        if ("MedicationRequest".equals(codeString))
2116          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MEDICATIONREQUEST);
2117        if ("MedicationUsage".equals(codeString))
2118          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MEDICATIONUSAGE);
2119        if ("MedicinalProductDefinition".equals(codeString))
2120          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MEDICINALPRODUCTDEFINITION);
2121        if ("MessageDefinition".equals(codeString))
2122          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MESSAGEDEFINITION);
2123        if ("MessageHeader".equals(codeString))
2124          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MESSAGEHEADER);
2125        if ("MolecularSequence".equals(codeString))
2126          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.MOLECULARSEQUENCE);
2127        if ("NamingSystem".equals(codeString))
2128          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.NAMINGSYSTEM);
2129        if ("NutritionIntake".equals(codeString))
2130          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.NUTRITIONINTAKE);
2131        if ("NutritionOrder".equals(codeString))
2132          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.NUTRITIONORDER);
2133        if ("Observation".equals(codeString))
2134          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.OBSERVATION);
2135        if ("ObservationDefinition".equals(codeString))
2136          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.OBSERVATIONDEFINITION);
2137        if ("OperationDefinition".equals(codeString))
2138          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.OPERATIONDEFINITION);
2139        if ("OperationOutcome".equals(codeString))
2140          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.OPERATIONOUTCOME);
2141        if ("Organization".equals(codeString))
2142          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ORGANIZATION);
2143        if ("OrganizationAffiliation".equals(codeString))
2144          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.ORGANIZATIONAFFILIATION);
2145        if ("PackagedProductDefinition".equals(codeString))
2146          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PACKAGEDPRODUCTDEFINITION);
2147        if ("Parameters".equals(codeString))
2148          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PARAMETERS);
2149        if ("Patient".equals(codeString))
2150          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PATIENT);
2151        if ("PaymentNotice".equals(codeString))
2152          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PAYMENTNOTICE);
2153        if ("PaymentReconciliation".equals(codeString))
2154          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PAYMENTRECONCILIATION);
2155        if ("Person".equals(codeString))
2156          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PERSON);
2157        if ("PlanDefinition".equals(codeString))
2158          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PLANDEFINITION);
2159        if ("Practitioner".equals(codeString))
2160          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PRACTITIONER);
2161        if ("PractitionerRole".equals(codeString))
2162          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PRACTITIONERROLE);
2163        if ("Procedure".equals(codeString))
2164          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PROCEDURE);
2165        if ("Provenance".equals(codeString))
2166          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.PROVENANCE);
2167        if ("Questionnaire".equals(codeString))
2168          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.QUESTIONNAIRE);
2169        if ("QuestionnaireResponse".equals(codeString))
2170          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.QUESTIONNAIRERESPONSE);
2171        if ("RegulatedAuthorization".equals(codeString))
2172          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.REGULATEDAUTHORIZATION);
2173        if ("RelatedPerson".equals(codeString))
2174          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.RELATEDPERSON);
2175        if ("RequestGroup".equals(codeString))
2176          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.REQUESTGROUP);
2177        if ("ResearchStudy".equals(codeString))
2178          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.RESEARCHSTUDY);
2179        if ("ResearchSubject".equals(codeString))
2180          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.RESEARCHSUBJECT);
2181        if ("Resource".equals(codeString))
2182          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.RESOURCE);
2183        if ("RiskAssessment".equals(codeString))
2184          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.RISKASSESSMENT);
2185        if ("Schedule".equals(codeString))
2186          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SCHEDULE);
2187        if ("SearchParameter".equals(codeString))
2188          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SEARCHPARAMETER);
2189        if ("ServiceRequest".equals(codeString))
2190          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SERVICEREQUEST);
2191        if ("Slot".equals(codeString))
2192          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SLOT);
2193        if ("Specimen".equals(codeString))
2194          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SPECIMEN);
2195        if ("SpecimenDefinition".equals(codeString))
2196          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SPECIMENDEFINITION);
2197        if ("StructureDefinition".equals(codeString))
2198          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.STRUCTUREDEFINITION);
2199        if ("StructureMap".equals(codeString))
2200          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.STRUCTUREMAP);
2201        if ("Subscription".equals(codeString))
2202          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SUBSCRIPTION);
2203        if ("Substance".equals(codeString))
2204          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SUBSTANCE);
2205        if ("SubstanceDefinition".equals(codeString))
2206          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SUBSTANCEDEFINITION);
2207        if ("SubstanceNucleicAcid".equals(codeString))
2208          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SUBSTANCENUCLEICACID);
2209        if ("SubstancePolymer".equals(codeString))
2210          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SUBSTANCEPOLYMER);
2211        if ("SubstanceProtein".equals(codeString))
2212          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SUBSTANCEPROTEIN);
2213        if ("SubstanceReferenceInformation".equals(codeString))
2214          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SUBSTANCEREFERENCEINFORMATION);
2215        if ("SubstanceSourceMaterial".equals(codeString))
2216          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SUBSTANCESOURCEMATERIAL);
2217        if ("SupplyDelivery".equals(codeString))
2218          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SUPPLYDELIVERY);
2219        if ("SupplyRequest".equals(codeString))
2220          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.SUPPLYREQUEST);
2221        if ("Task".equals(codeString))
2222          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.TASK);
2223        if ("TerminologyCapabilities".equals(codeString))
2224          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.TERMINOLOGYCAPABILITIES);
2225        if ("TestReport".equals(codeString))
2226          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.TESTREPORT);
2227        if ("TestScript".equals(codeString))
2228          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.TESTSCRIPT);
2229        if ("Topic".equals(codeString))
2230          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.TOPIC);
2231        if ("ValueSet".equals(codeString))
2232          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.VALUESET);
2233        if ("VerificationResult".equals(codeString))
2234          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.VERIFICATIONRESULT);
2235        if ("VisionPrescription".equals(codeString))
2236          return new Enumeration<FHIRResourceType>(this, FHIRResourceType.VISIONPRESCRIPTION);
2237        throw new FHIRException("Unknown FHIRResourceType code '"+codeString+"'");
2238        }
2239    public String toCode(FHIRResourceType code) {
2240      if (code == FHIRResourceType.ACCOUNT)
2241        return "Account";
2242      if (code == FHIRResourceType.ACTIVITYDEFINITION)
2243        return "ActivityDefinition";
2244      if (code == FHIRResourceType.ADMINISTRABLEPRODUCTDEFINITION)
2245        return "AdministrableProductDefinition";
2246      if (code == FHIRResourceType.ADVERSEEVENT)
2247        return "AdverseEvent";
2248      if (code == FHIRResourceType.ALLERGYINTOLERANCE)
2249        return "AllergyIntolerance";
2250      if (code == FHIRResourceType.APPOINTMENT)
2251        return "Appointment";
2252      if (code == FHIRResourceType.APPOINTMENTRESPONSE)
2253        return "AppointmentResponse";
2254      if (code == FHIRResourceType.AUDITEVENT)
2255        return "AuditEvent";
2256      if (code == FHIRResourceType.BASIC)
2257        return "Basic";
2258      if (code == FHIRResourceType.BINARY)
2259        return "Binary";
2260      if (code == FHIRResourceType.BIOLOGICALLYDERIVEDPRODUCT)
2261        return "BiologicallyDerivedProduct";
2262      if (code == FHIRResourceType.BODYSTRUCTURE)
2263        return "BodyStructure";
2264      if (code == FHIRResourceType.BUNDLE)
2265        return "Bundle";
2266      if (code == FHIRResourceType.CAPABILITYSTATEMENT)
2267        return "CapabilityStatement";
2268      if (code == FHIRResourceType.CAPABILITYSTATEMENT2)
2269        return "CapabilityStatement2";
2270      if (code == FHIRResourceType.CAREPLAN)
2271        return "CarePlan";
2272      if (code == FHIRResourceType.CARETEAM)
2273        return "CareTeam";
2274      if (code == FHIRResourceType.CATALOGENTRY)
2275        return "CatalogEntry";
2276      if (code == FHIRResourceType.CHARGEITEM)
2277        return "ChargeItem";
2278      if (code == FHIRResourceType.CHARGEITEMDEFINITION)
2279        return "ChargeItemDefinition";
2280      if (code == FHIRResourceType.CLAIM)
2281        return "Claim";
2282      if (code == FHIRResourceType.CLAIMRESPONSE)
2283        return "ClaimResponse";
2284      if (code == FHIRResourceType.CLINICALIMPRESSION)
2285        return "ClinicalImpression";
2286      if (code == FHIRResourceType.CLINICALUSEISSUE)
2287        return "ClinicalUseIssue";
2288      if (code == FHIRResourceType.CODESYSTEM)
2289        return "CodeSystem";
2290      if (code == FHIRResourceType.COMMUNICATION)
2291        return "Communication";
2292      if (code == FHIRResourceType.COMMUNICATIONREQUEST)
2293        return "CommunicationRequest";
2294      if (code == FHIRResourceType.COMPARTMENTDEFINITION)
2295        return "CompartmentDefinition";
2296      if (code == FHIRResourceType.COMPOSITION)
2297        return "Composition";
2298      if (code == FHIRResourceType.CONCEPTMAP)
2299        return "ConceptMap";
2300      if (code == FHIRResourceType.CONDITION)
2301        return "Condition";
2302      if (code == FHIRResourceType.CONDITIONDEFINITION)
2303        return "ConditionDefinition";
2304      if (code == FHIRResourceType.CONSENT)
2305        return "Consent";
2306      if (code == FHIRResourceType.CONTRACT)
2307        return "Contract";
2308      if (code == FHIRResourceType.COVERAGE)
2309        return "Coverage";
2310      if (code == FHIRResourceType.COVERAGEELIGIBILITYREQUEST)
2311        return "CoverageEligibilityRequest";
2312      if (code == FHIRResourceType.COVERAGEELIGIBILITYRESPONSE)
2313        return "CoverageEligibilityResponse";
2314      if (code == FHIRResourceType.DETECTEDISSUE)
2315        return "DetectedIssue";
2316      if (code == FHIRResourceType.DEVICE)
2317        return "Device";
2318      if (code == FHIRResourceType.DEVICEDEFINITION)
2319        return "DeviceDefinition";
2320      if (code == FHIRResourceType.DEVICEMETRIC)
2321        return "DeviceMetric";
2322      if (code == FHIRResourceType.DEVICEREQUEST)
2323        return "DeviceRequest";
2324      if (code == FHIRResourceType.DEVICEUSESTATEMENT)
2325        return "DeviceUseStatement";
2326      if (code == FHIRResourceType.DIAGNOSTICREPORT)
2327        return "DiagnosticReport";
2328      if (code == FHIRResourceType.DOCUMENTMANIFEST)
2329        return "DocumentManifest";
2330      if (code == FHIRResourceType.DOCUMENTREFERENCE)
2331        return "DocumentReference";
2332      if (code == FHIRResourceType.DOMAINRESOURCE)
2333        return "DomainResource";
2334      if (code == FHIRResourceType.ENCOUNTER)
2335        return "Encounter";
2336      if (code == FHIRResourceType.ENDPOINT)
2337        return "Endpoint";
2338      if (code == FHIRResourceType.ENROLLMENTREQUEST)
2339        return "EnrollmentRequest";
2340      if (code == FHIRResourceType.ENROLLMENTRESPONSE)
2341        return "EnrollmentResponse";
2342      if (code == FHIRResourceType.EPISODEOFCARE)
2343        return "EpisodeOfCare";
2344      if (code == FHIRResourceType.EVENTDEFINITION)
2345        return "EventDefinition";
2346      if (code == FHIRResourceType.EVIDENCE)
2347        return "Evidence";
2348      if (code == FHIRResourceType.EVIDENCEVARIABLE)
2349        return "EvidenceVariable";
2350      if (code == FHIRResourceType.EXAMPLESCENARIO)
2351        return "ExampleScenario";
2352      if (code == FHIRResourceType.EXPLANATIONOFBENEFIT)
2353        return "ExplanationOfBenefit";
2354      if (code == FHIRResourceType.FAMILYMEMBERHISTORY)
2355        return "FamilyMemberHistory";
2356      if (code == FHIRResourceType.FLAG)
2357        return "Flag";
2358      if (code == FHIRResourceType.GOAL)
2359        return "Goal";
2360      if (code == FHIRResourceType.GRAPHDEFINITION)
2361        return "GraphDefinition";
2362      if (code == FHIRResourceType.GROUP)
2363        return "Group";
2364      if (code == FHIRResourceType.GUIDANCERESPONSE)
2365        return "GuidanceResponse";
2366      if (code == FHIRResourceType.HEALTHCARESERVICE)
2367        return "HealthcareService";
2368      if (code == FHIRResourceType.IMAGINGSTUDY)
2369        return "ImagingStudy";
2370      if (code == FHIRResourceType.IMMUNIZATION)
2371        return "Immunization";
2372      if (code == FHIRResourceType.IMMUNIZATIONEVALUATION)
2373        return "ImmunizationEvaluation";
2374      if (code == FHIRResourceType.IMMUNIZATIONRECOMMENDATION)
2375        return "ImmunizationRecommendation";
2376      if (code == FHIRResourceType.IMPLEMENTATIONGUIDE)
2377        return "ImplementationGuide";
2378      if (code == FHIRResourceType.INGREDIENT)
2379        return "Ingredient";
2380      if (code == FHIRResourceType.INSURANCEPLAN)
2381        return "InsurancePlan";
2382      if (code == FHIRResourceType.INVOICE)
2383        return "Invoice";
2384      if (code == FHIRResourceType.LIBRARY)
2385        return "Library";
2386      if (code == FHIRResourceType.LINKAGE)
2387        return "Linkage";
2388      if (code == FHIRResourceType.LIST)
2389        return "List";
2390      if (code == FHIRResourceType.LOCATION)
2391        return "Location";
2392      if (code == FHIRResourceType.MANUFACTUREDITEMDEFINITION)
2393        return "ManufacturedItemDefinition";
2394      if (code == FHIRResourceType.MEASURE)
2395        return "Measure";
2396      if (code == FHIRResourceType.MEASUREREPORT)
2397        return "MeasureReport";
2398      if (code == FHIRResourceType.MEDICATION)
2399        return "Medication";
2400      if (code == FHIRResourceType.MEDICATIONADMINISTRATION)
2401        return "MedicationAdministration";
2402      if (code == FHIRResourceType.MEDICATIONDISPENSE)
2403        return "MedicationDispense";
2404      if (code == FHIRResourceType.MEDICATIONKNOWLEDGE)
2405        return "MedicationKnowledge";
2406      if (code == FHIRResourceType.MEDICATIONREQUEST)
2407        return "MedicationRequest";
2408      if (code == FHIRResourceType.MEDICATIONUSAGE)
2409        return "MedicationUsage";
2410      if (code == FHIRResourceType.MEDICINALPRODUCTDEFINITION)
2411        return "MedicinalProductDefinition";
2412      if (code == FHIRResourceType.MESSAGEDEFINITION)
2413        return "MessageDefinition";
2414      if (code == FHIRResourceType.MESSAGEHEADER)
2415        return "MessageHeader";
2416      if (code == FHIRResourceType.MOLECULARSEQUENCE)
2417        return "MolecularSequence";
2418      if (code == FHIRResourceType.NAMINGSYSTEM)
2419        return "NamingSystem";
2420      if (code == FHIRResourceType.NUTRITIONINTAKE)
2421        return "NutritionIntake";
2422      if (code == FHIRResourceType.NUTRITIONORDER)
2423        return "NutritionOrder";
2424      if (code == FHIRResourceType.OBSERVATION)
2425        return "Observation";
2426      if (code == FHIRResourceType.OBSERVATIONDEFINITION)
2427        return "ObservationDefinition";
2428      if (code == FHIRResourceType.OPERATIONDEFINITION)
2429        return "OperationDefinition";
2430      if (code == FHIRResourceType.OPERATIONOUTCOME)
2431        return "OperationOutcome";
2432      if (code == FHIRResourceType.ORGANIZATION)
2433        return "Organization";
2434      if (code == FHIRResourceType.ORGANIZATIONAFFILIATION)
2435        return "OrganizationAffiliation";
2436      if (code == FHIRResourceType.PACKAGEDPRODUCTDEFINITION)
2437        return "PackagedProductDefinition";
2438      if (code == FHIRResourceType.PARAMETERS)
2439        return "Parameters";
2440      if (code == FHIRResourceType.PATIENT)
2441        return "Patient";
2442      if (code == FHIRResourceType.PAYMENTNOTICE)
2443        return "PaymentNotice";
2444      if (code == FHIRResourceType.PAYMENTRECONCILIATION)
2445        return "PaymentReconciliation";
2446      if (code == FHIRResourceType.PERSON)
2447        return "Person";
2448      if (code == FHIRResourceType.PLANDEFINITION)
2449        return "PlanDefinition";
2450      if (code == FHIRResourceType.PRACTITIONER)
2451        return "Practitioner";
2452      if (code == FHIRResourceType.PRACTITIONERROLE)
2453        return "PractitionerRole";
2454      if (code == FHIRResourceType.PROCEDURE)
2455        return "Procedure";
2456      if (code == FHIRResourceType.PROVENANCE)
2457        return "Provenance";
2458      if (code == FHIRResourceType.QUESTIONNAIRE)
2459        return "Questionnaire";
2460      if (code == FHIRResourceType.QUESTIONNAIRERESPONSE)
2461        return "QuestionnaireResponse";
2462      if (code == FHIRResourceType.REGULATEDAUTHORIZATION)
2463        return "RegulatedAuthorization";
2464      if (code == FHIRResourceType.RELATEDPERSON)
2465        return "RelatedPerson";
2466      if (code == FHIRResourceType.REQUESTGROUP)
2467        return "RequestGroup";
2468      if (code == FHIRResourceType.RESEARCHSTUDY)
2469        return "ResearchStudy";
2470      if (code == FHIRResourceType.RESEARCHSUBJECT)
2471        return "ResearchSubject";
2472      if (code == FHIRResourceType.RESOURCE)
2473        return "Resource";
2474      if (code == FHIRResourceType.RISKASSESSMENT)
2475        return "RiskAssessment";
2476      if (code == FHIRResourceType.SCHEDULE)
2477        return "Schedule";
2478      if (code == FHIRResourceType.SEARCHPARAMETER)
2479        return "SearchParameter";
2480      if (code == FHIRResourceType.SERVICEREQUEST)
2481        return "ServiceRequest";
2482      if (code == FHIRResourceType.SLOT)
2483        return "Slot";
2484      if (code == FHIRResourceType.SPECIMEN)
2485        return "Specimen";
2486      if (code == FHIRResourceType.SPECIMENDEFINITION)
2487        return "SpecimenDefinition";
2488      if (code == FHIRResourceType.STRUCTUREDEFINITION)
2489        return "StructureDefinition";
2490      if (code == FHIRResourceType.STRUCTUREMAP)
2491        return "StructureMap";
2492      if (code == FHIRResourceType.SUBSCRIPTION)
2493        return "Subscription";
2494      if (code == FHIRResourceType.SUBSTANCE)
2495        return "Substance";
2496      if (code == FHIRResourceType.SUBSTANCEDEFINITION)
2497        return "SubstanceDefinition";
2498      if (code == FHIRResourceType.SUBSTANCENUCLEICACID)
2499        return "SubstanceNucleicAcid";
2500      if (code == FHIRResourceType.SUBSTANCEPOLYMER)
2501        return "SubstancePolymer";
2502      if (code == FHIRResourceType.SUBSTANCEPROTEIN)
2503        return "SubstanceProtein";
2504      if (code == FHIRResourceType.SUBSTANCEREFERENCEINFORMATION)
2505        return "SubstanceReferenceInformation";
2506      if (code == FHIRResourceType.SUBSTANCESOURCEMATERIAL)
2507        return "SubstanceSourceMaterial";
2508      if (code == FHIRResourceType.SUPPLYDELIVERY)
2509        return "SupplyDelivery";
2510      if (code == FHIRResourceType.SUPPLYREQUEST)
2511        return "SupplyRequest";
2512      if (code == FHIRResourceType.TASK)
2513        return "Task";
2514      if (code == FHIRResourceType.TERMINOLOGYCAPABILITIES)
2515        return "TerminologyCapabilities";
2516      if (code == FHIRResourceType.TESTREPORT)
2517        return "TestReport";
2518      if (code == FHIRResourceType.TESTSCRIPT)
2519        return "TestScript";
2520      if (code == FHIRResourceType.TOPIC)
2521        return "Topic";
2522      if (code == FHIRResourceType.VALUESET)
2523        return "ValueSet";
2524      if (code == FHIRResourceType.VERIFICATIONRESULT)
2525        return "VerificationResult";
2526      if (code == FHIRResourceType.VISIONPRESCRIPTION)
2527        return "VisionPrescription";
2528      return "?";
2529      }
2530    public String toSystem(FHIRResourceType code) {
2531      return code.getSystem();
2532      }
2533    }
2534
2535    @Block()
2536    public static class ExampleScenarioActorComponent extends BackboneElement implements IBaseBackboneElement {
2537        /**
2538         * ID or acronym of actor.
2539         */
2540        @Child(name = "actorId", type = {StringType.class}, order=1, min=1, max=1, modifier=false, summary=false)
2541        @Description(shortDefinition="ID or acronym of the actor", formalDefinition="ID or acronym of actor." )
2542        protected StringType actorId;
2543
2544        /**
2545         * The type of actor - person or system.
2546         */
2547        @Child(name = "type", type = {CodeType.class}, order=2, min=1, max=1, modifier=false, summary=false)
2548        @Description(shortDefinition="person | entity", formalDefinition="The type of actor - person or system." )
2549        @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/examplescenario-actor-type")
2550        protected Enumeration<ExampleScenarioActorType> type;
2551
2552        /**
2553         * The name of the actor as shown in the page.
2554         */
2555        @Child(name = "name", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false)
2556        @Description(shortDefinition="The name of the actor as shown in the page", formalDefinition="The name of the actor as shown in the page." )
2557        protected StringType name;
2558
2559        /**
2560         * The description of the actor.
2561         */
2562        @Child(name = "description", type = {MarkdownType.class}, order=4, min=0, max=1, modifier=false, summary=false)
2563        @Description(shortDefinition="The description of the actor", formalDefinition="The description of the actor." )
2564        protected MarkdownType description;
2565
2566        private static final long serialVersionUID = 1348364162L;
2567
2568    /**
2569     * Constructor
2570     */
2571      public ExampleScenarioActorComponent() {
2572        super();
2573      }
2574
2575    /**
2576     * Constructor
2577     */
2578      public ExampleScenarioActorComponent(StringType actorId, Enumeration<ExampleScenarioActorType> type) {
2579        super();
2580        this.actorId = actorId;
2581        this.type = type;
2582      }
2583
2584        /**
2585         * @return {@link #actorId} (ID or acronym of actor.). This is the underlying object with id, value and extensions. The accessor "getActorId" gives direct access to the value
2586         */
2587        public StringType getActorIdElement() { 
2588          if (this.actorId == null)
2589            if (Configuration.errorOnAutoCreate())
2590              throw new Error("Attempt to auto-create ExampleScenarioActorComponent.actorId");
2591            else if (Configuration.doAutoCreate())
2592              this.actorId = new StringType(); // bb
2593          return this.actorId;
2594        }
2595
2596        public boolean hasActorIdElement() { 
2597          return this.actorId != null && !this.actorId.isEmpty();
2598        }
2599
2600        public boolean hasActorId() { 
2601          return this.actorId != null && !this.actorId.isEmpty();
2602        }
2603
2604        /**
2605         * @param value {@link #actorId} (ID or acronym of actor.). This is the underlying object with id, value and extensions. The accessor "getActorId" gives direct access to the value
2606         */
2607        public ExampleScenarioActorComponent setActorIdElement(StringType value) { 
2608          this.actorId = value;
2609          return this;
2610        }
2611
2612        /**
2613         * @return ID or acronym of actor.
2614         */
2615        public String getActorId() { 
2616          return this.actorId == null ? null : this.actorId.getValue();
2617        }
2618
2619        /**
2620         * @param value ID or acronym of actor.
2621         */
2622        public ExampleScenarioActorComponent setActorId(String value) { 
2623            if (this.actorId == null)
2624              this.actorId = new StringType();
2625            this.actorId.setValue(value);
2626          return this;
2627        }
2628
2629        /**
2630         * @return {@link #type} (The type of actor - person or system.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value
2631         */
2632        public Enumeration<ExampleScenarioActorType> getTypeElement() { 
2633          if (this.type == null)
2634            if (Configuration.errorOnAutoCreate())
2635              throw new Error("Attempt to auto-create ExampleScenarioActorComponent.type");
2636            else if (Configuration.doAutoCreate())
2637              this.type = new Enumeration<ExampleScenarioActorType>(new ExampleScenarioActorTypeEnumFactory()); // bb
2638          return this.type;
2639        }
2640
2641        public boolean hasTypeElement() { 
2642          return this.type != null && !this.type.isEmpty();
2643        }
2644
2645        public boolean hasType() { 
2646          return this.type != null && !this.type.isEmpty();
2647        }
2648
2649        /**
2650         * @param value {@link #type} (The type of actor - person or system.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value
2651         */
2652        public ExampleScenarioActorComponent setTypeElement(Enumeration<ExampleScenarioActorType> value) { 
2653          this.type = value;
2654          return this;
2655        }
2656
2657        /**
2658         * @return The type of actor - person or system.
2659         */
2660        public ExampleScenarioActorType getType() { 
2661          return this.type == null ? null : this.type.getValue();
2662        }
2663
2664        /**
2665         * @param value The type of actor - person or system.
2666         */
2667        public ExampleScenarioActorComponent setType(ExampleScenarioActorType value) { 
2668            if (this.type == null)
2669              this.type = new Enumeration<ExampleScenarioActorType>(new ExampleScenarioActorTypeEnumFactory());
2670            this.type.setValue(value);
2671          return this;
2672        }
2673
2674        /**
2675         * @return {@link #name} (The name of the actor as shown in the page.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value
2676         */
2677        public StringType getNameElement() { 
2678          if (this.name == null)
2679            if (Configuration.errorOnAutoCreate())
2680              throw new Error("Attempt to auto-create ExampleScenarioActorComponent.name");
2681            else if (Configuration.doAutoCreate())
2682              this.name = new StringType(); // bb
2683          return this.name;
2684        }
2685
2686        public boolean hasNameElement() { 
2687          return this.name != null && !this.name.isEmpty();
2688        }
2689
2690        public boolean hasName() { 
2691          return this.name != null && !this.name.isEmpty();
2692        }
2693
2694        /**
2695         * @param value {@link #name} (The name of the actor as shown in the page.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value
2696         */
2697        public ExampleScenarioActorComponent setNameElement(StringType value) { 
2698          this.name = value;
2699          return this;
2700        }
2701
2702        /**
2703         * @return The name of the actor as shown in the page.
2704         */
2705        public String getName() { 
2706          return this.name == null ? null : this.name.getValue();
2707        }
2708
2709        /**
2710         * @param value The name of the actor as shown in the page.
2711         */
2712        public ExampleScenarioActorComponent setName(String value) { 
2713          if (Utilities.noString(value))
2714            this.name = null;
2715          else {
2716            if (this.name == null)
2717              this.name = new StringType();
2718            this.name.setValue(value);
2719          }
2720          return this;
2721        }
2722
2723        /**
2724         * @return {@link #description} (The description of the actor.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
2725         */
2726        public MarkdownType getDescriptionElement() { 
2727          if (this.description == null)
2728            if (Configuration.errorOnAutoCreate())
2729              throw new Error("Attempt to auto-create ExampleScenarioActorComponent.description");
2730            else if (Configuration.doAutoCreate())
2731              this.description = new MarkdownType(); // bb
2732          return this.description;
2733        }
2734
2735        public boolean hasDescriptionElement() { 
2736          return this.description != null && !this.description.isEmpty();
2737        }
2738
2739        public boolean hasDescription() { 
2740          return this.description != null && !this.description.isEmpty();
2741        }
2742
2743        /**
2744         * @param value {@link #description} (The description of the actor.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
2745         */
2746        public ExampleScenarioActorComponent setDescriptionElement(MarkdownType value) { 
2747          this.description = value;
2748          return this;
2749        }
2750
2751        /**
2752         * @return The description of the actor.
2753         */
2754        public String getDescription() { 
2755          return this.description == null ? null : this.description.getValue();
2756        }
2757
2758        /**
2759         * @param value The description of the actor.
2760         */
2761        public ExampleScenarioActorComponent setDescription(String value) { 
2762          if (value == null)
2763            this.description = null;
2764          else {
2765            if (this.description == null)
2766              this.description = new MarkdownType();
2767            this.description.setValue(value);
2768          }
2769          return this;
2770        }
2771
2772        protected void listChildren(List<Property> children) {
2773          super.listChildren(children);
2774          children.add(new Property("actorId", "string", "ID or acronym of actor.", 0, 1, actorId));
2775          children.add(new Property("type", "code", "The type of actor - person or system.", 0, 1, type));
2776          children.add(new Property("name", "string", "The name of the actor as shown in the page.", 0, 1, name));
2777          children.add(new Property("description", "markdown", "The description of the actor.", 0, 1, description));
2778        }
2779
2780        @Override
2781        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
2782          switch (_hash) {
2783          case -1161623056: /*actorId*/  return new Property("actorId", "string", "ID or acronym of actor.", 0, 1, actorId);
2784          case 3575610: /*type*/  return new Property("type", "code", "The type of actor - person or system.", 0, 1, type);
2785          case 3373707: /*name*/  return new Property("name", "string", "The name of the actor as shown in the page.", 0, 1, name);
2786          case -1724546052: /*description*/  return new Property("description", "markdown", "The description of the actor.", 0, 1, description);
2787          default: return super.getNamedProperty(_hash, _name, _checkValid);
2788          }
2789
2790        }
2791
2792      @Override
2793      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
2794        switch (hash) {
2795        case -1161623056: /*actorId*/ return this.actorId == null ? new Base[0] : new Base[] {this.actorId}; // StringType
2796        case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // Enumeration<ExampleScenarioActorType>
2797        case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType
2798        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // MarkdownType
2799        default: return super.getProperty(hash, name, checkValid);
2800        }
2801
2802      }
2803
2804      @Override
2805      public Base setProperty(int hash, String name, Base value) throws FHIRException {
2806        switch (hash) {
2807        case -1161623056: // actorId
2808          this.actorId = castToString(value); // StringType
2809          return value;
2810        case 3575610: // type
2811          value = new ExampleScenarioActorTypeEnumFactory().fromType(castToCode(value));
2812          this.type = (Enumeration) value; // Enumeration<ExampleScenarioActorType>
2813          return value;
2814        case 3373707: // name
2815          this.name = castToString(value); // StringType
2816          return value;
2817        case -1724546052: // description
2818          this.description = castToMarkdown(value); // MarkdownType
2819          return value;
2820        default: return super.setProperty(hash, name, value);
2821        }
2822
2823      }
2824
2825      @Override
2826      public Base setProperty(String name, Base value) throws FHIRException {
2827        if (name.equals("actorId")) {
2828          this.actorId = castToString(value); // StringType
2829        } else if (name.equals("type")) {
2830          value = new ExampleScenarioActorTypeEnumFactory().fromType(castToCode(value));
2831          this.type = (Enumeration) value; // Enumeration<ExampleScenarioActorType>
2832        } else if (name.equals("name")) {
2833          this.name = castToString(value); // StringType
2834        } else if (name.equals("description")) {
2835          this.description = castToMarkdown(value); // MarkdownType
2836        } else
2837          return super.setProperty(name, value);
2838        return value;
2839      }
2840
2841      @Override
2842      public Base makeProperty(int hash, String name) throws FHIRException {
2843        switch (hash) {
2844        case -1161623056:  return getActorIdElement();
2845        case 3575610:  return getTypeElement();
2846        case 3373707:  return getNameElement();
2847        case -1724546052:  return getDescriptionElement();
2848        default: return super.makeProperty(hash, name);
2849        }
2850
2851      }
2852
2853      @Override
2854      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
2855        switch (hash) {
2856        case -1161623056: /*actorId*/ return new String[] {"string"};
2857        case 3575610: /*type*/ return new String[] {"code"};
2858        case 3373707: /*name*/ return new String[] {"string"};
2859        case -1724546052: /*description*/ return new String[] {"markdown"};
2860        default: return super.getTypesForProperty(hash, name);
2861        }
2862
2863      }
2864
2865      @Override
2866      public Base addChild(String name) throws FHIRException {
2867        if (name.equals("actorId")) {
2868          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.actorId");
2869        }
2870        else if (name.equals("type")) {
2871          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.type");
2872        }
2873        else if (name.equals("name")) {
2874          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.name");
2875        }
2876        else if (name.equals("description")) {
2877          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.description");
2878        }
2879        else
2880          return super.addChild(name);
2881      }
2882
2883      public ExampleScenarioActorComponent copy() {
2884        ExampleScenarioActorComponent dst = new ExampleScenarioActorComponent();
2885        copyValues(dst);
2886        return dst;
2887      }
2888
2889      public void copyValues(ExampleScenarioActorComponent dst) {
2890        super.copyValues(dst);
2891        dst.actorId = actorId == null ? null : actorId.copy();
2892        dst.type = type == null ? null : type.copy();
2893        dst.name = name == null ? null : name.copy();
2894        dst.description = description == null ? null : description.copy();
2895      }
2896
2897      @Override
2898      public boolean equalsDeep(Base other_) {
2899        if (!super.equalsDeep(other_))
2900          return false;
2901        if (!(other_ instanceof ExampleScenarioActorComponent))
2902          return false;
2903        ExampleScenarioActorComponent o = (ExampleScenarioActorComponent) other_;
2904        return compareDeep(actorId, o.actorId, true) && compareDeep(type, o.type, true) && compareDeep(name, o.name, true)
2905           && compareDeep(description, o.description, true);
2906      }
2907
2908      @Override
2909      public boolean equalsShallow(Base other_) {
2910        if (!super.equalsShallow(other_))
2911          return false;
2912        if (!(other_ instanceof ExampleScenarioActorComponent))
2913          return false;
2914        ExampleScenarioActorComponent o = (ExampleScenarioActorComponent) other_;
2915        return compareValues(actorId, o.actorId, true) && compareValues(type, o.type, true) && compareValues(name, o.name, true)
2916           && compareValues(description, o.description, true);
2917      }
2918
2919      public boolean isEmpty() {
2920        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(actorId, type, name, description
2921          );
2922      }
2923
2924  public String fhirType() {
2925    return "ExampleScenario.actor";
2926
2927  }
2928
2929  }
2930
2931    @Block()
2932    public static class ExampleScenarioInstanceComponent extends BackboneElement implements IBaseBackboneElement {
2933        /**
2934         * The id of the resource for referencing.
2935         */
2936        @Child(name = "resourceId", type = {StringType.class}, order=1, min=1, max=1, modifier=false, summary=false)
2937        @Description(shortDefinition="The id of the resource for referencing", formalDefinition="The id of the resource for referencing." )
2938        protected StringType resourceId;
2939
2940        /**
2941         * The type of the resource.
2942         */
2943        @Child(name = "resourceType", type = {CodeType.class}, order=2, min=1, max=1, modifier=false, summary=false)
2944        @Description(shortDefinition="The type of the resource", formalDefinition="The type of the resource." )
2945        @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/resource-types")
2946        protected Enumeration<FHIRResourceType> resourceType;
2947
2948        /**
2949         * A short name for the resource instance.
2950         */
2951        @Child(name = "name", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false)
2952        @Description(shortDefinition="A short name for the resource instance", formalDefinition="A short name for the resource instance." )
2953        protected StringType name;
2954
2955        /**
2956         * Human-friendly description of the resource instance.
2957         */
2958        @Child(name = "description", type = {MarkdownType.class}, order=4, min=0, max=1, modifier=false, summary=false)
2959        @Description(shortDefinition="Human-friendly description of the resource instance", formalDefinition="Human-friendly description of the resource instance." )
2960        protected MarkdownType description;
2961
2962        /**
2963         * A specific version of the resource.
2964         */
2965        @Child(name = "version", type = {}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
2966        @Description(shortDefinition="A specific version of the resource", formalDefinition="A specific version of the resource." )
2967        protected List<ExampleScenarioInstanceVersionComponent> version;
2968
2969        /**
2970         * Resources contained in the instance (e.g. the observations contained in a bundle).
2971         */
2972        @Child(name = "containedInstance", type = {}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
2973        @Description(shortDefinition="Resources contained in the instance", formalDefinition="Resources contained in the instance (e.g. the observations contained in a bundle)." )
2974        protected List<ExampleScenarioInstanceContainedInstanceComponent> containedInstance;
2975
2976        private static final long serialVersionUID = -1131860669L;
2977
2978    /**
2979     * Constructor
2980     */
2981      public ExampleScenarioInstanceComponent() {
2982        super();
2983      }
2984
2985    /**
2986     * Constructor
2987     */
2988      public ExampleScenarioInstanceComponent(StringType resourceId, Enumeration<FHIRResourceType> resourceType) {
2989        super();
2990        this.resourceId = resourceId;
2991        this.resourceType = resourceType;
2992      }
2993
2994        /**
2995         * @return {@link #resourceId} (The id of the resource for referencing.). This is the underlying object with id, value and extensions. The accessor "getResourceId" gives direct access to the value
2996         */
2997        public StringType getResourceIdElement() { 
2998          if (this.resourceId == null)
2999            if (Configuration.errorOnAutoCreate())
3000              throw new Error("Attempt to auto-create ExampleScenarioInstanceComponent.resourceId");
3001            else if (Configuration.doAutoCreate())
3002              this.resourceId = new StringType(); // bb
3003          return this.resourceId;
3004        }
3005
3006        public boolean hasResourceIdElement() { 
3007          return this.resourceId != null && !this.resourceId.isEmpty();
3008        }
3009
3010        public boolean hasResourceId() { 
3011          return this.resourceId != null && !this.resourceId.isEmpty();
3012        }
3013
3014        /**
3015         * @param value {@link #resourceId} (The id of the resource for referencing.). This is the underlying object with id, value and extensions. The accessor "getResourceId" gives direct access to the value
3016         */
3017        public ExampleScenarioInstanceComponent setResourceIdElement(StringType value) { 
3018          this.resourceId = value;
3019          return this;
3020        }
3021
3022        /**
3023         * @return The id of the resource for referencing.
3024         */
3025        public String getResourceId() { 
3026          return this.resourceId == null ? null : this.resourceId.getValue();
3027        }
3028
3029        /**
3030         * @param value The id of the resource for referencing.
3031         */
3032        public ExampleScenarioInstanceComponent setResourceId(String value) { 
3033            if (this.resourceId == null)
3034              this.resourceId = new StringType();
3035            this.resourceId.setValue(value);
3036          return this;
3037        }
3038
3039        /**
3040         * @return {@link #resourceType} (The type of the resource.). This is the underlying object with id, value and extensions. The accessor "getResourceType" gives direct access to the value
3041         */
3042        public Enumeration<FHIRResourceType> getResourceTypeElement() { 
3043          if (this.resourceType == null)
3044            if (Configuration.errorOnAutoCreate())
3045              throw new Error("Attempt to auto-create ExampleScenarioInstanceComponent.resourceType");
3046            else if (Configuration.doAutoCreate())
3047              this.resourceType = new Enumeration<FHIRResourceType>(new FHIRResourceTypeEnumFactory()); // bb
3048          return this.resourceType;
3049        }
3050
3051        public boolean hasResourceTypeElement() { 
3052          return this.resourceType != null && !this.resourceType.isEmpty();
3053        }
3054
3055        public boolean hasResourceType() { 
3056          return this.resourceType != null && !this.resourceType.isEmpty();
3057        }
3058
3059        /**
3060         * @param value {@link #resourceType} (The type of the resource.). This is the underlying object with id, value and extensions. The accessor "getResourceType" gives direct access to the value
3061         */
3062        public ExampleScenarioInstanceComponent setResourceTypeElement(Enumeration<FHIRResourceType> value) { 
3063          this.resourceType = value;
3064          return this;
3065        }
3066
3067        /**
3068         * @return The type of the resource.
3069         */
3070        public FHIRResourceType getResourceType() { 
3071          return this.resourceType == null ? null : this.resourceType.getValue();
3072        }
3073
3074        /**
3075         * @param value The type of the resource.
3076         */
3077        public ExampleScenarioInstanceComponent setResourceType(FHIRResourceType value) { 
3078            if (this.resourceType == null)
3079              this.resourceType = new Enumeration<FHIRResourceType>(new FHIRResourceTypeEnumFactory());
3080            this.resourceType.setValue(value);
3081          return this;
3082        }
3083
3084        /**
3085         * @return {@link #name} (A short name for the resource instance.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value
3086         */
3087        public StringType getNameElement() { 
3088          if (this.name == null)
3089            if (Configuration.errorOnAutoCreate())
3090              throw new Error("Attempt to auto-create ExampleScenarioInstanceComponent.name");
3091            else if (Configuration.doAutoCreate())
3092              this.name = new StringType(); // bb
3093          return this.name;
3094        }
3095
3096        public boolean hasNameElement() { 
3097          return this.name != null && !this.name.isEmpty();
3098        }
3099
3100        public boolean hasName() { 
3101          return this.name != null && !this.name.isEmpty();
3102        }
3103
3104        /**
3105         * @param value {@link #name} (A short name for the resource instance.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value
3106         */
3107        public ExampleScenarioInstanceComponent setNameElement(StringType value) { 
3108          this.name = value;
3109          return this;
3110        }
3111
3112        /**
3113         * @return A short name for the resource instance.
3114         */
3115        public String getName() { 
3116          return this.name == null ? null : this.name.getValue();
3117        }
3118
3119        /**
3120         * @param value A short name for the resource instance.
3121         */
3122        public ExampleScenarioInstanceComponent setName(String value) { 
3123          if (Utilities.noString(value))
3124            this.name = null;
3125          else {
3126            if (this.name == null)
3127              this.name = new StringType();
3128            this.name.setValue(value);
3129          }
3130          return this;
3131        }
3132
3133        /**
3134         * @return {@link #description} (Human-friendly description of the resource instance.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
3135         */
3136        public MarkdownType getDescriptionElement() { 
3137          if (this.description == null)
3138            if (Configuration.errorOnAutoCreate())
3139              throw new Error("Attempt to auto-create ExampleScenarioInstanceComponent.description");
3140            else if (Configuration.doAutoCreate())
3141              this.description = new MarkdownType(); // bb
3142          return this.description;
3143        }
3144
3145        public boolean hasDescriptionElement() { 
3146          return this.description != null && !this.description.isEmpty();
3147        }
3148
3149        public boolean hasDescription() { 
3150          return this.description != null && !this.description.isEmpty();
3151        }
3152
3153        /**
3154         * @param value {@link #description} (Human-friendly description of the resource instance.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
3155         */
3156        public ExampleScenarioInstanceComponent setDescriptionElement(MarkdownType value) { 
3157          this.description = value;
3158          return this;
3159        }
3160
3161        /**
3162         * @return Human-friendly description of the resource instance.
3163         */
3164        public String getDescription() { 
3165          return this.description == null ? null : this.description.getValue();
3166        }
3167
3168        /**
3169         * @param value Human-friendly description of the resource instance.
3170         */
3171        public ExampleScenarioInstanceComponent setDescription(String value) { 
3172          if (value == null)
3173            this.description = null;
3174          else {
3175            if (this.description == null)
3176              this.description = new MarkdownType();
3177            this.description.setValue(value);
3178          }
3179          return this;
3180        }
3181
3182        /**
3183         * @return {@link #version} (A specific version of the resource.)
3184         */
3185        public List<ExampleScenarioInstanceVersionComponent> getVersion() { 
3186          if (this.version == null)
3187            this.version = new ArrayList<ExampleScenarioInstanceVersionComponent>();
3188          return this.version;
3189        }
3190
3191        /**
3192         * @return Returns a reference to <code>this</code> for easy method chaining
3193         */
3194        public ExampleScenarioInstanceComponent setVersion(List<ExampleScenarioInstanceVersionComponent> theVersion) { 
3195          this.version = theVersion;
3196          return this;
3197        }
3198
3199        public boolean hasVersion() { 
3200          if (this.version == null)
3201            return false;
3202          for (ExampleScenarioInstanceVersionComponent item : this.version)
3203            if (!item.isEmpty())
3204              return true;
3205          return false;
3206        }
3207
3208        public ExampleScenarioInstanceVersionComponent addVersion() { //3
3209          ExampleScenarioInstanceVersionComponent t = new ExampleScenarioInstanceVersionComponent();
3210          if (this.version == null)
3211            this.version = new ArrayList<ExampleScenarioInstanceVersionComponent>();
3212          this.version.add(t);
3213          return t;
3214        }
3215
3216        public ExampleScenarioInstanceComponent addVersion(ExampleScenarioInstanceVersionComponent t) { //3
3217          if (t == null)
3218            return this;
3219          if (this.version == null)
3220            this.version = new ArrayList<ExampleScenarioInstanceVersionComponent>();
3221          this.version.add(t);
3222          return this;
3223        }
3224
3225        /**
3226         * @return The first repetition of repeating field {@link #version}, creating it if it does not already exist
3227         */
3228        public ExampleScenarioInstanceVersionComponent getVersionFirstRep() { 
3229          if (getVersion().isEmpty()) {
3230            addVersion();
3231          }
3232          return getVersion().get(0);
3233        }
3234
3235        /**
3236         * @return {@link #containedInstance} (Resources contained in the instance (e.g. the observations contained in a bundle).)
3237         */
3238        public List<ExampleScenarioInstanceContainedInstanceComponent> getContainedInstance() { 
3239          if (this.containedInstance == null)
3240            this.containedInstance = new ArrayList<ExampleScenarioInstanceContainedInstanceComponent>();
3241          return this.containedInstance;
3242        }
3243
3244        /**
3245         * @return Returns a reference to <code>this</code> for easy method chaining
3246         */
3247        public ExampleScenarioInstanceComponent setContainedInstance(List<ExampleScenarioInstanceContainedInstanceComponent> theContainedInstance) { 
3248          this.containedInstance = theContainedInstance;
3249          return this;
3250        }
3251
3252        public boolean hasContainedInstance() { 
3253          if (this.containedInstance == null)
3254            return false;
3255          for (ExampleScenarioInstanceContainedInstanceComponent item : this.containedInstance)
3256            if (!item.isEmpty())
3257              return true;
3258          return false;
3259        }
3260
3261        public ExampleScenarioInstanceContainedInstanceComponent addContainedInstance() { //3
3262          ExampleScenarioInstanceContainedInstanceComponent t = new ExampleScenarioInstanceContainedInstanceComponent();
3263          if (this.containedInstance == null)
3264            this.containedInstance = new ArrayList<ExampleScenarioInstanceContainedInstanceComponent>();
3265          this.containedInstance.add(t);
3266          return t;
3267        }
3268
3269        public ExampleScenarioInstanceComponent addContainedInstance(ExampleScenarioInstanceContainedInstanceComponent t) { //3
3270          if (t == null)
3271            return this;
3272          if (this.containedInstance == null)
3273            this.containedInstance = new ArrayList<ExampleScenarioInstanceContainedInstanceComponent>();
3274          this.containedInstance.add(t);
3275          return this;
3276        }
3277
3278        /**
3279         * @return The first repetition of repeating field {@link #containedInstance}, creating it if it does not already exist
3280         */
3281        public ExampleScenarioInstanceContainedInstanceComponent getContainedInstanceFirstRep() { 
3282          if (getContainedInstance().isEmpty()) {
3283            addContainedInstance();
3284          }
3285          return getContainedInstance().get(0);
3286        }
3287
3288        protected void listChildren(List<Property> children) {
3289          super.listChildren(children);
3290          children.add(new Property("resourceId", "string", "The id of the resource for referencing.", 0, 1, resourceId));
3291          children.add(new Property("resourceType", "code", "The type of the resource.", 0, 1, resourceType));
3292          children.add(new Property("name", "string", "A short name for the resource instance.", 0, 1, name));
3293          children.add(new Property("description", "markdown", "Human-friendly description of the resource instance.", 0, 1, description));
3294          children.add(new Property("version", "", "A specific version of the resource.", 0, java.lang.Integer.MAX_VALUE, version));
3295          children.add(new Property("containedInstance", "", "Resources contained in the instance (e.g. the observations contained in a bundle).", 0, java.lang.Integer.MAX_VALUE, containedInstance));
3296        }
3297
3298        @Override
3299        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
3300          switch (_hash) {
3301          case -1345650231: /*resourceId*/  return new Property("resourceId", "string", "The id of the resource for referencing.", 0, 1, resourceId);
3302          case -384364440: /*resourceType*/  return new Property("resourceType", "code", "The type of the resource.", 0, 1, resourceType);
3303          case 3373707: /*name*/  return new Property("name", "string", "A short name for the resource instance.", 0, 1, name);
3304          case -1724546052: /*description*/  return new Property("description", "markdown", "Human-friendly description of the resource instance.", 0, 1, description);
3305          case 351608024: /*version*/  return new Property("version", "", "A specific version of the resource.", 0, java.lang.Integer.MAX_VALUE, version);
3306          case -417062360: /*containedInstance*/  return new Property("containedInstance", "", "Resources contained in the instance (e.g. the observations contained in a bundle).", 0, java.lang.Integer.MAX_VALUE, containedInstance);
3307          default: return super.getNamedProperty(_hash, _name, _checkValid);
3308          }
3309
3310        }
3311
3312      @Override
3313      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
3314        switch (hash) {
3315        case -1345650231: /*resourceId*/ return this.resourceId == null ? new Base[0] : new Base[] {this.resourceId}; // StringType
3316        case -384364440: /*resourceType*/ return this.resourceType == null ? new Base[0] : new Base[] {this.resourceType}; // Enumeration<FHIRResourceType>
3317        case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType
3318        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // MarkdownType
3319        case 351608024: /*version*/ return this.version == null ? new Base[0] : this.version.toArray(new Base[this.version.size()]); // ExampleScenarioInstanceVersionComponent
3320        case -417062360: /*containedInstance*/ return this.containedInstance == null ? new Base[0] : this.containedInstance.toArray(new Base[this.containedInstance.size()]); // ExampleScenarioInstanceContainedInstanceComponent
3321        default: return super.getProperty(hash, name, checkValid);
3322        }
3323
3324      }
3325
3326      @Override
3327      public Base setProperty(int hash, String name, Base value) throws FHIRException {
3328        switch (hash) {
3329        case -1345650231: // resourceId
3330          this.resourceId = castToString(value); // StringType
3331          return value;
3332        case -384364440: // resourceType
3333          value = new FHIRResourceTypeEnumFactory().fromType(castToCode(value));
3334          this.resourceType = (Enumeration) value; // Enumeration<FHIRResourceType>
3335          return value;
3336        case 3373707: // name
3337          this.name = castToString(value); // StringType
3338          return value;
3339        case -1724546052: // description
3340          this.description = castToMarkdown(value); // MarkdownType
3341          return value;
3342        case 351608024: // version
3343          this.getVersion().add((ExampleScenarioInstanceVersionComponent) value); // ExampleScenarioInstanceVersionComponent
3344          return value;
3345        case -417062360: // containedInstance
3346          this.getContainedInstance().add((ExampleScenarioInstanceContainedInstanceComponent) value); // ExampleScenarioInstanceContainedInstanceComponent
3347          return value;
3348        default: return super.setProperty(hash, name, value);
3349        }
3350
3351      }
3352
3353      @Override
3354      public Base setProperty(String name, Base value) throws FHIRException {
3355        if (name.equals("resourceId")) {
3356          this.resourceId = castToString(value); // StringType
3357        } else if (name.equals("resourceType")) {
3358          value = new FHIRResourceTypeEnumFactory().fromType(castToCode(value));
3359          this.resourceType = (Enumeration) value; // Enumeration<FHIRResourceType>
3360        } else if (name.equals("name")) {
3361          this.name = castToString(value); // StringType
3362        } else if (name.equals("description")) {
3363          this.description = castToMarkdown(value); // MarkdownType
3364        } else if (name.equals("version")) {
3365          this.getVersion().add((ExampleScenarioInstanceVersionComponent) value);
3366        } else if (name.equals("containedInstance")) {
3367          this.getContainedInstance().add((ExampleScenarioInstanceContainedInstanceComponent) value);
3368        } else
3369          return super.setProperty(name, value);
3370        return value;
3371      }
3372
3373      @Override
3374      public Base makeProperty(int hash, String name) throws FHIRException {
3375        switch (hash) {
3376        case -1345650231:  return getResourceIdElement();
3377        case -384364440:  return getResourceTypeElement();
3378        case 3373707:  return getNameElement();
3379        case -1724546052:  return getDescriptionElement();
3380        case 351608024:  return addVersion(); 
3381        case -417062360:  return addContainedInstance(); 
3382        default: return super.makeProperty(hash, name);
3383        }
3384
3385      }
3386
3387      @Override
3388      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
3389        switch (hash) {
3390        case -1345650231: /*resourceId*/ return new String[] {"string"};
3391        case -384364440: /*resourceType*/ return new String[] {"code"};
3392        case 3373707: /*name*/ return new String[] {"string"};
3393        case -1724546052: /*description*/ return new String[] {"markdown"};
3394        case 351608024: /*version*/ return new String[] {};
3395        case -417062360: /*containedInstance*/ return new String[] {};
3396        default: return super.getTypesForProperty(hash, name);
3397        }
3398
3399      }
3400
3401      @Override
3402      public Base addChild(String name) throws FHIRException {
3403        if (name.equals("resourceId")) {
3404          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.resourceId");
3405        }
3406        else if (name.equals("resourceType")) {
3407          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.resourceType");
3408        }
3409        else if (name.equals("name")) {
3410          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.name");
3411        }
3412        else if (name.equals("description")) {
3413          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.description");
3414        }
3415        else if (name.equals("version")) {
3416          return addVersion();
3417        }
3418        else if (name.equals("containedInstance")) {
3419          return addContainedInstance();
3420        }
3421        else
3422          return super.addChild(name);
3423      }
3424
3425      public ExampleScenarioInstanceComponent copy() {
3426        ExampleScenarioInstanceComponent dst = new ExampleScenarioInstanceComponent();
3427        copyValues(dst);
3428        return dst;
3429      }
3430
3431      public void copyValues(ExampleScenarioInstanceComponent dst) {
3432        super.copyValues(dst);
3433        dst.resourceId = resourceId == null ? null : resourceId.copy();
3434        dst.resourceType = resourceType == null ? null : resourceType.copy();
3435        dst.name = name == null ? null : name.copy();
3436        dst.description = description == null ? null : description.copy();
3437        if (version != null) {
3438          dst.version = new ArrayList<ExampleScenarioInstanceVersionComponent>();
3439          for (ExampleScenarioInstanceVersionComponent i : version)
3440            dst.version.add(i.copy());
3441        };
3442        if (containedInstance != null) {
3443          dst.containedInstance = new ArrayList<ExampleScenarioInstanceContainedInstanceComponent>();
3444          for (ExampleScenarioInstanceContainedInstanceComponent i : containedInstance)
3445            dst.containedInstance.add(i.copy());
3446        };
3447      }
3448
3449      @Override
3450      public boolean equalsDeep(Base other_) {
3451        if (!super.equalsDeep(other_))
3452          return false;
3453        if (!(other_ instanceof ExampleScenarioInstanceComponent))
3454          return false;
3455        ExampleScenarioInstanceComponent o = (ExampleScenarioInstanceComponent) other_;
3456        return compareDeep(resourceId, o.resourceId, true) && compareDeep(resourceType, o.resourceType, true)
3457           && compareDeep(name, o.name, true) && compareDeep(description, o.description, true) && compareDeep(version, o.version, true)
3458           && compareDeep(containedInstance, o.containedInstance, true);
3459      }
3460
3461      @Override
3462      public boolean equalsShallow(Base other_) {
3463        if (!super.equalsShallow(other_))
3464          return false;
3465        if (!(other_ instanceof ExampleScenarioInstanceComponent))
3466          return false;
3467        ExampleScenarioInstanceComponent o = (ExampleScenarioInstanceComponent) other_;
3468        return compareValues(resourceId, o.resourceId, true) && compareValues(resourceType, o.resourceType, true)
3469           && compareValues(name, o.name, true) && compareValues(description, o.description, true);
3470      }
3471
3472      public boolean isEmpty() {
3473        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(resourceId, resourceType, name
3474          , description, version, containedInstance);
3475      }
3476
3477  public String fhirType() {
3478    return "ExampleScenario.instance";
3479
3480  }
3481
3482  }
3483
3484    @Block()
3485    public static class ExampleScenarioInstanceVersionComponent extends BackboneElement implements IBaseBackboneElement {
3486        /**
3487         * The identifier of a specific version of a resource.
3488         */
3489        @Child(name = "versionId", type = {StringType.class}, order=1, min=1, max=1, modifier=false, summary=false)
3490        @Description(shortDefinition="The identifier of a specific version of a resource", formalDefinition="The identifier of a specific version of a resource." )
3491        protected StringType versionId;
3492
3493        /**
3494         * The description of the resource version.
3495         */
3496        @Child(name = "description", type = {MarkdownType.class}, order=2, min=1, max=1, modifier=false, summary=false)
3497        @Description(shortDefinition="The description of the resource version", formalDefinition="The description of the resource version." )
3498        protected MarkdownType description;
3499
3500        private static final long serialVersionUID = 960821913L;
3501
3502    /**
3503     * Constructor
3504     */
3505      public ExampleScenarioInstanceVersionComponent() {
3506        super();
3507      }
3508
3509    /**
3510     * Constructor
3511     */
3512      public ExampleScenarioInstanceVersionComponent(StringType versionId, MarkdownType description) {
3513        super();
3514        this.versionId = versionId;
3515        this.description = description;
3516      }
3517
3518        /**
3519         * @return {@link #versionId} (The identifier of a specific version of a resource.). This is the underlying object with id, value and extensions. The accessor "getVersionId" gives direct access to the value
3520         */
3521        public StringType getVersionIdElement() { 
3522          if (this.versionId == null)
3523            if (Configuration.errorOnAutoCreate())
3524              throw new Error("Attempt to auto-create ExampleScenarioInstanceVersionComponent.versionId");
3525            else if (Configuration.doAutoCreate())
3526              this.versionId = new StringType(); // bb
3527          return this.versionId;
3528        }
3529
3530        public boolean hasVersionIdElement() { 
3531          return this.versionId != null && !this.versionId.isEmpty();
3532        }
3533
3534        public boolean hasVersionId() { 
3535          return this.versionId != null && !this.versionId.isEmpty();
3536        }
3537
3538        /**
3539         * @param value {@link #versionId} (The identifier of a specific version of a resource.). This is the underlying object with id, value and extensions. The accessor "getVersionId" gives direct access to the value
3540         */
3541        public ExampleScenarioInstanceVersionComponent setVersionIdElement(StringType value) { 
3542          this.versionId = value;
3543          return this;
3544        }
3545
3546        /**
3547         * @return The identifier of a specific version of a resource.
3548         */
3549        public String getVersionId() { 
3550          return this.versionId == null ? null : this.versionId.getValue();
3551        }
3552
3553        /**
3554         * @param value The identifier of a specific version of a resource.
3555         */
3556        public ExampleScenarioInstanceVersionComponent setVersionId(String value) { 
3557            if (this.versionId == null)
3558              this.versionId = new StringType();
3559            this.versionId.setValue(value);
3560          return this;
3561        }
3562
3563        /**
3564         * @return {@link #description} (The description of the resource version.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
3565         */
3566        public MarkdownType getDescriptionElement() { 
3567          if (this.description == null)
3568            if (Configuration.errorOnAutoCreate())
3569              throw new Error("Attempt to auto-create ExampleScenarioInstanceVersionComponent.description");
3570            else if (Configuration.doAutoCreate())
3571              this.description = new MarkdownType(); // bb
3572          return this.description;
3573        }
3574
3575        public boolean hasDescriptionElement() { 
3576          return this.description != null && !this.description.isEmpty();
3577        }
3578
3579        public boolean hasDescription() { 
3580          return this.description != null && !this.description.isEmpty();
3581        }
3582
3583        /**
3584         * @param value {@link #description} (The description of the resource version.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
3585         */
3586        public ExampleScenarioInstanceVersionComponent setDescriptionElement(MarkdownType value) { 
3587          this.description = value;
3588          return this;
3589        }
3590
3591        /**
3592         * @return The description of the resource version.
3593         */
3594        public String getDescription() { 
3595          return this.description == null ? null : this.description.getValue();
3596        }
3597
3598        /**
3599         * @param value The description of the resource version.
3600         */
3601        public ExampleScenarioInstanceVersionComponent setDescription(String value) { 
3602            if (this.description == null)
3603              this.description = new MarkdownType();
3604            this.description.setValue(value);
3605          return this;
3606        }
3607
3608        protected void listChildren(List<Property> children) {
3609          super.listChildren(children);
3610          children.add(new Property("versionId", "string", "The identifier of a specific version of a resource.", 0, 1, versionId));
3611          children.add(new Property("description", "markdown", "The description of the resource version.", 0, 1, description));
3612        }
3613
3614        @Override
3615        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
3616          switch (_hash) {
3617          case -1407102957: /*versionId*/  return new Property("versionId", "string", "The identifier of a specific version of a resource.", 0, 1, versionId);
3618          case -1724546052: /*description*/  return new Property("description", "markdown", "The description of the resource version.", 0, 1, description);
3619          default: return super.getNamedProperty(_hash, _name, _checkValid);
3620          }
3621
3622        }
3623
3624      @Override
3625      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
3626        switch (hash) {
3627        case -1407102957: /*versionId*/ return this.versionId == null ? new Base[0] : new Base[] {this.versionId}; // StringType
3628        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // MarkdownType
3629        default: return super.getProperty(hash, name, checkValid);
3630        }
3631
3632      }
3633
3634      @Override
3635      public Base setProperty(int hash, String name, Base value) throws FHIRException {
3636        switch (hash) {
3637        case -1407102957: // versionId
3638          this.versionId = castToString(value); // StringType
3639          return value;
3640        case -1724546052: // description
3641          this.description = castToMarkdown(value); // MarkdownType
3642          return value;
3643        default: return super.setProperty(hash, name, value);
3644        }
3645
3646      }
3647
3648      @Override
3649      public Base setProperty(String name, Base value) throws FHIRException {
3650        if (name.equals("versionId")) {
3651          this.versionId = castToString(value); // StringType
3652        } else if (name.equals("description")) {
3653          this.description = castToMarkdown(value); // MarkdownType
3654        } else
3655          return super.setProperty(name, value);
3656        return value;
3657      }
3658
3659      @Override
3660      public Base makeProperty(int hash, String name) throws FHIRException {
3661        switch (hash) {
3662        case -1407102957:  return getVersionIdElement();
3663        case -1724546052:  return getDescriptionElement();
3664        default: return super.makeProperty(hash, name);
3665        }
3666
3667      }
3668
3669      @Override
3670      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
3671        switch (hash) {
3672        case -1407102957: /*versionId*/ return new String[] {"string"};
3673        case -1724546052: /*description*/ return new String[] {"markdown"};
3674        default: return super.getTypesForProperty(hash, name);
3675        }
3676
3677      }
3678
3679      @Override
3680      public Base addChild(String name) throws FHIRException {
3681        if (name.equals("versionId")) {
3682          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.versionId");
3683        }
3684        else if (name.equals("description")) {
3685          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.description");
3686        }
3687        else
3688          return super.addChild(name);
3689      }
3690
3691      public ExampleScenarioInstanceVersionComponent copy() {
3692        ExampleScenarioInstanceVersionComponent dst = new ExampleScenarioInstanceVersionComponent();
3693        copyValues(dst);
3694        return dst;
3695      }
3696
3697      public void copyValues(ExampleScenarioInstanceVersionComponent dst) {
3698        super.copyValues(dst);
3699        dst.versionId = versionId == null ? null : versionId.copy();
3700        dst.description = description == null ? null : description.copy();
3701      }
3702
3703      @Override
3704      public boolean equalsDeep(Base other_) {
3705        if (!super.equalsDeep(other_))
3706          return false;
3707        if (!(other_ instanceof ExampleScenarioInstanceVersionComponent))
3708          return false;
3709        ExampleScenarioInstanceVersionComponent o = (ExampleScenarioInstanceVersionComponent) other_;
3710        return compareDeep(versionId, o.versionId, true) && compareDeep(description, o.description, true)
3711          ;
3712      }
3713
3714      @Override
3715      public boolean equalsShallow(Base other_) {
3716        if (!super.equalsShallow(other_))
3717          return false;
3718        if (!(other_ instanceof ExampleScenarioInstanceVersionComponent))
3719          return false;
3720        ExampleScenarioInstanceVersionComponent o = (ExampleScenarioInstanceVersionComponent) other_;
3721        return compareValues(versionId, o.versionId, true) && compareValues(description, o.description, true)
3722          ;
3723      }
3724
3725      public boolean isEmpty() {
3726        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(versionId, description);
3727      }
3728
3729  public String fhirType() {
3730    return "ExampleScenario.instance.version";
3731
3732  }
3733
3734  }
3735
3736    @Block()
3737    public static class ExampleScenarioInstanceContainedInstanceComponent extends BackboneElement implements IBaseBackboneElement {
3738        /**
3739         * Each resource contained in the instance.
3740         */
3741        @Child(name = "resourceId", type = {StringType.class}, order=1, min=1, max=1, modifier=false, summary=false)
3742        @Description(shortDefinition="Each resource contained in the instance", formalDefinition="Each resource contained in the instance." )
3743        protected StringType resourceId;
3744
3745        /**
3746         * A specific version of a resource contained in the instance.
3747         */
3748        @Child(name = "versionId", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false)
3749        @Description(shortDefinition="A specific version of a resource contained in the instance", formalDefinition="A specific version of a resource contained in the instance." )
3750        protected StringType versionId;
3751
3752        private static final long serialVersionUID = 908084124L;
3753
3754    /**
3755     * Constructor
3756     */
3757      public ExampleScenarioInstanceContainedInstanceComponent() {
3758        super();
3759      }
3760
3761    /**
3762     * Constructor
3763     */
3764      public ExampleScenarioInstanceContainedInstanceComponent(StringType resourceId) {
3765        super();
3766        this.resourceId = resourceId;
3767      }
3768
3769        /**
3770         * @return {@link #resourceId} (Each resource contained in the instance.). This is the underlying object with id, value and extensions. The accessor "getResourceId" gives direct access to the value
3771         */
3772        public StringType getResourceIdElement() { 
3773          if (this.resourceId == null)
3774            if (Configuration.errorOnAutoCreate())
3775              throw new Error("Attempt to auto-create ExampleScenarioInstanceContainedInstanceComponent.resourceId");
3776            else if (Configuration.doAutoCreate())
3777              this.resourceId = new StringType(); // bb
3778          return this.resourceId;
3779        }
3780
3781        public boolean hasResourceIdElement() { 
3782          return this.resourceId != null && !this.resourceId.isEmpty();
3783        }
3784
3785        public boolean hasResourceId() { 
3786          return this.resourceId != null && !this.resourceId.isEmpty();
3787        }
3788
3789        /**
3790         * @param value {@link #resourceId} (Each resource contained in the instance.). This is the underlying object with id, value and extensions. The accessor "getResourceId" gives direct access to the value
3791         */
3792        public ExampleScenarioInstanceContainedInstanceComponent setResourceIdElement(StringType value) { 
3793          this.resourceId = value;
3794          return this;
3795        }
3796
3797        /**
3798         * @return Each resource contained in the instance.
3799         */
3800        public String getResourceId() { 
3801          return this.resourceId == null ? null : this.resourceId.getValue();
3802        }
3803
3804        /**
3805         * @param value Each resource contained in the instance.
3806         */
3807        public ExampleScenarioInstanceContainedInstanceComponent setResourceId(String value) { 
3808            if (this.resourceId == null)
3809              this.resourceId = new StringType();
3810            this.resourceId.setValue(value);
3811          return this;
3812        }
3813
3814        /**
3815         * @return {@link #versionId} (A specific version of a resource contained in the instance.). This is the underlying object with id, value and extensions. The accessor "getVersionId" gives direct access to the value
3816         */
3817        public StringType getVersionIdElement() { 
3818          if (this.versionId == null)
3819            if (Configuration.errorOnAutoCreate())
3820              throw new Error("Attempt to auto-create ExampleScenarioInstanceContainedInstanceComponent.versionId");
3821            else if (Configuration.doAutoCreate())
3822              this.versionId = new StringType(); // bb
3823          return this.versionId;
3824        }
3825
3826        public boolean hasVersionIdElement() { 
3827          return this.versionId != null && !this.versionId.isEmpty();
3828        }
3829
3830        public boolean hasVersionId() { 
3831          return this.versionId != null && !this.versionId.isEmpty();
3832        }
3833
3834        /**
3835         * @param value {@link #versionId} (A specific version of a resource contained in the instance.). This is the underlying object with id, value and extensions. The accessor "getVersionId" gives direct access to the value
3836         */
3837        public ExampleScenarioInstanceContainedInstanceComponent setVersionIdElement(StringType value) { 
3838          this.versionId = value;
3839          return this;
3840        }
3841
3842        /**
3843         * @return A specific version of a resource contained in the instance.
3844         */
3845        public String getVersionId() { 
3846          return this.versionId == null ? null : this.versionId.getValue();
3847        }
3848
3849        /**
3850         * @param value A specific version of a resource contained in the instance.
3851         */
3852        public ExampleScenarioInstanceContainedInstanceComponent setVersionId(String value) { 
3853          if (Utilities.noString(value))
3854            this.versionId = null;
3855          else {
3856            if (this.versionId == null)
3857              this.versionId = new StringType();
3858            this.versionId.setValue(value);
3859          }
3860          return this;
3861        }
3862
3863        protected void listChildren(List<Property> children) {
3864          super.listChildren(children);
3865          children.add(new Property("resourceId", "string", "Each resource contained in the instance.", 0, 1, resourceId));
3866          children.add(new Property("versionId", "string", "A specific version of a resource contained in the instance.", 0, 1, versionId));
3867        }
3868
3869        @Override
3870        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
3871          switch (_hash) {
3872          case -1345650231: /*resourceId*/  return new Property("resourceId", "string", "Each resource contained in the instance.", 0, 1, resourceId);
3873          case -1407102957: /*versionId*/  return new Property("versionId", "string", "A specific version of a resource contained in the instance.", 0, 1, versionId);
3874          default: return super.getNamedProperty(_hash, _name, _checkValid);
3875          }
3876
3877        }
3878
3879      @Override
3880      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
3881        switch (hash) {
3882        case -1345650231: /*resourceId*/ return this.resourceId == null ? new Base[0] : new Base[] {this.resourceId}; // StringType
3883        case -1407102957: /*versionId*/ return this.versionId == null ? new Base[0] : new Base[] {this.versionId}; // StringType
3884        default: return super.getProperty(hash, name, checkValid);
3885        }
3886
3887      }
3888
3889      @Override
3890      public Base setProperty(int hash, String name, Base value) throws FHIRException {
3891        switch (hash) {
3892        case -1345650231: // resourceId
3893          this.resourceId = castToString(value); // StringType
3894          return value;
3895        case -1407102957: // versionId
3896          this.versionId = castToString(value); // StringType
3897          return value;
3898        default: return super.setProperty(hash, name, value);
3899        }
3900
3901      }
3902
3903      @Override
3904      public Base setProperty(String name, Base value) throws FHIRException {
3905        if (name.equals("resourceId")) {
3906          this.resourceId = castToString(value); // StringType
3907        } else if (name.equals("versionId")) {
3908          this.versionId = castToString(value); // StringType
3909        } else
3910          return super.setProperty(name, value);
3911        return value;
3912      }
3913
3914      @Override
3915      public Base makeProperty(int hash, String name) throws FHIRException {
3916        switch (hash) {
3917        case -1345650231:  return getResourceIdElement();
3918        case -1407102957:  return getVersionIdElement();
3919        default: return super.makeProperty(hash, name);
3920        }
3921
3922      }
3923
3924      @Override
3925      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
3926        switch (hash) {
3927        case -1345650231: /*resourceId*/ return new String[] {"string"};
3928        case -1407102957: /*versionId*/ return new String[] {"string"};
3929        default: return super.getTypesForProperty(hash, name);
3930        }
3931
3932      }
3933
3934      @Override
3935      public Base addChild(String name) throws FHIRException {
3936        if (name.equals("resourceId")) {
3937          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.resourceId");
3938        }
3939        else if (name.equals("versionId")) {
3940          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.versionId");
3941        }
3942        else
3943          return super.addChild(name);
3944      }
3945
3946      public ExampleScenarioInstanceContainedInstanceComponent copy() {
3947        ExampleScenarioInstanceContainedInstanceComponent dst = new ExampleScenarioInstanceContainedInstanceComponent();
3948        copyValues(dst);
3949        return dst;
3950      }
3951
3952      public void copyValues(ExampleScenarioInstanceContainedInstanceComponent dst) {
3953        super.copyValues(dst);
3954        dst.resourceId = resourceId == null ? null : resourceId.copy();
3955        dst.versionId = versionId == null ? null : versionId.copy();
3956      }
3957
3958      @Override
3959      public boolean equalsDeep(Base other_) {
3960        if (!super.equalsDeep(other_))
3961          return false;
3962        if (!(other_ instanceof ExampleScenarioInstanceContainedInstanceComponent))
3963          return false;
3964        ExampleScenarioInstanceContainedInstanceComponent o = (ExampleScenarioInstanceContainedInstanceComponent) other_;
3965        return compareDeep(resourceId, o.resourceId, true) && compareDeep(versionId, o.versionId, true)
3966          ;
3967      }
3968
3969      @Override
3970      public boolean equalsShallow(Base other_) {
3971        if (!super.equalsShallow(other_))
3972          return false;
3973        if (!(other_ instanceof ExampleScenarioInstanceContainedInstanceComponent))
3974          return false;
3975        ExampleScenarioInstanceContainedInstanceComponent o = (ExampleScenarioInstanceContainedInstanceComponent) other_;
3976        return compareValues(resourceId, o.resourceId, true) && compareValues(versionId, o.versionId, true)
3977          ;
3978      }
3979
3980      public boolean isEmpty() {
3981        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(resourceId, versionId);
3982      }
3983
3984  public String fhirType() {
3985    return "ExampleScenario.instance.containedInstance";
3986
3987  }
3988
3989  }
3990
3991    @Block()
3992    public static class ExampleScenarioProcessComponent extends BackboneElement implements IBaseBackboneElement {
3993        /**
3994         * The diagram title of the group of operations.
3995         */
3996        @Child(name = "title", type = {StringType.class}, order=1, min=1, max=1, modifier=false, summary=true)
3997        @Description(shortDefinition="The diagram title of the group of operations", formalDefinition="The diagram title of the group of operations." )
3998        protected StringType title;
3999
4000        /**
4001         * A longer description of the group of operations.
4002         */
4003        @Child(name = "description", type = {MarkdownType.class}, order=2, min=0, max=1, modifier=false, summary=false)
4004        @Description(shortDefinition="A longer description of the group of operations", formalDefinition="A longer description of the group of operations." )
4005        protected MarkdownType description;
4006
4007        /**
4008         * Description of initial status before the process starts.
4009         */
4010        @Child(name = "preConditions", type = {MarkdownType.class}, order=3, min=0, max=1, modifier=false, summary=false)
4011        @Description(shortDefinition="Description of initial status before the process starts", formalDefinition="Description of initial status before the process starts." )
4012        protected MarkdownType preConditions;
4013
4014        /**
4015         * Description of final status after the process ends.
4016         */
4017        @Child(name = "postConditions", type = {MarkdownType.class}, order=4, min=0, max=1, modifier=false, summary=false)
4018        @Description(shortDefinition="Description of final status after the process ends", formalDefinition="Description of final status after the process ends." )
4019        protected MarkdownType postConditions;
4020
4021        /**
4022         * Each step of the process.
4023         */
4024        @Child(name = "step", type = {}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
4025        @Description(shortDefinition="Each step of the process", formalDefinition="Each step of the process." )
4026        protected List<ExampleScenarioProcessStepComponent> step;
4027
4028        private static final long serialVersionUID = 325578043L;
4029
4030    /**
4031     * Constructor
4032     */
4033      public ExampleScenarioProcessComponent() {
4034        super();
4035      }
4036
4037    /**
4038     * Constructor
4039     */
4040      public ExampleScenarioProcessComponent(StringType title) {
4041        super();
4042        this.title = title;
4043      }
4044
4045        /**
4046         * @return {@link #title} (The diagram title of the group of operations.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value
4047         */
4048        public StringType getTitleElement() { 
4049          if (this.title == null)
4050            if (Configuration.errorOnAutoCreate())
4051              throw new Error("Attempt to auto-create ExampleScenarioProcessComponent.title");
4052            else if (Configuration.doAutoCreate())
4053              this.title = new StringType(); // bb
4054          return this.title;
4055        }
4056
4057        public boolean hasTitleElement() { 
4058          return this.title != null && !this.title.isEmpty();
4059        }
4060
4061        public boolean hasTitle() { 
4062          return this.title != null && !this.title.isEmpty();
4063        }
4064
4065        /**
4066         * @param value {@link #title} (The diagram title of the group of operations.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value
4067         */
4068        public ExampleScenarioProcessComponent setTitleElement(StringType value) { 
4069          this.title = value;
4070          return this;
4071        }
4072
4073        /**
4074         * @return The diagram title of the group of operations.
4075         */
4076        public String getTitle() { 
4077          return this.title == null ? null : this.title.getValue();
4078        }
4079
4080        /**
4081         * @param value The diagram title of the group of operations.
4082         */
4083        public ExampleScenarioProcessComponent setTitle(String value) { 
4084            if (this.title == null)
4085              this.title = new StringType();
4086            this.title.setValue(value);
4087          return this;
4088        }
4089
4090        /**
4091         * @return {@link #description} (A longer description of the group of operations.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
4092         */
4093        public MarkdownType getDescriptionElement() { 
4094          if (this.description == null)
4095            if (Configuration.errorOnAutoCreate())
4096              throw new Error("Attempt to auto-create ExampleScenarioProcessComponent.description");
4097            else if (Configuration.doAutoCreate())
4098              this.description = new MarkdownType(); // bb
4099          return this.description;
4100        }
4101
4102        public boolean hasDescriptionElement() { 
4103          return this.description != null && !this.description.isEmpty();
4104        }
4105
4106        public boolean hasDescription() { 
4107          return this.description != null && !this.description.isEmpty();
4108        }
4109
4110        /**
4111         * @param value {@link #description} (A longer description of the group of operations.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
4112         */
4113        public ExampleScenarioProcessComponent setDescriptionElement(MarkdownType value) { 
4114          this.description = value;
4115          return this;
4116        }
4117
4118        /**
4119         * @return A longer description of the group of operations.
4120         */
4121        public String getDescription() { 
4122          return this.description == null ? null : this.description.getValue();
4123        }
4124
4125        /**
4126         * @param value A longer description of the group of operations.
4127         */
4128        public ExampleScenarioProcessComponent setDescription(String value) { 
4129          if (value == null)
4130            this.description = null;
4131          else {
4132            if (this.description == null)
4133              this.description = new MarkdownType();
4134            this.description.setValue(value);
4135          }
4136          return this;
4137        }
4138
4139        /**
4140         * @return {@link #preConditions} (Description of initial status before the process starts.). This is the underlying object with id, value and extensions. The accessor "getPreConditions" gives direct access to the value
4141         */
4142        public MarkdownType getPreConditionsElement() { 
4143          if (this.preConditions == null)
4144            if (Configuration.errorOnAutoCreate())
4145              throw new Error("Attempt to auto-create ExampleScenarioProcessComponent.preConditions");
4146            else if (Configuration.doAutoCreate())
4147              this.preConditions = new MarkdownType(); // bb
4148          return this.preConditions;
4149        }
4150
4151        public boolean hasPreConditionsElement() { 
4152          return this.preConditions != null && !this.preConditions.isEmpty();
4153        }
4154
4155        public boolean hasPreConditions() { 
4156          return this.preConditions != null && !this.preConditions.isEmpty();
4157        }
4158
4159        /**
4160         * @param value {@link #preConditions} (Description of initial status before the process starts.). This is the underlying object with id, value and extensions. The accessor "getPreConditions" gives direct access to the value
4161         */
4162        public ExampleScenarioProcessComponent setPreConditionsElement(MarkdownType value) { 
4163          this.preConditions = value;
4164          return this;
4165        }
4166
4167        /**
4168         * @return Description of initial status before the process starts.
4169         */
4170        public String getPreConditions() { 
4171          return this.preConditions == null ? null : this.preConditions.getValue();
4172        }
4173
4174        /**
4175         * @param value Description of initial status before the process starts.
4176         */
4177        public ExampleScenarioProcessComponent setPreConditions(String value) { 
4178          if (value == null)
4179            this.preConditions = null;
4180          else {
4181            if (this.preConditions == null)
4182              this.preConditions = new MarkdownType();
4183            this.preConditions.setValue(value);
4184          }
4185          return this;
4186        }
4187
4188        /**
4189         * @return {@link #postConditions} (Description of final status after the process ends.). This is the underlying object with id, value and extensions. The accessor "getPostConditions" gives direct access to the value
4190         */
4191        public MarkdownType getPostConditionsElement() { 
4192          if (this.postConditions == null)
4193            if (Configuration.errorOnAutoCreate())
4194              throw new Error("Attempt to auto-create ExampleScenarioProcessComponent.postConditions");
4195            else if (Configuration.doAutoCreate())
4196              this.postConditions = new MarkdownType(); // bb
4197          return this.postConditions;
4198        }
4199
4200        public boolean hasPostConditionsElement() { 
4201          return this.postConditions != null && !this.postConditions.isEmpty();
4202        }
4203
4204        public boolean hasPostConditions() { 
4205          return this.postConditions != null && !this.postConditions.isEmpty();
4206        }
4207
4208        /**
4209         * @param value {@link #postConditions} (Description of final status after the process ends.). This is the underlying object with id, value and extensions. The accessor "getPostConditions" gives direct access to the value
4210         */
4211        public ExampleScenarioProcessComponent setPostConditionsElement(MarkdownType value) { 
4212          this.postConditions = value;
4213          return this;
4214        }
4215
4216        /**
4217         * @return Description of final status after the process ends.
4218         */
4219        public String getPostConditions() { 
4220          return this.postConditions == null ? null : this.postConditions.getValue();
4221        }
4222
4223        /**
4224         * @param value Description of final status after the process ends.
4225         */
4226        public ExampleScenarioProcessComponent setPostConditions(String value) { 
4227          if (value == null)
4228            this.postConditions = null;
4229          else {
4230            if (this.postConditions == null)
4231              this.postConditions = new MarkdownType();
4232            this.postConditions.setValue(value);
4233          }
4234          return this;
4235        }
4236
4237        /**
4238         * @return {@link #step} (Each step of the process.)
4239         */
4240        public List<ExampleScenarioProcessStepComponent> getStep() { 
4241          if (this.step == null)
4242            this.step = new ArrayList<ExampleScenarioProcessStepComponent>();
4243          return this.step;
4244        }
4245
4246        /**
4247         * @return Returns a reference to <code>this</code> for easy method chaining
4248         */
4249        public ExampleScenarioProcessComponent setStep(List<ExampleScenarioProcessStepComponent> theStep) { 
4250          this.step = theStep;
4251          return this;
4252        }
4253
4254        public boolean hasStep() { 
4255          if (this.step == null)
4256            return false;
4257          for (ExampleScenarioProcessStepComponent item : this.step)
4258            if (!item.isEmpty())
4259              return true;
4260          return false;
4261        }
4262
4263        public ExampleScenarioProcessStepComponent addStep() { //3
4264          ExampleScenarioProcessStepComponent t = new ExampleScenarioProcessStepComponent();
4265          if (this.step == null)
4266            this.step = new ArrayList<ExampleScenarioProcessStepComponent>();
4267          this.step.add(t);
4268          return t;
4269        }
4270
4271        public ExampleScenarioProcessComponent addStep(ExampleScenarioProcessStepComponent t) { //3
4272          if (t == null)
4273            return this;
4274          if (this.step == null)
4275            this.step = new ArrayList<ExampleScenarioProcessStepComponent>();
4276          this.step.add(t);
4277          return this;
4278        }
4279
4280        /**
4281         * @return The first repetition of repeating field {@link #step}, creating it if it does not already exist
4282         */
4283        public ExampleScenarioProcessStepComponent getStepFirstRep() { 
4284          if (getStep().isEmpty()) {
4285            addStep();
4286          }
4287          return getStep().get(0);
4288        }
4289
4290        protected void listChildren(List<Property> children) {
4291          super.listChildren(children);
4292          children.add(new Property("title", "string", "The diagram title of the group of operations.", 0, 1, title));
4293          children.add(new Property("description", "markdown", "A longer description of the group of operations.", 0, 1, description));
4294          children.add(new Property("preConditions", "markdown", "Description of initial status before the process starts.", 0, 1, preConditions));
4295          children.add(new Property("postConditions", "markdown", "Description of final status after the process ends.", 0, 1, postConditions));
4296          children.add(new Property("step", "", "Each step of the process.", 0, java.lang.Integer.MAX_VALUE, step));
4297        }
4298
4299        @Override
4300        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
4301          switch (_hash) {
4302          case 110371416: /*title*/  return new Property("title", "string", "The diagram title of the group of operations.", 0, 1, title);
4303          case -1724546052: /*description*/  return new Property("description", "markdown", "A longer description of the group of operations.", 0, 1, description);
4304          case -1006692933: /*preConditions*/  return new Property("preConditions", "markdown", "Description of initial status before the process starts.", 0, 1, preConditions);
4305          case 1738302328: /*postConditions*/  return new Property("postConditions", "markdown", "Description of final status after the process ends.", 0, 1, postConditions);
4306          case 3540684: /*step*/  return new Property("step", "", "Each step of the process.", 0, java.lang.Integer.MAX_VALUE, step);
4307          default: return super.getNamedProperty(_hash, _name, _checkValid);
4308          }
4309
4310        }
4311
4312      @Override
4313      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
4314        switch (hash) {
4315        case 110371416: /*title*/ return this.title == null ? new Base[0] : new Base[] {this.title}; // StringType
4316        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // MarkdownType
4317        case -1006692933: /*preConditions*/ return this.preConditions == null ? new Base[0] : new Base[] {this.preConditions}; // MarkdownType
4318        case 1738302328: /*postConditions*/ return this.postConditions == null ? new Base[0] : new Base[] {this.postConditions}; // MarkdownType
4319        case 3540684: /*step*/ return this.step == null ? new Base[0] : this.step.toArray(new Base[this.step.size()]); // ExampleScenarioProcessStepComponent
4320        default: return super.getProperty(hash, name, checkValid);
4321        }
4322
4323      }
4324
4325      @Override
4326      public Base setProperty(int hash, String name, Base value) throws FHIRException {
4327        switch (hash) {
4328        case 110371416: // title
4329          this.title = castToString(value); // StringType
4330          return value;
4331        case -1724546052: // description
4332          this.description = castToMarkdown(value); // MarkdownType
4333          return value;
4334        case -1006692933: // preConditions
4335          this.preConditions = castToMarkdown(value); // MarkdownType
4336          return value;
4337        case 1738302328: // postConditions
4338          this.postConditions = castToMarkdown(value); // MarkdownType
4339          return value;
4340        case 3540684: // step
4341          this.getStep().add((ExampleScenarioProcessStepComponent) value); // ExampleScenarioProcessStepComponent
4342          return value;
4343        default: return super.setProperty(hash, name, value);
4344        }
4345
4346      }
4347
4348      @Override
4349      public Base setProperty(String name, Base value) throws FHIRException {
4350        if (name.equals("title")) {
4351          this.title = castToString(value); // StringType
4352        } else if (name.equals("description")) {
4353          this.description = castToMarkdown(value); // MarkdownType
4354        } else if (name.equals("preConditions")) {
4355          this.preConditions = castToMarkdown(value); // MarkdownType
4356        } else if (name.equals("postConditions")) {
4357          this.postConditions = castToMarkdown(value); // MarkdownType
4358        } else if (name.equals("step")) {
4359          this.getStep().add((ExampleScenarioProcessStepComponent) value);
4360        } else
4361          return super.setProperty(name, value);
4362        return value;
4363      }
4364
4365      @Override
4366      public Base makeProperty(int hash, String name) throws FHIRException {
4367        switch (hash) {
4368        case 110371416:  return getTitleElement();
4369        case -1724546052:  return getDescriptionElement();
4370        case -1006692933:  return getPreConditionsElement();
4371        case 1738302328:  return getPostConditionsElement();
4372        case 3540684:  return addStep(); 
4373        default: return super.makeProperty(hash, name);
4374        }
4375
4376      }
4377
4378      @Override
4379      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
4380        switch (hash) {
4381        case 110371416: /*title*/ return new String[] {"string"};
4382        case -1724546052: /*description*/ return new String[] {"markdown"};
4383        case -1006692933: /*preConditions*/ return new String[] {"markdown"};
4384        case 1738302328: /*postConditions*/ return new String[] {"markdown"};
4385        case 3540684: /*step*/ return new String[] {};
4386        default: return super.getTypesForProperty(hash, name);
4387        }
4388
4389      }
4390
4391      @Override
4392      public Base addChild(String name) throws FHIRException {
4393        if (name.equals("title")) {
4394          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.title");
4395        }
4396        else if (name.equals("description")) {
4397          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.description");
4398        }
4399        else if (name.equals("preConditions")) {
4400          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.preConditions");
4401        }
4402        else if (name.equals("postConditions")) {
4403          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.postConditions");
4404        }
4405        else if (name.equals("step")) {
4406          return addStep();
4407        }
4408        else
4409          return super.addChild(name);
4410      }
4411
4412      public ExampleScenarioProcessComponent copy() {
4413        ExampleScenarioProcessComponent dst = new ExampleScenarioProcessComponent();
4414        copyValues(dst);
4415        return dst;
4416      }
4417
4418      public void copyValues(ExampleScenarioProcessComponent dst) {
4419        super.copyValues(dst);
4420        dst.title = title == null ? null : title.copy();
4421        dst.description = description == null ? null : description.copy();
4422        dst.preConditions = preConditions == null ? null : preConditions.copy();
4423        dst.postConditions = postConditions == null ? null : postConditions.copy();
4424        if (step != null) {
4425          dst.step = new ArrayList<ExampleScenarioProcessStepComponent>();
4426          for (ExampleScenarioProcessStepComponent i : step)
4427            dst.step.add(i.copy());
4428        };
4429      }
4430
4431      @Override
4432      public boolean equalsDeep(Base other_) {
4433        if (!super.equalsDeep(other_))
4434          return false;
4435        if (!(other_ instanceof ExampleScenarioProcessComponent))
4436          return false;
4437        ExampleScenarioProcessComponent o = (ExampleScenarioProcessComponent) other_;
4438        return compareDeep(title, o.title, true) && compareDeep(description, o.description, true) && compareDeep(preConditions, o.preConditions, true)
4439           && compareDeep(postConditions, o.postConditions, true) && compareDeep(step, o.step, true);
4440      }
4441
4442      @Override
4443      public boolean equalsShallow(Base other_) {
4444        if (!super.equalsShallow(other_))
4445          return false;
4446        if (!(other_ instanceof ExampleScenarioProcessComponent))
4447          return false;
4448        ExampleScenarioProcessComponent o = (ExampleScenarioProcessComponent) other_;
4449        return compareValues(title, o.title, true) && compareValues(description, o.description, true) && compareValues(preConditions, o.preConditions, true)
4450           && compareValues(postConditions, o.postConditions, true);
4451      }
4452
4453      public boolean isEmpty() {
4454        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(title, description, preConditions
4455          , postConditions, step);
4456      }
4457
4458  public String fhirType() {
4459    return "ExampleScenario.process";
4460
4461  }
4462
4463  }
4464
4465    @Block()
4466    public static class ExampleScenarioProcessStepComponent extends BackboneElement implements IBaseBackboneElement {
4467        /**
4468         * Nested process.
4469         */
4470        @Child(name = "process", type = {ExampleScenarioProcessComponent.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
4471        @Description(shortDefinition="Nested process", formalDefinition="Nested process." )
4472        protected List<ExampleScenarioProcessComponent> process;
4473
4474        /**
4475         * If there is a pause in the flow.
4476         */
4477        @Child(name = "pause", type = {BooleanType.class}, order=2, min=0, max=1, modifier=false, summary=false)
4478        @Description(shortDefinition="If there is a pause in the flow", formalDefinition="If there is a pause in the flow." )
4479        protected BooleanType pause;
4480
4481        /**
4482         * Each interaction or action.
4483         */
4484        @Child(name = "operation", type = {}, order=3, min=0, max=1, modifier=false, summary=false)
4485        @Description(shortDefinition="Each interaction or action", formalDefinition="Each interaction or action." )
4486        protected ExampleScenarioProcessStepOperationComponent operation;
4487
4488        /**
4489         * Indicates an alternative step that can be taken instead of the operations on the base step in exceptional/atypical circumstances.
4490         */
4491        @Child(name = "alternative", type = {}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
4492        @Description(shortDefinition="Alternate non-typical step action", formalDefinition="Indicates an alternative step that can be taken instead of the operations on the base step in exceptional/atypical circumstances." )
4493        protected List<ExampleScenarioProcessStepAlternativeComponent> alternative;
4494
4495        private static final long serialVersionUID = -894029605L;
4496
4497    /**
4498     * Constructor
4499     */
4500      public ExampleScenarioProcessStepComponent() {
4501        super();
4502      }
4503
4504        /**
4505         * @return {@link #process} (Nested process.)
4506         */
4507        public List<ExampleScenarioProcessComponent> getProcess() { 
4508          if (this.process == null)
4509            this.process = new ArrayList<ExampleScenarioProcessComponent>();
4510          return this.process;
4511        }
4512
4513        /**
4514         * @return Returns a reference to <code>this</code> for easy method chaining
4515         */
4516        public ExampleScenarioProcessStepComponent setProcess(List<ExampleScenarioProcessComponent> theProcess) { 
4517          this.process = theProcess;
4518          return this;
4519        }
4520
4521        public boolean hasProcess() { 
4522          if (this.process == null)
4523            return false;
4524          for (ExampleScenarioProcessComponent item : this.process)
4525            if (!item.isEmpty())
4526              return true;
4527          return false;
4528        }
4529
4530        public ExampleScenarioProcessComponent addProcess() { //3
4531          ExampleScenarioProcessComponent t = new ExampleScenarioProcessComponent();
4532          if (this.process == null)
4533            this.process = new ArrayList<ExampleScenarioProcessComponent>();
4534          this.process.add(t);
4535          return t;
4536        }
4537
4538        public ExampleScenarioProcessStepComponent addProcess(ExampleScenarioProcessComponent t) { //3
4539          if (t == null)
4540            return this;
4541          if (this.process == null)
4542            this.process = new ArrayList<ExampleScenarioProcessComponent>();
4543          this.process.add(t);
4544          return this;
4545        }
4546
4547        /**
4548         * @return The first repetition of repeating field {@link #process}, creating it if it does not already exist
4549         */
4550        public ExampleScenarioProcessComponent getProcessFirstRep() { 
4551          if (getProcess().isEmpty()) {
4552            addProcess();
4553          }
4554          return getProcess().get(0);
4555        }
4556
4557        /**
4558         * @return {@link #pause} (If there is a pause in the flow.). This is the underlying object with id, value and extensions. The accessor "getPause" gives direct access to the value
4559         */
4560        public BooleanType getPauseElement() { 
4561          if (this.pause == null)
4562            if (Configuration.errorOnAutoCreate())
4563              throw new Error("Attempt to auto-create ExampleScenarioProcessStepComponent.pause");
4564            else if (Configuration.doAutoCreate())
4565              this.pause = new BooleanType(); // bb
4566          return this.pause;
4567        }
4568
4569        public boolean hasPauseElement() { 
4570          return this.pause != null && !this.pause.isEmpty();
4571        }
4572
4573        public boolean hasPause() { 
4574          return this.pause != null && !this.pause.isEmpty();
4575        }
4576
4577        /**
4578         * @param value {@link #pause} (If there is a pause in the flow.). This is the underlying object with id, value and extensions. The accessor "getPause" gives direct access to the value
4579         */
4580        public ExampleScenarioProcessStepComponent setPauseElement(BooleanType value) { 
4581          this.pause = value;
4582          return this;
4583        }
4584
4585        /**
4586         * @return If there is a pause in the flow.
4587         */
4588        public boolean getPause() { 
4589          return this.pause == null || this.pause.isEmpty() ? false : this.pause.getValue();
4590        }
4591
4592        /**
4593         * @param value If there is a pause in the flow.
4594         */
4595        public ExampleScenarioProcessStepComponent setPause(boolean value) { 
4596            if (this.pause == null)
4597              this.pause = new BooleanType();
4598            this.pause.setValue(value);
4599          return this;
4600        }
4601
4602        /**
4603         * @return {@link #operation} (Each interaction or action.)
4604         */
4605        public ExampleScenarioProcessStepOperationComponent getOperation() { 
4606          if (this.operation == null)
4607            if (Configuration.errorOnAutoCreate())
4608              throw new Error("Attempt to auto-create ExampleScenarioProcessStepComponent.operation");
4609            else if (Configuration.doAutoCreate())
4610              this.operation = new ExampleScenarioProcessStepOperationComponent(); // cc
4611          return this.operation;
4612        }
4613
4614        public boolean hasOperation() { 
4615          return this.operation != null && !this.operation.isEmpty();
4616        }
4617
4618        /**
4619         * @param value {@link #operation} (Each interaction or action.)
4620         */
4621        public ExampleScenarioProcessStepComponent setOperation(ExampleScenarioProcessStepOperationComponent value) { 
4622          this.operation = value;
4623          return this;
4624        }
4625
4626        /**
4627         * @return {@link #alternative} (Indicates an alternative step that can be taken instead of the operations on the base step in exceptional/atypical circumstances.)
4628         */
4629        public List<ExampleScenarioProcessStepAlternativeComponent> getAlternative() { 
4630          if (this.alternative == null)
4631            this.alternative = new ArrayList<ExampleScenarioProcessStepAlternativeComponent>();
4632          return this.alternative;
4633        }
4634
4635        /**
4636         * @return Returns a reference to <code>this</code> for easy method chaining
4637         */
4638        public ExampleScenarioProcessStepComponent setAlternative(List<ExampleScenarioProcessStepAlternativeComponent> theAlternative) { 
4639          this.alternative = theAlternative;
4640          return this;
4641        }
4642
4643        public boolean hasAlternative() { 
4644          if (this.alternative == null)
4645            return false;
4646          for (ExampleScenarioProcessStepAlternativeComponent item : this.alternative)
4647            if (!item.isEmpty())
4648              return true;
4649          return false;
4650        }
4651
4652        public ExampleScenarioProcessStepAlternativeComponent addAlternative() { //3
4653          ExampleScenarioProcessStepAlternativeComponent t = new ExampleScenarioProcessStepAlternativeComponent();
4654          if (this.alternative == null)
4655            this.alternative = new ArrayList<ExampleScenarioProcessStepAlternativeComponent>();
4656          this.alternative.add(t);
4657          return t;
4658        }
4659
4660        public ExampleScenarioProcessStepComponent addAlternative(ExampleScenarioProcessStepAlternativeComponent t) { //3
4661          if (t == null)
4662            return this;
4663          if (this.alternative == null)
4664            this.alternative = new ArrayList<ExampleScenarioProcessStepAlternativeComponent>();
4665          this.alternative.add(t);
4666          return this;
4667        }
4668
4669        /**
4670         * @return The first repetition of repeating field {@link #alternative}, creating it if it does not already exist
4671         */
4672        public ExampleScenarioProcessStepAlternativeComponent getAlternativeFirstRep() { 
4673          if (getAlternative().isEmpty()) {
4674            addAlternative();
4675          }
4676          return getAlternative().get(0);
4677        }
4678
4679        protected void listChildren(List<Property> children) {
4680          super.listChildren(children);
4681          children.add(new Property("process", "@ExampleScenario.process", "Nested process.", 0, java.lang.Integer.MAX_VALUE, process));
4682          children.add(new Property("pause", "boolean", "If there is a pause in the flow.", 0, 1, pause));
4683          children.add(new Property("operation", "", "Each interaction or action.", 0, 1, operation));
4684          children.add(new Property("alternative", "", "Indicates an alternative step that can be taken instead of the operations on the base step in exceptional/atypical circumstances.", 0, java.lang.Integer.MAX_VALUE, alternative));
4685        }
4686
4687        @Override
4688        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
4689          switch (_hash) {
4690          case -309518737: /*process*/  return new Property("process", "@ExampleScenario.process", "Nested process.", 0, java.lang.Integer.MAX_VALUE, process);
4691          case 106440182: /*pause*/  return new Property("pause", "boolean", "If there is a pause in the flow.", 0, 1, pause);
4692          case 1662702951: /*operation*/  return new Property("operation", "", "Each interaction or action.", 0, 1, operation);
4693          case -196794451: /*alternative*/  return new Property("alternative", "", "Indicates an alternative step that can be taken instead of the operations on the base step in exceptional/atypical circumstances.", 0, java.lang.Integer.MAX_VALUE, alternative);
4694          default: return super.getNamedProperty(_hash, _name, _checkValid);
4695          }
4696
4697        }
4698
4699      @Override
4700      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
4701        switch (hash) {
4702        case -309518737: /*process*/ return this.process == null ? new Base[0] : this.process.toArray(new Base[this.process.size()]); // ExampleScenarioProcessComponent
4703        case 106440182: /*pause*/ return this.pause == null ? new Base[0] : new Base[] {this.pause}; // BooleanType
4704        case 1662702951: /*operation*/ return this.operation == null ? new Base[0] : new Base[] {this.operation}; // ExampleScenarioProcessStepOperationComponent
4705        case -196794451: /*alternative*/ return this.alternative == null ? new Base[0] : this.alternative.toArray(new Base[this.alternative.size()]); // ExampleScenarioProcessStepAlternativeComponent
4706        default: return super.getProperty(hash, name, checkValid);
4707        }
4708
4709      }
4710
4711      @Override
4712      public Base setProperty(int hash, String name, Base value) throws FHIRException {
4713        switch (hash) {
4714        case -309518737: // process
4715          this.getProcess().add((ExampleScenarioProcessComponent) value); // ExampleScenarioProcessComponent
4716          return value;
4717        case 106440182: // pause
4718          this.pause = castToBoolean(value); // BooleanType
4719          return value;
4720        case 1662702951: // operation
4721          this.operation = (ExampleScenarioProcessStepOperationComponent) value; // ExampleScenarioProcessStepOperationComponent
4722          return value;
4723        case -196794451: // alternative
4724          this.getAlternative().add((ExampleScenarioProcessStepAlternativeComponent) value); // ExampleScenarioProcessStepAlternativeComponent
4725          return value;
4726        default: return super.setProperty(hash, name, value);
4727        }
4728
4729      }
4730
4731      @Override
4732      public Base setProperty(String name, Base value) throws FHIRException {
4733        if (name.equals("process")) {
4734          this.getProcess().add((ExampleScenarioProcessComponent) value);
4735        } else if (name.equals("pause")) {
4736          this.pause = castToBoolean(value); // BooleanType
4737        } else if (name.equals("operation")) {
4738          this.operation = (ExampleScenarioProcessStepOperationComponent) value; // ExampleScenarioProcessStepOperationComponent
4739        } else if (name.equals("alternative")) {
4740          this.getAlternative().add((ExampleScenarioProcessStepAlternativeComponent) value);
4741        } else
4742          return super.setProperty(name, value);
4743        return value;
4744      }
4745
4746      @Override
4747      public Base makeProperty(int hash, String name) throws FHIRException {
4748        switch (hash) {
4749        case -309518737:  return addProcess(); 
4750        case 106440182:  return getPauseElement();
4751        case 1662702951:  return getOperation();
4752        case -196794451:  return addAlternative(); 
4753        default: return super.makeProperty(hash, name);
4754        }
4755
4756      }
4757
4758      @Override
4759      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
4760        switch (hash) {
4761        case -309518737: /*process*/ return new String[] {"@ExampleScenario.process"};
4762        case 106440182: /*pause*/ return new String[] {"boolean"};
4763        case 1662702951: /*operation*/ return new String[] {};
4764        case -196794451: /*alternative*/ return new String[] {};
4765        default: return super.getTypesForProperty(hash, name);
4766        }
4767
4768      }
4769
4770      @Override
4771      public Base addChild(String name) throws FHIRException {
4772        if (name.equals("process")) {
4773          return addProcess();
4774        }
4775        else if (name.equals("pause")) {
4776          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.pause");
4777        }
4778        else if (name.equals("operation")) {
4779          this.operation = new ExampleScenarioProcessStepOperationComponent();
4780          return this.operation;
4781        }
4782        else if (name.equals("alternative")) {
4783          return addAlternative();
4784        }
4785        else
4786          return super.addChild(name);
4787      }
4788
4789      public ExampleScenarioProcessStepComponent copy() {
4790        ExampleScenarioProcessStepComponent dst = new ExampleScenarioProcessStepComponent();
4791        copyValues(dst);
4792        return dst;
4793      }
4794
4795      public void copyValues(ExampleScenarioProcessStepComponent dst) {
4796        super.copyValues(dst);
4797        if (process != null) {
4798          dst.process = new ArrayList<ExampleScenarioProcessComponent>();
4799          for (ExampleScenarioProcessComponent i : process)
4800            dst.process.add(i.copy());
4801        };
4802        dst.pause = pause == null ? null : pause.copy();
4803        dst.operation = operation == null ? null : operation.copy();
4804        if (alternative != null) {
4805          dst.alternative = new ArrayList<ExampleScenarioProcessStepAlternativeComponent>();
4806          for (ExampleScenarioProcessStepAlternativeComponent i : alternative)
4807            dst.alternative.add(i.copy());
4808        };
4809      }
4810
4811      @Override
4812      public boolean equalsDeep(Base other_) {
4813        if (!super.equalsDeep(other_))
4814          return false;
4815        if (!(other_ instanceof ExampleScenarioProcessStepComponent))
4816          return false;
4817        ExampleScenarioProcessStepComponent o = (ExampleScenarioProcessStepComponent) other_;
4818        return compareDeep(process, o.process, true) && compareDeep(pause, o.pause, true) && compareDeep(operation, o.operation, true)
4819           && compareDeep(alternative, o.alternative, true);
4820      }
4821
4822      @Override
4823      public boolean equalsShallow(Base other_) {
4824        if (!super.equalsShallow(other_))
4825          return false;
4826        if (!(other_ instanceof ExampleScenarioProcessStepComponent))
4827          return false;
4828        ExampleScenarioProcessStepComponent o = (ExampleScenarioProcessStepComponent) other_;
4829        return compareValues(pause, o.pause, true);
4830      }
4831
4832      public boolean isEmpty() {
4833        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(process, pause, operation
4834          , alternative);
4835      }
4836
4837  public String fhirType() {
4838    return "ExampleScenario.process.step";
4839
4840  }
4841
4842  }
4843
4844    @Block()
4845    public static class ExampleScenarioProcessStepOperationComponent extends BackboneElement implements IBaseBackboneElement {
4846        /**
4847         * The sequential number of the interaction, e.g. 1.2.5.
4848         */
4849        @Child(name = "number", type = {StringType.class}, order=1, min=1, max=1, modifier=false, summary=false)
4850        @Description(shortDefinition="The sequential number of the interaction", formalDefinition="The sequential number of the interaction, e.g. 1.2.5." )
4851        protected StringType number;
4852
4853        /**
4854         * The type of operation - CRUD.
4855         */
4856        @Child(name = "type", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false)
4857        @Description(shortDefinition="The type of operation - CRUD", formalDefinition="The type of operation - CRUD." )
4858        protected StringType type;
4859
4860        /**
4861         * The human-friendly name of the interaction.
4862         */
4863        @Child(name = "name", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false)
4864        @Description(shortDefinition="The human-friendly name of the interaction", formalDefinition="The human-friendly name of the interaction." )
4865        protected StringType name;
4866
4867        /**
4868         * Who starts the transaction.
4869         */
4870        @Child(name = "initiator", type = {StringType.class}, order=4, min=0, max=1, modifier=false, summary=false)
4871        @Description(shortDefinition="Who starts the transaction", formalDefinition="Who starts the transaction." )
4872        protected StringType initiator;
4873
4874        /**
4875         * Who receives the transaction.
4876         */
4877        @Child(name = "receiver", type = {StringType.class}, order=5, min=0, max=1, modifier=false, summary=false)
4878        @Description(shortDefinition="Who receives the transaction", formalDefinition="Who receives the transaction." )
4879        protected StringType receiver;
4880
4881        /**
4882         * A comment to be inserted in the diagram.
4883         */
4884        @Child(name = "description", type = {MarkdownType.class}, order=6, min=0, max=1, modifier=false, summary=false)
4885        @Description(shortDefinition="A comment to be inserted in the diagram", formalDefinition="A comment to be inserted in the diagram." )
4886        protected MarkdownType description;
4887
4888        /**
4889         * Whether the initiator is deactivated right after the transaction.
4890         */
4891        @Child(name = "initiatorActive", type = {BooleanType.class}, order=7, min=0, max=1, modifier=false, summary=false)
4892        @Description(shortDefinition="Whether the initiator is deactivated right after the transaction", formalDefinition="Whether the initiator is deactivated right after the transaction." )
4893        protected BooleanType initiatorActive;
4894
4895        /**
4896         * Whether the receiver is deactivated right after the transaction.
4897         */
4898        @Child(name = "receiverActive", type = {BooleanType.class}, order=8, min=0, max=1, modifier=false, summary=false)
4899        @Description(shortDefinition="Whether the receiver is deactivated right after the transaction", formalDefinition="Whether the receiver is deactivated right after the transaction." )
4900        protected BooleanType receiverActive;
4901
4902        /**
4903         * Each resource instance used by the initiator.
4904         */
4905        @Child(name = "request", type = {ExampleScenarioInstanceContainedInstanceComponent.class}, order=9, min=0, max=1, modifier=false, summary=false)
4906        @Description(shortDefinition="Each resource instance used by the initiator", formalDefinition="Each resource instance used by the initiator." )
4907        protected ExampleScenarioInstanceContainedInstanceComponent request;
4908
4909        /**
4910         * Each resource instance used by the responder.
4911         */
4912        @Child(name = "response", type = {ExampleScenarioInstanceContainedInstanceComponent.class}, order=10, min=0, max=1, modifier=false, summary=false)
4913        @Description(shortDefinition="Each resource instance used by the responder", formalDefinition="Each resource instance used by the responder." )
4914        protected ExampleScenarioInstanceContainedInstanceComponent response;
4915
4916        private static final long serialVersionUID = 911241906L;
4917
4918    /**
4919     * Constructor
4920     */
4921      public ExampleScenarioProcessStepOperationComponent() {
4922        super();
4923      }
4924
4925    /**
4926     * Constructor
4927     */
4928      public ExampleScenarioProcessStepOperationComponent(StringType number) {
4929        super();
4930        this.number = number;
4931      }
4932
4933        /**
4934         * @return {@link #number} (The sequential number of the interaction, e.g. 1.2.5.). This is the underlying object with id, value and extensions. The accessor "getNumber" gives direct access to the value
4935         */
4936        public StringType getNumberElement() { 
4937          if (this.number == null)
4938            if (Configuration.errorOnAutoCreate())
4939              throw new Error("Attempt to auto-create ExampleScenarioProcessStepOperationComponent.number");
4940            else if (Configuration.doAutoCreate())
4941              this.number = new StringType(); // bb
4942          return this.number;
4943        }
4944
4945        public boolean hasNumberElement() { 
4946          return this.number != null && !this.number.isEmpty();
4947        }
4948
4949        public boolean hasNumber() { 
4950          return this.number != null && !this.number.isEmpty();
4951        }
4952
4953        /**
4954         * @param value {@link #number} (The sequential number of the interaction, e.g. 1.2.5.). This is the underlying object with id, value and extensions. The accessor "getNumber" gives direct access to the value
4955         */
4956        public ExampleScenarioProcessStepOperationComponent setNumberElement(StringType value) { 
4957          this.number = value;
4958          return this;
4959        }
4960
4961        /**
4962         * @return The sequential number of the interaction, e.g. 1.2.5.
4963         */
4964        public String getNumber() { 
4965          return this.number == null ? null : this.number.getValue();
4966        }
4967
4968        /**
4969         * @param value The sequential number of the interaction, e.g. 1.2.5.
4970         */
4971        public ExampleScenarioProcessStepOperationComponent setNumber(String value) { 
4972            if (this.number == null)
4973              this.number = new StringType();
4974            this.number.setValue(value);
4975          return this;
4976        }
4977
4978        /**
4979         * @return {@link #type} (The type of operation - CRUD.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value
4980         */
4981        public StringType getTypeElement() { 
4982          if (this.type == null)
4983            if (Configuration.errorOnAutoCreate())
4984              throw new Error("Attempt to auto-create ExampleScenarioProcessStepOperationComponent.type");
4985            else if (Configuration.doAutoCreate())
4986              this.type = new StringType(); // bb
4987          return this.type;
4988        }
4989
4990        public boolean hasTypeElement() { 
4991          return this.type != null && !this.type.isEmpty();
4992        }
4993
4994        public boolean hasType() { 
4995          return this.type != null && !this.type.isEmpty();
4996        }
4997
4998        /**
4999         * @param value {@link #type} (The type of operation - CRUD.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value
5000         */
5001        public ExampleScenarioProcessStepOperationComponent setTypeElement(StringType value) { 
5002          this.type = value;
5003          return this;
5004        }
5005
5006        /**
5007         * @return The type of operation - CRUD.
5008         */
5009        public String getType() { 
5010          return this.type == null ? null : this.type.getValue();
5011        }
5012
5013        /**
5014         * @param value The type of operation - CRUD.
5015         */
5016        public ExampleScenarioProcessStepOperationComponent setType(String value) { 
5017          if (Utilities.noString(value))
5018            this.type = null;
5019          else {
5020            if (this.type == null)
5021              this.type = new StringType();
5022            this.type.setValue(value);
5023          }
5024          return this;
5025        }
5026
5027        /**
5028         * @return {@link #name} (The human-friendly name of the interaction.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value
5029         */
5030        public StringType getNameElement() { 
5031          if (this.name == null)
5032            if (Configuration.errorOnAutoCreate())
5033              throw new Error("Attempt to auto-create ExampleScenarioProcessStepOperationComponent.name");
5034            else if (Configuration.doAutoCreate())
5035              this.name = new StringType(); // bb
5036          return this.name;
5037        }
5038
5039        public boolean hasNameElement() { 
5040          return this.name != null && !this.name.isEmpty();
5041        }
5042
5043        public boolean hasName() { 
5044          return this.name != null && !this.name.isEmpty();
5045        }
5046
5047        /**
5048         * @param value {@link #name} (The human-friendly name of the interaction.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value
5049         */
5050        public ExampleScenarioProcessStepOperationComponent setNameElement(StringType value) { 
5051          this.name = value;
5052          return this;
5053        }
5054
5055        /**
5056         * @return The human-friendly name of the interaction.
5057         */
5058        public String getName() { 
5059          return this.name == null ? null : this.name.getValue();
5060        }
5061
5062        /**
5063         * @param value The human-friendly name of the interaction.
5064         */
5065        public ExampleScenarioProcessStepOperationComponent setName(String value) { 
5066          if (Utilities.noString(value))
5067            this.name = null;
5068          else {
5069            if (this.name == null)
5070              this.name = new StringType();
5071            this.name.setValue(value);
5072          }
5073          return this;
5074        }
5075
5076        /**
5077         * @return {@link #initiator} (Who starts the transaction.). This is the underlying object with id, value and extensions. The accessor "getInitiator" gives direct access to the value
5078         */
5079        public StringType getInitiatorElement() { 
5080          if (this.initiator == null)
5081            if (Configuration.errorOnAutoCreate())
5082              throw new Error("Attempt to auto-create ExampleScenarioProcessStepOperationComponent.initiator");
5083            else if (Configuration.doAutoCreate())
5084              this.initiator = new StringType(); // bb
5085          return this.initiator;
5086        }
5087
5088        public boolean hasInitiatorElement() { 
5089          return this.initiator != null && !this.initiator.isEmpty();
5090        }
5091
5092        public boolean hasInitiator() { 
5093          return this.initiator != null && !this.initiator.isEmpty();
5094        }
5095
5096        /**
5097         * @param value {@link #initiator} (Who starts the transaction.). This is the underlying object with id, value and extensions. The accessor "getInitiator" gives direct access to the value
5098         */
5099        public ExampleScenarioProcessStepOperationComponent setInitiatorElement(StringType value) { 
5100          this.initiator = value;
5101          return this;
5102        }
5103
5104        /**
5105         * @return Who starts the transaction.
5106         */
5107        public String getInitiator() { 
5108          return this.initiator == null ? null : this.initiator.getValue();
5109        }
5110
5111        /**
5112         * @param value Who starts the transaction.
5113         */
5114        public ExampleScenarioProcessStepOperationComponent setInitiator(String value) { 
5115          if (Utilities.noString(value))
5116            this.initiator = null;
5117          else {
5118            if (this.initiator == null)
5119              this.initiator = new StringType();
5120            this.initiator.setValue(value);
5121          }
5122          return this;
5123        }
5124
5125        /**
5126         * @return {@link #receiver} (Who receives the transaction.). This is the underlying object with id, value and extensions. The accessor "getReceiver" gives direct access to the value
5127         */
5128        public StringType getReceiverElement() { 
5129          if (this.receiver == null)
5130            if (Configuration.errorOnAutoCreate())
5131              throw new Error("Attempt to auto-create ExampleScenarioProcessStepOperationComponent.receiver");
5132            else if (Configuration.doAutoCreate())
5133              this.receiver = new StringType(); // bb
5134          return this.receiver;
5135        }
5136
5137        public boolean hasReceiverElement() { 
5138          return this.receiver != null && !this.receiver.isEmpty();
5139        }
5140
5141        public boolean hasReceiver() { 
5142          return this.receiver != null && !this.receiver.isEmpty();
5143        }
5144
5145        /**
5146         * @param value {@link #receiver} (Who receives the transaction.). This is the underlying object with id, value and extensions. The accessor "getReceiver" gives direct access to the value
5147         */
5148        public ExampleScenarioProcessStepOperationComponent setReceiverElement(StringType value) { 
5149          this.receiver = value;
5150          return this;
5151        }
5152
5153        /**
5154         * @return Who receives the transaction.
5155         */
5156        public String getReceiver() { 
5157          return this.receiver == null ? null : this.receiver.getValue();
5158        }
5159
5160        /**
5161         * @param value Who receives the transaction.
5162         */
5163        public ExampleScenarioProcessStepOperationComponent setReceiver(String value) { 
5164          if (Utilities.noString(value))
5165            this.receiver = null;
5166          else {
5167            if (this.receiver == null)
5168              this.receiver = new StringType();
5169            this.receiver.setValue(value);
5170          }
5171          return this;
5172        }
5173
5174        /**
5175         * @return {@link #description} (A comment to be inserted in the diagram.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
5176         */
5177        public MarkdownType getDescriptionElement() { 
5178          if (this.description == null)
5179            if (Configuration.errorOnAutoCreate())
5180              throw new Error("Attempt to auto-create ExampleScenarioProcessStepOperationComponent.description");
5181            else if (Configuration.doAutoCreate())
5182              this.description = new MarkdownType(); // bb
5183          return this.description;
5184        }
5185
5186        public boolean hasDescriptionElement() { 
5187          return this.description != null && !this.description.isEmpty();
5188        }
5189
5190        public boolean hasDescription() { 
5191          return this.description != null && !this.description.isEmpty();
5192        }
5193
5194        /**
5195         * @param value {@link #description} (A comment to be inserted in the diagram.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
5196         */
5197        public ExampleScenarioProcessStepOperationComponent setDescriptionElement(MarkdownType value) { 
5198          this.description = value;
5199          return this;
5200        }
5201
5202        /**
5203         * @return A comment to be inserted in the diagram.
5204         */
5205        public String getDescription() { 
5206          return this.description == null ? null : this.description.getValue();
5207        }
5208
5209        /**
5210         * @param value A comment to be inserted in the diagram.
5211         */
5212        public ExampleScenarioProcessStepOperationComponent setDescription(String value) { 
5213          if (value == null)
5214            this.description = null;
5215          else {
5216            if (this.description == null)
5217              this.description = new MarkdownType();
5218            this.description.setValue(value);
5219          }
5220          return this;
5221        }
5222
5223        /**
5224         * @return {@link #initiatorActive} (Whether the initiator is deactivated right after the transaction.). This is the underlying object with id, value and extensions. The accessor "getInitiatorActive" gives direct access to the value
5225         */
5226        public BooleanType getInitiatorActiveElement() { 
5227          if (this.initiatorActive == null)
5228            if (Configuration.errorOnAutoCreate())
5229              throw new Error("Attempt to auto-create ExampleScenarioProcessStepOperationComponent.initiatorActive");
5230            else if (Configuration.doAutoCreate())
5231              this.initiatorActive = new BooleanType(); // bb
5232          return this.initiatorActive;
5233        }
5234
5235        public boolean hasInitiatorActiveElement() { 
5236          return this.initiatorActive != null && !this.initiatorActive.isEmpty();
5237        }
5238
5239        public boolean hasInitiatorActive() { 
5240          return this.initiatorActive != null && !this.initiatorActive.isEmpty();
5241        }
5242
5243        /**
5244         * @param value {@link #initiatorActive} (Whether the initiator is deactivated right after the transaction.). This is the underlying object with id, value and extensions. The accessor "getInitiatorActive" gives direct access to the value
5245         */
5246        public ExampleScenarioProcessStepOperationComponent setInitiatorActiveElement(BooleanType value) { 
5247          this.initiatorActive = value;
5248          return this;
5249        }
5250
5251        /**
5252         * @return Whether the initiator is deactivated right after the transaction.
5253         */
5254        public boolean getInitiatorActive() { 
5255          return this.initiatorActive == null || this.initiatorActive.isEmpty() ? false : this.initiatorActive.getValue();
5256        }
5257
5258        /**
5259         * @param value Whether the initiator is deactivated right after the transaction.
5260         */
5261        public ExampleScenarioProcessStepOperationComponent setInitiatorActive(boolean value) { 
5262            if (this.initiatorActive == null)
5263              this.initiatorActive = new BooleanType();
5264            this.initiatorActive.setValue(value);
5265          return this;
5266        }
5267
5268        /**
5269         * @return {@link #receiverActive} (Whether the receiver is deactivated right after the transaction.). This is the underlying object with id, value and extensions. The accessor "getReceiverActive" gives direct access to the value
5270         */
5271        public BooleanType getReceiverActiveElement() { 
5272          if (this.receiverActive == null)
5273            if (Configuration.errorOnAutoCreate())
5274              throw new Error("Attempt to auto-create ExampleScenarioProcessStepOperationComponent.receiverActive");
5275            else if (Configuration.doAutoCreate())
5276              this.receiverActive = new BooleanType(); // bb
5277          return this.receiverActive;
5278        }
5279
5280        public boolean hasReceiverActiveElement() { 
5281          return this.receiverActive != null && !this.receiverActive.isEmpty();
5282        }
5283
5284        public boolean hasReceiverActive() { 
5285          return this.receiverActive != null && !this.receiverActive.isEmpty();
5286        }
5287
5288        /**
5289         * @param value {@link #receiverActive} (Whether the receiver is deactivated right after the transaction.). This is the underlying object with id, value and extensions. The accessor "getReceiverActive" gives direct access to the value
5290         */
5291        public ExampleScenarioProcessStepOperationComponent setReceiverActiveElement(BooleanType value) { 
5292          this.receiverActive = value;
5293          return this;
5294        }
5295
5296        /**
5297         * @return Whether the receiver is deactivated right after the transaction.
5298         */
5299        public boolean getReceiverActive() { 
5300          return this.receiverActive == null || this.receiverActive.isEmpty() ? false : this.receiverActive.getValue();
5301        }
5302
5303        /**
5304         * @param value Whether the receiver is deactivated right after the transaction.
5305         */
5306        public ExampleScenarioProcessStepOperationComponent setReceiverActive(boolean value) { 
5307            if (this.receiverActive == null)
5308              this.receiverActive = new BooleanType();
5309            this.receiverActive.setValue(value);
5310          return this;
5311        }
5312
5313        /**
5314         * @return {@link #request} (Each resource instance used by the initiator.)
5315         */
5316        public ExampleScenarioInstanceContainedInstanceComponent getRequest() { 
5317          if (this.request == null)
5318            if (Configuration.errorOnAutoCreate())
5319              throw new Error("Attempt to auto-create ExampleScenarioProcessStepOperationComponent.request");
5320            else if (Configuration.doAutoCreate())
5321              this.request = new ExampleScenarioInstanceContainedInstanceComponent(); // cc
5322          return this.request;
5323        }
5324
5325        public boolean hasRequest() { 
5326          return this.request != null && !this.request.isEmpty();
5327        }
5328
5329        /**
5330         * @param value {@link #request} (Each resource instance used by the initiator.)
5331         */
5332        public ExampleScenarioProcessStepOperationComponent setRequest(ExampleScenarioInstanceContainedInstanceComponent value) { 
5333          this.request = value;
5334          return this;
5335        }
5336
5337        /**
5338         * @return {@link #response} (Each resource instance used by the responder.)
5339         */
5340        public ExampleScenarioInstanceContainedInstanceComponent getResponse() { 
5341          if (this.response == null)
5342            if (Configuration.errorOnAutoCreate())
5343              throw new Error("Attempt to auto-create ExampleScenarioProcessStepOperationComponent.response");
5344            else if (Configuration.doAutoCreate())
5345              this.response = new ExampleScenarioInstanceContainedInstanceComponent(); // cc
5346          return this.response;
5347        }
5348
5349        public boolean hasResponse() { 
5350          return this.response != null && !this.response.isEmpty();
5351        }
5352
5353        /**
5354         * @param value {@link #response} (Each resource instance used by the responder.)
5355         */
5356        public ExampleScenarioProcessStepOperationComponent setResponse(ExampleScenarioInstanceContainedInstanceComponent value) { 
5357          this.response = value;
5358          return this;
5359        }
5360
5361        protected void listChildren(List<Property> children) {
5362          super.listChildren(children);
5363          children.add(new Property("number", "string", "The sequential number of the interaction, e.g. 1.2.5.", 0, 1, number));
5364          children.add(new Property("type", "string", "The type of operation - CRUD.", 0, 1, type));
5365          children.add(new Property("name", "string", "The human-friendly name of the interaction.", 0, 1, name));
5366          children.add(new Property("initiator", "string", "Who starts the transaction.", 0, 1, initiator));
5367          children.add(new Property("receiver", "string", "Who receives the transaction.", 0, 1, receiver));
5368          children.add(new Property("description", "markdown", "A comment to be inserted in the diagram.", 0, 1, description));
5369          children.add(new Property("initiatorActive", "boolean", "Whether the initiator is deactivated right after the transaction.", 0, 1, initiatorActive));
5370          children.add(new Property("receiverActive", "boolean", "Whether the receiver is deactivated right after the transaction.", 0, 1, receiverActive));
5371          children.add(new Property("request", "@ExampleScenario.instance.containedInstance", "Each resource instance used by the initiator.", 0, 1, request));
5372          children.add(new Property("response", "@ExampleScenario.instance.containedInstance", "Each resource instance used by the responder.", 0, 1, response));
5373        }
5374
5375        @Override
5376        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
5377          switch (_hash) {
5378          case -1034364087: /*number*/  return new Property("number", "string", "The sequential number of the interaction, e.g. 1.2.5.", 0, 1, number);
5379          case 3575610: /*type*/  return new Property("type", "string", "The type of operation - CRUD.", 0, 1, type);
5380          case 3373707: /*name*/  return new Property("name", "string", "The human-friendly name of the interaction.", 0, 1, name);
5381          case -248987089: /*initiator*/  return new Property("initiator", "string", "Who starts the transaction.", 0, 1, initiator);
5382          case -808719889: /*receiver*/  return new Property("receiver", "string", "Who receives the transaction.", 0, 1, receiver);
5383          case -1724546052: /*description*/  return new Property("description", "markdown", "A comment to be inserted in the diagram.", 0, 1, description);
5384          case 384339477: /*initiatorActive*/  return new Property("initiatorActive", "boolean", "Whether the initiator is deactivated right after the transaction.", 0, 1, initiatorActive);
5385          case -285284907: /*receiverActive*/  return new Property("receiverActive", "boolean", "Whether the receiver is deactivated right after the transaction.", 0, 1, receiverActive);
5386          case 1095692943: /*request*/  return new Property("request", "@ExampleScenario.instance.containedInstance", "Each resource instance used by the initiator.", 0, 1, request);
5387          case -340323263: /*response*/  return new Property("response", "@ExampleScenario.instance.containedInstance", "Each resource instance used by the responder.", 0, 1, response);
5388          default: return super.getNamedProperty(_hash, _name, _checkValid);
5389          }
5390
5391        }
5392
5393      @Override
5394      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
5395        switch (hash) {
5396        case -1034364087: /*number*/ return this.number == null ? new Base[0] : new Base[] {this.number}; // StringType
5397        case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // StringType
5398        case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType
5399        case -248987089: /*initiator*/ return this.initiator == null ? new Base[0] : new Base[] {this.initiator}; // StringType
5400        case -808719889: /*receiver*/ return this.receiver == null ? new Base[0] : new Base[] {this.receiver}; // StringType
5401        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // MarkdownType
5402        case 384339477: /*initiatorActive*/ return this.initiatorActive == null ? new Base[0] : new Base[] {this.initiatorActive}; // BooleanType
5403        case -285284907: /*receiverActive*/ return this.receiverActive == null ? new Base[0] : new Base[] {this.receiverActive}; // BooleanType
5404        case 1095692943: /*request*/ return this.request == null ? new Base[0] : new Base[] {this.request}; // ExampleScenarioInstanceContainedInstanceComponent
5405        case -340323263: /*response*/ return this.response == null ? new Base[0] : new Base[] {this.response}; // ExampleScenarioInstanceContainedInstanceComponent
5406        default: return super.getProperty(hash, name, checkValid);
5407        }
5408
5409      }
5410
5411      @Override
5412      public Base setProperty(int hash, String name, Base value) throws FHIRException {
5413        switch (hash) {
5414        case -1034364087: // number
5415          this.number = castToString(value); // StringType
5416          return value;
5417        case 3575610: // type
5418          this.type = castToString(value); // StringType
5419          return value;
5420        case 3373707: // name
5421          this.name = castToString(value); // StringType
5422          return value;
5423        case -248987089: // initiator
5424          this.initiator = castToString(value); // StringType
5425          return value;
5426        case -808719889: // receiver
5427          this.receiver = castToString(value); // StringType
5428          return value;
5429        case -1724546052: // description
5430          this.description = castToMarkdown(value); // MarkdownType
5431          return value;
5432        case 384339477: // initiatorActive
5433          this.initiatorActive = castToBoolean(value); // BooleanType
5434          return value;
5435        case -285284907: // receiverActive
5436          this.receiverActive = castToBoolean(value); // BooleanType
5437          return value;
5438        case 1095692943: // request
5439          this.request = (ExampleScenarioInstanceContainedInstanceComponent) value; // ExampleScenarioInstanceContainedInstanceComponent
5440          return value;
5441        case -340323263: // response
5442          this.response = (ExampleScenarioInstanceContainedInstanceComponent) value; // ExampleScenarioInstanceContainedInstanceComponent
5443          return value;
5444        default: return super.setProperty(hash, name, value);
5445        }
5446
5447      }
5448
5449      @Override
5450      public Base setProperty(String name, Base value) throws FHIRException {
5451        if (name.equals("number")) {
5452          this.number = castToString(value); // StringType
5453        } else if (name.equals("type")) {
5454          this.type = castToString(value); // StringType
5455        } else if (name.equals("name")) {
5456          this.name = castToString(value); // StringType
5457        } else if (name.equals("initiator")) {
5458          this.initiator = castToString(value); // StringType
5459        } else if (name.equals("receiver")) {
5460          this.receiver = castToString(value); // StringType
5461        } else if (name.equals("description")) {
5462          this.description = castToMarkdown(value); // MarkdownType
5463        } else if (name.equals("initiatorActive")) {
5464          this.initiatorActive = castToBoolean(value); // BooleanType
5465        } else if (name.equals("receiverActive")) {
5466          this.receiverActive = castToBoolean(value); // BooleanType
5467        } else if (name.equals("request")) {
5468          this.request = (ExampleScenarioInstanceContainedInstanceComponent) value; // ExampleScenarioInstanceContainedInstanceComponent
5469        } else if (name.equals("response")) {
5470          this.response = (ExampleScenarioInstanceContainedInstanceComponent) value; // ExampleScenarioInstanceContainedInstanceComponent
5471        } else
5472          return super.setProperty(name, value);
5473        return value;
5474      }
5475
5476      @Override
5477      public Base makeProperty(int hash, String name) throws FHIRException {
5478        switch (hash) {
5479        case -1034364087:  return getNumberElement();
5480        case 3575610:  return getTypeElement();
5481        case 3373707:  return getNameElement();
5482        case -248987089:  return getInitiatorElement();
5483        case -808719889:  return getReceiverElement();
5484        case -1724546052:  return getDescriptionElement();
5485        case 384339477:  return getInitiatorActiveElement();
5486        case -285284907:  return getReceiverActiveElement();
5487        case 1095692943:  return getRequest();
5488        case -340323263:  return getResponse();
5489        default: return super.makeProperty(hash, name);
5490        }
5491
5492      }
5493
5494      @Override
5495      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
5496        switch (hash) {
5497        case -1034364087: /*number*/ return new String[] {"string"};
5498        case 3575610: /*type*/ return new String[] {"string"};
5499        case 3373707: /*name*/ return new String[] {"string"};
5500        case -248987089: /*initiator*/ return new String[] {"string"};
5501        case -808719889: /*receiver*/ return new String[] {"string"};
5502        case -1724546052: /*description*/ return new String[] {"markdown"};
5503        case 384339477: /*initiatorActive*/ return new String[] {"boolean"};
5504        case -285284907: /*receiverActive*/ return new String[] {"boolean"};
5505        case 1095692943: /*request*/ return new String[] {"@ExampleScenario.instance.containedInstance"};
5506        case -340323263: /*response*/ return new String[] {"@ExampleScenario.instance.containedInstance"};
5507        default: return super.getTypesForProperty(hash, name);
5508        }
5509
5510      }
5511
5512      @Override
5513      public Base addChild(String name) throws FHIRException {
5514        if (name.equals("number")) {
5515          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.number");
5516        }
5517        else if (name.equals("type")) {
5518          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.type");
5519        }
5520        else if (name.equals("name")) {
5521          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.name");
5522        }
5523        else if (name.equals("initiator")) {
5524          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.initiator");
5525        }
5526        else if (name.equals("receiver")) {
5527          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.receiver");
5528        }
5529        else if (name.equals("description")) {
5530          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.description");
5531        }
5532        else if (name.equals("initiatorActive")) {
5533          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.initiatorActive");
5534        }
5535        else if (name.equals("receiverActive")) {
5536          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.receiverActive");
5537        }
5538        else if (name.equals("request")) {
5539          this.request = new ExampleScenarioInstanceContainedInstanceComponent();
5540          return this.request;
5541        }
5542        else if (name.equals("response")) {
5543          this.response = new ExampleScenarioInstanceContainedInstanceComponent();
5544          return this.response;
5545        }
5546        else
5547          return super.addChild(name);
5548      }
5549
5550      public ExampleScenarioProcessStepOperationComponent copy() {
5551        ExampleScenarioProcessStepOperationComponent dst = new ExampleScenarioProcessStepOperationComponent();
5552        copyValues(dst);
5553        return dst;
5554      }
5555
5556      public void copyValues(ExampleScenarioProcessStepOperationComponent dst) {
5557        super.copyValues(dst);
5558        dst.number = number == null ? null : number.copy();
5559        dst.type = type == null ? null : type.copy();
5560        dst.name = name == null ? null : name.copy();
5561        dst.initiator = initiator == null ? null : initiator.copy();
5562        dst.receiver = receiver == null ? null : receiver.copy();
5563        dst.description = description == null ? null : description.copy();
5564        dst.initiatorActive = initiatorActive == null ? null : initiatorActive.copy();
5565        dst.receiverActive = receiverActive == null ? null : receiverActive.copy();
5566        dst.request = request == null ? null : request.copy();
5567        dst.response = response == null ? null : response.copy();
5568      }
5569
5570      @Override
5571      public boolean equalsDeep(Base other_) {
5572        if (!super.equalsDeep(other_))
5573          return false;
5574        if (!(other_ instanceof ExampleScenarioProcessStepOperationComponent))
5575          return false;
5576        ExampleScenarioProcessStepOperationComponent o = (ExampleScenarioProcessStepOperationComponent) other_;
5577        return compareDeep(number, o.number, true) && compareDeep(type, o.type, true) && compareDeep(name, o.name, true)
5578           && compareDeep(initiator, o.initiator, true) && compareDeep(receiver, o.receiver, true) && compareDeep(description, o.description, true)
5579           && compareDeep(initiatorActive, o.initiatorActive, true) && compareDeep(receiverActive, o.receiverActive, true)
5580           && compareDeep(request, o.request, true) && compareDeep(response, o.response, true);
5581      }
5582
5583      @Override
5584      public boolean equalsShallow(Base other_) {
5585        if (!super.equalsShallow(other_))
5586          return false;
5587        if (!(other_ instanceof ExampleScenarioProcessStepOperationComponent))
5588          return false;
5589        ExampleScenarioProcessStepOperationComponent o = (ExampleScenarioProcessStepOperationComponent) other_;
5590        return compareValues(number, o.number, true) && compareValues(type, o.type, true) && compareValues(name, o.name, true)
5591           && compareValues(initiator, o.initiator, true) && compareValues(receiver, o.receiver, true) && compareValues(description, o.description, true)
5592           && compareValues(initiatorActive, o.initiatorActive, true) && compareValues(receiverActive, o.receiverActive, true)
5593          ;
5594      }
5595
5596      public boolean isEmpty() {
5597        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(number, type, name, initiator
5598          , receiver, description, initiatorActive, receiverActive, request, response);
5599      }
5600
5601  public String fhirType() {
5602    return "ExampleScenario.process.step.operation";
5603
5604  }
5605
5606  }
5607
5608    @Block()
5609    public static class ExampleScenarioProcessStepAlternativeComponent extends BackboneElement implements IBaseBackboneElement {
5610        /**
5611         * The label to display for the alternative that gives a sense of the circumstance in which the alternative should be invoked.
5612         */
5613        @Child(name = "title", type = {StringType.class}, order=1, min=1, max=1, modifier=false, summary=false)
5614        @Description(shortDefinition="Label for alternative", formalDefinition="The label to display for the alternative that gives a sense of the circumstance in which the alternative should be invoked." )
5615        protected StringType title;
5616
5617        /**
5618         * A human-readable description of the alternative explaining when the alternative should occur rather than the base step.
5619         */
5620        @Child(name = "description", type = {MarkdownType.class}, order=2, min=0, max=1, modifier=false, summary=false)
5621        @Description(shortDefinition="A human-readable description of each option", formalDefinition="A human-readable description of the alternative explaining when the alternative should occur rather than the base step." )
5622        protected MarkdownType description;
5623
5624        /**
5625         * What happens in each alternative option.
5626         */
5627        @Child(name = "step", type = {ExampleScenarioProcessStepComponent.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
5628        @Description(shortDefinition="What happens in each alternative option", formalDefinition="What happens in each alternative option." )
5629        protected List<ExampleScenarioProcessStepComponent> step;
5630
5631        private static final long serialVersionUID = -254687460L;
5632
5633    /**
5634     * Constructor
5635     */
5636      public ExampleScenarioProcessStepAlternativeComponent() {
5637        super();
5638      }
5639
5640    /**
5641     * Constructor
5642     */
5643      public ExampleScenarioProcessStepAlternativeComponent(StringType title) {
5644        super();
5645        this.title = title;
5646      }
5647
5648        /**
5649         * @return {@link #title} (The label to display for the alternative that gives a sense of the circumstance in which the alternative should be invoked.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value
5650         */
5651        public StringType getTitleElement() { 
5652          if (this.title == null)
5653            if (Configuration.errorOnAutoCreate())
5654              throw new Error("Attempt to auto-create ExampleScenarioProcessStepAlternativeComponent.title");
5655            else if (Configuration.doAutoCreate())
5656              this.title = new StringType(); // bb
5657          return this.title;
5658        }
5659
5660        public boolean hasTitleElement() { 
5661          return this.title != null && !this.title.isEmpty();
5662        }
5663
5664        public boolean hasTitle() { 
5665          return this.title != null && !this.title.isEmpty();
5666        }
5667
5668        /**
5669         * @param value {@link #title} (The label to display for the alternative that gives a sense of the circumstance in which the alternative should be invoked.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value
5670         */
5671        public ExampleScenarioProcessStepAlternativeComponent setTitleElement(StringType value) { 
5672          this.title = value;
5673          return this;
5674        }
5675
5676        /**
5677         * @return The label to display for the alternative that gives a sense of the circumstance in which the alternative should be invoked.
5678         */
5679        public String getTitle() { 
5680          return this.title == null ? null : this.title.getValue();
5681        }
5682
5683        /**
5684         * @param value The label to display for the alternative that gives a sense of the circumstance in which the alternative should be invoked.
5685         */
5686        public ExampleScenarioProcessStepAlternativeComponent setTitle(String value) { 
5687            if (this.title == null)
5688              this.title = new StringType();
5689            this.title.setValue(value);
5690          return this;
5691        }
5692
5693        /**
5694         * @return {@link #description} (A human-readable description of the alternative explaining when the alternative should occur rather than the base step.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
5695         */
5696        public MarkdownType getDescriptionElement() { 
5697          if (this.description == null)
5698            if (Configuration.errorOnAutoCreate())
5699              throw new Error("Attempt to auto-create ExampleScenarioProcessStepAlternativeComponent.description");
5700            else if (Configuration.doAutoCreate())
5701              this.description = new MarkdownType(); // bb
5702          return this.description;
5703        }
5704
5705        public boolean hasDescriptionElement() { 
5706          return this.description != null && !this.description.isEmpty();
5707        }
5708
5709        public boolean hasDescription() { 
5710          return this.description != null && !this.description.isEmpty();
5711        }
5712
5713        /**
5714         * @param value {@link #description} (A human-readable description of the alternative explaining when the alternative should occur rather than the base step.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
5715         */
5716        public ExampleScenarioProcessStepAlternativeComponent setDescriptionElement(MarkdownType value) { 
5717          this.description = value;
5718          return this;
5719        }
5720
5721        /**
5722         * @return A human-readable description of the alternative explaining when the alternative should occur rather than the base step.
5723         */
5724        public String getDescription() { 
5725          return this.description == null ? null : this.description.getValue();
5726        }
5727
5728        /**
5729         * @param value A human-readable description of the alternative explaining when the alternative should occur rather than the base step.
5730         */
5731        public ExampleScenarioProcessStepAlternativeComponent setDescription(String value) { 
5732          if (value == null)
5733            this.description = null;
5734          else {
5735            if (this.description == null)
5736              this.description = new MarkdownType();
5737            this.description.setValue(value);
5738          }
5739          return this;
5740        }
5741
5742        /**
5743         * @return {@link #step} (What happens in each alternative option.)
5744         */
5745        public List<ExampleScenarioProcessStepComponent> getStep() { 
5746          if (this.step == null)
5747            this.step = new ArrayList<ExampleScenarioProcessStepComponent>();
5748          return this.step;
5749        }
5750
5751        /**
5752         * @return Returns a reference to <code>this</code> for easy method chaining
5753         */
5754        public ExampleScenarioProcessStepAlternativeComponent setStep(List<ExampleScenarioProcessStepComponent> theStep) { 
5755          this.step = theStep;
5756          return this;
5757        }
5758
5759        public boolean hasStep() { 
5760          if (this.step == null)
5761            return false;
5762          for (ExampleScenarioProcessStepComponent item : this.step)
5763            if (!item.isEmpty())
5764              return true;
5765          return false;
5766        }
5767
5768        public ExampleScenarioProcessStepComponent addStep() { //3
5769          ExampleScenarioProcessStepComponent t = new ExampleScenarioProcessStepComponent();
5770          if (this.step == null)
5771            this.step = new ArrayList<ExampleScenarioProcessStepComponent>();
5772          this.step.add(t);
5773          return t;
5774        }
5775
5776        public ExampleScenarioProcessStepAlternativeComponent addStep(ExampleScenarioProcessStepComponent t) { //3
5777          if (t == null)
5778            return this;
5779          if (this.step == null)
5780            this.step = new ArrayList<ExampleScenarioProcessStepComponent>();
5781          this.step.add(t);
5782          return this;
5783        }
5784
5785        /**
5786         * @return The first repetition of repeating field {@link #step}, creating it if it does not already exist
5787         */
5788        public ExampleScenarioProcessStepComponent getStepFirstRep() { 
5789          if (getStep().isEmpty()) {
5790            addStep();
5791          }
5792          return getStep().get(0);
5793        }
5794
5795        protected void listChildren(List<Property> children) {
5796          super.listChildren(children);
5797          children.add(new Property("title", "string", "The label to display for the alternative that gives a sense of the circumstance in which the alternative should be invoked.", 0, 1, title));
5798          children.add(new Property("description", "markdown", "A human-readable description of the alternative explaining when the alternative should occur rather than the base step.", 0, 1, description));
5799          children.add(new Property("step", "@ExampleScenario.process.step", "What happens in each alternative option.", 0, java.lang.Integer.MAX_VALUE, step));
5800        }
5801
5802        @Override
5803        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
5804          switch (_hash) {
5805          case 110371416: /*title*/  return new Property("title", "string", "The label to display for the alternative that gives a sense of the circumstance in which the alternative should be invoked.", 0, 1, title);
5806          case -1724546052: /*description*/  return new Property("description", "markdown", "A human-readable description of the alternative explaining when the alternative should occur rather than the base step.", 0, 1, description);
5807          case 3540684: /*step*/  return new Property("step", "@ExampleScenario.process.step", "What happens in each alternative option.", 0, java.lang.Integer.MAX_VALUE, step);
5808          default: return super.getNamedProperty(_hash, _name, _checkValid);
5809          }
5810
5811        }
5812
5813      @Override
5814      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
5815        switch (hash) {
5816        case 110371416: /*title*/ return this.title == null ? new Base[0] : new Base[] {this.title}; // StringType
5817        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // MarkdownType
5818        case 3540684: /*step*/ return this.step == null ? new Base[0] : this.step.toArray(new Base[this.step.size()]); // ExampleScenarioProcessStepComponent
5819        default: return super.getProperty(hash, name, checkValid);
5820        }
5821
5822      }
5823
5824      @Override
5825      public Base setProperty(int hash, String name, Base value) throws FHIRException {
5826        switch (hash) {
5827        case 110371416: // title
5828          this.title = castToString(value); // StringType
5829          return value;
5830        case -1724546052: // description
5831          this.description = castToMarkdown(value); // MarkdownType
5832          return value;
5833        case 3540684: // step
5834          this.getStep().add((ExampleScenarioProcessStepComponent) value); // ExampleScenarioProcessStepComponent
5835          return value;
5836        default: return super.setProperty(hash, name, value);
5837        }
5838
5839      }
5840
5841      @Override
5842      public Base setProperty(String name, Base value) throws FHIRException {
5843        if (name.equals("title")) {
5844          this.title = castToString(value); // StringType
5845        } else if (name.equals("description")) {
5846          this.description = castToMarkdown(value); // MarkdownType
5847        } else if (name.equals("step")) {
5848          this.getStep().add((ExampleScenarioProcessStepComponent) value);
5849        } else
5850          return super.setProperty(name, value);
5851        return value;
5852      }
5853
5854      @Override
5855      public Base makeProperty(int hash, String name) throws FHIRException {
5856        switch (hash) {
5857        case 110371416:  return getTitleElement();
5858        case -1724546052:  return getDescriptionElement();
5859        case 3540684:  return addStep(); 
5860        default: return super.makeProperty(hash, name);
5861        }
5862
5863      }
5864
5865      @Override
5866      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
5867        switch (hash) {
5868        case 110371416: /*title*/ return new String[] {"string"};
5869        case -1724546052: /*description*/ return new String[] {"markdown"};
5870        case 3540684: /*step*/ return new String[] {"@ExampleScenario.process.step"};
5871        default: return super.getTypesForProperty(hash, name);
5872        }
5873
5874      }
5875
5876      @Override
5877      public Base addChild(String name) throws FHIRException {
5878        if (name.equals("title")) {
5879          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.title");
5880        }
5881        else if (name.equals("description")) {
5882          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.description");
5883        }
5884        else if (name.equals("step")) {
5885          return addStep();
5886        }
5887        else
5888          return super.addChild(name);
5889      }
5890
5891      public ExampleScenarioProcessStepAlternativeComponent copy() {
5892        ExampleScenarioProcessStepAlternativeComponent dst = new ExampleScenarioProcessStepAlternativeComponent();
5893        copyValues(dst);
5894        return dst;
5895      }
5896
5897      public void copyValues(ExampleScenarioProcessStepAlternativeComponent dst) {
5898        super.copyValues(dst);
5899        dst.title = title == null ? null : title.copy();
5900        dst.description = description == null ? null : description.copy();
5901        if (step != null) {
5902          dst.step = new ArrayList<ExampleScenarioProcessStepComponent>();
5903          for (ExampleScenarioProcessStepComponent i : step)
5904            dst.step.add(i.copy());
5905        };
5906      }
5907
5908      @Override
5909      public boolean equalsDeep(Base other_) {
5910        if (!super.equalsDeep(other_))
5911          return false;
5912        if (!(other_ instanceof ExampleScenarioProcessStepAlternativeComponent))
5913          return false;
5914        ExampleScenarioProcessStepAlternativeComponent o = (ExampleScenarioProcessStepAlternativeComponent) other_;
5915        return compareDeep(title, o.title, true) && compareDeep(description, o.description, true) && compareDeep(step, o.step, true)
5916          ;
5917      }
5918
5919      @Override
5920      public boolean equalsShallow(Base other_) {
5921        if (!super.equalsShallow(other_))
5922          return false;
5923        if (!(other_ instanceof ExampleScenarioProcessStepAlternativeComponent))
5924          return false;
5925        ExampleScenarioProcessStepAlternativeComponent o = (ExampleScenarioProcessStepAlternativeComponent) other_;
5926        return compareValues(title, o.title, true) && compareValues(description, o.description, true);
5927      }
5928
5929      public boolean isEmpty() {
5930        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(title, description, step
5931          );
5932      }
5933
5934  public String fhirType() {
5935    return "ExampleScenario.process.step.alternative";
5936
5937  }
5938
5939  }
5940
5941    /**
5942     * A formal identifier that is used to identify this example scenario when it is represented in other formats, or referenced in a specification, model, design or an instance.
5943     */
5944    @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true)
5945    @Description(shortDefinition="Additional identifier for the example scenario", formalDefinition="A formal identifier that is used to identify this example scenario when it is represented in other formats, or referenced in a specification, model, design or an instance." )
5946    protected List<Identifier> identifier;
5947
5948    /**
5949     * A copyright statement relating to the example scenario and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the example scenario.
5950     */
5951    @Child(name = "copyright", type = {MarkdownType.class}, order=1, min=0, max=1, modifier=false, summary=false)
5952    @Description(shortDefinition="Use and/or publishing restrictions", formalDefinition="A copyright statement relating to the example scenario and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the example scenario." )
5953    protected MarkdownType copyright;
5954
5955    /**
5956     * What the example scenario resource is created for. This should not be used to show the business purpose of the scenario itself, but the purpose of documenting a scenario.
5957     */
5958    @Child(name = "purpose", type = {MarkdownType.class}, order=2, min=0, max=1, modifier=false, summary=false)
5959    @Description(shortDefinition="The purpose of the example, e.g. to illustrate a scenario", formalDefinition="What the example scenario resource is created for. This should not be used to show the business purpose of the scenario itself, but the purpose of documenting a scenario." )
5960    protected MarkdownType purpose;
5961
5962    /**
5963     * Actor participating in the resource.
5964     */
5965    @Child(name = "actor", type = {}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
5966    @Description(shortDefinition="Actor participating in the resource", formalDefinition="Actor participating in the resource." )
5967    protected List<ExampleScenarioActorComponent> actor;
5968
5969    /**
5970     * Each resource and each version that is present in the workflow.
5971     */
5972    @Child(name = "instance", type = {}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
5973    @Description(shortDefinition="Each resource and each version that is present in the workflow", formalDefinition="Each resource and each version that is present in the workflow." )
5974    protected List<ExampleScenarioInstanceComponent> instance;
5975
5976    /**
5977     * Each major process - a group of operations.
5978     */
5979    @Child(name = "process", type = {}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
5980    @Description(shortDefinition="Each major process - a group of operations", formalDefinition="Each major process - a group of operations." )
5981    protected List<ExampleScenarioProcessComponent> process;
5982
5983    /**
5984     * Another nested workflow.
5985     */
5986    @Child(name = "workflow", type = {CanonicalType.class}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
5987    @Description(shortDefinition="Another nested workflow", formalDefinition="Another nested workflow." )
5988    protected List<CanonicalType> workflow;
5989
5990    private static final long serialVersionUID = 758248907L;
5991
5992  /**
5993   * Constructor
5994   */
5995    public ExampleScenario() {
5996      super();
5997    }
5998
5999  /**
6000   * Constructor
6001   */
6002    public ExampleScenario(Enumeration<PublicationStatus> status) {
6003      super();
6004      this.status = status;
6005    }
6006
6007    /**
6008     * @return {@link #url} (An absolute URI that is used to identify this example scenario when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this example scenario is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the example scenario is stored on different servers.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value
6009     */
6010    public UriType getUrlElement() { 
6011      if (this.url == null)
6012        if (Configuration.errorOnAutoCreate())
6013          throw new Error("Attempt to auto-create ExampleScenario.url");
6014        else if (Configuration.doAutoCreate())
6015          this.url = new UriType(); // bb
6016      return this.url;
6017    }
6018
6019    public boolean hasUrlElement() { 
6020      return this.url != null && !this.url.isEmpty();
6021    }
6022
6023    public boolean hasUrl() { 
6024      return this.url != null && !this.url.isEmpty();
6025    }
6026
6027    /**
6028     * @param value {@link #url} (An absolute URI that is used to identify this example scenario when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this example scenario is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the example scenario is stored on different servers.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value
6029     */
6030    public ExampleScenario setUrlElement(UriType value) { 
6031      this.url = value;
6032      return this;
6033    }
6034
6035    /**
6036     * @return An absolute URI that is used to identify this example scenario when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this example scenario is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the example scenario is stored on different servers.
6037     */
6038    public String getUrl() { 
6039      return this.url == null ? null : this.url.getValue();
6040    }
6041
6042    /**
6043     * @param value An absolute URI that is used to identify this example scenario when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this example scenario is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the example scenario is stored on different servers.
6044     */
6045    public ExampleScenario setUrl(String value) { 
6046      if (Utilities.noString(value))
6047        this.url = null;
6048      else {
6049        if (this.url == null)
6050          this.url = new UriType();
6051        this.url.setValue(value);
6052      }
6053      return this;
6054    }
6055
6056    /**
6057     * @return {@link #identifier} (A formal identifier that is used to identify this example scenario when it is represented in other formats, or referenced in a specification, model, design or an instance.)
6058     */
6059    public List<Identifier> getIdentifier() { 
6060      if (this.identifier == null)
6061        this.identifier = new ArrayList<Identifier>();
6062      return this.identifier;
6063    }
6064
6065    /**
6066     * @return Returns a reference to <code>this</code> for easy method chaining
6067     */
6068    public ExampleScenario setIdentifier(List<Identifier> theIdentifier) { 
6069      this.identifier = theIdentifier;
6070      return this;
6071    }
6072
6073    public boolean hasIdentifier() { 
6074      if (this.identifier == null)
6075        return false;
6076      for (Identifier item : this.identifier)
6077        if (!item.isEmpty())
6078          return true;
6079      return false;
6080    }
6081
6082    public Identifier addIdentifier() { //3
6083      Identifier t = new Identifier();
6084      if (this.identifier == null)
6085        this.identifier = new ArrayList<Identifier>();
6086      this.identifier.add(t);
6087      return t;
6088    }
6089
6090    public ExampleScenario addIdentifier(Identifier t) { //3
6091      if (t == null)
6092        return this;
6093      if (this.identifier == null)
6094        this.identifier = new ArrayList<Identifier>();
6095      this.identifier.add(t);
6096      return this;
6097    }
6098
6099    /**
6100     * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist
6101     */
6102    public Identifier getIdentifierFirstRep() { 
6103      if (getIdentifier().isEmpty()) {
6104        addIdentifier();
6105      }
6106      return getIdentifier().get(0);
6107    }
6108
6109    /**
6110     * @return {@link #version} (The identifier that is used to identify this version of the example scenario when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the example scenario author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value
6111     */
6112    public StringType getVersionElement() { 
6113      if (this.version == null)
6114        if (Configuration.errorOnAutoCreate())
6115          throw new Error("Attempt to auto-create ExampleScenario.version");
6116        else if (Configuration.doAutoCreate())
6117          this.version = new StringType(); // bb
6118      return this.version;
6119    }
6120
6121    public boolean hasVersionElement() { 
6122      return this.version != null && !this.version.isEmpty();
6123    }
6124
6125    public boolean hasVersion() { 
6126      return this.version != null && !this.version.isEmpty();
6127    }
6128
6129    /**
6130     * @param value {@link #version} (The identifier that is used to identify this version of the example scenario when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the example scenario author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value
6131     */
6132    public ExampleScenario setVersionElement(StringType value) { 
6133      this.version = value;
6134      return this;
6135    }
6136
6137    /**
6138     * @return The identifier that is used to identify this version of the example scenario when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the example scenario author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.
6139     */
6140    public String getVersion() { 
6141      return this.version == null ? null : this.version.getValue();
6142    }
6143
6144    /**
6145     * @param value The identifier that is used to identify this version of the example scenario when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the example scenario author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.
6146     */
6147    public ExampleScenario setVersion(String value) { 
6148      if (Utilities.noString(value))
6149        this.version = null;
6150      else {
6151        if (this.version == null)
6152          this.version = new StringType();
6153        this.version.setValue(value);
6154      }
6155      return this;
6156    }
6157
6158    /**
6159     * @return {@link #name} (A natural language name identifying the example scenario. This name should be usable as an identifier for the module by machine processing applications such as code generation.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value
6160     */
6161    public StringType getNameElement() { 
6162      if (this.name == null)
6163        if (Configuration.errorOnAutoCreate())
6164          throw new Error("Attempt to auto-create ExampleScenario.name");
6165        else if (Configuration.doAutoCreate())
6166          this.name = new StringType(); // bb
6167      return this.name;
6168    }
6169
6170    public boolean hasNameElement() { 
6171      return this.name != null && !this.name.isEmpty();
6172    }
6173
6174    public boolean hasName() { 
6175      return this.name != null && !this.name.isEmpty();
6176    }
6177
6178    /**
6179     * @param value {@link #name} (A natural language name identifying the example scenario. This name should be usable as an identifier for the module by machine processing applications such as code generation.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value
6180     */
6181    public ExampleScenario setNameElement(StringType value) { 
6182      this.name = value;
6183      return this;
6184    }
6185
6186    /**
6187     * @return A natural language name identifying the example scenario. This name should be usable as an identifier for the module by machine processing applications such as code generation.
6188     */
6189    public String getName() { 
6190      return this.name == null ? null : this.name.getValue();
6191    }
6192
6193    /**
6194     * @param value A natural language name identifying the example scenario. This name should be usable as an identifier for the module by machine processing applications such as code generation.
6195     */
6196    public ExampleScenario setName(String value) { 
6197      if (Utilities.noString(value))
6198        this.name = null;
6199      else {
6200        if (this.name == null)
6201          this.name = new StringType();
6202        this.name.setValue(value);
6203      }
6204      return this;
6205    }
6206
6207    /**
6208     * @return {@link #status} (The status of this example scenario. Enables tracking the life-cycle of the content.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value
6209     */
6210    public Enumeration<PublicationStatus> getStatusElement() { 
6211      if (this.status == null)
6212        if (Configuration.errorOnAutoCreate())
6213          throw new Error("Attempt to auto-create ExampleScenario.status");
6214        else if (Configuration.doAutoCreate())
6215          this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); // bb
6216      return this.status;
6217    }
6218
6219    public boolean hasStatusElement() { 
6220      return this.status != null && !this.status.isEmpty();
6221    }
6222
6223    public boolean hasStatus() { 
6224      return this.status != null && !this.status.isEmpty();
6225    }
6226
6227    /**
6228     * @param value {@link #status} (The status of this example scenario. Enables tracking the life-cycle of the content.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value
6229     */
6230    public ExampleScenario setStatusElement(Enumeration<PublicationStatus> value) { 
6231      this.status = value;
6232      return this;
6233    }
6234
6235    /**
6236     * @return The status of this example scenario. Enables tracking the life-cycle of the content.
6237     */
6238    public PublicationStatus getStatus() { 
6239      return this.status == null ? null : this.status.getValue();
6240    }
6241
6242    /**
6243     * @param value The status of this example scenario. Enables tracking the life-cycle of the content.
6244     */
6245    public ExampleScenario setStatus(PublicationStatus value) { 
6246        if (this.status == null)
6247          this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory());
6248        this.status.setValue(value);
6249      return this;
6250    }
6251
6252    /**
6253     * @return {@link #experimental} (A Boolean value to indicate that this example scenario is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.). This is the underlying object with id, value and extensions. The accessor "getExperimental" gives direct access to the value
6254     */
6255    public BooleanType getExperimentalElement() { 
6256      if (this.experimental == null)
6257        if (Configuration.errorOnAutoCreate())
6258          throw new Error("Attempt to auto-create ExampleScenario.experimental");
6259        else if (Configuration.doAutoCreate())
6260          this.experimental = new BooleanType(); // bb
6261      return this.experimental;
6262    }
6263
6264    public boolean hasExperimentalElement() { 
6265      return this.experimental != null && !this.experimental.isEmpty();
6266    }
6267
6268    public boolean hasExperimental() { 
6269      return this.experimental != null && !this.experimental.isEmpty();
6270    }
6271
6272    /**
6273     * @param value {@link #experimental} (A Boolean value to indicate that this example scenario is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.). This is the underlying object with id, value and extensions. The accessor "getExperimental" gives direct access to the value
6274     */
6275    public ExampleScenario setExperimentalElement(BooleanType value) { 
6276      this.experimental = value;
6277      return this;
6278    }
6279
6280    /**
6281     * @return A Boolean value to indicate that this example scenario is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.
6282     */
6283    public boolean getExperimental() { 
6284      return this.experimental == null || this.experimental.isEmpty() ? false : this.experimental.getValue();
6285    }
6286
6287    /**
6288     * @param value A Boolean value to indicate that this example scenario is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.
6289     */
6290    public ExampleScenario setExperimental(boolean value) { 
6291        if (this.experimental == null)
6292          this.experimental = new BooleanType();
6293        this.experimental.setValue(value);
6294      return this;
6295    }
6296
6297    /**
6298     * @return {@link #date} (The date  (and optionally time) when the example scenario was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the example scenario changes. (e.g. the 'content logical definition').). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value
6299     */
6300    public DateTimeType getDateElement() { 
6301      if (this.date == null)
6302        if (Configuration.errorOnAutoCreate())
6303          throw new Error("Attempt to auto-create ExampleScenario.date");
6304        else if (Configuration.doAutoCreate())
6305          this.date = new DateTimeType(); // bb
6306      return this.date;
6307    }
6308
6309    public boolean hasDateElement() { 
6310      return this.date != null && !this.date.isEmpty();
6311    }
6312
6313    public boolean hasDate() { 
6314      return this.date != null && !this.date.isEmpty();
6315    }
6316
6317    /**
6318     * @param value {@link #date} (The date  (and optionally time) when the example scenario was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the example scenario changes. (e.g. the 'content logical definition').). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value
6319     */
6320    public ExampleScenario setDateElement(DateTimeType value) { 
6321      this.date = value;
6322      return this;
6323    }
6324
6325    /**
6326     * @return The date  (and optionally time) when the example scenario was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the example scenario changes. (e.g. the 'content logical definition').
6327     */
6328    public Date getDate() { 
6329      return this.date == null ? null : this.date.getValue();
6330    }
6331
6332    /**
6333     * @param value The date  (and optionally time) when the example scenario was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the example scenario changes. (e.g. the 'content logical definition').
6334     */
6335    public ExampleScenario setDate(Date value) { 
6336      if (value == null)
6337        this.date = null;
6338      else {
6339        if (this.date == null)
6340          this.date = new DateTimeType();
6341        this.date.setValue(value);
6342      }
6343      return this;
6344    }
6345
6346    /**
6347     * @return {@link #publisher} (The name of the organization or individual that published the example scenario.). This is the underlying object with id, value and extensions. The accessor "getPublisher" gives direct access to the value
6348     */
6349    public StringType getPublisherElement() { 
6350      if (this.publisher == null)
6351        if (Configuration.errorOnAutoCreate())
6352          throw new Error("Attempt to auto-create ExampleScenario.publisher");
6353        else if (Configuration.doAutoCreate())
6354          this.publisher = new StringType(); // bb
6355      return this.publisher;
6356    }
6357
6358    public boolean hasPublisherElement() { 
6359      return this.publisher != null && !this.publisher.isEmpty();
6360    }
6361
6362    public boolean hasPublisher() { 
6363      return this.publisher != null && !this.publisher.isEmpty();
6364    }
6365
6366    /**
6367     * @param value {@link #publisher} (The name of the organization or individual that published the example scenario.). This is the underlying object with id, value and extensions. The accessor "getPublisher" gives direct access to the value
6368     */
6369    public ExampleScenario setPublisherElement(StringType value) { 
6370      this.publisher = value;
6371      return this;
6372    }
6373
6374    /**
6375     * @return The name of the organization or individual that published the example scenario.
6376     */
6377    public String getPublisher() { 
6378      return this.publisher == null ? null : this.publisher.getValue();
6379    }
6380
6381    /**
6382     * @param value The name of the organization or individual that published the example scenario.
6383     */
6384    public ExampleScenario setPublisher(String value) { 
6385      if (Utilities.noString(value))
6386        this.publisher = null;
6387      else {
6388        if (this.publisher == null)
6389          this.publisher = new StringType();
6390        this.publisher.setValue(value);
6391      }
6392      return this;
6393    }
6394
6395    /**
6396     * @return {@link #contact} (Contact details to assist a user in finding and communicating with the publisher.)
6397     */
6398    public List<ContactDetail> getContact() { 
6399      if (this.contact == null)
6400        this.contact = new ArrayList<ContactDetail>();
6401      return this.contact;
6402    }
6403
6404    /**
6405     * @return Returns a reference to <code>this</code> for easy method chaining
6406     */
6407    public ExampleScenario setContact(List<ContactDetail> theContact) { 
6408      this.contact = theContact;
6409      return this;
6410    }
6411
6412    public boolean hasContact() { 
6413      if (this.contact == null)
6414        return false;
6415      for (ContactDetail item : this.contact)
6416        if (!item.isEmpty())
6417          return true;
6418      return false;
6419    }
6420
6421    public ContactDetail addContact() { //3
6422      ContactDetail t = new ContactDetail();
6423      if (this.contact == null)
6424        this.contact = new ArrayList<ContactDetail>();
6425      this.contact.add(t);
6426      return t;
6427    }
6428
6429    public ExampleScenario addContact(ContactDetail t) { //3
6430      if (t == null)
6431        return this;
6432      if (this.contact == null)
6433        this.contact = new ArrayList<ContactDetail>();
6434      this.contact.add(t);
6435      return this;
6436    }
6437
6438    /**
6439     * @return The first repetition of repeating field {@link #contact}, creating it if it does not already exist
6440     */
6441    public ContactDetail getContactFirstRep() { 
6442      if (getContact().isEmpty()) {
6443        addContact();
6444      }
6445      return getContact().get(0);
6446    }
6447
6448    /**
6449     * @return {@link #useContext} (The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate example scenario instances.)
6450     */
6451    public List<UsageContext> getUseContext() { 
6452      if (this.useContext == null)
6453        this.useContext = new ArrayList<UsageContext>();
6454      return this.useContext;
6455    }
6456
6457    /**
6458     * @return Returns a reference to <code>this</code> for easy method chaining
6459     */
6460    public ExampleScenario setUseContext(List<UsageContext> theUseContext) { 
6461      this.useContext = theUseContext;
6462      return this;
6463    }
6464
6465    public boolean hasUseContext() { 
6466      if (this.useContext == null)
6467        return false;
6468      for (UsageContext item : this.useContext)
6469        if (!item.isEmpty())
6470          return true;
6471      return false;
6472    }
6473
6474    public UsageContext addUseContext() { //3
6475      UsageContext t = new UsageContext();
6476      if (this.useContext == null)
6477        this.useContext = new ArrayList<UsageContext>();
6478      this.useContext.add(t);
6479      return t;
6480    }
6481
6482    public ExampleScenario addUseContext(UsageContext t) { //3
6483      if (t == null)
6484        return this;
6485      if (this.useContext == null)
6486        this.useContext = new ArrayList<UsageContext>();
6487      this.useContext.add(t);
6488      return this;
6489    }
6490
6491    /**
6492     * @return The first repetition of repeating field {@link #useContext}, creating it if it does not already exist
6493     */
6494    public UsageContext getUseContextFirstRep() { 
6495      if (getUseContext().isEmpty()) {
6496        addUseContext();
6497      }
6498      return getUseContext().get(0);
6499    }
6500
6501    /**
6502     * @return {@link #jurisdiction} (A legal or geographic region in which the example scenario is intended to be used.)
6503     */
6504    public List<CodeableConcept> getJurisdiction() { 
6505      if (this.jurisdiction == null)
6506        this.jurisdiction = new ArrayList<CodeableConcept>();
6507      return this.jurisdiction;
6508    }
6509
6510    /**
6511     * @return Returns a reference to <code>this</code> for easy method chaining
6512     */
6513    public ExampleScenario setJurisdiction(List<CodeableConcept> theJurisdiction) { 
6514      this.jurisdiction = theJurisdiction;
6515      return this;
6516    }
6517
6518    public boolean hasJurisdiction() { 
6519      if (this.jurisdiction == null)
6520        return false;
6521      for (CodeableConcept item : this.jurisdiction)
6522        if (!item.isEmpty())
6523          return true;
6524      return false;
6525    }
6526
6527    public CodeableConcept addJurisdiction() { //3
6528      CodeableConcept t = new CodeableConcept();
6529      if (this.jurisdiction == null)
6530        this.jurisdiction = new ArrayList<CodeableConcept>();
6531      this.jurisdiction.add(t);
6532      return t;
6533    }
6534
6535    public ExampleScenario addJurisdiction(CodeableConcept t) { //3
6536      if (t == null)
6537        return this;
6538      if (this.jurisdiction == null)
6539        this.jurisdiction = new ArrayList<CodeableConcept>();
6540      this.jurisdiction.add(t);
6541      return this;
6542    }
6543
6544    /**
6545     * @return The first repetition of repeating field {@link #jurisdiction}, creating it if it does not already exist
6546     */
6547    public CodeableConcept getJurisdictionFirstRep() { 
6548      if (getJurisdiction().isEmpty()) {
6549        addJurisdiction();
6550      }
6551      return getJurisdiction().get(0);
6552    }
6553
6554    /**
6555     * @return {@link #copyright} (A copyright statement relating to the example scenario and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the example scenario.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value
6556     */
6557    public MarkdownType getCopyrightElement() { 
6558      if (this.copyright == null)
6559        if (Configuration.errorOnAutoCreate())
6560          throw new Error("Attempt to auto-create ExampleScenario.copyright");
6561        else if (Configuration.doAutoCreate())
6562          this.copyright = new MarkdownType(); // bb
6563      return this.copyright;
6564    }
6565
6566    public boolean hasCopyrightElement() { 
6567      return this.copyright != null && !this.copyright.isEmpty();
6568    }
6569
6570    public boolean hasCopyright() { 
6571      return this.copyright != null && !this.copyright.isEmpty();
6572    }
6573
6574    /**
6575     * @param value {@link #copyright} (A copyright statement relating to the example scenario and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the example scenario.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value
6576     */
6577    public ExampleScenario setCopyrightElement(MarkdownType value) { 
6578      this.copyright = value;
6579      return this;
6580    }
6581
6582    /**
6583     * @return A copyright statement relating to the example scenario and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the example scenario.
6584     */
6585    public String getCopyright() { 
6586      return this.copyright == null ? null : this.copyright.getValue();
6587    }
6588
6589    /**
6590     * @param value A copyright statement relating to the example scenario and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the example scenario.
6591     */
6592    public ExampleScenario setCopyright(String value) { 
6593      if (value == null)
6594        this.copyright = null;
6595      else {
6596        if (this.copyright == null)
6597          this.copyright = new MarkdownType();
6598        this.copyright.setValue(value);
6599      }
6600      return this;
6601    }
6602
6603    /**
6604     * @return {@link #purpose} (What the example scenario resource is created for. This should not be used to show the business purpose of the scenario itself, but the purpose of documenting a scenario.). This is the underlying object with id, value and extensions. The accessor "getPurpose" gives direct access to the value
6605     */
6606    public MarkdownType getPurposeElement() { 
6607      if (this.purpose == null)
6608        if (Configuration.errorOnAutoCreate())
6609          throw new Error("Attempt to auto-create ExampleScenario.purpose");
6610        else if (Configuration.doAutoCreate())
6611          this.purpose = new MarkdownType(); // bb
6612      return this.purpose;
6613    }
6614
6615    public boolean hasPurposeElement() { 
6616      return this.purpose != null && !this.purpose.isEmpty();
6617    }
6618
6619    public boolean hasPurpose() { 
6620      return this.purpose != null && !this.purpose.isEmpty();
6621    }
6622
6623    /**
6624     * @param value {@link #purpose} (What the example scenario resource is created for. This should not be used to show the business purpose of the scenario itself, but the purpose of documenting a scenario.). This is the underlying object with id, value and extensions. The accessor "getPurpose" gives direct access to the value
6625     */
6626    public ExampleScenario setPurposeElement(MarkdownType value) { 
6627      this.purpose = value;
6628      return this;
6629    }
6630
6631    /**
6632     * @return What the example scenario resource is created for. This should not be used to show the business purpose of the scenario itself, but the purpose of documenting a scenario.
6633     */
6634    public String getPurpose() { 
6635      return this.purpose == null ? null : this.purpose.getValue();
6636    }
6637
6638    /**
6639     * @param value What the example scenario resource is created for. This should not be used to show the business purpose of the scenario itself, but the purpose of documenting a scenario.
6640     */
6641    public ExampleScenario setPurpose(String value) { 
6642      if (value == null)
6643        this.purpose = null;
6644      else {
6645        if (this.purpose == null)
6646          this.purpose = new MarkdownType();
6647        this.purpose.setValue(value);
6648      }
6649      return this;
6650    }
6651
6652    /**
6653     * @return {@link #actor} (Actor participating in the resource.)
6654     */
6655    public List<ExampleScenarioActorComponent> getActor() { 
6656      if (this.actor == null)
6657        this.actor = new ArrayList<ExampleScenarioActorComponent>();
6658      return this.actor;
6659    }
6660
6661    /**
6662     * @return Returns a reference to <code>this</code> for easy method chaining
6663     */
6664    public ExampleScenario setActor(List<ExampleScenarioActorComponent> theActor) { 
6665      this.actor = theActor;
6666      return this;
6667    }
6668
6669    public boolean hasActor() { 
6670      if (this.actor == null)
6671        return false;
6672      for (ExampleScenarioActorComponent item : this.actor)
6673        if (!item.isEmpty())
6674          return true;
6675      return false;
6676    }
6677
6678    public ExampleScenarioActorComponent addActor() { //3
6679      ExampleScenarioActorComponent t = new ExampleScenarioActorComponent();
6680      if (this.actor == null)
6681        this.actor = new ArrayList<ExampleScenarioActorComponent>();
6682      this.actor.add(t);
6683      return t;
6684    }
6685
6686    public ExampleScenario addActor(ExampleScenarioActorComponent t) { //3
6687      if (t == null)
6688        return this;
6689      if (this.actor == null)
6690        this.actor = new ArrayList<ExampleScenarioActorComponent>();
6691      this.actor.add(t);
6692      return this;
6693    }
6694
6695    /**
6696     * @return The first repetition of repeating field {@link #actor}, creating it if it does not already exist
6697     */
6698    public ExampleScenarioActorComponent getActorFirstRep() { 
6699      if (getActor().isEmpty()) {
6700        addActor();
6701      }
6702      return getActor().get(0);
6703    }
6704
6705    /**
6706     * @return {@link #instance} (Each resource and each version that is present in the workflow.)
6707     */
6708    public List<ExampleScenarioInstanceComponent> getInstance() { 
6709      if (this.instance == null)
6710        this.instance = new ArrayList<ExampleScenarioInstanceComponent>();
6711      return this.instance;
6712    }
6713
6714    /**
6715     * @return Returns a reference to <code>this</code> for easy method chaining
6716     */
6717    public ExampleScenario setInstance(List<ExampleScenarioInstanceComponent> theInstance) { 
6718      this.instance = theInstance;
6719      return this;
6720    }
6721
6722    public boolean hasInstance() { 
6723      if (this.instance == null)
6724        return false;
6725      for (ExampleScenarioInstanceComponent item : this.instance)
6726        if (!item.isEmpty())
6727          return true;
6728      return false;
6729    }
6730
6731    public ExampleScenarioInstanceComponent addInstance() { //3
6732      ExampleScenarioInstanceComponent t = new ExampleScenarioInstanceComponent();
6733      if (this.instance == null)
6734        this.instance = new ArrayList<ExampleScenarioInstanceComponent>();
6735      this.instance.add(t);
6736      return t;
6737    }
6738
6739    public ExampleScenario addInstance(ExampleScenarioInstanceComponent t) { //3
6740      if (t == null)
6741        return this;
6742      if (this.instance == null)
6743        this.instance = new ArrayList<ExampleScenarioInstanceComponent>();
6744      this.instance.add(t);
6745      return this;
6746    }
6747
6748    /**
6749     * @return The first repetition of repeating field {@link #instance}, creating it if it does not already exist
6750     */
6751    public ExampleScenarioInstanceComponent getInstanceFirstRep() { 
6752      if (getInstance().isEmpty()) {
6753        addInstance();
6754      }
6755      return getInstance().get(0);
6756    }
6757
6758    /**
6759     * @return {@link #process} (Each major process - a group of operations.)
6760     */
6761    public List<ExampleScenarioProcessComponent> getProcess() { 
6762      if (this.process == null)
6763        this.process = new ArrayList<ExampleScenarioProcessComponent>();
6764      return this.process;
6765    }
6766
6767    /**
6768     * @return Returns a reference to <code>this</code> for easy method chaining
6769     */
6770    public ExampleScenario setProcess(List<ExampleScenarioProcessComponent> theProcess) { 
6771      this.process = theProcess;
6772      return this;
6773    }
6774
6775    public boolean hasProcess() { 
6776      if (this.process == null)
6777        return false;
6778      for (ExampleScenarioProcessComponent item : this.process)
6779        if (!item.isEmpty())
6780          return true;
6781      return false;
6782    }
6783
6784    public ExampleScenarioProcessComponent addProcess() { //3
6785      ExampleScenarioProcessComponent t = new ExampleScenarioProcessComponent();
6786      if (this.process == null)
6787        this.process = new ArrayList<ExampleScenarioProcessComponent>();
6788      this.process.add(t);
6789      return t;
6790    }
6791
6792    public ExampleScenario addProcess(ExampleScenarioProcessComponent t) { //3
6793      if (t == null)
6794        return this;
6795      if (this.process == null)
6796        this.process = new ArrayList<ExampleScenarioProcessComponent>();
6797      this.process.add(t);
6798      return this;
6799    }
6800
6801    /**
6802     * @return The first repetition of repeating field {@link #process}, creating it if it does not already exist
6803     */
6804    public ExampleScenarioProcessComponent getProcessFirstRep() { 
6805      if (getProcess().isEmpty()) {
6806        addProcess();
6807      }
6808      return getProcess().get(0);
6809    }
6810
6811    /**
6812     * @return {@link #workflow} (Another nested workflow.)
6813     */
6814    public List<CanonicalType> getWorkflow() { 
6815      if (this.workflow == null)
6816        this.workflow = new ArrayList<CanonicalType>();
6817      return this.workflow;
6818    }
6819
6820    /**
6821     * @return Returns a reference to <code>this</code> for easy method chaining
6822     */
6823    public ExampleScenario setWorkflow(List<CanonicalType> theWorkflow) { 
6824      this.workflow = theWorkflow;
6825      return this;
6826    }
6827
6828    public boolean hasWorkflow() { 
6829      if (this.workflow == null)
6830        return false;
6831      for (CanonicalType item : this.workflow)
6832        if (!item.isEmpty())
6833          return true;
6834      return false;
6835    }
6836
6837    /**
6838     * @return {@link #workflow} (Another nested workflow.)
6839     */
6840    public CanonicalType addWorkflowElement() {//2 
6841      CanonicalType t = new CanonicalType();
6842      if (this.workflow == null)
6843        this.workflow = new ArrayList<CanonicalType>();
6844      this.workflow.add(t);
6845      return t;
6846    }
6847
6848    /**
6849     * @param value {@link #workflow} (Another nested workflow.)
6850     */
6851    public ExampleScenario addWorkflow(String value) { //1
6852      CanonicalType t = new CanonicalType();
6853      t.setValue(value);
6854      if (this.workflow == null)
6855        this.workflow = new ArrayList<CanonicalType>();
6856      this.workflow.add(t);
6857      return this;
6858    }
6859
6860    /**
6861     * @param value {@link #workflow} (Another nested workflow.)
6862     */
6863    public boolean hasWorkflow(String value) { 
6864      if (this.workflow == null)
6865        return false;
6866      for (CanonicalType v : this.workflow)
6867        if (v.getValue().equals(value)) // canonical(ExampleScenario)
6868          return true;
6869      return false;
6870    }
6871
6872      protected void listChildren(List<Property> children) {
6873        super.listChildren(children);
6874        children.add(new Property("url", "uri", "An absolute URI that is used to identify this example scenario when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this example scenario is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the example scenario is stored on different servers.", 0, 1, url));
6875        children.add(new Property("identifier", "Identifier", "A formal identifier that is used to identify this example scenario when it is represented in other formats, or referenced in a specification, model, design or an instance.", 0, java.lang.Integer.MAX_VALUE, identifier));
6876        children.add(new Property("version", "string", "The identifier that is used to identify this version of the example scenario when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the example scenario author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.", 0, 1, version));
6877        children.add(new Property("name", "string", "A natural language name identifying the example scenario. This name should be usable as an identifier for the module by machine processing applications such as code generation.", 0, 1, name));
6878        children.add(new Property("status", "code", "The status of this example scenario. Enables tracking the life-cycle of the content.", 0, 1, status));
6879        children.add(new Property("experimental", "boolean", "A Boolean value to indicate that this example scenario is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.", 0, 1, experimental));
6880        children.add(new Property("date", "dateTime", "The date  (and optionally time) when the example scenario was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the example scenario changes. (e.g. the 'content logical definition').", 0, 1, date));
6881        children.add(new Property("publisher", "string", "The name of the organization or individual that published the example scenario.", 0, 1, publisher));
6882        children.add(new Property("contact", "ContactDetail", "Contact details to assist a user in finding and communicating with the publisher.", 0, java.lang.Integer.MAX_VALUE, contact));
6883        children.add(new Property("useContext", "UsageContext", "The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate example scenario instances.", 0, java.lang.Integer.MAX_VALUE, useContext));
6884        children.add(new Property("jurisdiction", "CodeableConcept", "A legal or geographic region in which the example scenario is intended to be used.", 0, java.lang.Integer.MAX_VALUE, jurisdiction));
6885        children.add(new Property("copyright", "markdown", "A copyright statement relating to the example scenario and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the example scenario.", 0, 1, copyright));
6886        children.add(new Property("purpose", "markdown", "What the example scenario resource is created for. This should not be used to show the business purpose of the scenario itself, but the purpose of documenting a scenario.", 0, 1, purpose));
6887        children.add(new Property("actor", "", "Actor participating in the resource.", 0, java.lang.Integer.MAX_VALUE, actor));
6888        children.add(new Property("instance", "", "Each resource and each version that is present in the workflow.", 0, java.lang.Integer.MAX_VALUE, instance));
6889        children.add(new Property("process", "", "Each major process - a group of operations.", 0, java.lang.Integer.MAX_VALUE, process));
6890        children.add(new Property("workflow", "canonical(ExampleScenario)", "Another nested workflow.", 0, java.lang.Integer.MAX_VALUE, workflow));
6891      }
6892
6893      @Override
6894      public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
6895        switch (_hash) {
6896        case 116079: /*url*/  return new Property("url", "uri", "An absolute URI that is used to identify this example scenario when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this example scenario is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the example scenario is stored on different servers.", 0, 1, url);
6897        case -1618432855: /*identifier*/  return new Property("identifier", "Identifier", "A formal identifier that is used to identify this example scenario when it is represented in other formats, or referenced in a specification, model, design or an instance.", 0, java.lang.Integer.MAX_VALUE, identifier);
6898        case 351608024: /*version*/  return new Property("version", "string", "The identifier that is used to identify this version of the example scenario when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the example scenario author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.", 0, 1, version);
6899        case 3373707: /*name*/  return new Property("name", "string", "A natural language name identifying the example scenario. This name should be usable as an identifier for the module by machine processing applications such as code generation.", 0, 1, name);
6900        case -892481550: /*status*/  return new Property("status", "code", "The status of this example scenario. Enables tracking the life-cycle of the content.", 0, 1, status);
6901        case -404562712: /*experimental*/  return new Property("experimental", "boolean", "A Boolean value to indicate that this example scenario is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.", 0, 1, experimental);
6902        case 3076014: /*date*/  return new Property("date", "dateTime", "The date  (and optionally time) when the example scenario was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the example scenario changes. (e.g. the 'content logical definition').", 0, 1, date);
6903        case 1447404028: /*publisher*/  return new Property("publisher", "string", "The name of the organization or individual that published the example scenario.", 0, 1, publisher);
6904        case 951526432: /*contact*/  return new Property("contact", "ContactDetail", "Contact details to assist a user in finding and communicating with the publisher.", 0, java.lang.Integer.MAX_VALUE, contact);
6905        case -669707736: /*useContext*/  return new Property("useContext", "UsageContext", "The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate example scenario instances.", 0, java.lang.Integer.MAX_VALUE, useContext);
6906        case -507075711: /*jurisdiction*/  return new Property("jurisdiction", "CodeableConcept", "A legal or geographic region in which the example scenario is intended to be used.", 0, java.lang.Integer.MAX_VALUE, jurisdiction);
6907        case 1522889671: /*copyright*/  return new Property("copyright", "markdown", "A copyright statement relating to the example scenario and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the example scenario.", 0, 1, copyright);
6908        case -220463842: /*purpose*/  return new Property("purpose", "markdown", "What the example scenario resource is created for. This should not be used to show the business purpose of the scenario itself, but the purpose of documenting a scenario.", 0, 1, purpose);
6909        case 92645877: /*actor*/  return new Property("actor", "", "Actor participating in the resource.", 0, java.lang.Integer.MAX_VALUE, actor);
6910        case 555127957: /*instance*/  return new Property("instance", "", "Each resource and each version that is present in the workflow.", 0, java.lang.Integer.MAX_VALUE, instance);
6911        case -309518737: /*process*/  return new Property("process", "", "Each major process - a group of operations.", 0, java.lang.Integer.MAX_VALUE, process);
6912        case 35379135: /*workflow*/  return new Property("workflow", "canonical(ExampleScenario)", "Another nested workflow.", 0, java.lang.Integer.MAX_VALUE, workflow);
6913        default: return super.getNamedProperty(_hash, _name, _checkValid);
6914        }
6915
6916      }
6917
6918      @Override
6919      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
6920        switch (hash) {
6921        case 116079: /*url*/ return this.url == null ? new Base[0] : new Base[] {this.url}; // UriType
6922        case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier
6923        case 351608024: /*version*/ return this.version == null ? new Base[0] : new Base[] {this.version}; // StringType
6924        case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType
6925        case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<PublicationStatus>
6926        case -404562712: /*experimental*/ return this.experimental == null ? new Base[0] : new Base[] {this.experimental}; // BooleanType
6927        case 3076014: /*date*/ return this.date == null ? new Base[0] : new Base[] {this.date}; // DateTimeType
6928        case 1447404028: /*publisher*/ return this.publisher == null ? new Base[0] : new Base[] {this.publisher}; // StringType
6929        case 951526432: /*contact*/ return this.contact == null ? new Base[0] : this.contact.toArray(new Base[this.contact.size()]); // ContactDetail
6930        case -669707736: /*useContext*/ return this.useContext == null ? new Base[0] : this.useContext.toArray(new Base[this.useContext.size()]); // UsageContext
6931        case -507075711: /*jurisdiction*/ return this.jurisdiction == null ? new Base[0] : this.jurisdiction.toArray(new Base[this.jurisdiction.size()]); // CodeableConcept
6932        case 1522889671: /*copyright*/ return this.copyright == null ? new Base[0] : new Base[] {this.copyright}; // MarkdownType
6933        case -220463842: /*purpose*/ return this.purpose == null ? new Base[0] : new Base[] {this.purpose}; // MarkdownType
6934        case 92645877: /*actor*/ return this.actor == null ? new Base[0] : this.actor.toArray(new Base[this.actor.size()]); // ExampleScenarioActorComponent
6935        case 555127957: /*instance*/ return this.instance == null ? new Base[0] : this.instance.toArray(new Base[this.instance.size()]); // ExampleScenarioInstanceComponent
6936        case -309518737: /*process*/ return this.process == null ? new Base[0] : this.process.toArray(new Base[this.process.size()]); // ExampleScenarioProcessComponent
6937        case 35379135: /*workflow*/ return this.workflow == null ? new Base[0] : this.workflow.toArray(new Base[this.workflow.size()]); // CanonicalType
6938        default: return super.getProperty(hash, name, checkValid);
6939        }
6940
6941      }
6942
6943      @Override
6944      public Base setProperty(int hash, String name, Base value) throws FHIRException {
6945        switch (hash) {
6946        case 116079: // url
6947          this.url = castToUri(value); // UriType
6948          return value;
6949        case -1618432855: // identifier
6950          this.getIdentifier().add(castToIdentifier(value)); // Identifier
6951          return value;
6952        case 351608024: // version
6953          this.version = castToString(value); // StringType
6954          return value;
6955        case 3373707: // name
6956          this.name = castToString(value); // StringType
6957          return value;
6958        case -892481550: // status
6959          value = new PublicationStatusEnumFactory().fromType(castToCode(value));
6960          this.status = (Enumeration) value; // Enumeration<PublicationStatus>
6961          return value;
6962        case -404562712: // experimental
6963          this.experimental = castToBoolean(value); // BooleanType
6964          return value;
6965        case 3076014: // date
6966          this.date = castToDateTime(value); // DateTimeType
6967          return value;
6968        case 1447404028: // publisher
6969          this.publisher = castToString(value); // StringType
6970          return value;
6971        case 951526432: // contact
6972          this.getContact().add(castToContactDetail(value)); // ContactDetail
6973          return value;
6974        case -669707736: // useContext
6975          this.getUseContext().add(castToUsageContext(value)); // UsageContext
6976          return value;
6977        case -507075711: // jurisdiction
6978          this.getJurisdiction().add(castToCodeableConcept(value)); // CodeableConcept
6979          return value;
6980        case 1522889671: // copyright
6981          this.copyright = castToMarkdown(value); // MarkdownType
6982          return value;
6983        case -220463842: // purpose
6984          this.purpose = castToMarkdown(value); // MarkdownType
6985          return value;
6986        case 92645877: // actor
6987          this.getActor().add((ExampleScenarioActorComponent) value); // ExampleScenarioActorComponent
6988          return value;
6989        case 555127957: // instance
6990          this.getInstance().add((ExampleScenarioInstanceComponent) value); // ExampleScenarioInstanceComponent
6991          return value;
6992        case -309518737: // process
6993          this.getProcess().add((ExampleScenarioProcessComponent) value); // ExampleScenarioProcessComponent
6994          return value;
6995        case 35379135: // workflow
6996          this.getWorkflow().add(castToCanonical(value)); // CanonicalType
6997          return value;
6998        default: return super.setProperty(hash, name, value);
6999        }
7000
7001      }
7002
7003      @Override
7004      public Base setProperty(String name, Base value) throws FHIRException {
7005        if (name.equals("url")) {
7006          this.url = castToUri(value); // UriType
7007        } else if (name.equals("identifier")) {
7008          this.getIdentifier().add(castToIdentifier(value));
7009        } else if (name.equals("version")) {
7010          this.version = castToString(value); // StringType
7011        } else if (name.equals("name")) {
7012          this.name = castToString(value); // StringType
7013        } else if (name.equals("status")) {
7014          value = new PublicationStatusEnumFactory().fromType(castToCode(value));
7015          this.status = (Enumeration) value; // Enumeration<PublicationStatus>
7016        } else if (name.equals("experimental")) {
7017          this.experimental = castToBoolean(value); // BooleanType
7018        } else if (name.equals("date")) {
7019          this.date = castToDateTime(value); // DateTimeType
7020        } else if (name.equals("publisher")) {
7021          this.publisher = castToString(value); // StringType
7022        } else if (name.equals("contact")) {
7023          this.getContact().add(castToContactDetail(value));
7024        } else if (name.equals("useContext")) {
7025          this.getUseContext().add(castToUsageContext(value));
7026        } else if (name.equals("jurisdiction")) {
7027          this.getJurisdiction().add(castToCodeableConcept(value));
7028        } else if (name.equals("copyright")) {
7029          this.copyright = castToMarkdown(value); // MarkdownType
7030        } else if (name.equals("purpose")) {
7031          this.purpose = castToMarkdown(value); // MarkdownType
7032        } else if (name.equals("actor")) {
7033          this.getActor().add((ExampleScenarioActorComponent) value);
7034        } else if (name.equals("instance")) {
7035          this.getInstance().add((ExampleScenarioInstanceComponent) value);
7036        } else if (name.equals("process")) {
7037          this.getProcess().add((ExampleScenarioProcessComponent) value);
7038        } else if (name.equals("workflow")) {
7039          this.getWorkflow().add(castToCanonical(value));
7040        } else
7041          return super.setProperty(name, value);
7042        return value;
7043      }
7044
7045      @Override
7046      public Base makeProperty(int hash, String name) throws FHIRException {
7047        switch (hash) {
7048        case 116079:  return getUrlElement();
7049        case -1618432855:  return addIdentifier(); 
7050        case 351608024:  return getVersionElement();
7051        case 3373707:  return getNameElement();
7052        case -892481550:  return getStatusElement();
7053        case -404562712:  return getExperimentalElement();
7054        case 3076014:  return getDateElement();
7055        case 1447404028:  return getPublisherElement();
7056        case 951526432:  return addContact(); 
7057        case -669707736:  return addUseContext(); 
7058        case -507075711:  return addJurisdiction(); 
7059        case 1522889671:  return getCopyrightElement();
7060        case -220463842:  return getPurposeElement();
7061        case 92645877:  return addActor(); 
7062        case 555127957:  return addInstance(); 
7063        case -309518737:  return addProcess(); 
7064        case 35379135:  return addWorkflowElement();
7065        default: return super.makeProperty(hash, name);
7066        }
7067
7068      }
7069
7070      @Override
7071      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
7072        switch (hash) {
7073        case 116079: /*url*/ return new String[] {"uri"};
7074        case -1618432855: /*identifier*/ return new String[] {"Identifier"};
7075        case 351608024: /*version*/ return new String[] {"string"};
7076        case 3373707: /*name*/ return new String[] {"string"};
7077        case -892481550: /*status*/ return new String[] {"code"};
7078        case -404562712: /*experimental*/ return new String[] {"boolean"};
7079        case 3076014: /*date*/ return new String[] {"dateTime"};
7080        case 1447404028: /*publisher*/ return new String[] {"string"};
7081        case 951526432: /*contact*/ return new String[] {"ContactDetail"};
7082        case -669707736: /*useContext*/ return new String[] {"UsageContext"};
7083        case -507075711: /*jurisdiction*/ return new String[] {"CodeableConcept"};
7084        case 1522889671: /*copyright*/ return new String[] {"markdown"};
7085        case -220463842: /*purpose*/ return new String[] {"markdown"};
7086        case 92645877: /*actor*/ return new String[] {};
7087        case 555127957: /*instance*/ return new String[] {};
7088        case -309518737: /*process*/ return new String[] {};
7089        case 35379135: /*workflow*/ return new String[] {"canonical"};
7090        default: return super.getTypesForProperty(hash, name);
7091        }
7092
7093      }
7094
7095      @Override
7096      public Base addChild(String name) throws FHIRException {
7097        if (name.equals("url")) {
7098          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.url");
7099        }
7100        else if (name.equals("identifier")) {
7101          return addIdentifier();
7102        }
7103        else if (name.equals("version")) {
7104          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.version");
7105        }
7106        else if (name.equals("name")) {
7107          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.name");
7108        }
7109        else if (name.equals("status")) {
7110          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.status");
7111        }
7112        else if (name.equals("experimental")) {
7113          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.experimental");
7114        }
7115        else if (name.equals("date")) {
7116          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.date");
7117        }
7118        else if (name.equals("publisher")) {
7119          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.publisher");
7120        }
7121        else if (name.equals("contact")) {
7122          return addContact();
7123        }
7124        else if (name.equals("useContext")) {
7125          return addUseContext();
7126        }
7127        else if (name.equals("jurisdiction")) {
7128          return addJurisdiction();
7129        }
7130        else if (name.equals("copyright")) {
7131          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.copyright");
7132        }
7133        else if (name.equals("purpose")) {
7134          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.purpose");
7135        }
7136        else if (name.equals("actor")) {
7137          return addActor();
7138        }
7139        else if (name.equals("instance")) {
7140          return addInstance();
7141        }
7142        else if (name.equals("process")) {
7143          return addProcess();
7144        }
7145        else if (name.equals("workflow")) {
7146          throw new FHIRException("Cannot call addChild on a primitive type ExampleScenario.workflow");
7147        }
7148        else
7149          return super.addChild(name);
7150      }
7151
7152  public String fhirType() {
7153    return "ExampleScenario";
7154
7155  }
7156
7157      public ExampleScenario copy() {
7158        ExampleScenario dst = new ExampleScenario();
7159        copyValues(dst);
7160        return dst;
7161      }
7162
7163      public void copyValues(ExampleScenario dst) {
7164        super.copyValues(dst);
7165        dst.url = url == null ? null : url.copy();
7166        if (identifier != null) {
7167          dst.identifier = new ArrayList<Identifier>();
7168          for (Identifier i : identifier)
7169            dst.identifier.add(i.copy());
7170        };
7171        dst.version = version == null ? null : version.copy();
7172        dst.name = name == null ? null : name.copy();
7173        dst.status = status == null ? null : status.copy();
7174        dst.experimental = experimental == null ? null : experimental.copy();
7175        dst.date = date == null ? null : date.copy();
7176        dst.publisher = publisher == null ? null : publisher.copy();
7177        if (contact != null) {
7178          dst.contact = new ArrayList<ContactDetail>();
7179          for (ContactDetail i : contact)
7180            dst.contact.add(i.copy());
7181        };
7182        if (useContext != null) {
7183          dst.useContext = new ArrayList<UsageContext>();
7184          for (UsageContext i : useContext)
7185            dst.useContext.add(i.copy());
7186        };
7187        if (jurisdiction != null) {
7188          dst.jurisdiction = new ArrayList<CodeableConcept>();
7189          for (CodeableConcept i : jurisdiction)
7190            dst.jurisdiction.add(i.copy());
7191        };
7192        dst.copyright = copyright == null ? null : copyright.copy();
7193        dst.purpose = purpose == null ? null : purpose.copy();
7194        if (actor != null) {
7195          dst.actor = new ArrayList<ExampleScenarioActorComponent>();
7196          for (ExampleScenarioActorComponent i : actor)
7197            dst.actor.add(i.copy());
7198        };
7199        if (instance != null) {
7200          dst.instance = new ArrayList<ExampleScenarioInstanceComponent>();
7201          for (ExampleScenarioInstanceComponent i : instance)
7202            dst.instance.add(i.copy());
7203        };
7204        if (process != null) {
7205          dst.process = new ArrayList<ExampleScenarioProcessComponent>();
7206          for (ExampleScenarioProcessComponent i : process)
7207            dst.process.add(i.copy());
7208        };
7209        if (workflow != null) {
7210          dst.workflow = new ArrayList<CanonicalType>();
7211          for (CanonicalType i : workflow)
7212            dst.workflow.add(i.copy());
7213        };
7214      }
7215
7216      protected ExampleScenario typedCopy() {
7217        return copy();
7218      }
7219
7220      @Override
7221      public boolean equalsDeep(Base other_) {
7222        if (!super.equalsDeep(other_))
7223          return false;
7224        if (!(other_ instanceof ExampleScenario))
7225          return false;
7226        ExampleScenario o = (ExampleScenario) other_;
7227        return compareDeep(identifier, o.identifier, true) && compareDeep(copyright, o.copyright, true)
7228           && compareDeep(purpose, o.purpose, true) && compareDeep(actor, o.actor, true) && compareDeep(instance, o.instance, true)
7229           && compareDeep(process, o.process, true) && compareDeep(workflow, o.workflow, true);
7230      }
7231
7232      @Override
7233      public boolean equalsShallow(Base other_) {
7234        if (!super.equalsShallow(other_))
7235          return false;
7236        if (!(other_ instanceof ExampleScenario))
7237          return false;
7238        ExampleScenario o = (ExampleScenario) other_;
7239        return compareValues(copyright, o.copyright, true) && compareValues(purpose, o.purpose, true);
7240      }
7241
7242      public boolean isEmpty() {
7243        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, copyright, purpose
7244          , actor, instance, process, workflow);
7245      }
7246
7247  @Override
7248  public ResourceType getResourceType() {
7249    return ResourceType.ExampleScenario;
7250   }
7251
7252 /**
7253   * Search parameter: <b>date</b>
7254   * <p>
7255   * Description: <b>The example scenario publication date</b><br>
7256   * Type: <b>date</b><br>
7257   * Path: <b>ExampleScenario.date</b><br>
7258   * </p>
7259   */
7260  @SearchParamDefinition(name="date", path="ExampleScenario.date", description="The example scenario publication date", type="date" )
7261  public static final String SP_DATE = "date";
7262 /**
7263   * <b>Fluent Client</b> search parameter constant for <b>date</b>
7264   * <p>
7265   * Description: <b>The example scenario publication date</b><br>
7266   * Type: <b>date</b><br>
7267   * Path: <b>ExampleScenario.date</b><br>
7268   * </p>
7269   */
7270  public static final ca.uhn.fhir.rest.gclient.DateClientParam DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_DATE);
7271
7272 /**
7273   * Search parameter: <b>identifier</b>
7274   * <p>
7275   * Description: <b>External identifier for the example scenario</b><br>
7276   * Type: <b>token</b><br>
7277   * Path: <b>ExampleScenario.identifier</b><br>
7278   * </p>
7279   */
7280  @SearchParamDefinition(name="identifier", path="ExampleScenario.identifier", description="External identifier for the example scenario", type="token" )
7281  public static final String SP_IDENTIFIER = "identifier";
7282 /**
7283   * <b>Fluent Client</b> search parameter constant for <b>identifier</b>
7284   * <p>
7285   * Description: <b>External identifier for the example scenario</b><br>
7286   * Type: <b>token</b><br>
7287   * Path: <b>ExampleScenario.identifier</b><br>
7288   * </p>
7289   */
7290  public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER);
7291
7292 /**
7293   * Search parameter: <b>context-type-value</b>
7294   * <p>
7295   * Description: <b>A use context type and value assigned to the example scenario</b><br>
7296   * Type: <b>composite</b><br>
7297   * Path: <b></b><br>
7298   * </p>
7299   */
7300  @SearchParamDefinition(name="context-type-value", path="ExampleScenario.useContext", description="A use context type and value assigned to the example scenario", type="composite", compositeOf={"context-type", "context"} )
7301  public static final String SP_CONTEXT_TYPE_VALUE = "context-type-value";
7302 /**
7303   * <b>Fluent Client</b> search parameter constant for <b>context-type-value</b>
7304   * <p>
7305   * Description: <b>A use context type and value assigned to the example scenario</b><br>
7306   * Type: <b>composite</b><br>
7307   * Path: <b></b><br>
7308   * </p>
7309   */
7310  public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam> CONTEXT_TYPE_VALUE = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam>(SP_CONTEXT_TYPE_VALUE);
7311
7312 /**
7313   * Search parameter: <b>jurisdiction</b>
7314   * <p>
7315   * Description: <b>Intended jurisdiction for the example scenario</b><br>
7316   * Type: <b>token</b><br>
7317   * Path: <b>ExampleScenario.jurisdiction</b><br>
7318   * </p>
7319   */
7320  @SearchParamDefinition(name="jurisdiction", path="ExampleScenario.jurisdiction", description="Intended jurisdiction for the example scenario", type="token" )
7321  public static final String SP_JURISDICTION = "jurisdiction";
7322 /**
7323   * <b>Fluent Client</b> search parameter constant for <b>jurisdiction</b>
7324   * <p>
7325   * Description: <b>Intended jurisdiction for the example scenario</b><br>
7326   * Type: <b>token</b><br>
7327   * Path: <b>ExampleScenario.jurisdiction</b><br>
7328   * </p>
7329   */
7330  public static final ca.uhn.fhir.rest.gclient.TokenClientParam JURISDICTION = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_JURISDICTION);
7331
7332 /**
7333   * Search parameter: <b>context-type</b>
7334   * <p>
7335   * Description: <b>A type of use context assigned to the example scenario</b><br>
7336   * Type: <b>token</b><br>
7337   * Path: <b>ExampleScenario.useContext.code</b><br>
7338   * </p>
7339   */
7340  @SearchParamDefinition(name="context-type", path="ExampleScenario.useContext.code", description="A type of use context assigned to the example scenario", type="token" )
7341  public static final String SP_CONTEXT_TYPE = "context-type";
7342 /**
7343   * <b>Fluent Client</b> search parameter constant for <b>context-type</b>
7344   * <p>
7345   * Description: <b>A type of use context assigned to the example scenario</b><br>
7346   * Type: <b>token</b><br>
7347   * Path: <b>ExampleScenario.useContext.code</b><br>
7348   * </p>
7349   */
7350  public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT_TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CONTEXT_TYPE);
7351
7352 /**
7353   * Search parameter: <b>version</b>
7354   * <p>
7355   * Description: <b>The business version of the example scenario</b><br>
7356   * Type: <b>token</b><br>
7357   * Path: <b>ExampleScenario.version</b><br>
7358   * </p>
7359   */
7360  @SearchParamDefinition(name="version", path="ExampleScenario.version", description="The business version of the example scenario", type="token" )
7361  public static final String SP_VERSION = "version";
7362 /**
7363   * <b>Fluent Client</b> search parameter constant for <b>version</b>
7364   * <p>
7365   * Description: <b>The business version of the example scenario</b><br>
7366   * Type: <b>token</b><br>
7367   * Path: <b>ExampleScenario.version</b><br>
7368   * </p>
7369   */
7370  public static final ca.uhn.fhir.rest.gclient.TokenClientParam VERSION = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_VERSION);
7371
7372 /**
7373   * Search parameter: <b>url</b>
7374   * <p>
7375   * Description: <b>The uri that identifies the example scenario</b><br>
7376   * Type: <b>uri</b><br>
7377   * Path: <b>ExampleScenario.url</b><br>
7378   * </p>
7379   */
7380  @SearchParamDefinition(name="url", path="ExampleScenario.url", description="The uri that identifies the example scenario", type="uri" )
7381  public static final String SP_URL = "url";
7382 /**
7383   * <b>Fluent Client</b> search parameter constant for <b>url</b>
7384   * <p>
7385   * Description: <b>The uri that identifies the example scenario</b><br>
7386   * Type: <b>uri</b><br>
7387   * Path: <b>ExampleScenario.url</b><br>
7388   * </p>
7389   */
7390  public static final ca.uhn.fhir.rest.gclient.UriClientParam URL = new ca.uhn.fhir.rest.gclient.UriClientParam(SP_URL);
7391
7392 /**
7393   * Search parameter: <b>context-quantity</b>
7394   * <p>
7395   * Description: <b>A quantity- or range-valued use context assigned to the example scenario</b><br>
7396   * Type: <b>quantity</b><br>
7397   * Path: <b>ExampleScenario.useContext.valueQuantity, ExampleScenario.useContext.valueRange</b><br>
7398   * </p>
7399   */
7400  @SearchParamDefinition(name="context-quantity", path="(ExampleScenario.useContext.value as Quantity) | (ExampleScenario.useContext.value as Range)", description="A quantity- or range-valued use context assigned to the example scenario", type="quantity" )
7401  public static final String SP_CONTEXT_QUANTITY = "context-quantity";
7402 /**
7403   * <b>Fluent Client</b> search parameter constant for <b>context-quantity</b>
7404   * <p>
7405   * Description: <b>A quantity- or range-valued use context assigned to the example scenario</b><br>
7406   * Type: <b>quantity</b><br>
7407   * Path: <b>ExampleScenario.useContext.valueQuantity, ExampleScenario.useContext.valueRange</b><br>
7408   * </p>
7409   */
7410  public static final ca.uhn.fhir.rest.gclient.QuantityClientParam CONTEXT_QUANTITY = new ca.uhn.fhir.rest.gclient.QuantityClientParam(SP_CONTEXT_QUANTITY);
7411
7412 /**
7413   * Search parameter: <b>name</b>
7414   * <p>
7415   * Description: <b>Computationally friendly name of the example scenario</b><br>
7416   * Type: <b>string</b><br>
7417   * Path: <b>ExampleScenario.name</b><br>
7418   * </p>
7419   */
7420  @SearchParamDefinition(name="name", path="ExampleScenario.name", description="Computationally friendly name of the example scenario", type="string" )
7421  public static final String SP_NAME = "name";
7422 /**
7423   * <b>Fluent Client</b> search parameter constant for <b>name</b>
7424   * <p>
7425   * Description: <b>Computationally friendly name of the example scenario</b><br>
7426   * Type: <b>string</b><br>
7427   * Path: <b>ExampleScenario.name</b><br>
7428   * </p>
7429   */
7430  public static final ca.uhn.fhir.rest.gclient.StringClientParam NAME = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_NAME);
7431
7432 /**
7433   * Search parameter: <b>context</b>
7434   * <p>
7435   * Description: <b>A use context assigned to the example scenario</b><br>
7436   * Type: <b>token</b><br>
7437   * Path: <b>ExampleScenario.useContext.valueCodeableConcept</b><br>
7438   * </p>
7439   */
7440  @SearchParamDefinition(name="context", path="(ExampleScenario.useContext.value as CodeableConcept)", description="A use context assigned to the example scenario", type="token" )
7441  public static final String SP_CONTEXT = "context";
7442 /**
7443   * <b>Fluent Client</b> search parameter constant for <b>context</b>
7444   * <p>
7445   * Description: <b>A use context assigned to the example scenario</b><br>
7446   * Type: <b>token</b><br>
7447   * Path: <b>ExampleScenario.useContext.valueCodeableConcept</b><br>
7448   * </p>
7449   */
7450  public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CONTEXT);
7451
7452 /**
7453   * Search parameter: <b>publisher</b>
7454   * <p>
7455   * Description: <b>Name of the publisher of the example scenario</b><br>
7456   * Type: <b>string</b><br>
7457   * Path: <b>ExampleScenario.publisher</b><br>
7458   * </p>
7459   */
7460  @SearchParamDefinition(name="publisher", path="ExampleScenario.publisher", description="Name of the publisher of the example scenario", type="string" )
7461  public static final String SP_PUBLISHER = "publisher";
7462 /**
7463   * <b>Fluent Client</b> search parameter constant for <b>publisher</b>
7464   * <p>
7465   * Description: <b>Name of the publisher of the example scenario</b><br>
7466   * Type: <b>string</b><br>
7467   * Path: <b>ExampleScenario.publisher</b><br>
7468   * </p>
7469   */
7470  public static final ca.uhn.fhir.rest.gclient.StringClientParam PUBLISHER = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_PUBLISHER);
7471
7472 /**
7473   * Search parameter: <b>context-type-quantity</b>
7474   * <p>
7475   * Description: <b>A use context type and quantity- or range-based value assigned to the example scenario</b><br>
7476   * Type: <b>composite</b><br>
7477   * Path: <b></b><br>
7478   * </p>
7479   */
7480  @SearchParamDefinition(name="context-type-quantity", path="ExampleScenario.useContext", description="A use context type and quantity- or range-based value assigned to the example scenario", type="composite", compositeOf={"context-type", "context-quantity"} )
7481  public static final String SP_CONTEXT_TYPE_QUANTITY = "context-type-quantity";
7482 /**
7483   * <b>Fluent Client</b> search parameter constant for <b>context-type-quantity</b>
7484   * <p>
7485   * Description: <b>A use context type and quantity- or range-based value assigned to the example scenario</b><br>
7486   * Type: <b>composite</b><br>
7487   * Path: <b></b><br>
7488   * </p>
7489   */
7490  public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam> CONTEXT_TYPE_QUANTITY = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam>(SP_CONTEXT_TYPE_QUANTITY);
7491
7492 /**
7493   * Search parameter: <b>status</b>
7494   * <p>
7495   * Description: <b>The current status of the example scenario</b><br>
7496   * Type: <b>token</b><br>
7497   * Path: <b>ExampleScenario.status</b><br>
7498   * </p>
7499   */
7500  @SearchParamDefinition(name="status", path="ExampleScenario.status", description="The current status of the example scenario", type="token" )
7501  public static final String SP_STATUS = "status";
7502 /**
7503   * <b>Fluent Client</b> search parameter constant for <b>status</b>
7504   * <p>
7505   * Description: <b>The current status of the example scenario</b><br>
7506   * Type: <b>token</b><br>
7507   * Path: <b>ExampleScenario.status</b><br>
7508   * </p>
7509   */
7510  public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS);
7511
7512
7513}
7514