Struct jrsonnet_gcmodule::RawWeak
source · [−]pub struct RawWeak<T: ?Sized, O: AbstractObjectSpace>(_);
Expand description
Low-level type for Weak<T>
.
Implementations
sourceimpl<T: ?Sized, O: AbstractObjectSpace> RawWeak<T, O>
impl<T: ?Sized, O: AbstractObjectSpace> RawWeak<T, O>
sourcepub fn upgrade(&self) -> Option<RawCc<T, O>>
pub fn upgrade(&self) -> Option<RawCc<T, O>>
Attempts to obtain a “strong reference”.
Returns None
if the value has already been dropped.
sourcepub fn strong_count(&self) -> usize
pub fn strong_count(&self) -> usize
Gets the reference count not considering weak references.
sourcepub fn weak_count(&self) -> usize
pub fn weak_count(&self) -> usize
Get the weak (non-owning) reference count.
Trait Implementations
impl<T: UnwindSafe + ?Sized, O: AbstractObjectSpace> UnwindSafe for RawWeak<T, O>
Auto Trait Implementations
impl<T, O> !RefUnwindSafe for RawWeak<T, O>
impl<T, O> !Send for RawWeak<T, O>
impl<T, O> !Sync for RawWeak<T, O>
impl<T: ?Sized, O> Unpin for RawWeak<T, O>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more