pub trait Decode {
// Required method
fn build(layout: &Layout, symbols: &dyn Sym, visitor: &mut Visitor) -> Self;
}Expand description
A type that can be decoded from a layout, symbols and a visitor.
Required Methods§
Sourcefn build(layout: &Layout, symbols: &dyn Sym, visitor: &mut Visitor) -> Self
fn build(layout: &Layout, symbols: &dyn Sym, visitor: &mut Visitor) -> Self
Creates a value of Self corresponding to the supplied information.
The input parameters are already guaranteed to be correctly formed. Therefore, no decode errors are expected from this function. If necessary, this code should panic, indicating a bug in the caller code.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.