fromString<T> static method
Implementation
static T? fromString<T>(List<T> enumValues, String value) {
try {
return enumValues.singleWhere(
(dynamic enumItem) =>
EnumToString.convertToString(enumItem).toLowerCase() ==
value.toLowerCase(),
);
} on Exception {
return null;
}
}