shareWithMany method

Future<EncryptedTopic> shareWithMany(
  1. String sdkId,
  2. EncryptedTopic topic,
  3. Map<String, TopicShareOptions> delegates
)

Implementation

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