pub trait Message<'a>: Decodable<'a> {
fn fields<F, T>(&self, f: F) -> Result<T>
where
F: FnOnce(&[&dyn Encodable]) -> Result<T>;
}
Expand description
Messages encoded as an ASN.1 SEQUENCE
.
The “message” pattern this trait provides is not an ASN.1 concept,
but rather a pattern for writing ASN.1 DER decoders and encoders which
map ASN.1 SEQUENCE
types to Rust structs with a minimum of code.
Types which impl this trait receive blanket impls for the Decodable
,
Encodable
, and Tagged
traits.