001package org.hl7.fhir.dstu2016may.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 Sun, May 8, 2016 03:05+1000 for FHIR v1.4.0 036 037 038import org.hl7.fhir.exceptions.FHIRException; 039 040public enum HspcObservationWeightPrecond { 041 042 /** 043 * Body weight measured while clothed 044 */ 045 _84123, 046 /** 047 * Body weight measured while unclothed 048 */ 049 _84124, 050 /** 051 * Infant weight while wearing a diaper 052 */ 053 _84127, 054 /** 055 * Infant weight without a diaper 056 */ 057 _84128, 058 /** 059 * Body weight that includes a cast 060 */ 061 _84129, 062 /** 063 * Body weight minus the weight of a cast 064 */ 065 _84130, 066 /** 067 * Body weight including a prosthetic limb 068 */ 069 _84131, 070 /** 071 * Body weight minus the weight of a prosthetic limb 072 */ 073 _84132, 074 /** 075 * Body weight including a brace 076 */ 077 _84133, 078 /** 079 * Body weight minus the weight of a brace 080 */ 081 _84134, 082 /** 083 * Body weight including a gown or drape 084 */ 085 _84135, 086 /** 087 * Body weight the includes some other weight 088 */ 089 _84136, 090 /** 091 * Body weight after subtracting some other included weight 092 */ 093 _84137, 094 /** 095 * added to help the parsers 096 */ 097 NULL; 098 public static HspcObservationWeightPrecond fromCode(String codeString) throws FHIRException { 099 if (codeString == null || "".equals(codeString)) 100 return null; 101 if ("84123".equals(codeString)) 102 return _84123; 103 if ("84124".equals(codeString)) 104 return _84124; 105 if ("84127".equals(codeString)) 106 return _84127; 107 if ("84128".equals(codeString)) 108 return _84128; 109 if ("84129".equals(codeString)) 110 return _84129; 111 if ("84130".equals(codeString)) 112 return _84130; 113 if ("84131".equals(codeString)) 114 return _84131; 115 if ("84132".equals(codeString)) 116 return _84132; 117 if ("84133".equals(codeString)) 118 return _84133; 119 if ("84134".equals(codeString)) 120 return _84134; 121 if ("84135".equals(codeString)) 122 return _84135; 123 if ("84136".equals(codeString)) 124 return _84136; 125 if ("84137".equals(codeString)) 126 return _84137; 127 throw new FHIRException("Unknown HspcObservationWeightPrecond code '"+codeString+"'"); 128 } 129 public String toCode() { 130 switch (this) { 131 case _84123: return "84123"; 132 case _84124: return "84124"; 133 case _84127: return "84127"; 134 case _84128: return "84128"; 135 case _84129: return "84129"; 136 case _84130: return "84130"; 137 case _84131: return "84131"; 138 case _84132: return "84132"; 139 case _84133: return "84133"; 140 case _84134: return "84134"; 141 case _84135: return "84135"; 142 case _84136: return "84136"; 143 case _84137: return "84137"; 144 case NULL: return null; 145 default: return "?"; 146 } 147 } 148 public String getSystem() { 149 return "http://hl7.org/fhir/observation-hspc-weightPrecond"; 150 } 151 public String getDefinition() { 152 switch (this) { 153 case _84123: return "Body weight measured while clothed"; 154 case _84124: return "Body weight measured while unclothed"; 155 case _84127: return "Infant weight while wearing a diaper"; 156 case _84128: return "Infant weight without a diaper"; 157 case _84129: return "Body weight that includes a cast"; 158 case _84130: return "Body weight minus the weight of a cast"; 159 case _84131: return "Body weight including a prosthetic limb"; 160 case _84132: return "Body weight minus the weight of a prosthetic limb"; 161 case _84133: return "Body weight including a brace"; 162 case _84134: return "Body weight minus the weight of a brace"; 163 case _84135: return "Body weight including a gown or drape"; 164 case _84136: return "Body weight the includes some other weight"; 165 case _84137: return "Body weight after subtracting some other included weight"; 166 case NULL: return null; 167 default: return "?"; 168 } 169 } 170 public String getDisplay() { 171 switch (this) { 172 case _84123: return "Weight with street clothes"; 173 case _84124: return "Weight without street clothes"; 174 case _84127: return "Weight with diapers"; 175 case _84128: return "Weight without diapers"; 176 case _84129: return "Weight with cast"; 177 case _84130: return "Weight without cast"; 178 case _84131: return "Weight with limb prosthesis"; 179 case _84132: return "Weight without limb prosthesis"; 180 case _84133: return "Weight with brace"; 181 case _84134: return "Weight without brace"; 182 case _84135: return "Weight with gown or drape"; 183 case _84136: return "Weight with added-on weight"; 184 case _84137: return "Weight without added-on weight"; 185 case NULL: return null; 186 default: return "?"; 187 } 188 } 189 190 191}