Java Enum unused field warning
What am I doing wrong here?
public enum Type {
INFO("INFO"),
WARN("WARN"),
ERROR("ERROR"),
FATAL("FATAL");
private String value;
private Type(String aValue) {
value = aValue;
}
};
I get warning about value being unused...
all I can think about is using @SupressWarnings for it but I'm new to enum
so I'm just checking here if maybe I did something wrong... any thoughts?
No comments:
Post a Comment