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