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