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 V3RoleLinkType {
059
060        /**
061         * An action taken with respect to a subject Entity by a regulatory or authoritative body with supervisory capacity over that entity. The action is taken in response to behavior by the subject Entity that body finds to be undesirable.
062
063                        Suspension, license restrictions, monetary fine, letter of reprimand, mandated training, mandated supervision, etc.Examples:
064         */
065        REL, 
066        /**
067         * This relationship indicates the source Role is available to the target Role as a backup. An entity in a backup role will be available as a substitute or replacement in the event that the entity assigned the role is unavailable. In medical roles where it is critical that the function be performed and there is a possibility that the individual assigned may be ill or otherwise indisposed, another individual is assigned to cover for the individual originally assigned the role. A backup may be required to be identified, but unless the backup is actually used, he/she would not assume the assigned entity role.
068         */
069        BACKUP, 
070        /**
071         * This relationship indicates the target Role provides or receives information regarding the target role.  For example, AssignedEntity is a contact for a ServiceDeliveryLocation.
072         */
073        CONT, 
074        /**
075         * The source Role has direct authority over the target role in a chain of authority.
076         */
077        DIRAUTH, 
078        /**
079         * Description: The source role provides identification for the target role. The source role must be IDENT. The player entity of the source role is constrained to be the same as (i.e. the equivalent of, or equal to) the player of the target role if present. If the player is absent from the source role, then it is assumed to be the same as the player of the target role.
080         */
081        IDENT, 
082        /**
083         * The source Role has indirect authority over the target role in a chain of authority.
084         */
085        INDAUTH, 
086        /**
087         * The target Role is part of the Source Role.
088         */
089        PART, 
090        /**
091         * This relationship indicates that the source Role replaces (or subsumes) the target Role.  Allows for new identifiers and/or new effective time for a registry entry or a certification, etc.
092         */
093        REPL, 
094        /**
095         * added to help the parsers
096         */
097        NULL;
098        public static V3RoleLinkType fromCode(String codeString) throws FHIRException {
099            if (codeString == null || "".equals(codeString))
100                return null;
101        if ("REL".equals(codeString))
102          return REL;
103        if ("BACKUP".equals(codeString))
104          return BACKUP;
105        if ("CONT".equals(codeString))
106          return CONT;
107        if ("DIRAUTH".equals(codeString))
108          return DIRAUTH;
109        if ("IDENT".equals(codeString))
110          return IDENT;
111        if ("INDAUTH".equals(codeString))
112          return INDAUTH;
113        if ("PART".equals(codeString))
114          return PART;
115        if ("REPL".equals(codeString))
116          return REPL;
117        throw new FHIRException("Unknown V3RoleLinkType code '"+codeString+"'");
118        }
119        public String toCode() {
120          switch (this) {
121            case REL: return "REL";
122            case BACKUP: return "BACKUP";
123            case CONT: return "CONT";
124            case DIRAUTH: return "DIRAUTH";
125            case IDENT: return "IDENT";
126            case INDAUTH: return "INDAUTH";
127            case PART: return "PART";
128            case REPL: return "REPL";
129            default: return "?";
130          }
131        }
132        public String getSystem() {
133          return "http://terminology.hl7.org/CodeSystem/v3-RoleLinkType";
134        }
135        public String getDefinition() {
136          switch (this) {
137            case REL: return "An action taken with respect to a subject Entity by a regulatory or authoritative body with supervisory capacity over that entity. The action is taken in response to behavior by the subject Entity that body finds to be undesirable.\r\n\n                        Suspension, license restrictions, monetary fine, letter of reprimand, mandated training, mandated supervision, etc.Examples:";
138            case BACKUP: return "This relationship indicates the source Role is available to the target Role as a backup. An entity in a backup role will be available as a substitute or replacement in the event that the entity assigned the role is unavailable. In medical roles where it is critical that the function be performed and there is a possibility that the individual assigned may be ill or otherwise indisposed, another individual is assigned to cover for the individual originally assigned the role. A backup may be required to be identified, but unless the backup is actually used, he/she would not assume the assigned entity role.";
139            case CONT: return "This relationship indicates the target Role provides or receives information regarding the target role.  For example, AssignedEntity is a contact for a ServiceDeliveryLocation.";
140            case DIRAUTH: return "The source Role has direct authority over the target role in a chain of authority.";
141            case IDENT: return "Description: The source role provides identification for the target role. The source role must be IDENT. The player entity of the source role is constrained to be the same as (i.e. the equivalent of, or equal to) the player of the target role if present. If the player is absent from the source role, then it is assumed to be the same as the player of the target role.";
142            case INDAUTH: return "The source Role has indirect authority over the target role in a chain of authority.";
143            case PART: return "The target Role is part of the Source Role.";
144            case REPL: return "This relationship indicates that the source Role replaces (or subsumes) the target Role.  Allows for new identifiers and/or new effective time for a registry entry or a certification, etc.";
145            default: return "?";
146          }
147        }
148        public String getDisplay() {
149          switch (this) {
150            case REL: return "related";
151            case BACKUP: return "is backup for";
152            case CONT: return "has contact";
153            case DIRAUTH: return "has direct authority over";
154            case IDENT: return "Identification";
155            case INDAUTH: return "has indirect authority over";
156            case PART: return "has part";
157            case REPL: return "replaces";
158            default: return "?";
159          }
160    }
161
162
163}
164