I Have this enum
public enum Reos {
VALUE1(\"A\"),VALUE2(\"B\");
private String text;
Reos(String text){this.text = text;}
I've found what I need. http://chrisjordan.ca/post/50865405944/custom-json-serialization-for-enums-using-jackson.
It was 2 steps.
@Override
public String toString() {
return text;
}
@JsonCreator
public static Reos fromText(String text)
And that's all.
I hope this could help others facing the same problem.