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 V3Hl7Realm {
058
059        /**
060         * Description: Concepts that can be used as Binding Realms when creating Binding Statements.  These codes are permitted to appear in the InfrastructureRoot.realmCode attribute.
061         */
062        BINDINGREALMS, 
063        /**
064         * Description: Realm codes for official HL7 organizational bodies.  This includes both the HL7 International organization as well as all recognized international affiliates (past and present).  These groups have the ability to bind vocabulary and develop artifacts.  As well, they have the ability to have "ownership" over other binding realms and namespace realms via the owningAffiliate property of those other realm codes.
065         */
066        AFFILIATEREALMS, 
067        /**
068         * Description: Realm code for use of Argentina
069         */
070        AR, 
071        /**
072         * Description: Realm code for use of Austria
073         */
074        AT, 
075        /**
076         * Description: Realm code for use of Australia
077         */
078        AU, 
079        /**
080         * Description: Realm code for use of Brazil
081         */
082        BR, 
083        /**
084         * Description: Realm code for use of Canada
085         */
086        CA, 
087        /**
088         * Description: Realm code for use of Switzerland
089         */
090        CH, 
091        /**
092         * Description: Realm code for use of Chile
093         */
094        CL, 
095        /**
096         * Description: Realm code for use of China
097         */
098        CN, 
099        /**
100         * Description: Realm code for use of Localized Version
101         */
102        CO, 
103        /**
104         * Description: Realm code for use of Czech Republic
105         */
106        CZ, 
107        /**
108         * Description: Realm code for use of Germany
109         */
110        DE, 
111        /**
112         * Description: Realm code for use of Denmark
113         */
114        DK, 
115        /**
116         * Description: Realm code for use of Spain
117         */
118        ES, 
119        /**
120         * Description: Realm code for use of Finland
121         */
122        FI, 
123        /**
124         * Description: Realm code for use of France
125         */
126        FR, 
127        /**
128         * Description: Realm code for use of Greece
129         */
130        GR, 
131        /**
132         * Description: Realm code for use of Croatia
133         */
134        HR, 
135        /**
136         * Description: Realm code for use of Ireland
137         */
138        IE, 
139        /**
140         * Description: Realm code for use of India
141         */
142        IN, 
143        /**
144         * Description: Realm code for use of Italy
145         */
146        IT, 
147        /**
148         * Description: Realm code for use of Japan
149         */
150        JP, 
151        /**
152         * Description: Realm code for use of Korea
153         */
154        KR, 
155        /**
156         * Description: Realm code for use of Lithuania
157         */
158        LT, 
159        /**
160         * Description: Realm code for use of Mexico
161         */
162        MX, 
163        /**
164         * Description: Realm code for use of The Netherlands
165         */
166        NL, 
167        /**
168         * Description: Realm code for use of New Zealand
169         */
170        NZ, 
171        /**
172         * Description: Realm code for use of Romania
173         */
174        RO, 
175        /**
176         * Description: Realm code for use of Russian Federation
177         */
178        RU, 
179        /**
180         * Description: Realm code for use of Sweden
181         */
182        SE, 
183        /**
184         * Description: Realm code for use of Localized Version
185         */
186        SG, 
187        /**
188         * Description: Realm code for use of Southern Africa
189         */
190        SOA, 
191        /**
192         * Description: Realm code for use of Turkey
193         */
194        TR, 
195        /**
196         * Description: Realm code for use of Taiwan
197         */
198        TW, 
199        /**
200         * Description: Realm code for use of United Kingdom
201         */
202        UK, 
203        /**
204         * Description: Realm code for use of United States of America
205         */
206        US, 
207        /**
208         * Description: Realm code for use of Universal realm or context, used in every instance
209         */
210        UV, 
211        /**
212         * Description: Realm code for use of Uruguay
213         */
214        UY, 
215        /**
216         * Description: Realm code for use of Unclassified Realm
217         */
218        C1, 
219        /**
220         * Description: Realm code for use of Great Britain
221         */
222        GB, 
223        /**
224         * Description: Realm code for use of Representative Realm
225         */
226        R1, 
227        /**
228         * Description: Realm code for use of Example Realm
229         */
230        X1, 
231        /**
232         * Description: Codes that can be used in the "realm" portion of HL7 v3 artifact identifiers.
233         */
234        NAMESPACEREALMS, 
235        /**
236         * Description: An artifact created for local use only.  This realm namespace has no owning affiliate.  Its use is uncontrolled, i.e. anyone can create artifacts using this realm namespace.  Because of this, there is a significant likelihood of artifact identifier collisions.  Implementers are encouraged to register their artifacts under an affiliate owned and controlled namespace to avoid such collision problems where possible.
237         */
238        ZZ, 
239        /**
240         * added to help the parsers
241         */
242        NULL;
243        public static V3Hl7Realm fromCode(String codeString) throws FHIRException {
244            if (codeString == null || "".equals(codeString))
245                return null;
246        if ("BindingRealms".equals(codeString))
247          return BINDINGREALMS;
248        if ("AffiliateRealms".equals(codeString))
249          return AFFILIATEREALMS;
250        if ("AR".equals(codeString))
251          return AR;
252        if ("AT".equals(codeString))
253          return AT;
254        if ("AU".equals(codeString))
255          return AU;
256        if ("BR".equals(codeString))
257          return BR;
258        if ("CA".equals(codeString))
259          return CA;
260        if ("CH".equals(codeString))
261          return CH;
262        if ("CL".equals(codeString))
263          return CL;
264        if ("CN".equals(codeString))
265          return CN;
266        if ("CO".equals(codeString))
267          return CO;
268        if ("CZ".equals(codeString))
269          return CZ;
270        if ("DE".equals(codeString))
271          return DE;
272        if ("DK".equals(codeString))
273          return DK;
274        if ("ES".equals(codeString))
275          return ES;
276        if ("FI".equals(codeString))
277          return FI;
278        if ("FR".equals(codeString))
279          return FR;
280        if ("GR".equals(codeString))
281          return GR;
282        if ("HR".equals(codeString))
283          return HR;
284        if ("IE".equals(codeString))
285          return IE;
286        if ("IN".equals(codeString))
287          return IN;
288        if ("IT".equals(codeString))
289          return IT;
290        if ("JP".equals(codeString))
291          return JP;
292        if ("KR".equals(codeString))
293          return KR;
294        if ("LT".equals(codeString))
295          return LT;
296        if ("MX".equals(codeString))
297          return MX;
298        if ("NL".equals(codeString))
299          return NL;
300        if ("NZ".equals(codeString))
301          return NZ;
302        if ("RO".equals(codeString))
303          return RO;
304        if ("RU".equals(codeString))
305          return RU;
306        if ("SE".equals(codeString))
307          return SE;
308        if ("SG".equals(codeString))
309          return SG;
310        if ("SOA".equals(codeString))
311          return SOA;
312        if ("TR".equals(codeString))
313          return TR;
314        if ("TW".equals(codeString))
315          return TW;
316        if ("UK".equals(codeString))
317          return UK;
318        if ("US".equals(codeString))
319          return US;
320        if ("UV".equals(codeString))
321          return UV;
322        if ("UY".equals(codeString))
323          return UY;
324        if ("C1".equals(codeString))
325          return C1;
326        if ("GB".equals(codeString))
327          return GB;
328        if ("R1".equals(codeString))
329          return R1;
330        if ("X1".equals(codeString))
331          return X1;
332        if ("NamespaceRealms".equals(codeString))
333          return NAMESPACEREALMS;
334        if ("ZZ".equals(codeString))
335          return ZZ;
336        throw new FHIRException("Unknown V3Hl7Realm code '"+codeString+"'");
337        }
338        public String toCode() {
339          switch (this) {
340            case BINDINGREALMS: return "BindingRealms";
341            case AFFILIATEREALMS: return "AffiliateRealms";
342            case AR: return "AR";
343            case AT: return "AT";
344            case AU: return "AU";
345            case BR: return "BR";
346            case CA: return "CA";
347            case CH: return "CH";
348            case CL: return "CL";
349            case CN: return "CN";
350            case CO: return "CO";
351            case CZ: return "CZ";
352            case DE: return "DE";
353            case DK: return "DK";
354            case ES: return "ES";
355            case FI: return "FI";
356            case FR: return "FR";
357            case GR: return "GR";
358            case HR: return "HR";
359            case IE: return "IE";
360            case IN: return "IN";
361            case IT: return "IT";
362            case JP: return "JP";
363            case KR: return "KR";
364            case LT: return "LT";
365            case MX: return "MX";
366            case NL: return "NL";
367            case NZ: return "NZ";
368            case RO: return "RO";
369            case RU: return "RU";
370            case SE: return "SE";
371            case SG: return "SG";
372            case SOA: return "SOA";
373            case TR: return "TR";
374            case TW: return "TW";
375            case UK: return "UK";
376            case US: return "US";
377            case UV: return "UV";
378            case UY: return "UY";
379            case C1: return "C1";
380            case GB: return "GB";
381            case R1: return "R1";
382            case X1: return "X1";
383            case NAMESPACEREALMS: return "NamespaceRealms";
384            case ZZ: return "ZZ";
385            default: return "?";
386          }
387        }
388        public String getSystem() {
389          return "http://terminology.hl7.org/CodeSystem/v3-hl7Realm";
390        }
391        public String getDefinition() {
392          switch (this) {
393            case BINDINGREALMS: return "Description: Concepts that can be used as Binding Realms when creating Binding Statements.  These codes are permitted to appear in the InfrastructureRoot.realmCode attribute.";
394            case AFFILIATEREALMS: return "Description: Realm codes for official HL7 organizational bodies.  This includes both the HL7 International organization as well as all recognized international affiliates (past and present).  These groups have the ability to bind vocabulary and develop artifacts.  As well, they have the ability to have \"ownership\" over other binding realms and namespace realms via the owningAffiliate property of those other realm codes.";
395            case AR: return "Description: Realm code for use of Argentina";
396            case AT: return "Description: Realm code for use of Austria";
397            case AU: return "Description: Realm code for use of Australia";
398            case BR: return "Description: Realm code for use of Brazil";
399            case CA: return "Description: Realm code for use of Canada";
400            case CH: return "Description: Realm code for use of Switzerland";
401            case CL: return "Description: Realm code for use of Chile";
402            case CN: return "Description: Realm code for use of China";
403            case CO: return "Description: Realm code for use of Localized Version";
404            case CZ: return "Description: Realm code for use of Czech Republic";
405            case DE: return "Description: Realm code for use of Germany";
406            case DK: return "Description: Realm code for use of Denmark";
407            case ES: return "Description: Realm code for use of Spain";
408            case FI: return "Description: Realm code for use of Finland";
409            case FR: return "Description: Realm code for use of France";
410            case GR: return "Description: Realm code for use of Greece";
411            case HR: return "Description: Realm code for use of Croatia";
412            case IE: return "Description: Realm code for use of Ireland";
413            case IN: return "Description: Realm code for use of India";
414            case IT: return "Description: Realm code for use of Italy";
415            case JP: return "Description: Realm code for use of Japan";
416            case KR: return "Description: Realm code for use of Korea";
417            case LT: return "Description: Realm code for use of Lithuania";
418            case MX: return "Description: Realm code for use of Mexico";
419            case NL: return "Description: Realm code for use of The Netherlands";
420            case NZ: return "Description: Realm code for use of New Zealand";
421            case RO: return "Description: Realm code for use of Romania";
422            case RU: return "Description: Realm code for use of Russian Federation";
423            case SE: return "Description: Realm code for use of Sweden";
424            case SG: return "Description: Realm code for use of Localized Version";
425            case SOA: return "Description: Realm code for use of Southern Africa";
426            case TR: return "Description: Realm code for use of Turkey";
427            case TW: return "Description: Realm code for use of Taiwan";
428            case UK: return "Description: Realm code for use of United Kingdom";
429            case US: return "Description: Realm code for use of United States of America";
430            case UV: return "Description: Realm code for use of Universal realm or context, used in every instance";
431            case UY: return "Description: Realm code for use of Uruguay";
432            case C1: return "Description: Realm code for use of Unclassified Realm";
433            case GB: return "Description: Realm code for use of Great Britain";
434            case R1: return "Description: Realm code for use of Representative Realm";
435            case X1: return "Description: Realm code for use of Example Realm";
436            case NAMESPACEREALMS: return "Description: Codes that can be used in the \"realm\" portion of HL7 v3 artifact identifiers.";
437            case ZZ: return "Description: An artifact created for local use only.  This realm namespace has no owning affiliate.  Its use is uncontrolled, i.e. anyone can create artifacts using this realm namespace.  Because of this, there is a significant likelihood of artifact identifier collisions.  Implementers are encouraged to register their artifacts under an affiliate owned and controlled namespace to avoid such collision problems where possible.";
438            default: return "?";
439          }
440        }
441        public String getDisplay() {
442          switch (this) {
443            case BINDINGREALMS: return "binding realms";
444            case AFFILIATEREALMS: return "Affiliate Realms";
445            case AR: return "Argentina";
446            case AT: return "Austria";
447            case AU: return "Australia";
448            case BR: return "Brazil";
449            case CA: return "Canada";
450            case CH: return "Switzerland";
451            case CL: return "Chile";
452            case CN: return "China";
453            case CO: return "Columbia";
454            case CZ: return "Czech Republic";
455            case DE: return "Germany";
456            case DK: return "Denmark";
457            case ES: return "Spain";
458            case FI: return "Finland";
459            case FR: return "France";
460            case GR: return "Greece";
461            case HR: return "Croatia";
462            case IE: return "Ireland";
463            case IN: return "India";
464            case IT: return "Italy";
465            case JP: return "Japan";
466            case KR: return "Korea";
467            case LT: return "Lithuania";
468            case MX: return "Mexico";
469            case NL: return "The Netherlands";
470            case NZ: return "New Zealand";
471            case RO: return "Romania";
472            case RU: return "Russian Federation";
473            case SE: return "Sweden";
474            case SG: return "Singapore";
475            case SOA: return "Southern Africa";
476            case TR: return "Turkey";
477            case TW: return "Taiwan";
478            case UK: return "United Kingdom";
479            case US: return "United States of America";
480            case UV: return "Universal";
481            case UY: return "Uruguay";
482            case C1: return "Unclassified Realm";
483            case GB: return "Great Britain";
484            case R1: return "Representative Realm";
485            case X1: return "Example Realm";
486            case NAMESPACEREALMS: return "namespace realms";
487            case ZZ: return "Localized Version";
488            default: return "?";
489          }
490    }
491
492
493}
494