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 V3EntityNameUse {
036
037        /**
038         * Identifies the different representations of a name.  The representation may affect how the name is used.  (E.g. use of Ideographic for formal communications.)
039         */
040        _NAMEREPRESENTATIONUSE, 
041        /**
042         * Alphabetic transcription of name (Japanese: romaji)
043         */
044        ABC, 
045        /**
046         * Ideographic representation of name (e.g. Japanese kanji, Chinese characters)
047         */
048        IDE, 
049        /**
050         * Syllabic transcription of name (e.g. Japanese kana, Korean hangul)
051         */
052        SYL, 
053        /**
054         * A name assigned to a person. Reasons some organizations assign alternate names may include not knowing the person's name, or to maintain anonymity. Some, but not necessarily all, of the name types that people call "alias" may fit into this category.
055         */
056        ASGN, 
057        /**
058         * As recorded on a license, record, certificate, etc. (only if different from legal name)
059         */
060        C, 
061        /**
062         * e.g. Chief Red Cloud
063         */
064        I, 
065        /**
066         * Known as/conventional/the one you use
067         */
068        L, 
069        /**
070         * Definition:The formal name as registered in an official (government) registry, but which name might not be commonly used. Particularly used in countries with a law system based on Napoleonic law.
071         */
072        OR, 
073        /**
074         * A self asserted name that the person is using or has used.
075         */
076        P, 
077        /**
078         * Includes writer's pseudonym, stage name, etc.
079         */
080        A, 
081        /**
082         * e.g. Sister Mary Francis, Brother John
083         */
084        R, 
085        /**
086         * A name intended for use in searching or matching.
087         */
088        SRCH, 
089        /**
090         * A name spelled phonetically.
091
092                        There are a variety of phonetic spelling algorithms. This code value does not distinguish between these.Discussion:
093         */
094        PHON, 
095        /**
096         * A name spelled according to the SoundEx algorithm.
097         */
098        SNDX, 
099        /**
100         * added to help the parsers
101         */
102        NULL;
103        public static V3EntityNameUse fromCode(String codeString) throws Exception {
104            if (codeString == null || "".equals(codeString))
105                return null;
106        if ("_NameRepresentationUse".equals(codeString))
107          return _NAMEREPRESENTATIONUSE;
108        if ("ABC".equals(codeString))
109          return ABC;
110        if ("IDE".equals(codeString))
111          return IDE;
112        if ("SYL".equals(codeString))
113          return SYL;
114        if ("ASGN".equals(codeString))
115          return ASGN;
116        if ("C".equals(codeString))
117          return C;
118        if ("I".equals(codeString))
119          return I;
120        if ("L".equals(codeString))
121          return L;
122        if ("OR".equals(codeString))
123          return OR;
124        if ("P".equals(codeString))
125          return P;
126        if ("A".equals(codeString))
127          return A;
128        if ("R".equals(codeString))
129          return R;
130        if ("SRCH".equals(codeString))
131          return SRCH;
132        if ("PHON".equals(codeString))
133          return PHON;
134        if ("SNDX".equals(codeString))
135          return SNDX;
136        throw new Exception("Unknown V3EntityNameUse code '"+codeString+"'");
137        }
138        public String toCode() {
139          switch (this) {
140            case _NAMEREPRESENTATIONUSE: return "_NameRepresentationUse";
141            case ABC: return "ABC";
142            case IDE: return "IDE";
143            case SYL: return "SYL";
144            case ASGN: return "ASGN";
145            case C: return "C";
146            case I: return "I";
147            case L: return "L";
148            case OR: return "OR";
149            case P: return "P";
150            case A: return "A";
151            case R: return "R";
152            case SRCH: return "SRCH";
153            case PHON: return "PHON";
154            case SNDX: return "SNDX";
155            default: return "?";
156          }
157        }
158        public String getSystem() {
159          return "http://hl7.org/fhir/v3/EntityNameUse";
160        }
161        public String getDefinition() {
162          switch (this) {
163            case _NAMEREPRESENTATIONUSE: return "Identifies the different representations of a name.  The representation may affect how the name is used.  (E.g. use of Ideographic for formal communications.)";
164            case ABC: return "Alphabetic transcription of name (Japanese: romaji)";
165            case IDE: return "Ideographic representation of name (e.g. Japanese kanji, Chinese characters)";
166            case SYL: return "Syllabic transcription of name (e.g. Japanese kana, Korean hangul)";
167            case ASGN: return "A name assigned to a person. Reasons some organizations assign alternate names may include not knowing the person's name, or to maintain anonymity. Some, but not necessarily all, of the name types that people call \"alias\" may fit into this category.";
168            case C: return "As recorded on a license, record, certificate, etc. (only if different from legal name)";
169            case I: return "e.g. Chief Red Cloud";
170            case L: return "Known as/conventional/the one you use";
171            case OR: return "Definition:The formal name as registered in an official (government) registry, but which name might not be commonly used. Particularly used in countries with a law system based on Napoleonic law.";
172            case P: return "A self asserted name that the person is using or has used.";
173            case A: return "Includes writer's pseudonym, stage name, etc.";
174            case R: return "e.g. Sister Mary Francis, Brother John";
175            case SRCH: return "A name intended for use in searching or matching.";
176            case PHON: return "A name spelled phonetically.\r\n\n                        There are a variety of phonetic spelling algorithms. This code value does not distinguish between these.Discussion:";
177            case SNDX: return "A name spelled according to the SoundEx algorithm.";
178            default: return "?";
179          }
180        }
181        public String getDisplay() {
182          switch (this) {
183            case _NAMEREPRESENTATIONUSE: return "NameRepresentationUse";
184            case ABC: return "Alphabetic";
185            case IDE: return "Ideographic";
186            case SYL: return "Syllabic";
187            case ASGN: return "assigned";
188            case C: return "License";
189            case I: return "Indigenous/Tribal";
190            case L: return "Legal";
191            case OR: return "official registry";
192            case P: return "pseudonym";
193            case A: return "Artist/Stage";
194            case R: return "Religious";
195            case SRCH: return "search";
196            case PHON: return "phonetic";
197            case SNDX: return "Soundex";
198            default: return "?";
199          }
200    }
201
202
203}
204