pub trait Container {
type Item: Item;
// Required methods
fn revision(&self) -> Revision;
fn items_as_parsed(&self) -> &[Uitem<Self::Item>];
// Provided methods
fn items(&self) -> Vec<Self::Item> { ... }
fn metadata_items(&self) -> Vec<&MetadataItem> { ... }
}Expand description
Trait for Unified containers, that exposes the items within them.
Required Associated Types§
Required Methods§
Sourcefn items_as_parsed(&self) -> &[Uitem<Self::Item>]
fn items_as_parsed(&self) -> &[Uitem<Self::Item>]
Returns all items (data and metadata) in the order they were parsed from the string encoding.
Provided Methods§
Sourcefn items(&self) -> Vec<Self::Item>
fn items(&self) -> Vec<Self::Item>
Returns the data items contained within this container, sorted in preference order.
Sourcefn metadata_items(&self) -> Vec<&MetadataItem>
fn metadata_items(&self) -> Vec<&MetadataItem>
Returns just the metadata items from this container.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".