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.r4.model.EnumFactory;
035
036public class V3ReligiousAffiliationEnumFactory implements EnumFactory<V3ReligiousAffiliation> {
037
038  public V3ReligiousAffiliation fromCode(String codeString) throws IllegalArgumentException {
039    if (codeString == null || "".equals(codeString))
040      return null;
041    if ("1001".equals(codeString))
042      return V3ReligiousAffiliation._1001;
043    if ("1002".equals(codeString))
044      return V3ReligiousAffiliation._1002;
045    if ("1003".equals(codeString))
046      return V3ReligiousAffiliation._1003;
047    if ("1004".equals(codeString))
048      return V3ReligiousAffiliation._1004;
049    if ("1005".equals(codeString))
050      return V3ReligiousAffiliation._1005;
051    if ("1006".equals(codeString))
052      return V3ReligiousAffiliation._1006;
053    if ("1007".equals(codeString))
054      return V3ReligiousAffiliation._1007;
055    if ("1008".equals(codeString))
056      return V3ReligiousAffiliation._1008;
057    if ("1009".equals(codeString))
058      return V3ReligiousAffiliation._1009;
059    if ("1010".equals(codeString))
060      return V3ReligiousAffiliation._1010;
061    if ("1011".equals(codeString))
062      return V3ReligiousAffiliation._1011;
063    if ("1012".equals(codeString))
064      return V3ReligiousAffiliation._1012;
065    if ("1013".equals(codeString))
066      return V3ReligiousAffiliation._1013;
067    if ("1014".equals(codeString))
068      return V3ReligiousAffiliation._1014;
069    if ("1015".equals(codeString))
070      return V3ReligiousAffiliation._1015;
071    if ("1016".equals(codeString))
072      return V3ReligiousAffiliation._1016;
073    if ("1017".equals(codeString))
074      return V3ReligiousAffiliation._1017;
075    if ("1018".equals(codeString))
076      return V3ReligiousAffiliation._1018;
077    if ("1019".equals(codeString))
078      return V3ReligiousAffiliation._1019;
079    if ("1020".equals(codeString))
080      return V3ReligiousAffiliation._1020;
081    if ("1021".equals(codeString))
082      return V3ReligiousAffiliation._1021;
083    if ("1022".equals(codeString))
084      return V3ReligiousAffiliation._1022;
085    if ("1023".equals(codeString))
086      return V3ReligiousAffiliation._1023;
087    if ("1024".equals(codeString))
088      return V3ReligiousAffiliation._1024;
089    if ("1025".equals(codeString))
090      return V3ReligiousAffiliation._1025;
091    if ("1026".equals(codeString))
092      return V3ReligiousAffiliation._1026;
093    if ("1027".equals(codeString))
094      return V3ReligiousAffiliation._1027;
095    if ("1028".equals(codeString))
096      return V3ReligiousAffiliation._1028;
097    if ("1029".equals(codeString))
098      return V3ReligiousAffiliation._1029;
099    if ("1030".equals(codeString))
100      return V3ReligiousAffiliation._1030;
101    if ("1031".equals(codeString))
102      return V3ReligiousAffiliation._1031;
103    if ("1032".equals(codeString))
104      return V3ReligiousAffiliation._1032;
105    if ("1033".equals(codeString))
106      return V3ReligiousAffiliation._1033;
107    if ("1034".equals(codeString))
108      return V3ReligiousAffiliation._1034;
109    if ("1035".equals(codeString))
110      return V3ReligiousAffiliation._1035;
111    if ("1036".equals(codeString))
112      return V3ReligiousAffiliation._1036;
113    if ("1037".equals(codeString))
114      return V3ReligiousAffiliation._1037;
115    if ("1038".equals(codeString))
116      return V3ReligiousAffiliation._1038;
117    if ("1039".equals(codeString))
118      return V3ReligiousAffiliation._1039;
119    if ("1040".equals(codeString))
120      return V3ReligiousAffiliation._1040;
121    if ("1041".equals(codeString))
122      return V3ReligiousAffiliation._1041;
123    if ("1042".equals(codeString))
124      return V3ReligiousAffiliation._1042;
125    if ("1043".equals(codeString))
126      return V3ReligiousAffiliation._1043;
127    if ("1044".equals(codeString))
128      return V3ReligiousAffiliation._1044;
129    if ("1045".equals(codeString))
130      return V3ReligiousAffiliation._1045;
131    if ("1046".equals(codeString))
132      return V3ReligiousAffiliation._1046;
133    if ("1047".equals(codeString))
134      return V3ReligiousAffiliation._1047;
135    if ("1048".equals(codeString))
136      return V3ReligiousAffiliation._1048;
137    if ("1049".equals(codeString))
138      return V3ReligiousAffiliation._1049;
139    if ("1050".equals(codeString))
140      return V3ReligiousAffiliation._1050;
141    if ("1051".equals(codeString))
142      return V3ReligiousAffiliation._1051;
143    if ("1052".equals(codeString))
144      return V3ReligiousAffiliation._1052;
145    if ("1053".equals(codeString))
146      return V3ReligiousAffiliation._1053;
147    if ("1054".equals(codeString))
148      return V3ReligiousAffiliation._1054;
149    if ("1055".equals(codeString))
150      return V3ReligiousAffiliation._1055;
151    if ("1056".equals(codeString))
152      return V3ReligiousAffiliation._1056;
153    if ("1057".equals(codeString))
154      return V3ReligiousAffiliation._1057;
155    if ("1058".equals(codeString))
156      return V3ReligiousAffiliation._1058;
157    if ("1059".equals(codeString))
158      return V3ReligiousAffiliation._1059;
159    if ("1060".equals(codeString))
160      return V3ReligiousAffiliation._1060;
161    if ("1061".equals(codeString))
162      return V3ReligiousAffiliation._1061;
163    if ("1062".equals(codeString))
164      return V3ReligiousAffiliation._1062;
165    if ("1063".equals(codeString))
166      return V3ReligiousAffiliation._1063;
167    if ("1064".equals(codeString))
168      return V3ReligiousAffiliation._1064;
169    if ("1065".equals(codeString))
170      return V3ReligiousAffiliation._1065;
171    if ("1066".equals(codeString))
172      return V3ReligiousAffiliation._1066;
173    if ("1067".equals(codeString))
174      return V3ReligiousAffiliation._1067;
175    if ("1068".equals(codeString))
176      return V3ReligiousAffiliation._1068;
177    if ("1069".equals(codeString))
178      return V3ReligiousAffiliation._1069;
179    if ("1070".equals(codeString))
180      return V3ReligiousAffiliation._1070;
181    if ("1071".equals(codeString))
182      return V3ReligiousAffiliation._1071;
183    if ("1072".equals(codeString))
184      return V3ReligiousAffiliation._1072;
185    if ("1073".equals(codeString))
186      return V3ReligiousAffiliation._1073;
187    if ("1074".equals(codeString))
188      return V3ReligiousAffiliation._1074;
189    if ("1075".equals(codeString))
190      return V3ReligiousAffiliation._1075;
191    if ("1076".equals(codeString))
192      return V3ReligiousAffiliation._1076;
193    if ("1077".equals(codeString))
194      return V3ReligiousAffiliation._1077;
195    if ("1078".equals(codeString))
196      return V3ReligiousAffiliation._1078;
197    if ("1079".equals(codeString))
198      return V3ReligiousAffiliation._1079;
199    if ("1080".equals(codeString))
200      return V3ReligiousAffiliation._1080;
201    if ("1081".equals(codeString))
202      return V3ReligiousAffiliation._1081;
203    if ("1082".equals(codeString))
204      return V3ReligiousAffiliation._1082;
205    throw new IllegalArgumentException("Unknown V3ReligiousAffiliation code '" + codeString + "'");
206  }
207
208  public String toCode(V3ReligiousAffiliation code) {
209       if (code == V3ReligiousAffiliation.NULL)
210           return null;
211       if (code == V3ReligiousAffiliation._1001)
212      return "1001";
213    if (code == V3ReligiousAffiliation._1002)
214      return "1002";
215    if (code == V3ReligiousAffiliation._1003)
216      return "1003";
217    if (code == V3ReligiousAffiliation._1004)
218      return "1004";
219    if (code == V3ReligiousAffiliation._1005)
220      return "1005";
221    if (code == V3ReligiousAffiliation._1006)
222      return "1006";
223    if (code == V3ReligiousAffiliation._1007)
224      return "1007";
225    if (code == V3ReligiousAffiliation._1008)
226      return "1008";
227    if (code == V3ReligiousAffiliation._1009)
228      return "1009";
229    if (code == V3ReligiousAffiliation._1010)
230      return "1010";
231    if (code == V3ReligiousAffiliation._1011)
232      return "1011";
233    if (code == V3ReligiousAffiliation._1012)
234      return "1012";
235    if (code == V3ReligiousAffiliation._1013)
236      return "1013";
237    if (code == V3ReligiousAffiliation._1014)
238      return "1014";
239    if (code == V3ReligiousAffiliation._1015)
240      return "1015";
241    if (code == V3ReligiousAffiliation._1016)
242      return "1016";
243    if (code == V3ReligiousAffiliation._1017)
244      return "1017";
245    if (code == V3ReligiousAffiliation._1018)
246      return "1018";
247    if (code == V3ReligiousAffiliation._1019)
248      return "1019";
249    if (code == V3ReligiousAffiliation._1020)
250      return "1020";
251    if (code == V3ReligiousAffiliation._1021)
252      return "1021";
253    if (code == V3ReligiousAffiliation._1022)
254      return "1022";
255    if (code == V3ReligiousAffiliation._1023)
256      return "1023";
257    if (code == V3ReligiousAffiliation._1024)
258      return "1024";
259    if (code == V3ReligiousAffiliation._1025)
260      return "1025";
261    if (code == V3ReligiousAffiliation._1026)
262      return "1026";
263    if (code == V3ReligiousAffiliation._1027)
264      return "1027";
265    if (code == V3ReligiousAffiliation._1028)
266      return "1028";
267    if (code == V3ReligiousAffiliation._1029)
268      return "1029";
269    if (code == V3ReligiousAffiliation._1030)
270      return "1030";
271    if (code == V3ReligiousAffiliation._1031)
272      return "1031";
273    if (code == V3ReligiousAffiliation._1032)
274      return "1032";
275    if (code == V3ReligiousAffiliation._1033)
276      return "1033";
277    if (code == V3ReligiousAffiliation._1034)
278      return "1034";
279    if (code == V3ReligiousAffiliation._1035)
280      return "1035";
281    if (code == V3ReligiousAffiliation._1036)
282      return "1036";
283    if (code == V3ReligiousAffiliation._1037)
284      return "1037";
285    if (code == V3ReligiousAffiliation._1038)
286      return "1038";
287    if (code == V3ReligiousAffiliation._1039)
288      return "1039";
289    if (code == V3ReligiousAffiliation._1040)
290      return "1040";
291    if (code == V3ReligiousAffiliation._1041)
292      return "1041";
293    if (code == V3ReligiousAffiliation._1042)
294      return "1042";
295    if (code == V3ReligiousAffiliation._1043)
296      return "1043";
297    if (code == V3ReligiousAffiliation._1044)
298      return "1044";
299    if (code == V3ReligiousAffiliation._1045)
300      return "1045";
301    if (code == V3ReligiousAffiliation._1046)
302      return "1046";
303    if (code == V3ReligiousAffiliation._1047)
304      return "1047";
305    if (code == V3ReligiousAffiliation._1048)
306      return "1048";
307    if (code == V3ReligiousAffiliation._1049)
308      return "1049";
309    if (code == V3ReligiousAffiliation._1050)
310      return "1050";
311    if (code == V3ReligiousAffiliation._1051)
312      return "1051";
313    if (code == V3ReligiousAffiliation._1052)
314      return "1052";
315    if (code == V3ReligiousAffiliation._1053)
316      return "1053";
317    if (code == V3ReligiousAffiliation._1054)
318      return "1054";
319    if (code == V3ReligiousAffiliation._1055)
320      return "1055";
321    if (code == V3ReligiousAffiliation._1056)
322      return "1056";
323    if (code == V3ReligiousAffiliation._1057)
324      return "1057";
325    if (code == V3ReligiousAffiliation._1058)
326      return "1058";
327    if (code == V3ReligiousAffiliation._1059)
328      return "1059";
329    if (code == V3ReligiousAffiliation._1060)
330      return "1060";
331    if (code == V3ReligiousAffiliation._1061)
332      return "1061";
333    if (code == V3ReligiousAffiliation._1062)
334      return "1062";
335    if (code == V3ReligiousAffiliation._1063)
336      return "1063";
337    if (code == V3ReligiousAffiliation._1064)
338      return "1064";
339    if (code == V3ReligiousAffiliation._1065)
340      return "1065";
341    if (code == V3ReligiousAffiliation._1066)
342      return "1066";
343    if (code == V3ReligiousAffiliation._1067)
344      return "1067";
345    if (code == V3ReligiousAffiliation._1068)
346      return "1068";
347    if (code == V3ReligiousAffiliation._1069)
348      return "1069";
349    if (code == V3ReligiousAffiliation._1070)
350      return "1070";
351    if (code == V3ReligiousAffiliation._1071)
352      return "1071";
353    if (code == V3ReligiousAffiliation._1072)
354      return "1072";
355    if (code == V3ReligiousAffiliation._1073)
356      return "1073";
357    if (code == V3ReligiousAffiliation._1074)
358      return "1074";
359    if (code == V3ReligiousAffiliation._1075)
360      return "1075";
361    if (code == V3ReligiousAffiliation._1076)
362      return "1076";
363    if (code == V3ReligiousAffiliation._1077)
364      return "1077";
365    if (code == V3ReligiousAffiliation._1078)
366      return "1078";
367    if (code == V3ReligiousAffiliation._1079)
368      return "1079";
369    if (code == V3ReligiousAffiliation._1080)
370      return "1080";
371    if (code == V3ReligiousAffiliation._1081)
372      return "1081";
373    if (code == V3ReligiousAffiliation._1082)
374      return "1082";
375    return "?";
376   }
377
378  public String toSystem(V3ReligiousAffiliation code) {
379    return code.getSystem();
380  }
381
382}