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, Mar 4, 2018 12:52-0500 for FHIR v3.2.0 033 034 035import org.hl7.fhir.exceptions.FHIRException; 036 037public enum GuidePageKind { 038 039 /** 040 * This is a page of content that is included in the implementation guide. It has no particular function. 041 */ 042 PAGE, 043 /** 044 * This is a page that represents a human readable rendering of an example. 045 */ 046 EXAMPLE, 047 /** 048 * This is a page that represents a list of resources of one or more types. 049 */ 050 LIST, 051 /** 052 * This is a page showing where an included guide is injected. 053 */ 054 INCLUDE, 055 /** 056 * This is a page that lists the resources of a given type, and also creates pages for all the listed types as other pages in the section. 057 */ 058 DIRECTORY, 059 /** 060 * This is a page that creates the listed resources as a dictionary. 061 */ 062 DICTIONARY, 063 /** 064 * This is a generated page that contains the table of contents. 065 */ 066 TOC, 067 /** 068 * This is a page that represents a presented resource. This is typically used for generated conformance resource presentations. 069 */ 070 RESOURCE, 071 /** 072 * added to help the parsers 073 */ 074 NULL; 075 public static GuidePageKind fromCode(String codeString) throws FHIRException { 076 if (codeString == null || "".equals(codeString)) 077 return null; 078 if ("page".equals(codeString)) 079 return PAGE; 080 if ("example".equals(codeString)) 081 return EXAMPLE; 082 if ("list".equals(codeString)) 083 return LIST; 084 if ("include".equals(codeString)) 085 return INCLUDE; 086 if ("directory".equals(codeString)) 087 return DIRECTORY; 088 if ("dictionary".equals(codeString)) 089 return DICTIONARY; 090 if ("toc".equals(codeString)) 091 return TOC; 092 if ("resource".equals(codeString)) 093 return RESOURCE; 094 throw new FHIRException("Unknown GuidePageKind code '"+codeString+"'"); 095 } 096 public String toCode() { 097 switch (this) { 098 case PAGE: return "page"; 099 case EXAMPLE: return "example"; 100 case LIST: return "list"; 101 case INCLUDE: return "include"; 102 case DIRECTORY: return "directory"; 103 case DICTIONARY: return "dictionary"; 104 case TOC: return "toc"; 105 case RESOURCE: return "resource"; 106 default: return "?"; 107 } 108 } 109 public String getSystem() { 110 return "http://hl7.org/fhir/guide-page-kind"; 111 } 112 public String getDefinition() { 113 switch (this) { 114 case PAGE: return "This is a page of content that is included in the implementation guide. It has no particular function."; 115 case EXAMPLE: return "This is a page that represents a human readable rendering of an example."; 116 case LIST: return "This is a page that represents a list of resources of one or more types."; 117 case INCLUDE: return "This is a page showing where an included guide is injected."; 118 case DIRECTORY: return "This is a page that lists the resources of a given type, and also creates pages for all the listed types as other pages in the section."; 119 case DICTIONARY: return "This is a page that creates the listed resources as a dictionary."; 120 case TOC: return "This is a generated page that contains the table of contents."; 121 case RESOURCE: return "This is a page that represents a presented resource. This is typically used for generated conformance resource presentations."; 122 default: return "?"; 123 } 124 } 125 public String getDisplay() { 126 switch (this) { 127 case PAGE: return "Page"; 128 case EXAMPLE: return "Example"; 129 case LIST: return "List"; 130 case INCLUDE: return "Include"; 131 case DIRECTORY: return "Directory"; 132 case DICTIONARY: return "Dictionary"; 133 case TOC: return "Table Of Contents"; 134 case RESOURCE: return "Resource"; 135 default: return "?"; 136 } 137 } 138 139 140} 141