Package org.apache.sis.internal.jaxb.cat
Class EnumAdapter<ValueType extends EnumAdapter<ValueType,BoundType>,BoundType extends Enum<BoundType>>
java.lang.Object
javax.xml.bind.annotation.adapters.XmlAdapter<ValueType,BoundType>
org.apache.sis.internal.jaxb.cat.EnumAdapter<ValueType,BoundType>
- Type Parameters:
ValueType
- the subclass implementing this adapter.BoundType
- the enum being adapted.
- Direct Known Subclasses:
MD_ObligationCode
public abstract class EnumAdapter<ValueType extends EnumAdapter<ValueType,BoundType>,BoundType extends Enum<BoundType>>
extends XmlAdapter<ValueType,BoundType>
An adapter for
Enum
, in order to implement the ISO 19115-3 standard.
Example:
- Since:
- 0.5
- Version:
- 1.0
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class javax.xml.bind.annotation.adapters.XmlAdapter
marshal, unmarshal
-
Constructor Details
-
EnumAdapter
protected EnumAdapter()For subclass constructors.
-
-
Method Details
-
name
Converts the given XML value to an enumeration constant name.- Parameters:
value
- the text in the XML element.- Returns:
- the presumed enumeration constant name.
-
value
Returns the text to write in the XML element for the given enumeration constant.- Parameters:
e
- the enumeration constant.- Returns:
- the text to write in the XML element.
-