fromValue static method

UIUserInterfaceIdiom fromValue(
  1. int value
)

Implementation

static UIUserInterfaceIdiom fromValue(int value) => switch (value) {
  -1 => UIUserInterfaceIdiomUnspecified,
  0 => UIUserInterfaceIdiomPhone,
  1 => UIUserInterfaceIdiomPad,
  2 => UIUserInterfaceIdiomTV,
  3 => UIUserInterfaceIdiomCarPlay,
  5 => UIUserInterfaceIdiomMac,
  _ => throw ArgumentError('Unknown value for UIUserInterfaceIdiom: $value'),
};