34 lines
805 B
Java
34 lines
805 B
Java
package eu.eudat.commons.enums.notification;
|
|
|
|
import com.fasterxml.jackson.annotation.JsonValue;
|
|
import eu.eudat.commons.enums.EnumUtils;
|
|
import eu.eudat.data.converters.enums.DatabaseEnum;
|
|
|
|
import java.util.Map;
|
|
|
|
public enum NotificationNotifyState implements DatabaseEnum<Short> {
|
|
PENDING((short)0),
|
|
PROCESSING((short)1),
|
|
SUCCESSFUL((short)2),
|
|
ERROR((short)3),
|
|
OMITTED((short)4);
|
|
|
|
private final Short value;
|
|
|
|
NotificationNotifyState(Short value) {
|
|
this.value = value;
|
|
}
|
|
|
|
@JsonValue
|
|
public Short getValue() {
|
|
return value;
|
|
}
|
|
|
|
private static final Map<Short, NotificationNotifyState> map = EnumUtils.getEnumValueMap(NotificationNotifyState.class);
|
|
|
|
public static NotificationNotifyState of(Short i) {
|
|
return map.get(i);
|
|
}
|
|
|
|
}
|