pub trait Container {
type Data;
// Required method
fn init(data: Self::Data) -> Self;
}Expand description
Init is a trait used in ServiceProvider for create an empty version of Container. If you
create your own version of container and you want that it can work with other container like
ConvertContainer, you must implement this trait.
Required Associated Types§
Required Methods§
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.