enum
type is the source of database column values for an
enumerated mapping. The annotated
field must be declared final, and must be of type:
byte, short, or int for
EnumType#ORDINAL, or
String for EnumType#STRING.
Example:
enum Status {
OPEN(0), CLOSED(1), CANCELLED(-1);
@EnumeratedValue
final int intValue;
Status(int intValue) {
this.intValue = intValue;
}
}
Enumerated, EnumType