001/* 002 * GeoAPI - Java interfaces for OGC/ISO standards 003 * Copyright © 2004-2024 Open Geospatial Consortium, Inc. 004 * http://www.geoapi.org 005 * 006 * Licensed under the Apache License, Version 2.0 (the "License"); 007 * you may not use this file except in compliance with the License. 008 * You may obtain a copy of the License at 009 * 010 * http://www.apache.org/licenses/LICENSE-2.0 011 * 012 * Unless required by applicable law or agreed to in writing, software 013 * distributed under the License is distributed on an "AS IS" BASIS, 014 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 015 * See the License for the specific language governing permissions and 016 * limitations under the License. 017 */ 018package org.opengis.metadata.citation; 019 020import org.opengis.util.CodeList; 021import org.opengis.annotation.UML; 022import org.opengis.geoapi.internal.Vocabulary; 023 024import static org.opengis.annotation.Obligation.*; 025import static org.opengis.annotation.Specification.*; 026 027 028/** 029 * Mode in which the data is represented. 030 * 031 * @author Martin Desruisseaux (IRD) 032 * @author Rémi Maréchal (Geomatys) 033 * @version 3.1 034 * @since 2.0 035 */ 036@Vocabulary(capacity=21) 037@UML(identifier="CI_PresentationFormCode", specification=ISO_19115) 038public final class PresentationForm extends CodeList<PresentationForm> { 039 /** 040 * Serial number for compatibility with different versions. 041 */ 042 private static final long serialVersionUID = 5668779490885399888L; 043 044 /** 045 * Digital representation of a primarily textual item (can contain illustrations also). 046 */ 047 @UML(identifier="documentDigital", obligation=CONDITIONAL, specification=ISO_19115) 048 public static final PresentationForm DOCUMENT_DIGITAL = new PresentationForm("DOCUMENT_DIGITAL"); 049 050 /** 051 * Representation of a primarily textual item (can contain illustrations also) on paper, 052 * photographic material, or other media. 053 */ 054 @UML(identifier="documentHardcopy", obligation=CONDITIONAL, specification=ISO_19115) 055 public static final PresentationForm DOCUMENT_HARDCOPY = new PresentationForm("DOCUMENT_HARDCOPY"); 056 057 /** 058 * Likeness of natural or man-made features, objects, and activities acquired through 059 * the sensing of visual or any other segment of the electromagnetic spectrum by sensors, 060 * such as thermal infrared, and high resolution radar and stored in digital format. 061 */ 062 @UML(identifier="imageDigital", obligation=CONDITIONAL, specification=ISO_19115) 063 public static final PresentationForm IMAGE_DIGITAL = new PresentationForm("IMAGE_DIGITAL"); 064 065 /** 066 * Likeness of natural or man-made features, objects, and activities acquired through 067 * the sensing of visual or any other segment of the electromagnetic spectrum by sensors, 068 * such as thermal infrared, and high resolution radar and reproduced on paper, photographic 069 * material, or other media for use directly by the human user. 070 */ 071 @UML(identifier="imageHardcopy", obligation=CONDITIONAL, specification=ISO_19115) 072 public static final PresentationForm IMAGE_HARDCOPY = new PresentationForm("IMAGE_HARDCOPY"); 073 074 /** 075 * Map represented in raster or vector form. 076 */ 077 @UML(identifier="mapDigital", obligation=CONDITIONAL, specification=ISO_19115) 078 public static final PresentationForm MAP_DIGITAL = new PresentationForm("MAP_DIGITAL"); 079 080 /** 081 * Map printed on paper, photographic material, or other media for use directly by the 082 * human user. 083 */ 084 @UML(identifier="mapHardcopy", obligation=CONDITIONAL, specification=ISO_19115) 085 public static final PresentationForm MAP_HARDCOPY = new PresentationForm("MAP_HARDCOPY"); 086 087 /** 088 * Multi-dimensional digital representation of a feature, process, etc. 089 */ 090 @UML(identifier="modelDigital", obligation=CONDITIONAL, specification=ISO_19115) 091 public static final PresentationForm MODEL_DIGITAL = new PresentationForm("MODEL_DIGITAL"); 092 093 /** 094 * 3-dimensional, physical model. 095 */ 096 @UML(identifier="modelHardcopy", obligation=CONDITIONAL, specification=ISO_19115) 097 public static final PresentationForm MODEL_HARDCOPY = new PresentationForm("MODEL_HARDCOPY"); 098 099 /** 100 * Vertical cross-section in digital form. 101 */ 102 @UML(identifier="profileDigital", obligation=CONDITIONAL, specification=ISO_19115) 103 public static final PresentationForm PROFILE_DIGITAL = new PresentationForm("PROFILE_DIGITAL"); 104 105 /** 106 * Vertical cross-section printed on paper, etc. 107 */ 108 @UML(identifier="profileHardcopy", obligation=CONDITIONAL, specification=ISO_19115) 109 public static final PresentationForm PROFILE_HARDCOPY = new PresentationForm("PROFILE_HARDCOPY"); 110 111 /** 112 * Digital representation of facts or figures systematically displayed, especially in columns. 113 */ 114 @UML(identifier="tableDigital", obligation=CONDITIONAL, specification=ISO_19115) 115 public static final PresentationForm TABLE_DIGITAL = new PresentationForm("TABLE_DIGITAL"); 116 117 /** 118 * Representation of facts or figures systematically displayed, especially in columns, 119 * printed on paper, photographic material, or other media. 120 */ 121 @UML(identifier="tableHardcopy", obligation=CONDITIONAL, specification=ISO_19115) 122 public static final PresentationForm TABLE_HARDCOPY = new PresentationForm("TABLE_HARDCOPY"); 123 124 /** 125 * Digital video recording. 126 */ 127 @UML(identifier="videoDigital", obligation=CONDITIONAL, specification=ISO_19115) 128 public static final PresentationForm VIDEO_DIGITAL = new PresentationForm("VIDEO_DIGITAL"); 129 130 /** 131 * Video recording on film. 132 */ 133 @UML(identifier="videoHardcopy", obligation=CONDITIONAL, specification=ISO_19115) 134 public static final PresentationForm VIDEO_HARDCOPY = new PresentationForm("VIDEO_HARDCOPY"); 135 136 /** 137 * Digital audio recording. 138 * 139 * @since 3.1 140 */ 141 @UML(identifier="audioDigital", obligation=CONDITIONAL, specification=ISO_19115) 142 public static final PresentationForm AUDIO_DIGITAL = new PresentationForm("AUDIO_DIGITAL"); 143 144 /** 145 * Audio recording delivered by analog media, such as a magnetic tape 146 * 147 * @since 3.1 148 */ 149 @UML(identifier="audioHardcopy", obligation=CONDITIONAL, specification=ISO_19115) 150 public static final PresentationForm AUDIO_HARDCOPY = new PresentationForm("AUDIO_HARDCOPY"); 151 152 /** 153 * Information representation using simultaneously various digital modes for text, sound, image. 154 * 155 * @since 3.1 156 */ 157 @UML(identifier="multimediaDigital", obligation=CONDITIONAL, specification=ISO_19115) 158 public static final PresentationForm MULTIMEDIA_DIGITAL = new PresentationForm("MULTIMEDIA_DIGITAL"); 159 160 /** 161 * Information representation using simultaneously various analog modes for text, sound, image. 162 * 163 * @since 3.1 164 */ 165 @UML(identifier="multimediaHardcopy", obligation=CONDITIONAL, specification=ISO_19115) 166 public static final PresentationForm MULTIMEDIA_HARDCOPY = new PresentationForm("MULTIMEDIA_HARDCOPY"); 167 168 /** 169 * A physical object. 170 * 171 * <div class="note"><b>Example:</b> 172 * rock or mineral sample, microscope slide. 173 * </div> 174 * 175 * @since 3.1 176 */ 177 @UML(identifier="physicalObject", obligation=CONDITIONAL, specification=ISO_19115) 178 public static final PresentationForm PHYSICAL_OBJECT = new PresentationForm("PHYSICAL_OBJECT"); 179 180 /** 181 * Information represented graphically by charts such as pie chart, bar chart, 182 * and other type of diagrams and recorded in digital format. 183 * 184 * @since 3.1 185 */ 186 @UML(identifier="diagramDigital", obligation=CONDITIONAL, specification=ISO_19115) 187 public static final PresentationForm DIAGRAM_DIGITAL = new PresentationForm("DIAGRAM_DIGITAL"); 188 189 /** 190 * Information represented graphically by charts such as pie chart, bar chart, 191 * and other type of diagrams and printed on paper, photographic material, or other media. 192 * 193 * @since 3.1 194 */ 195 @UML(identifier="diagramHardcopy", obligation=CONDITIONAL, specification=ISO_19115) 196 public static final PresentationForm DIAGRAM_HARDCOPY = new PresentationForm("DIAGRAM_HARDCOPY"); 197 198 /** 199 * Constructs an element of the given name. 200 * 201 * @param name the name of the new element. This name shall not be in use by another element of this type. 202 */ 203 private PresentationForm(final String name) { 204 super(name); 205 } 206 207 /** 208 * Returns the list of {@code PresentationForm}s. 209 * 210 * @return the list of codes declared in the current JVM. 211 */ 212 public static PresentationForm[] values() { 213 return values(PresentationForm.class); 214 } 215 216 /** 217 * Returns the list of codes of the same kind as this code list element. 218 * Invoking this method is equivalent to invoking {@link #values()}, except that 219 * this method can be invoked on an instance of the parent {@code CodeList} class. 220 * 221 * @return all code {@linkplain #values() values} for this code list. 222 */ 223 @Override 224 public PresentationForm[] family() { 225 return values(); 226 } 227 228 /** 229 * Returns the presentation form that matches the given string, or returns a new one if none match it. 230 * This methods returns the first instance (in declaration order) for which the {@linkplain #name() name} 231 * is {@linkplain String#equalsIgnoreCase(String) equals, ignoring case}, to the given name. 232 * If no existing instance is found, then a new one is created for the given name. 233 * 234 * @param code the name of the code to fetch or to create. 235 * @return a code matching the given name. 236 */ 237 public static PresentationForm valueOf(String code) { 238 return valueOf(PresentationForm.class, code, PresentationForm::new).get(); 239 } 240}