shareWithMany method

Future<EncryptedMessage> shareWithMany(
  1. String sdkId,
  2. EncryptedMessage message,
  3. Map<String, MessageShareOptions> delegates
)

Implementation

Future<EncryptedMessage> shareWithMany(String sdkId, EncryptedMessage message, Map<String, MessageShareOptions> delegates) async {
	final res = await _methodChannel.invokeMethod<String>(
		'MessageApi.encrypted.shareWithMany',
		{
			"sdkId": sdkId,
			"message": jsonEncode(EncryptedMessage.encode(message)),
			"delegates": jsonEncode(delegates.map((k0, v0) => MapEntry(k0, MessageShareOptions.encode(v0)))),
		}
	);
	if (res == null) throw AssertionError("received null result from platform method shareWithMany");
	final parsedResJson = jsonDecode(res);
	return EncryptedMessage.fromJSON(parsedResJson);
}