001package org.hl7.fhir.r4.model.codesystems; 002 003/*- 004 * #%L 005 * org.hl7.fhir.r4 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/* 025 Copyright (c) 2011+, HL7, Inc. 026 All rights reserved. 027 028 Redistribution and use in source and binary forms, with or without modification, 029 are permitted provided that the following conditions are met: 030 031 * Redistributions of source code must retain the above copyright notice, this 032 list of conditions and the following disclaimer. 033 * Redistributions in binary form must reproduce the above copyright notice, 034 this list of conditions and the following disclaimer in the documentation 035 and/or other materials provided with the distribution. 036 * Neither the name of HL7 nor the names of its contributors may be used to 037 endorse or promote products derived from this software without specific 038 prior written permission. 039 040 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 041 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 042 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 043 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 044 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 045 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 046 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 047 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 048 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 049 POSSIBILITY OF SUCH DAMAGE. 050 051*/ 052 053// Generated on Wed, Jan 30, 2019 16:19-0500 for FHIR v4.0.0 054 055 056import org.hl7.fhir.exceptions.FHIRException; 057 058public enum V3ActRelationshipSubset { 059 060 /** 061 * Used to indicate that the participation is a filtered subset of the total participations of the same type owned by the Act. 062 063 Used when there is a need to limit the participations to the first, the last, the next or some other filtered subset. 064 */ 065 _PARTICIPATIONSUBSET, 066 /** 067 * An occurrence that is scheduled to occur in the future. An Act whose effective time is greater than 'now', where 'now' is the time the instance is authored. 068 */ 069 FUTURE, 070 /** 071 * Represents a 'summary' of all acts that are scheduled to occur in the future (whose effective time is greater than 'now' where is the time the instance is authored.). The effectiveTime represents the outer boundary of all occurrences, repeatNumber represents the total number of repetitions, etc. 072 */ 073 FUTSUM, 074 /** 075 * Restricted to the latest known occurrence that is scheduled to occur. The Act with the highest known effective time. 076 */ 077 LAST, 078 /** 079 * Restricted to the nearest recent known occurrence scheduled to occur in the future. The Act with the lowest effective time, still greater than 'now'. ('now' is the time the instance is authored.) 080 */ 081 NEXT, 082 /** 083 * An occurrence that occurred or was scheduled to occur in the past. An Act whose effective time is less than 'now'. ('now' is the time the instance is authored.) 084 */ 085 PAST, 086 /** 087 * Restricted to the earliest known occurrence that occurred or was scheduled to occur in the past. The Act with the lowest effective time. ('now' is the time the instance is authored.) 088 */ 089 FIRST, 090 /** 091 * Represents a 'summary' of all acts that previously occurred or were scheduled to occur. The effectiveTime represents the outer boundary of all occurrences, repeatNumber represents the total number of repetitions, etc. ('now' is the time the instance is authored.) 092 */ 093 PREVSUM, 094 /** 095 * Restricted to the most recent known occurrence that occurred or was scheduled to occur in the past. The Act with the most recent effective time, still less than 'now'. ('now' is the time the instance is authored.) 096 */ 097 RECENT, 098 /** 099 * Represents a 'summary' of all acts that have occurred or were scheduled to occur and which are scheduled to occur in the future. The effectiveTime represents the outer boundary of all occurrences, repeatNumber represents the total number of repetitions, etc. 100 */ 101 SUM, 102 /** 103 * ActRelationshipExpectedSubset 104 */ 105 ACTRELATIONSHIPEXPECTEDSUBSET, 106 /** 107 * ActRelationshipPastSubset 108 */ 109 ACTRELATIONSHIPPASTSUBSET, 110 /** 111 * The occurrence whose value attribute is greater than all other occurrences at the time the instance is created. 112 */ 113 MAX, 114 /** 115 * The occurrence whose value attribute is less than all other occurrences at the time the instance is created. 116 */ 117 MIN, 118 /** 119 * added to help the parsers 120 */ 121 NULL; 122 public static V3ActRelationshipSubset fromCode(String codeString) throws FHIRException { 123 if (codeString == null || "".equals(codeString)) 124 return null; 125 if ("_ParticipationSubset".equals(codeString)) 126 return _PARTICIPATIONSUBSET; 127 if ("FUTURE".equals(codeString)) 128 return FUTURE; 129 if ("FUTSUM".equals(codeString)) 130 return FUTSUM; 131 if ("LAST".equals(codeString)) 132 return LAST; 133 if ("NEXT".equals(codeString)) 134 return NEXT; 135 if ("PAST".equals(codeString)) 136 return PAST; 137 if ("FIRST".equals(codeString)) 138 return FIRST; 139 if ("PREVSUM".equals(codeString)) 140 return PREVSUM; 141 if ("RECENT".equals(codeString)) 142 return RECENT; 143 if ("SUM".equals(codeString)) 144 return SUM; 145 if ("ActRelationshipExpectedSubset".equals(codeString)) 146 return ACTRELATIONSHIPEXPECTEDSUBSET; 147 if ("ActRelationshipPastSubset".equals(codeString)) 148 return ACTRELATIONSHIPPASTSUBSET; 149 if ("MAX".equals(codeString)) 150 return MAX; 151 if ("MIN".equals(codeString)) 152 return MIN; 153 throw new FHIRException("Unknown V3ActRelationshipSubset code '"+codeString+"'"); 154 } 155 public String toCode() { 156 switch (this) { 157 case _PARTICIPATIONSUBSET: return "_ParticipationSubset"; 158 case FUTURE: return "FUTURE"; 159 case FUTSUM: return "FUTSUM"; 160 case LAST: return "LAST"; 161 case NEXT: return "NEXT"; 162 case PAST: return "PAST"; 163 case FIRST: return "FIRST"; 164 case PREVSUM: return "PREVSUM"; 165 case RECENT: return "RECENT"; 166 case SUM: return "SUM"; 167 case ACTRELATIONSHIPEXPECTEDSUBSET: return "ActRelationshipExpectedSubset"; 168 case ACTRELATIONSHIPPASTSUBSET: return "ActRelationshipPastSubset"; 169 case MAX: return "MAX"; 170 case MIN: return "MIN"; 171 default: return "?"; 172 } 173 } 174 public String getSystem() { 175 return "http://terminology.hl7.org/CodeSystem/v3-ActRelationshipSubset"; 176 } 177 public String getDefinition() { 178 switch (this) { 179 case _PARTICIPATIONSUBSET: return "Used to indicate that the participation is a filtered subset of the total participations of the same type owned by the Act. \r\n\n Used when there is a need to limit the participations to the first, the last, the next or some other filtered subset."; 180 case FUTURE: return "An occurrence that is scheduled to occur in the future. An Act whose effective time is greater than 'now', where 'now' is the time the instance is authored."; 181 case FUTSUM: return "Represents a 'summary' of all acts that are scheduled to occur in the future (whose effective time is greater than 'now' where is the time the instance is authored.). The effectiveTime represents the outer boundary of all occurrences, repeatNumber represents the total number of repetitions, etc."; 182 case LAST: return "Restricted to the latest known occurrence that is scheduled to occur. The Act with the highest known effective time."; 183 case NEXT: return "Restricted to the nearest recent known occurrence scheduled to occur in the future. The Act with the lowest effective time, still greater than 'now'. ('now' is the time the instance is authored.)"; 184 case PAST: return "An occurrence that occurred or was scheduled to occur in the past. An Act whose effective time is less than 'now'. ('now' is the time the instance is authored.)"; 185 case FIRST: return "Restricted to the earliest known occurrence that occurred or was scheduled to occur in the past. The Act with the lowest effective time. ('now' is the time the instance is authored.)"; 186 case PREVSUM: return "Represents a 'summary' of all acts that previously occurred or were scheduled to occur. The effectiveTime represents the outer boundary of all occurrences, repeatNumber represents the total number of repetitions, etc. ('now' is the time the instance is authored.)"; 187 case RECENT: return "Restricted to the most recent known occurrence that occurred or was scheduled to occur in the past. The Act with the most recent effective time, still less than 'now'. ('now' is the time the instance is authored.)"; 188 case SUM: return "Represents a 'summary' of all acts that have occurred or were scheduled to occur and which are scheduled to occur in the future. The effectiveTime represents the outer boundary of all occurrences, repeatNumber represents the total number of repetitions, etc."; 189 case ACTRELATIONSHIPEXPECTEDSUBSET: return "ActRelationshipExpectedSubset"; 190 case ACTRELATIONSHIPPASTSUBSET: return "ActRelationshipPastSubset"; 191 case MAX: return "The occurrence whose value attribute is greater than all other occurrences at the time the instance is created."; 192 case MIN: return "The occurrence whose value attribute is less than all other occurrences at the time the instance is created."; 193 default: return "?"; 194 } 195 } 196 public String getDisplay() { 197 switch (this) { 198 case _PARTICIPATIONSUBSET: return "ParticipationSubset"; 199 case FUTURE: return "expected future"; 200 case FUTSUM: return "future summary"; 201 case LAST: return "expected last"; 202 case NEXT: return "expected next"; 203 case PAST: return "previous"; 204 case FIRST: return "first known"; 205 case PREVSUM: return "previous summary"; 206 case RECENT: return "most recent"; 207 case SUM: return "summary"; 208 case ACTRELATIONSHIPEXPECTEDSUBSET: return "ActRelationshipExpectedSubset"; 209 case ACTRELATIONSHIPPASTSUBSET: return "ActRelationshipPastSubset"; 210 case MAX: return "maximum"; 211 case MIN: return "minimum"; 212 default: return "?"; 213 } 214 } 215 216 217} 218