001    /*
002     *    GeoAPI - Java interfaces for OGC/ISO standards
003     *    http://www.geoapi.org
004     *
005     *    Copyright (C) 2004-2012 Open Geospatial Consortium, Inc.
006     *    All Rights Reserved. http://www.opengeospatial.org/ogc/legal
007     *
008     *    Permission to use, copy, and modify this software and its documentation, with
009     *    or without modification, for any purpose and without fee or royalty is hereby
010     *    granted, provided that you include the following on ALL copies of the software
011     *    and documentation or portions thereof, including modifications, that you make:
012     *
013     *    1. The full text of this NOTICE in a location viewable to users of the
014     *       redistributed or derivative work.
015     *    2. Notice of any changes or modifications to the OGC files, including the
016     *       date changes were made.
017     *
018     *    THIS SOFTWARE AND DOCUMENTATION IS PROVIDED "AS IS," AND COPYRIGHT HOLDERS MAKE
019     *    NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
020     *    TO, WARRANTIES OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE OR THAT
021     *    THE USE OF THE SOFTWARE OR DOCUMENTATION WILL NOT INFRINGE ANY THIRD PARTY
022     *    PATENTS, COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS.
023     *
024     *    COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR
025     *    CONSEQUENTIAL DAMAGES ARISING OUT OF ANY USE OF THE SOFTWARE OR DOCUMENTATION.
026     *
027     *    The name and trademarks of copyright holders may NOT be used in advertising or
028     *    publicity pertaining to the software without specific, written prior permission.
029     *    Title to copyright in this software and any associated documentation will at all
030     *    times remain with copyright holders.
031     */
032    package org.opengis.metadata;
033    
034    import java.util.Collection;
035    import org.opengis.util.InternationalString;
036    import org.opengis.metadata.citation.ResponsibleParty;
037    import org.opengis.annotation.UML;
038    
039    import static org.opengis.annotation.Obligation.*;
040    import static org.opengis.annotation.Specification.*;
041    
042    
043    /**
044     * New metadata element, not found in ISO 19115, which is required to describe geographic data.
045     *
046     * @author  Martin Desruisseaux (IRD)
047     * @version 3.0
048     * @since   2.0
049     *
050     * @navassoc 1 - - Obligation
051     * @navassoc 1 - - Datatype
052     * @navassoc - - - ResponsibleParty
053     */
054    @UML(identifier="MD_ExtendedElementInformation", specification=ISO_19115)
055    public interface ExtendedElementInformation {
056        /**
057         * Name of the extended metadata element.
058         *
059         * @return Name of the extended metadata element.
060         */
061        @UML(identifier="name", obligation=MANDATORY, specification=ISO_19115)
062        String getName();
063    
064        /**
065         * Short form suitable for use in an implementation method such as XML or SGML.
066         * Returns {@code null} if the {@linkplain #getDataType data type}
067         * is {@linkplain Datatype#CODE_LIST_ELEMENT code list element}, in which case
068         * {@link #getDomainCode()} may be used instead.
069         *
070         * @return Short form suitable for use in an implementation method such as XML or SGML,
071         *         or {@code null}.
072         *
073         * @condition {@linkplain #getDataType Data type} not equal
074         *            {@link Datatype#CODE_LIST_ELEMENT CODE_LIST_ELEMENT}.
075         */
076        @UML(identifier="shortName", obligation=CONDITIONAL, specification=ISO_19115)
077        String getShortName();
078    
079        /**
080         * Three digit code assigned to the extended element.
081         * Returns a non-null value only if the {@linkplain #getDataType data type}
082         * is {@linkplain Datatype#CODE_LIST_ELEMENT code list element}, in which case
083         * {@link #getShortName()} may be used instead.
084         *
085         * @return Three digit code assigned to the extended element, or {@code null}.
086         *
087         * @condition {@linkplain #getDataType Data type} not equal
088         *            {@link Datatype#CODE_LIST_ELEMENT CODE_LIST_ELEMENT}.
089         */
090        @UML(identifier="domainCode", obligation=CONDITIONAL, specification=ISO_19115)
091        Integer getDomainCode();
092    
093        /**
094         * Definition of the extended element.
095         *
096         * @return Definition of the extended element.
097         */
098        @UML(identifier="definition", obligation=MANDATORY, specification=ISO_19115)
099        InternationalString getDefinition();
100    
101        /**
102         * Obligation of the extended element.
103         *
104         * @return Obligation of the extended element, or {@code null}.
105         *
106         * @condition {@linkplain #getDataType Data type} not equal
107         *            {@link Datatype#CODE_LIST CODE_LIST} or
108         *            {@link Datatype#ENUMERATION ENUMERATION} or
109         *            {@link Datatype#CODE_LIST_ELEMENT CODE_LIST_ELEMENT}.
110         */
111        @UML(identifier="obligation", obligation=CONDITIONAL, specification=ISO_19115)
112        Obligation getObligation();
113    
114        /**
115         * Condition under which the extended element is mandatory.
116         * Returns a non-null value only if the {@linkplain #getObligation obligation}
117         * is {@linkplain Obligation#CONDITIONAL conditional}.
118         *
119         * @return The condition under which the extended element is mandatory, or {@code null}.
120         *
121         * @condition {@linkplain #getObligation Obligation} equals
122         *            {@link Obligation#CONDITIONAL CONDITIONAL}.
123         */
124        @UML(identifier="condition", obligation=CONDITIONAL, specification=ISO_19115)
125        InternationalString getCondition();
126    
127        /**
128         * Code which identifies the kind of value provided in the extended element.
129         *
130         * @return The kind of value provided in the extended element.
131         */
132        @UML(identifier="dataType", obligation=MANDATORY, specification=ISO_19115)
133        Datatype getDataType();
134    
135        /**
136         * Maximum occurrence of the extended element.
137         * Returns {@code null} if it doesn't apply, for example if the
138         * {@linkplain #getDataType data type} is {@linkplain Datatype#ENUMERATION enumeration},
139         * {@linkplain Datatype#CODE_LIST code list} or {@linkplain Datatype#CODE_LIST_ELEMENT
140         * code list element}.
141         *
142         * @return Maximum occurrence of the extended element, or {@code null}.
143         */
144        @UML(identifier="maximumOccurrence", obligation=CONDITIONAL, specification=ISO_19115)
145        Integer getMaximumOccurrence();
146    
147        /**
148         * Valid values that can be assigned to the extended element.
149         * Returns {@code null} if it doesn't apply, for example if the
150         * {@linkplain #getDataType data type} is {@linkplain Datatype#ENUMERATION enumeration},
151         * {@linkplain Datatype#CODE_LIST code list} or {@linkplain Datatype#CODE_LIST_ELEMENT
152         * code list element}.
153         *
154         * @return Valid values that can be assigned to the extended element, or {@code null}.
155         *
156         * @condition {@linkplain #getDataType Data type} not {@link Datatype#ENUMERATION ENUMERATION},
157         *            {@link Datatype#CODE_LIST CODE_LIST} or {@link Datatype#CODE_LIST_ELEMENT
158         *            CODE_LIST_ELEMENT}.
159         */
160        @UML(identifier="domainValue", obligation=CONDITIONAL, specification=ISO_19115)
161        InternationalString getDomainValue();
162    
163        /**
164         * Name of the metadata entity(s) under which this extended metadata element may appear.
165         * The name(s) may be standard metadata element(s) or other extended metadata element(s).
166         *
167         * @return Name of the metadata entity(s) under which this extended metadata element may appear.
168         */
169        @UML(identifier="parentEntity", obligation=MANDATORY, specification=ISO_19115)
170        Collection<String> getParentEntity();
171    
172        /**
173         * Specifies how the extended element relates to other existing elements and entities.
174         *
175         * @return How the extended element relates to other existing elements and entities.
176         */
177        @UML(identifier="rule", obligation=MANDATORY, specification=ISO_19115)
178        InternationalString getRule();
179    
180        /**
181         * Reason for creating the extended element.
182         *
183         * @return Reason for creating the extended element.
184         */
185        @UML(identifier="rationale", obligation=OPTIONAL, specification=ISO_19115)
186        Collection<? extends InternationalString> getRationales();
187    
188        /**
189         * Name of the person or organization creating the extended element.
190         *
191         * @return Name of the person or organization creating the extended element.
192         */
193        @UML(identifier="source", obligation=MANDATORY, specification=ISO_19115)
194        Collection<? extends ResponsibleParty> getSources();
195    }