Package org.opengis.metadata
Class Obligation
- All Implemented Interfaces:
Serializable
,Comparable<Obligation>
@UML(identifier="MD_ObligationCode",
specification=ISO_19115)
public final class Obligation
extends CodeList<Obligation>
Obligation of the element or entity.
- Since:
- 2.0
- Version:
- 3.0
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.opengis.util.CodeList
CodeList.Filter
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Obligation
Element is required when a specific condition is met.static final Obligation
Element is always required.static final Obligation
Element is not required.private static final long
Serial number for compatibility with different versions.private static final List
<Obligation> List of all enumerations of this type. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
Obligation
(String name) Constructs an enum with the given name. -
Method Summary
Modifier and TypeMethodDescriptionfamily()
Returns the list of enumerations of the same kind than this enum.static Obligation
Returns the obligation that matches the given string, or returns a new one if none match it.static Obligation[]
values()
Returns the list ofObligation
s.
-
Field Details
-
serialVersionUID
private static final long serialVersionUIDSerial number for compatibility with different versions.- See Also:
-
VALUES
List of all enumerations of this type. Must be declared before any enum declaration. -
MANDATORY
@UML(identifier="mandatory", obligation=CONDITIONAL, specification=ISO_19115) public static final Obligation MANDATORYElement is always required. -
OPTIONAL
@UML(identifier="optional", obligation=CONDITIONAL, specification=ISO_19115) public static final Obligation OPTIONALElement is not required. -
CONDITIONAL
@UML(identifier="conditional", obligation=CONDITIONAL, specification=ISO_19115) public static final Obligation CONDITIONALElement is required when a specific condition is met.
-
-
Constructor Details
-
Obligation
Constructs an enum with the given name. The new enum is automatically added to the list returned byvalues()
.- Parameters:
name
- The enum name. This name must not be in use by an other enum of this type.
-
-
Method Details
-
values
Returns the list ofObligation
s.- Returns:
- The list of codes declared in the current JVM.
-
family
Returns the list of enumerations of the same kind than this enum.- Specified by:
family
in classCodeList<Obligation>
- Returns:
- The codes of the same kind than this code.
-
valueOf
Returns the obligation that matches the given string, or returns a new one if none match it.- Parameters:
code
- The name of the code to fetch or to create.- Returns:
- A code matching the given name.
-