getInstalledCertificates method

  1. @override
Future<List<Certificate>> getInstalledCertificates()
override

Получит список установленных сертификатов

Implementation

@override
Future<List<Certificate>> getInstalledCertificates() async {
  try {
    String response = await methodChannel.invokeMethod("getInstalledCertificates");
    Map<String, dynamic> map = json.decode(response);
    final certificatesMaps = List<Map<String, dynamic>>.from(map['certificates'] as List);
    return certificatesMaps.map((e) => Certificate.fromMap(e)).toList();
  } catch (exception) {
    throw Exception();
  }
}