encodeSequence static method

Uint8List encodeSequence({
  1. required Uint8List content,
})

Implementation

static Uint8List encodeSequence({required Uint8List content}) {
  var encoded = Uint8List.fromList([]);
  encoded.add(ASN1Identifier.constructedTag |
      ASN1IdentifierTagNumber.SEQUENCE.toValue());
  encoded.addAll(contentLength(size: content.length));
  encoded.addAll(content);
  return Uint8List.fromList(encoded);
}