Struct shred::cell::TrustCell [−][src]
pub struct TrustCell<T> { /* fields omitted */ }
Expand description
A custom cell container that is a RefCell
with thread-safety.
Implementations
Consumes this cell and returns ownership of T
.
Get an immutable reference to the inner data.
Absence of write accesses is checked at run-time.
Panics
This function will panic if there is a mutable reference to the data already in use.
Get an immutable reference to the inner data.
Absence of write accesses is checked at run-time. If access is not possible, an error is returned.
Get a mutable reference to the inner data.
Exclusive access is checked at run-time.
Panics
This function will panic if there are any references to the data already in use.
Get a mutable reference to the inner data.
Exclusive access is checked at run-time. If access is not possible, an error is returned.
Trait Implementations
Auto Trait Implementations
impl<T> !RefUnwindSafe for TrustCell<T>
impl<T> UnwindSafe for TrustCell<T> where
T: UnwindSafe,