resolveContentToFile static method
Save the content of the specified content:xxxx style URI to a file.
Implementation
static Future<ContentMetadata> resolveContentToFile(
String uri,
String filePath,
) async {
try {
final result = await _channel.invokeMethod('saveContentToFile', {
"uri": uri,
"filePath": filePath,
});
return ContentMetadata(
mimeType: result['mimeType'] as String?,
fileName: result['fileName'] as String?,
);
} on Exception {
throw Exception('Handling URI "$uri" failed.');
}
}