pub trait Encoding: SealedContainer {
// Provided methods
fn try_from_items(
revision: Revision,
items: Vec<Uitem<Self::Item>>,
) -> Result<Self, ParseError> { ... }
fn decode(s: &str) -> Result<(NetworkType, Revision, Self), ParseError> { ... }
fn encode(&self, network: &NetworkType) -> String { ... }
}Expand description
Trait providing common encoding and decoding logic for Unified containers.
Provided Methods§
Sourcefn try_from_items(
revision: Revision,
items: Vec<Uitem<Self::Item>>,
) -> Result<Self, ParseError>
fn try_from_items( revision: Revision, items: Vec<Uitem<Self::Item>>, ) -> Result<Self, ParseError>
Constructs a value of a unified container type from a vector of items, sorted according to typecode as specified in ZIP 316.
This function will return an error if ZIP 316 invariants are violated.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".