[][src]Struct shared_arena::PoolBox

pub struct PoolBox<T> { /* fields omitted */ }

A pointer to T in Pool

PoolBox implements DerefMut so it is directly mutable (without mutex or other synchronization methods).

It is not clonable and cannot be sent to others threads.

let pool = Pool::new();
let mut my_opt: PoolBox<Option<i32>> = pool.alloc(Some(10));

assert!(my_opt.is_some());
assert_eq!(my_opt.take(), Some(10));
assert!(my_opt.is_none());

Trait Implementations

impl<T> Deref for PoolBox<T>[src]

type Target = T

The resulting type after dereferencing.

impl<T> DerefMut for PoolBox<T>[src]

impl<T> Drop for PoolBox<T>[src]

Drop the PoolBox

The value pointed by this PoolBox is also dropped

Auto Trait Implementations

impl<T> !RefUnwindSafe for PoolBox<T>

impl<T> !Send for PoolBox<T>

impl<T> !Sync for PoolBox<T>

impl<T> Unpin for PoolBox<T>

impl<T> !UnwindSafe for PoolBox<T>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.