fromValue static method

IOSWritingToolsBehavior? fromValue(
  1. int? value
)

Gets a possible IOSWritingToolsBehavior instance from int value.

Implementation

static IOSWritingToolsBehavior? fromValue(int? value) {
  if (value != null) {
    try {
      return IOSWritingToolsBehavior.values.firstWhere(
        (element) => element.toValue() == value,
      );
    } catch (e) {
      return null;
    }
  }
  return null;
}