pub struct Nw<T: ?Sized>(/* private fields */);
Expand description
Weak reference to node.
Implementations§
Source§impl<T: ?Sized> Nw<T>
impl<T: ?Sized> Nw<T>
Sourcepub fn upgrade(&self) -> Option<Nr<T>>
pub fn upgrade(&self) -> Option<Nr<T>>
Create strong pointer to this node.
Returns None
if the inner value has since been dropped.
Sourcepub fn strong_count(&self) -> usize
pub fn strong_count(&self) -> usize
Get the number of strong pointer to this node.
Sourcepub fn weak_count(&self) -> usize
pub fn weak_count(&self) -> usize
Get the number of weak pointer to this node.
Trait Implementations§
Source§impl<T: ?Sized> Ord for Nw<T>
impl<T: ?Sized> Ord for Nw<T>
Source§impl<T: ?Sized> PartialOrd for Nw<T>
impl<T: ?Sized> PartialOrd for Nw<T>
impl<T: ?Sized> Eq for Nw<T>
Auto Trait Implementations§
impl<T> Freeze for Nw<T>where
T: ?Sized,
impl<T> !RefUnwindSafe for Nw<T>
impl<T> !Send for Nw<T>
impl<T> !Sync for Nw<T>
impl<T> Unpin for Nw<T>where
T: ?Sized,
impl<T> !UnwindSafe for Nw<T>
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