from static method

LetterGrade from(
  1. Object? v
)

Implementation

static LetterGrade from(Object? v) => switch (v) {
      'a' => a,
      'b' => b,
      'c' => c,
      'd' => d,
      'f' => f,
      _ => unknown,
    };