fromValue static method

UIInterfaceOrientation fromValue(
  1. int value
)

Implementation

static UIInterfaceOrientation fromValue(int value) => switch (value) {
  0 => UIInterfaceOrientationUnknown,
  1 => UIInterfaceOrientationPortrait,
  2 => UIInterfaceOrientationPortraitUpsideDown,
  4 => UIInterfaceOrientationLandscapeLeft,
  3 => UIInterfaceOrientationLandscapeRight,
  _ => throw ArgumentError('Unknown value for UIInterfaceOrientation: $value'),
};