Skip to main content

LookupKey

Trait LookupKey 

Source
pub trait LookupKey {
    // Required method
    fn lookup<'m, V>(&self, map: &'m HashMap<Key, V>) -> Option<&'m V>;
}
Expand description

A value that can locate an entry in a context without allocating a new key.

The crate implements this for the enabled key backend, so you rarely implement it yourself.

Required Methods§

Source

fn lookup<'m, V>(&self, map: &'m HashMap<Key, V>) -> Option<&'m V>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl LookupKey for &Key

Available on crate feature langid only.
Source§

impl LookupKey for Key

Available on crate feature langid only.