get method
Future<Contact?>
get(
- String id, {
- Set<
ContactProperty> ? properties, - Account? account,
- bool androidLookup = false,
Implementation
Future<Contact?> get(
String id, {
Set<ContactProperty>? properties,
Account? account,
bool androidLookup = false,
}) async {
final props = properties ?? ContactProperties.none;
final result = await _channel.invokeMethod<Map>(
'crud.get',
_withIosNotes({
'id': id,
'properties': props.toJson(),
if (account != null) 'account': account.toJson(),
if (androidLookup) 'lookup': true,
}),
);
return JsonHelpers.decode(result, Contact.fromJson);
}