Function der_parser::der::parse_der_set_of
source · pub fn parse_der_set_of<'a, F>(f: F) -> impl FnMut(&'a [u8]) -> BerResult<'_>
Expand description
Parse a SET OF object
Given a subparser for a DER type, parse a set of identical objects.
/// Read a SET OF INTEGER
fn parser(i:&[u8]) -> BerResult<DerObject> {
parse_der_set_of(parse_der_integer)(i)
}
let (rem, v) = parser(&bytes).expect("parsing failed");