001package org.hl7.fhir.instance.model.valuesets;
002
003/*
004  Copyright (c) 2011+, HL7, Inc.
005  All rights reserved.
006  
007  Redistribution and use in source and binary forms, with or without modification, 
008  are permitted provided that the following conditions are met:
009  
010   * Redistributions of source code must retain the above copyright notice, this 
011     list of conditions and the following disclaimer.
012   * Redistributions in binary form must reproduce the above copyright notice, 
013     this list of conditions and the following disclaimer in the documentation 
014     and/or other materials provided with the distribution.
015   * Neither the name of HL7 nor the names of its contributors may be used to 
016     endorse or promote products derived from this software without specific 
017     prior written permission.
018  
019  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 
020  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 
021  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 
022  IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 
023  INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 
024  NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 
025  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 
026  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 
027  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
028  POSSIBILITY OF SUCH DAMAGE.
029  
030*/
031
032// Generated on Wed, Nov 11, 2015 10:54-0500 for FHIR v1.0.2
033
034
035public enum ProvenanceAgentRole {
036
037        /**
038         * A person entering the data into the originating system
039         */
040        ENTERER, 
041        /**
042         * A person, animal, organization or device that who actually and principally carries out the activity
043         */
044        PERFORMER, 
045        /**
046         * A party that originates the resource and therefore has responsibility for the information given in the resource and ownership of this resource
047         */
048        AUTHOR, 
049        /**
050         * A person who verifies the correctness and appropriateness of activity
051         */
052        VERIFIER, 
053        /**
054         * The person authenticated the content and accepted legal responsibility for its content
055         */
056        LEGAL, 
057        /**
058         * A verifier who attests to the accuracy of the resource
059         */
060        ATTESTER, 
061        /**
062         * A person who reported information that contributed to the resource
063         */
064        INFORMANT, 
065        /**
066         * The entity that is accountable for maintaining a true an accurate copy of the original record
067         */
068        CUSTODIAN, 
069        /**
070         * A device that operates independently of an author on custodian's algorithms for data extraction of existing information for purpose of generating a new artifact.
071         */
072        ASSEMBLER, 
073        /**
074         * A device used by an author to record new information, which may also be used by the author to select existing information for aggregation with newly recorded information for the purpose of generating a new artifact.
075         */
076        COMPOSER, 
077        /**
078         * added to help the parsers
079         */
080        NULL;
081        public static ProvenanceAgentRole fromCode(String codeString) throws Exception {
082            if (codeString == null || "".equals(codeString))
083                return null;
084        if ("enterer".equals(codeString))
085          return ENTERER;
086        if ("performer".equals(codeString))
087          return PERFORMER;
088        if ("author".equals(codeString))
089          return AUTHOR;
090        if ("verifier".equals(codeString))
091          return VERIFIER;
092        if ("legal".equals(codeString))
093          return LEGAL;
094        if ("attester".equals(codeString))
095          return ATTESTER;
096        if ("informant".equals(codeString))
097          return INFORMANT;
098        if ("custodian".equals(codeString))
099          return CUSTODIAN;
100        if ("assembler".equals(codeString))
101          return ASSEMBLER;
102        if ("composer".equals(codeString))
103          return COMPOSER;
104        throw new Exception("Unknown ProvenanceAgentRole code '"+codeString+"'");
105        }
106        public String toCode() {
107          switch (this) {
108            case ENTERER: return "enterer";
109            case PERFORMER: return "performer";
110            case AUTHOR: return "author";
111            case VERIFIER: return "verifier";
112            case LEGAL: return "legal";
113            case ATTESTER: return "attester";
114            case INFORMANT: return "informant";
115            case CUSTODIAN: return "custodian";
116            case ASSEMBLER: return "assembler";
117            case COMPOSER: return "composer";
118            default: return "?";
119          }
120        }
121        public String getSystem() {
122          return "http://hl7.org/fhir/provenance-participant-role";
123        }
124        public String getDefinition() {
125          switch (this) {
126            case ENTERER: return "A person entering the data into the originating system";
127            case PERFORMER: return "A person, animal, organization or device that who actually and principally carries out the activity";
128            case AUTHOR: return "A party that originates the resource and therefore has responsibility for the information given in the resource and ownership of this resource";
129            case VERIFIER: return "A person who verifies the correctness and appropriateness of activity";
130            case LEGAL: return "The person authenticated the content and accepted legal responsibility for its content";
131            case ATTESTER: return "A verifier who attests to the accuracy of the resource";
132            case INFORMANT: return "A person who reported information that contributed to the resource";
133            case CUSTODIAN: return "The entity that is accountable for maintaining a true an accurate copy of the original record";
134            case ASSEMBLER: return "A device that operates independently of an author on custodian's algorithms for data extraction of existing information for purpose of generating a new artifact.";
135            case COMPOSER: return "A device used by an author to record new information, which may also be used by the author to select existing information for aggregation with newly recorded information for the purpose of generating a new artifact.";
136            default: return "?";
137          }
138        }
139        public String getDisplay() {
140          switch (this) {
141            case ENTERER: return "Enterer";
142            case PERFORMER: return "Performer";
143            case AUTHOR: return "Author";
144            case VERIFIER: return "Verifier";
145            case LEGAL: return "Legal Authenticator";
146            case ATTESTER: return "Attester";
147            case INFORMANT: return "Informant";
148            case CUSTODIAN: return "Custodian";
149            case ASSEMBLER: return "Assembler";
150            case COMPOSER: return "Composer";
151            default: return "?";
152          }
153    }
154
155
156}
157