MessageNotificationLevel.parse constructor

MessageNotificationLevel.parse(
  1. int value
)

Parses a MessageNotificationLevel from an int.

The value must be a valid message notification level.

Implementation

factory MessageNotificationLevel.parse(int value) => MessageNotificationLevel.values.firstWhere(
      (level) => level.value == value,
      orElse: () => throw FormatException('Invalid message notification level', value),
    );