writeFileUriBytes method
Implementation
@override
Future<SafNewFile> writeFileUriBytes(
String fileUri,
Uint8List data, {
bool? append,
}) async {
// This calls the same native method as `writeFileBytes`, but with a different set of parameters.
final map = await methodChannel.invokeMapMethod<String, dynamic>(
'writeFileBytes',
{'fileUri': fileUri.toString(), 'data': data, 'append': append ?? false},
);
if (map == null) {
throw Exception('Unexpected empty response from `writeFileUriBytes`');
}
return SafNewFile.fromMap(map);
}