001package org.hl7.fhir.r4.model.codesystems;
002
003
004
005
006/*
007  Copyright (c) 2011+, HL7, Inc.
008  All rights reserved.
009  
010  Redistribution and use in source and binary forms, with or without modification, 
011  are permitted provided that the following conditions are met:
012  
013   * Redistributions of source code must retain the above copyright notice, this 
014     list of conditions and the following disclaimer.
015   * Redistributions in binary form must reproduce the above copyright notice, 
016     this list of conditions and the following disclaimer in the documentation 
017     and/or other materials provided with the distribution.
018   * Neither the name of HL7 nor the names of its contributors may be used to 
019     endorse or promote products derived from this software without specific 
020     prior written permission.
021  
022  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 
023  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 
024  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 
025  IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 
026  INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 
027  NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 
028  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 
029  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 
030  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
031  POSSIBILITY OF SUCH DAMAGE.
032  
033*/
034
035// Generated on Wed, Jan 30, 2019 16:19-0500 for FHIR v4.0.0
036
037
038import org.hl7.fhir.exceptions.FHIRException;
039
040public enum RequestResourceTypes {
041
042        /**
043         * 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).
044         */
045        APPOINTMENT, 
046        /**
047         * A reply to an appointment request for a patient and/or practitioner(s), such as a confirmation or rejection.
048         */
049        APPOINTMENTRESPONSE, 
050        /**
051         * Healthcare plan for patient or group.
052         */
053        CAREPLAN, 
054        /**
055         * Claim, Pre-determination or Pre-authorization.
056         */
057        CLAIM, 
058        /**
059         * A request for information to be sent to a receiver.
060         */
061        COMMUNICATIONREQUEST, 
062        /**
063         * Legal Agreement.
064         */
065        CONTRACT, 
066        /**
067         * Medical device request.
068         */
069        DEVICEREQUEST, 
070        /**
071         * Enrollment request.
072         */
073        ENROLLMENTREQUEST, 
074        /**
075         * Guidance or advice relating to an immunization.
076         */
077        IMMUNIZATIONRECOMMENDATION, 
078        /**
079         * Ordering of medication for patient or group.
080         */
081        MEDICATIONREQUEST, 
082        /**
083         * Diet, formula or nutritional supplement request.
084         */
085        NUTRITIONORDER, 
086        /**
087         * A record of a request for service such as diagnostic investigations, treatments, or operations to be performed.
088         */
089        SERVICEREQUEST, 
090        /**
091         * Request for a medication, substance or device.
092         */
093        SUPPLYREQUEST, 
094        /**
095         * A task to be performed.
096         */
097        TASK, 
098        /**
099         * Prescription for vision correction products for a patient.
100         */
101        VISIONPRESCRIPTION, 
102        /**
103         * added to help the parsers
104         */
105        NULL;
106        public static RequestResourceTypes fromCode(String codeString) throws FHIRException {
107            if (codeString == null || "".equals(codeString))
108                return null;
109        if ("Appointment".equals(codeString))
110          return APPOINTMENT;
111        if ("AppointmentResponse".equals(codeString))
112          return APPOINTMENTRESPONSE;
113        if ("CarePlan".equals(codeString))
114          return CAREPLAN;
115        if ("Claim".equals(codeString))
116          return CLAIM;
117        if ("CommunicationRequest".equals(codeString))
118          return COMMUNICATIONREQUEST;
119        if ("Contract".equals(codeString))
120          return CONTRACT;
121        if ("DeviceRequest".equals(codeString))
122          return DEVICEREQUEST;
123        if ("EnrollmentRequest".equals(codeString))
124          return ENROLLMENTREQUEST;
125        if ("ImmunizationRecommendation".equals(codeString))
126          return IMMUNIZATIONRECOMMENDATION;
127        if ("MedicationRequest".equals(codeString))
128          return MEDICATIONREQUEST;
129        if ("NutritionOrder".equals(codeString))
130          return NUTRITIONORDER;
131        if ("ServiceRequest".equals(codeString))
132          return SERVICEREQUEST;
133        if ("SupplyRequest".equals(codeString))
134          return SUPPLYREQUEST;
135        if ("Task".equals(codeString))
136          return TASK;
137        if ("VisionPrescription".equals(codeString))
138          return VISIONPRESCRIPTION;
139        throw new FHIRException("Unknown RequestResourceTypes code '"+codeString+"'");
140        }
141        public String toCode() {
142          switch (this) {
143            case APPOINTMENT: return "Appointment";
144            case APPOINTMENTRESPONSE: return "AppointmentResponse";
145            case CAREPLAN: return "CarePlan";
146            case CLAIM: return "Claim";
147            case COMMUNICATIONREQUEST: return "CommunicationRequest";
148            case CONTRACT: return "Contract";
149            case DEVICEREQUEST: return "DeviceRequest";
150            case ENROLLMENTREQUEST: return "EnrollmentRequest";
151            case IMMUNIZATIONRECOMMENDATION: return "ImmunizationRecommendation";
152            case MEDICATIONREQUEST: return "MedicationRequest";
153            case NUTRITIONORDER: return "NutritionOrder";
154            case SERVICEREQUEST: return "ServiceRequest";
155            case SUPPLYREQUEST: return "SupplyRequest";
156            case TASK: return "Task";
157            case VISIONPRESCRIPTION: return "VisionPrescription";
158            default: return "?";
159          }
160        }
161        public String getSystem() {
162          return "http://hl7.org/fhir/request-resource-types";
163        }
164        public String getDefinition() {
165          switch (this) {
166            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).";
167            case APPOINTMENTRESPONSE: return "A reply to an appointment request for a patient and/or practitioner(s), such as a confirmation or rejection.";
168            case CAREPLAN: return "Healthcare plan for patient or group.";
169            case CLAIM: return "Claim, Pre-determination or Pre-authorization.";
170            case COMMUNICATIONREQUEST: return "A request for information to be sent to a receiver.";
171            case CONTRACT: return "Legal Agreement.";
172            case DEVICEREQUEST: return "Medical device request.";
173            case ENROLLMENTREQUEST: return "Enrollment request.";
174            case IMMUNIZATIONRECOMMENDATION: return "Guidance or advice relating to an immunization.";
175            case MEDICATIONREQUEST: return "Ordering of medication for patient or group.";
176            case NUTRITIONORDER: return "Diet, formula or nutritional supplement request.";
177            case SERVICEREQUEST: return "A record of a request for service such as diagnostic investigations, treatments, or operations to be performed.";
178            case SUPPLYREQUEST: return "Request for a medication, substance or device.";
179            case TASK: return "A task to be performed.";
180            case VISIONPRESCRIPTION: return "Prescription for vision correction products for a patient.";
181            default: return "?";
182          }
183        }
184        public String getDisplay() {
185          switch (this) {
186            case APPOINTMENT: return "Appointment";
187            case APPOINTMENTRESPONSE: return "AppointmentResponse";
188            case CAREPLAN: return "CarePlan";
189            case CLAIM: return "Claim";
190            case COMMUNICATIONREQUEST: return "CommunicationRequest";
191            case CONTRACT: return "Contract";
192            case DEVICEREQUEST: return "DeviceRequest";
193            case ENROLLMENTREQUEST: return "EnrollmentRequest";
194            case IMMUNIZATIONRECOMMENDATION: return "ImmunizationRecommendation";
195            case MEDICATIONREQUEST: return "MedicationRequest";
196            case NUTRITIONORDER: return "NutritionOrder";
197            case SERVICEREQUEST: return "ServiceRequest";
198            case SUPPLYREQUEST: return "SupplyRequest";
199            case TASK: return "Task";
200            case VISIONPRESCRIPTION: return "VisionPrescription";
201            default: return "?";
202          }
203    }
204
205
206}