001package org.hl7.fhir.dstu3.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 Sat, Mar 25, 2017 21:03-0400 for FHIR v3.0.0
036
037
038import org.hl7.fhir.dstu3.model.EnumFactory;
039
040public class V3VaccineManufacturerEnumFactory implements EnumFactory<V3VaccineManufacturer> {
041
042  public V3VaccineManufacturer fromCode(String codeString) throws IllegalArgumentException {
043    if (codeString == null || "".equals(codeString))
044      return null;
045    if ("AB".equals(codeString))
046      return V3VaccineManufacturer.AB;
047    if ("AD".equals(codeString))
048      return V3VaccineManufacturer.AD;
049    if ("ALP".equals(codeString))
050      return V3VaccineManufacturer.ALP;
051    if ("AR".equals(codeString))
052      return V3VaccineManufacturer.AR;
053    if ("AVI".equals(codeString))
054      return V3VaccineManufacturer.AVI;
055    if ("BA".equals(codeString))
056      return V3VaccineManufacturer.BA;
057    if ("BAY".equals(codeString))
058      return V3VaccineManufacturer.BAY;
059    if ("BP".equals(codeString))
060      return V3VaccineManufacturer.BP;
061    if ("BPC".equals(codeString))
062      return V3VaccineManufacturer.BPC;
063    if ("CEN".equals(codeString))
064      return V3VaccineManufacturer.CEN;
065    if ("CHI".equals(codeString))
066      return V3VaccineManufacturer.CHI;
067    if ("CON".equals(codeString))
068      return V3VaccineManufacturer.CON;
069    if ("EVN".equals(codeString))
070      return V3VaccineManufacturer.EVN;
071    if ("GRE".equals(codeString))
072      return V3VaccineManufacturer.GRE;
073    if ("IAG".equals(codeString))
074      return V3VaccineManufacturer.IAG;
075    if ("IM".equals(codeString))
076      return V3VaccineManufacturer.IM;
077    if ("IUS".equals(codeString))
078      return V3VaccineManufacturer.IUS;
079    if ("JPN".equals(codeString))
080      return V3VaccineManufacturer.JPN;
081    if ("KGC".equals(codeString))
082      return V3VaccineManufacturer.KGC;
083    if ("LED".equals(codeString))
084      return V3VaccineManufacturer.LED;
085    if ("MA".equals(codeString))
086      return V3VaccineManufacturer.MA;
087    if ("MED".equals(codeString))
088      return V3VaccineManufacturer.MED;
089    if ("MIL".equals(codeString))
090      return V3VaccineManufacturer.MIL;
091    if ("MIP".equals(codeString))
092      return V3VaccineManufacturer.MIP;
093    if ("MSD".equals(codeString))
094      return V3VaccineManufacturer.MSD;
095    if ("NAB".equals(codeString))
096      return V3VaccineManufacturer.NAB;
097    if ("NAV".equals(codeString))
098      return V3VaccineManufacturer.NAV;
099    if ("NOV".equals(codeString))
100      return V3VaccineManufacturer.NOV;
101    if ("NYB".equals(codeString))
102      return V3VaccineManufacturer.NYB;
103    if ("ORT".equals(codeString))
104      return V3VaccineManufacturer.ORT;
105    if ("OTC".equals(codeString))
106      return V3VaccineManufacturer.OTC;
107    if ("PD".equals(codeString))
108      return V3VaccineManufacturer.PD;
109    if ("PMC".equals(codeString))
110      return V3VaccineManufacturer.PMC;
111    if ("PRX".equals(codeString))
112      return V3VaccineManufacturer.PRX;
113    if ("SCL".equals(codeString))
114      return V3VaccineManufacturer.SCL;
115    if ("SI".equals(codeString))
116      return V3VaccineManufacturer.SI;
117    if ("SKB".equals(codeString))
118      return V3VaccineManufacturer.SKB;
119    if ("USA".equals(codeString))
120      return V3VaccineManufacturer.USA;
121    if ("WA".equals(codeString))
122      return V3VaccineManufacturer.WA;
123    if ("WAL".equals(codeString))
124      return V3VaccineManufacturer.WAL;
125    throw new IllegalArgumentException("Unknown V3VaccineManufacturer code '"+codeString+"'");
126  }
127
128  public String toCode(V3VaccineManufacturer code) {
129       if (code == V3VaccineManufacturer.NULL)
130           return null;
131       if (code == V3VaccineManufacturer.AB)
132      return "AB";
133    if (code == V3VaccineManufacturer.AD)
134      return "AD";
135    if (code == V3VaccineManufacturer.ALP)
136      return "ALP";
137    if (code == V3VaccineManufacturer.AR)
138      return "AR";
139    if (code == V3VaccineManufacturer.AVI)
140      return "AVI";
141    if (code == V3VaccineManufacturer.BA)
142      return "BA";
143    if (code == V3VaccineManufacturer.BAY)
144      return "BAY";
145    if (code == V3VaccineManufacturer.BP)
146      return "BP";
147    if (code == V3VaccineManufacturer.BPC)
148      return "BPC";
149    if (code == V3VaccineManufacturer.CEN)
150      return "CEN";
151    if (code == V3VaccineManufacturer.CHI)
152      return "CHI";
153    if (code == V3VaccineManufacturer.CON)
154      return "CON";
155    if (code == V3VaccineManufacturer.EVN)
156      return "EVN";
157    if (code == V3VaccineManufacturer.GRE)
158      return "GRE";
159    if (code == V3VaccineManufacturer.IAG)
160      return "IAG";
161    if (code == V3VaccineManufacturer.IM)
162      return "IM";
163    if (code == V3VaccineManufacturer.IUS)
164      return "IUS";
165    if (code == V3VaccineManufacturer.JPN)
166      return "JPN";
167    if (code == V3VaccineManufacturer.KGC)
168      return "KGC";
169    if (code == V3VaccineManufacturer.LED)
170      return "LED";
171    if (code == V3VaccineManufacturer.MA)
172      return "MA";
173    if (code == V3VaccineManufacturer.MED)
174      return "MED";
175    if (code == V3VaccineManufacturer.MIL)
176      return "MIL";
177    if (code == V3VaccineManufacturer.MIP)
178      return "MIP";
179    if (code == V3VaccineManufacturer.MSD)
180      return "MSD";
181    if (code == V3VaccineManufacturer.NAB)
182      return "NAB";
183    if (code == V3VaccineManufacturer.NAV)
184      return "NAV";
185    if (code == V3VaccineManufacturer.NOV)
186      return "NOV";
187    if (code == V3VaccineManufacturer.NYB)
188      return "NYB";
189    if (code == V3VaccineManufacturer.ORT)
190      return "ORT";
191    if (code == V3VaccineManufacturer.OTC)
192      return "OTC";
193    if (code == V3VaccineManufacturer.PD)
194      return "PD";
195    if (code == V3VaccineManufacturer.PMC)
196      return "PMC";
197    if (code == V3VaccineManufacturer.PRX)
198      return "PRX";
199    if (code == V3VaccineManufacturer.SCL)
200      return "SCL";
201    if (code == V3VaccineManufacturer.SI)
202      return "SI";
203    if (code == V3VaccineManufacturer.SKB)
204      return "SKB";
205    if (code == V3VaccineManufacturer.USA)
206      return "USA";
207    if (code == V3VaccineManufacturer.WA)
208      return "WA";
209    if (code == V3VaccineManufacturer.WAL)
210      return "WAL";
211    return "?";
212   }
213
214    public String toSystem(V3VaccineManufacturer code) {
215      return code.getSystem();
216      }
217
218}