fromString static method

IcsStatus fromString(
  1. String key
)

Implementation

static IcsStatus fromString(String key) {
  final effectiveKey = key.toUpperCase();
  return IcsStatus.values.firstWhere(
    (e) => e.key == effectiveKey,
    orElse: () {
      throw ICalendarStatusParseException('Unknown IcsStatus: $key');
    },
  );
}