fromString method

SearchOrder? fromString(
  1. String val
)

Implementation

SearchOrder? fromString(String val) {
  final override = {
    'rank': SearchOrder.rank,
    'recent': SearchOrder.recent,
  }[val];
// ignore: unnecessary_this
  return this.contains(override) ? override : null;
}