pub trait GetIDValue<K: ID, V> {
// Required method
fn get_id_value<S: Borrow<str> + ?Sized>(
&self,
id: &S,
) -> Result<(&K, &V), MissingIDError<K>>;
}Expand description
A trait for getting an ID and a value from a map
Required Methods§
Sourcefn get_id_value<S: Borrow<str> + ?Sized>(
&self,
id: &S,
) -> Result<(&K, &V), MissingIDError<K>>
fn get_id_value<S: Borrow<str> + ?Sized>( &self, id: &S, ) -> Result<(&K, &V), MissingIDError<K>>
Get the ID and value, if any, for the given collection
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.