ScreenshotException.fromPlatformException constructor

ScreenshotException.fromPlatformException({
  1. required String code,
  2. required String? message,
  3. dynamic details,
})

Create ScreenshotException from method channel error.

Implementation

factory ScreenshotException.fromPlatformException({
  required String code,
  required String? message,
  dynamic details,
}) {
  return ScreenshotException(
    code: code,
    message: message ?? 'Unknown error',
    details: details,
  );
}