trainUser method
Implementation
@override
Future<IAMPASSUser?> trainUser(IAMPASSUser registeredUser) async {
String encodedUser = json.encode(registeredUser.toJson());
Map<String, String> args = {"registered_user": encodedUser};
final result = await methodChannel.invokeMethod<String>('TrainUser', args);
if (result != null) {
Map<String, dynamic> map = jsonDecode(result);
final IAMPASSUser trainedUser = IAMPASSUser.fromJson(map);
return trainedUser;
}
return null;
}