001package org.hl7.fhir.r4.model.codesystems;
002
003/*
004  Copyright (c) 2011+, HL7, Inc.
005  All rights reserved.
006  
007  Redistribution and use in source and binary forms, with or without modification, 
008  are permitted provided that the following conditions are met:
009  
010   * Redistributions of source code must retain the above copyright notice, this 
011     list of conditions and the following disclaimer.
012   * Redistributions in binary form must reproduce the above copyright notice, 
013     this list of conditions and the following disclaimer in the documentation 
014     and/or other materials provided with the distribution.
015   * Neither the name of HL7 nor the names of its contributors may be used to 
016     endorse or promote products derived from this software without specific 
017     prior written permission.
018  
019  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 
020  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 
021  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 
022  IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 
023  INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 
024  NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 
025  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 
026  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 
027  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
028  POSSIBILITY OF SUCH DAMAGE.
029  
030*/
031
032// Generated on Wed, Jan 30, 2019 16:19-0500 for FHIR v4.0.0
033
034import org.hl7.fhir.exceptions.FHIRException;
035
036public enum ExRevenueCenter {
037
038  /**
039   * Anaesthesia.
040   */
041  _0370,
042  /**
043   * Physical Therapy.
044   */
045  _0420,
046  /**
047   * Physical Therapy - visit charge.
048   */
049  _0421,
050  /**
051   * Speech-Language Pathology.
052   */
053  _0440,
054  /**
055   * Speech-Language Pathology- visit charge
056   */
057  _0441,
058  /**
059   * Emergency Room
060   */
061  _0450,
062  /**
063   * Emergency Room - EM/EMTALA
064   */
065  _0451,
066  /**
067   * Emergency Room - beyond EMTALA
068   */
069  _0452,
070  /**
071   * Vision Clinic
072   */
073  _0010,
074  /**
075   * added to help the parsers
076   */
077  NULL;
078
079  public static ExRevenueCenter fromCode(String codeString) throws FHIRException {
080    if (codeString == null || "".equals(codeString))
081      return null;
082    if ("0370".equals(codeString))
083      return _0370;
084    if ("0420".equals(codeString))
085      return _0420;
086    if ("0421".equals(codeString))
087      return _0421;
088    if ("0440".equals(codeString))
089      return _0440;
090    if ("0441".equals(codeString))
091      return _0441;
092    if ("0450".equals(codeString))
093      return _0450;
094    if ("0451".equals(codeString))
095      return _0451;
096    if ("0452".equals(codeString))
097      return _0452;
098    if ("0010".equals(codeString))
099      return _0010;
100    throw new FHIRException("Unknown ExRevenueCenter code '" + codeString + "'");
101  }
102
103  public String toCode() {
104    switch (this) {
105    case _0370:
106      return "0370";
107    case _0420:
108      return "0420";
109    case _0421:
110      return "0421";
111    case _0440:
112      return "0440";
113    case _0441:
114      return "0441";
115    case _0450:
116      return "0450";
117    case _0451:
118      return "0451";
119    case _0452:
120      return "0452";
121    case _0010:
122      return "0010";
123    case NULL:
124      return null;
125    default:
126      return "?";
127    }
128  }
129
130  public String getSystem() {
131    return "http://terminology.hl7.org/CodeSystem/ex-revenue-center";
132  }
133
134  public String getDefinition() {
135    switch (this) {
136    case _0370:
137      return "Anaesthesia.";
138    case _0420:
139      return "Physical Therapy.";
140    case _0421:
141      return "Physical Therapy - visit charge.";
142    case _0440:
143      return "Speech-Language Pathology.";
144    case _0441:
145      return "Speech-Language Pathology- visit charge";
146    case _0450:
147      return "Emergency Room";
148    case _0451:
149      return "Emergency Room - EM/EMTALA";
150    case _0452:
151      return "Emergency Room - beyond EMTALA";
152    case _0010:
153      return "Vision Clinic";
154    case NULL:
155      return null;
156    default:
157      return "?";
158    }
159  }
160
161  public String getDisplay() {
162    switch (this) {
163    case _0370:
164      return "Anaesthesia";
165    case _0420:
166      return "Physical Therapy";
167    case _0421:
168      return "Physical Therapy - ";
169    case _0440:
170      return "Speech-Language Pathology";
171    case _0441:
172      return "Speech-Language Pathology - Visit";
173    case _0450:
174      return "Emergency Room";
175    case _0451:
176      return "Emergency Room - EM/EMTALA";
177    case _0452:
178      return "Emergency Room - beyond EMTALA";
179    case _0010:
180      return "Vision Clinic";
181    case NULL:
182      return null;
183    default:
184      return "?";
185    }
186  }
187
188}