Package org.opengis.metadata
Class Obligation
- Object
-
- CodeList<Obligation>
-
- Obligation
-
- All Implemented Interfaces:
Serializable,Comparable<Obligation>,ControlledVocabulary
@UML(identifier="MD_ObligationCode", specification=ISO_19115) public final class Obligation extends CodeList<Obligation>
Obligation of the element or entity.Upcoming API change — enumeration
According ISO 19115,Obligationshall be an enumeration, not a code list. Such enumeration already exists in theorg.opengis.annotationpackage. Consequently thisObligationclass may be deleted in favor ororg.opengis.annotation.Obligationin GeoAPI 4.0. See GEO-199 for more information.- Since:
- 2.0
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class CodeList
CodeList.Filter
-
-
Field Summary
Fields Modifier and Type Field Description static ObligationCONDITIONALElement is required when a specific condition is met.static ObligationMANDATORYElement is always required.static ObligationOPTIONALElement is not required.
-
Method Summary
Modifier and Type Method Description Obligation[]family()Returns the list of codes of the same kind than this code list element.static ObligationvalueOf(String code)Returns the obligation that matches the given string, or returns a new one if none match it.static Obligation[]values()Returns the list ofObligations.
-
-
-
Field Detail
-
MANDATORY
@UML(identifier="mandatory", obligation=CONDITIONAL, specification=ISO_19115) public static final Obligation MANDATORY
Element is always required.
-
OPTIONAL
@UML(identifier="optional", obligation=CONDITIONAL, specification=ISO_19115) public static final Obligation OPTIONAL
Element is not required.
-
CONDITIONAL
@UML(identifier="conditional", obligation=CONDITIONAL, specification=ISO_19115) public static final Obligation CONDITIONAL
Element is required when a specific condition is met.
-
-
Method Detail
-
values
public static Obligation[] values()
Returns the list ofObligations.- Returns:
- The list of codes declared in the current JVM.
-
family
public Obligation[] family()
Returns the list of codes of the same kind than this code list element. Invoking this method is equivalent to invokingvalues(), except that this method can be invoked on an instance of the parentCodeListclass.- Specified by:
familyin interfaceControlledVocabulary- Specified by:
familyin classCodeList<Obligation>- Returns:
- All code values for this code list.
-
valueOf
public static Obligation valueOf(String code)
Returns the obligation that matches the given string, or returns a new one if none match it. More specifically, this methods returns the first instance for whichname().equals(code)returnstrue. If no existing instance is found, then a new one is created for the given name.- Parameters:
code- The name of the code to fetch or to create.- Returns:
- A code matching the given name.
-
-