001package org.hl7.fhir.r4.model.codesystems; 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 Sun, May 6, 2018 17:51-0400 for FHIR v3.4.0 033 034 035import org.hl7.fhir.exceptions.FHIRException; 036 037public enum OrganizationRole { 038 039 /** 040 * null 041 */ 042 PROVIDER, 043 /** 044 * An organization such as a public health agency, community/social services provider, etc. 045 */ 046 AGENCY, 047 /** 048 * An organization providing research-related services such as conducting research, recruiting research participants, analyzing data, etc. 049 */ 050 RESEARCH, 051 /** 052 * An organization providing reimbursement, payment, or related services 053 */ 054 PAYER, 055 /** 056 * An organization providing diagnostic testing/laboratory services 057 */ 058 DIAGNOSTICS, 059 /** 060 * An organization that provides medical supplies (e.g. medical devices, equipment, pharmaceutical products, etc.) 061 */ 062 SUPPLIER, 063 /** 064 * An organization that facilitates electronic clinical data exchange between entities 065 */ 066 HIE_HIO, 067 /** 068 * A type of non-ownership relationship between entities (encompassess partnerships, collaboration, joint ventures, etc.) 069 */ 070 MEMBER, 071 /** 072 * added to help the parsers 073 */ 074 NULL; 075 public static OrganizationRole fromCode(String codeString) throws FHIRException { 076 if (codeString == null || "".equals(codeString)) 077 return null; 078 if ("provider".equals(codeString)) 079 return PROVIDER; 080 if ("agency".equals(codeString)) 081 return AGENCY; 082 if ("research".equals(codeString)) 083 return RESEARCH; 084 if ("payer".equals(codeString)) 085 return PAYER; 086 if ("diagnostics".equals(codeString)) 087 return DIAGNOSTICS; 088 if ("supplier".equals(codeString)) 089 return SUPPLIER; 090 if ("HIE/HIO".equals(codeString)) 091 return HIE_HIO; 092 if ("member".equals(codeString)) 093 return MEMBER; 094 throw new FHIRException("Unknown OrganizationRole code '"+codeString+"'"); 095 } 096 public String toCode() { 097 switch (this) { 098 case PROVIDER: return "provider"; 099 case AGENCY: return "agency"; 100 case RESEARCH: return "research"; 101 case PAYER: return "payer"; 102 case DIAGNOSTICS: return "diagnostics"; 103 case SUPPLIER: return "supplier"; 104 case HIE_HIO: return "HIE/HIO"; 105 case MEMBER: return "member"; 106 default: return "?"; 107 } 108 } 109 public String getSystem() { 110 return "http://hl7.org/fhir/organization-role"; 111 } 112 public String getDefinition() { 113 switch (this) { 114 case PROVIDER: return ""; 115 case AGENCY: return "An organization such as a public health agency, community/social services provider, etc."; 116 case RESEARCH: return "An organization providing research-related services such as conducting research, recruiting research participants, analyzing data, etc."; 117 case PAYER: return "An organization providing reimbursement, payment, or related services"; 118 case DIAGNOSTICS: return "An organization providing diagnostic testing/laboratory services"; 119 case SUPPLIER: return "An organization that provides medical supplies (e.g. medical devices, equipment, pharmaceutical products, etc.)"; 120 case HIE_HIO: return "An organization that facilitates electronic clinical data exchange between entities"; 121 case MEMBER: return "A type of non-ownership relationship between entities (encompassess partnerships, collaboration, joint ventures, etc.)"; 122 default: return "?"; 123 } 124 } 125 public String getDisplay() { 126 switch (this) { 127 case PROVIDER: return "Provider"; 128 case AGENCY: return "Agency"; 129 case RESEARCH: return "Research"; 130 case PAYER: return "Payer"; 131 case DIAGNOSTICS: return "Diagnostics"; 132 case SUPPLIER: return "Supplier"; 133 case HIE_HIO: return "HIE/HIO"; 134 case MEMBER: return "Member"; 135 default: return "?"; 136 } 137 } 138 139 140} 141