getFile static method
get medium file by medium id
Implementation
static Future<File> getFile({
required String mediumId,
MediumType? mediumType,
String? mimeType,
}) async {
final path = await _channel.invokeMethod('getFile', {
'mediumId': mediumId,
'mediumType': mediumTypeToJson(mediumType),
'mimeType': mimeType,
}) as String?;
if (path == null) throw "Cannot get file $mediumId with type $mimeType";
return File(path);
}