getPatient method

Future<GroupScoped<EncryptedPatient>?> getPatient(
  1. String sdkId,
  2. String groupId,
  3. String entityId
)

Implementation

Future<GroupScoped<EncryptedPatient>?> getPatient(String sdkId, String groupId, String entityId) async {
	final res = await _methodChannel.invokeMethod<String>(
		'PatientBasicApi.inGroup.getPatient',
		{
			"sdkId": sdkId,
			"groupId": jsonEncode(groupId),
			"entityId": jsonEncode(entityId),
		}
	).catchError(convertPlatformException);
	if (res == null) throw AssertionError("received null result from platform method getPatient");
	final parsedResJson = jsonDecode(res);
	return parsedResJson == null ? null : GroupScoped.fromJSON(
		parsedResJson,
		(x1) {
			return EncryptedPatient.fromJSON(x1);
		},
	);
}