modifyDocument method

Future<EncryptedDocument> modifyDocument(
  1. String sdkId,
  2. EncryptedDocument entity
)

Implementation

Future<EncryptedDocument> modifyDocument(String sdkId, EncryptedDocument entity) async {
	final res = await _methodChannel.invokeMethod<String>(
		'DocumentApi.encrypted.modifyDocument',
		{
			"sdkId": sdkId,
			"entity": jsonEncode(EncryptedDocument.encode(entity)),
		}
	);
	if (res == null) throw AssertionError("received null result from platform method modifyDocument");
	final parsedResJson = jsonDecode(res);
	return EncryptedDocument.fromJSON(parsedResJson);
}