001package org.hl7.fhir.instance.model.valuesets;
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, Nov 11, 2015 10:54-0500 for FHIR v1.0.2
033
034
035public enum OrganizationType {
036
037        /**
038         * An organization that provides healthcare services.
039         */
040        PROV, 
041        /**
042         * A department or ward within a hospital (Generally is not applicable to top level organizations)
043         */
044        DEPT, 
045        /**
046         * An organizational team is usually a grouping of practitioners that perform a specific function within an organization (which could be a top level organization, or a department).
047         */
048        TEAM, 
049        /**
050         * A political body, often used when including organization records for government bodies such as a Federal Government, State or Local Government.
051         */
052        GOVT, 
053        /**
054         * A company that provides insurance to its subscribers that may include healthcare related policies.
055         */
056        INS, 
057        /**
058         * An educational institution that provides education or research facilities.
059         */
060        EDU, 
061        /**
062         * An organization that is identified as a part of a religious institution.
063         */
064        RELI, 
065        /**
066         * An organization that is identified as a Pharmaceutical/Clinical Research Sponsor.
067         */
068        CRS, 
069        /**
070         * An un-incorporated community group.
071         */
072        CG, 
073        /**
074         * An organization that is a registered business or corporation but not identified by other types.
075         */
076        BUS, 
077        /**
078         * Other type of organization not already specified.
079         */
080        OTHER, 
081        /**
082         * added to help the parsers
083         */
084        NULL;
085        public static OrganizationType fromCode(String codeString) throws Exception {
086            if (codeString == null || "".equals(codeString))
087                return null;
088        if ("prov".equals(codeString))
089          return PROV;
090        if ("dept".equals(codeString))
091          return DEPT;
092        if ("team".equals(codeString))
093          return TEAM;
094        if ("govt".equals(codeString))
095          return GOVT;
096        if ("ins".equals(codeString))
097          return INS;
098        if ("edu".equals(codeString))
099          return EDU;
100        if ("reli".equals(codeString))
101          return RELI;
102        if ("crs".equals(codeString))
103          return CRS;
104        if ("cg".equals(codeString))
105          return CG;
106        if ("bus".equals(codeString))
107          return BUS;
108        if ("other".equals(codeString))
109          return OTHER;
110        throw new Exception("Unknown OrganizationType code '"+codeString+"'");
111        }
112        public String toCode() {
113          switch (this) {
114            case PROV: return "prov";
115            case DEPT: return "dept";
116            case TEAM: return "team";
117            case GOVT: return "govt";
118            case INS: return "ins";
119            case EDU: return "edu";
120            case RELI: return "reli";
121            case CRS: return "crs";
122            case CG: return "cg";
123            case BUS: return "bus";
124            case OTHER: return "other";
125            default: return "?";
126          }
127        }
128        public String getSystem() {
129          return "http://hl7.org/fhir/organization-type";
130        }
131        public String getDefinition() {
132          switch (this) {
133            case PROV: return "An organization that provides healthcare services.";
134            case DEPT: return "A department or ward within a hospital (Generally is not applicable to top level organizations)";
135            case TEAM: return "An organizational team is usually a grouping of practitioners that perform a specific function within an organization (which could be a top level organization, or a department).";
136            case GOVT: return "A political body, often used when including organization records for government bodies such as a Federal Government, State or Local Government.";
137            case INS: return "A company that provides insurance to its subscribers that may include healthcare related policies.";
138            case EDU: return "An educational institution that provides education or research facilities.";
139            case RELI: return "An organization that is identified as a part of a religious institution.";
140            case CRS: return "An organization that is identified as a Pharmaceutical/Clinical Research Sponsor.";
141            case CG: return "An un-incorporated community group.";
142            case BUS: return "An organization that is a registered business or corporation but not identified by other types.";
143            case OTHER: return "Other type of organization not already specified.";
144            default: return "?";
145          }
146        }
147        public String getDisplay() {
148          switch (this) {
149            case PROV: return "Healthcare Provider";
150            case DEPT: return "Hospital Department";
151            case TEAM: return "Organizational team";
152            case GOVT: return "Government";
153            case INS: return "Insurance Company";
154            case EDU: return "Educational Institute";
155            case RELI: return "Religious Institution";
156            case CRS: return "Clinical Research Sponsor";
157            case CG: return "Community Group";
158            case BUS: return "Non-Healthcare Business or Corporation";
159            case OTHER: return "Other";
160            default: return "?";
161          }
162    }
163
164
165}
166