fromValue static method

SortByOrderEnum? fromValue(
  1. String value
)

Implementation

static SortByOrderEnum? fromValue(String value) {
  try {
    return SortByOrderEnum.values.firstWhere((e) => e.value == value);
  } catch (_) {
    return null;
  }
}