Package de.intarsys.tools.enumeration
Class EnumItem
java.lang.Object
de.intarsys.tools.enumeration.EnumItem
- All Implemented Interfaces:
Comparable
The abstract superclass for an enumeration implementation.
To implement an enumeration class:
- create a subclass of EnumItem - create a final public static attribute named META to the EnumMeta of the class. final public static EnumMeta META = getMeta(XYZ.class); - create a final public static attribute for every member of the enumeration. public static final XYZ ABC = new XYZ("abxc","My ABC");
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
protected
protected
protected
protected
protected
-
Method Summary
-
Constructor Details
-
EnumItem
-
EnumItem
-
EnumItem
-
EnumItem
-
EnumItem
-
EnumItem
-
-
Method Details
-
getMeta
-
compareTo
- Specified by:
compareTo
in interfaceComparable
-
getDescription
-
getIconName
-
getId
-
getLabel
-
getLocalizedLabel
-
getMessage
-
getMeta
-
getTip
-
getWeight
protected int getWeight() -
setDefault
protected void setDefault() -
setIconName
-
toString
-