pub struct WeakInternString { /* private fields */ }Expand description
A weak interned string.
Similar to Weak
Implementations§
Source§impl WeakInternString
impl WeakInternString
Sourcepub fn is_alive(&self) -> bool
pub fn is_alive(&self) -> bool
Returns true if the string is still alive The string is considered dead if there are no strong references
Sourcepub fn into_strong(&self) -> Option<InternString>
pub fn into_strong(&self) -> Option<InternString>
Converts to a strong reference if the string is still alive
Trait Implementations§
Source§impl Clone for WeakInternString
impl Clone for WeakInternString
Source§impl Debug for WeakInternString
impl Debug for WeakInternString
Source§impl Display for WeakInternString
impl Display for WeakInternString
Source§impl Drop for WeakInternString
impl Drop for WeakInternString
Source§impl Hash for WeakInternString
impl Hash for WeakInternString
Source§impl PartialEq<&str> for WeakInternString
impl PartialEq<&str> for WeakInternString
Source§impl PartialEq<InternString> for WeakInternString
impl PartialEq<InternString> for WeakInternString
Source§fn eq(&self, other: &InternString) -> bool
fn eq(&self, other: &InternString) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialEq<WeakInternString> for InternString
impl PartialEq<WeakInternString> for InternString
Source§fn eq(&self, other: &WeakInternString) -> bool
fn eq(&self, other: &WeakInternString) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialEq for WeakInternString
impl PartialEq for WeakInternString
Source§fn eq(&self, other: &WeakInternString) -> bool
fn eq(&self, other: &WeakInternString) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for WeakInternString
impl Send for WeakInternString
impl StructuralPartialEq for WeakInternString
impl Sync for WeakInternString
Auto Trait Implementations§
impl Freeze for WeakInternString
impl RefUnwindSafe for WeakInternString
impl Unpin for WeakInternString
impl UnsafeUnpin for WeakInternString
impl UnwindSafe for WeakInternString
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