/** * Parses a serialized value to a Action instance. * * @param value the serialized value to parse. * @return the parsed Action object, or null if unable to parse. */ @JsonCreator public static Action fromString(String value) { Action[] items = Action.values(); for (Action item : items) { if (item.toString().equalsIgnoreCase(value)) { return item; } } return null; }
/** * Parses a serialized value to a Action instance. * * @param value the serialized value to parse. * @return the parsed Action object, or null if unable to parse. */ @JsonCreator public static Action fromString(String value) { Action[] items = Action.values(); for (Action item : items) { if (item.toString().equalsIgnoreCase(value)) { return item; } } return null; }