PemPart.decodeLabelled constructor
Implementation
factory PemPart.decodeLabelled(String pem, List<String> labels) {
final lines = pem.split(_newlineRegexp).reversed.toList();
while (true) {
final part = _decodeNextPem(lines);
if (part == null) break;
if (labels.contains(part.label)) return part;
}
throw Exception('No block found');
}