shareWith method

Future<EncryptedContact> shareWith(
  1. String sdkId,
  2. String delegateId,
  3. EncryptedContact contact,
  4. ContactShareOptions? options,
)

Implementation

Future<EncryptedContact> shareWith(String sdkId, String delegateId, EncryptedContact contact, ContactShareOptions? options) async {
	final res = await _methodChannel.invokeMethod<String>(
		'ContactApi.encrypted.shareWith',
		{
			"sdkId": sdkId,
			"delegateId": jsonEncode(delegateId),
			"contact": jsonEncode(EncryptedContact.encode(contact)),
			"options": jsonEncode(options == null ? null : ContactShareOptions.encode(options!)),
		}
	);
	if (res == null) throw AssertionError("received null result from platform method shareWith");
	final parsedResJson = jsonDecode(res);
	return EncryptedContact.fromJSON(parsedResJson);
}