Struct cell_rc::CellRc
[−]
[src]
pub struct CellRc<T: ?Sized> { /* fields omitted */ }
Wrapper around Rc<T>
Methods
impl<T: ?Sized> CellRc<T>
[src]
fn new(rc: Rc<T>) -> Self
Creates a new CellRc<T>
from a Rc<T>
fn into_inner(self) -> Rc<T>
Consumes a CellRc<T>
, returning the wrapped Rc<T>
fn get(&self) -> Rc<T>
Returns a clone of the wrapped Rc<T>
, incresing the strong count.
fn set(&self, rc: Rc<T>) -> Rc<T>
Sets the wrapped Rc<T>
to a new value and returns the old one.
fn downgrade(&self) -> Weak<T>
Creares a Weak<T>
. See Rc::downgrade
fn downgrade_cell(&self) -> CellWeak<T>
Creates a CellWeak<T>
.
fn weak_count(&self) -> usize
See Rc::weak_count
.
fn strong_count(&self) -> usize
See Rc::strong_count
.
fn ptr_eq(&self, other: &Rc<T>) -> bool
See Rc::ptr_eq
.
fn ptr_eq_cell(&self, other: &Self) -> bool
See Rc::ptr_eq
.
impl<T> CellRc<T>
[src]
fn try_unwrap(self) -> Result<T, Self>
See Rc::try_unwrap
.
fn into_raw(self) -> *const T
See Rc::into_raw
.
unsafe fn from_raw(ptr: *const T) -> Self
See Rc::from_raw
.
Trait Implementations
impl<T: Debug + ?Sized> Debug for CellRc<T>
[src]
impl<T: ?Sized> From<Rc<T>> for CellRc<T>
[src]
impl<T: ?Sized> Clone for CellRc<T>
[src]
fn clone(&self) -> Self
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more