001package org.hl7.fhir.r5.model.codesystems; 002 003/* 004 * #%L 005 * org.hl7.fhir.r5 006 * %% 007 * Copyright (C) 2014 - 2019 Health Level 7 008 * %% 009 * Licensed under the Apache License, Version 2.0 (the "License"); 010 * you may not use this file except in compliance with the License. 011 * You may obtain a copy of the License at 012 * 013 * http://www.apache.org/licenses/LICENSE-2.0 014 * 015 * Unless required by applicable law or agreed to in writing, software 016 * distributed under the License is distributed on an "AS IS" BASIS, 017 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 018 * See the License for the specific language governing permissions and 019 * limitations under the License. 020 * #L% 021 */ 022 023/* 024 Copyright (c) 2011+, HL7, Inc. 025 All rights reserved. 026 027 Redistribution and use in source and binary forms, with or without modification, 028 are permitted provided that the following conditions are met: 029 030 * Redistributions of source code must retain the above copyright notice, this 031 list of conditions and the following disclaimer. 032 * Redistributions in binary form must reproduce the above copyright notice, 033 this list of conditions and the following disclaimer in the documentation 034 and/or other materials provided with the distribution. 035 * Neither the name of HL7 nor the names of its contributors may be used to 036 endorse or promote products derived from this software without specific 037 prior written permission. 038 039 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 040 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 041 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 042 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 043 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 044 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 045 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 046 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 047 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 048 POSSIBILITY OF SUCH DAMAGE. 049 050*/ 051 052// Generated on Thu, Oct 17, 2019 09:42+1100 for FHIR v4.1.0 053 054 055import org.hl7.fhir.exceptions.FHIRException; 056 057public enum ReferencerangeMeaning { 058 059 /** 060 * General types of reference range. 061 */ 062 TYPE, 063 /** 064 * Values expected for a normal member of the relevant control population being measured. Typically each results producer such as a laboratory has specific normal ranges and they are usually defined as within two standard deviations from the mean and account for 95.45% of this population. 065 */ 066 NORMAL, 067 /** 068 * The range that is recommended by a relevant professional body. 069 */ 070 RECOMMENDED, 071 /** 072 * The range at which treatment would/should be considered. 073 */ 074 TREATMENT, 075 /** 076 * The optimal range for best therapeutic outcomes. 077 */ 078 THERAPEUTIC, 079 /** 080 * The optimal range for best therapeutic outcomes for a specimen taken immediately before administration. 081 */ 082 PRE, 083 /** 084 * The optimal range for best therapeutic outcomes for a specimen taken immediately after administration. 085 */ 086 POST, 087 /** 088 * Endocrine related states that change the expected value. 089 */ 090 ENDOCRINE, 091 /** 092 * An expected range in an individual prior to puberty. 093 */ 094 PREPUBERTY, 095 /** 096 * An expected range in an individual during the follicular stage of the cycle. 097 */ 098 FOLLICULAR, 099 /** 100 * An expected range in an individual during the midcycle stage of the cycle. 101 */ 102 MIDCYCLE, 103 /** 104 * An expected range in an individual during the luteal stage of the cycle. 105 */ 106 LUTEAL, 107 /** 108 * An expected range in an individual post-menopause. 109 */ 110 POSTMENOPAUSAL, 111 /** 112 * added to help the parsers 113 */ 114 NULL; 115 public static ReferencerangeMeaning fromCode(String codeString) throws FHIRException { 116 if (codeString == null || "".equals(codeString)) 117 return null; 118 if ("type".equals(codeString)) 119 return TYPE; 120 if ("normal".equals(codeString)) 121 return NORMAL; 122 if ("recommended".equals(codeString)) 123 return RECOMMENDED; 124 if ("treatment".equals(codeString)) 125 return TREATMENT; 126 if ("therapeutic".equals(codeString)) 127 return THERAPEUTIC; 128 if ("pre".equals(codeString)) 129 return PRE; 130 if ("post".equals(codeString)) 131 return POST; 132 if ("endocrine".equals(codeString)) 133 return ENDOCRINE; 134 if ("pre-puberty".equals(codeString)) 135 return PREPUBERTY; 136 if ("follicular".equals(codeString)) 137 return FOLLICULAR; 138 if ("midcycle".equals(codeString)) 139 return MIDCYCLE; 140 if ("luteal".equals(codeString)) 141 return LUTEAL; 142 if ("postmenopausal".equals(codeString)) 143 return POSTMENOPAUSAL; 144 throw new FHIRException("Unknown ReferencerangeMeaning code '"+codeString+"'"); 145 } 146 public String toCode() { 147 switch (this) { 148 case TYPE: return "type"; 149 case NORMAL: return "normal"; 150 case RECOMMENDED: return "recommended"; 151 case TREATMENT: return "treatment"; 152 case THERAPEUTIC: return "therapeutic"; 153 case PRE: return "pre"; 154 case POST: return "post"; 155 case ENDOCRINE: return "endocrine"; 156 case PREPUBERTY: return "pre-puberty"; 157 case FOLLICULAR: return "follicular"; 158 case MIDCYCLE: return "midcycle"; 159 case LUTEAL: return "luteal"; 160 case POSTMENOPAUSAL: return "postmenopausal"; 161 default: return "?"; 162 } 163 } 164 public String getSystem() { 165 return "http://terminology.hl7.org/CodeSystem/referencerange-meaning"; 166 } 167 public String getDefinition() { 168 switch (this) { 169 case TYPE: return "General types of reference range."; 170 case NORMAL: return "Values expected for a normal member of the relevant control population being measured. Typically each results producer such as a laboratory has specific normal ranges and they are usually defined as within two standard deviations from the mean and account for 95.45% of this population."; 171 case RECOMMENDED: return "The range that is recommended by a relevant professional body."; 172 case TREATMENT: return "The range at which treatment would/should be considered."; 173 case THERAPEUTIC: return "The optimal range for best therapeutic outcomes."; 174 case PRE: return "The optimal range for best therapeutic outcomes for a specimen taken immediately before administration."; 175 case POST: return "The optimal range for best therapeutic outcomes for a specimen taken immediately after administration."; 176 case ENDOCRINE: return "Endocrine related states that change the expected value."; 177 case PREPUBERTY: return "An expected range in an individual prior to puberty."; 178 case FOLLICULAR: return "An expected range in an individual during the follicular stage of the cycle."; 179 case MIDCYCLE: return "An expected range in an individual during the midcycle stage of the cycle."; 180 case LUTEAL: return "An expected range in an individual during the luteal stage of the cycle."; 181 case POSTMENOPAUSAL: return "An expected range in an individual post-menopause."; 182 default: return "?"; 183 } 184 } 185 public String getDisplay() { 186 switch (this) { 187 case TYPE: return "Type"; 188 case NORMAL: return "Normal Range"; 189 case RECOMMENDED: return "Recommended Range"; 190 case TREATMENT: return "Treatment Range"; 191 case THERAPEUTIC: return "Therapeutic Desired Level"; 192 case PRE: return "Pre Therapeutic Desired Level"; 193 case POST: return "Post Therapeutic Desired Level"; 194 case ENDOCRINE: return "Endocrine"; 195 case PREPUBERTY: return "Pre-Puberty"; 196 case FOLLICULAR: return "Follicular Stage"; 197 case MIDCYCLE: return "MidCycle"; 198 case LUTEAL: return "Luteal"; 199 case POSTMENOPAUSAL: return "Post-Menopause"; 200 default: return "?"; 201 } 202 } 203 204 205} 206