Struct metainfo::FastStrMap
source · pub struct FastStrMap { /* private fields */ }
Expand description
This is an optimized version of TypeMap to FastStr that eliminates the need to Box the values.
This map is suitable for T that impls both From
Implementations§
source§impl FastStrMap
impl FastStrMap
pub fn new() -> Self
pub fn with_capacity(capacity: usize) -> Self
pub fn insert<T: Send + Sync + 'static>(&mut self, t: FastStr)
pub fn get<T: 'static>(&self) -> Option<&FastStr>
pub fn get_mut<T: 'static>(&mut self) -> Option<&mut FastStr>
pub fn contains<T: 'static>(&self) -> bool
pub fn remove<T: 'static>(&mut self) -> Option<FastStr>
pub fn clear(&mut self)
pub fn extend(&mut self, other: FastStrMap)
pub fn iter(&self) -> Iter<'_, TypeId, FastStr>
pub fn entry<T: 'static>(&mut self) -> Entry<'_, TypeId, FastStr>
pub fn is_empty(&self) -> bool
pub fn len(&self) -> usize
pub fn capacity(&self) -> usize
Trait Implementations§
source§impl Debug for FastStrMap
impl Debug for FastStrMap
source§impl Default for FastStrMap
impl Default for FastStrMap
source§fn default() -> FastStrMap
fn default() -> FastStrMap
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for FastStrMap
impl RefUnwindSafe for FastStrMap
impl Send for FastStrMap
impl Sync for FastStrMap
impl Unpin for FastStrMap
impl UnwindSafe for FastStrMap
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more