Trait roopes::prelude::HeapPool

source ·
pub trait HeapPool<C> {
    // Required methods
    fn check_out(&mut self) -> C;
    fn check_in(&mut self, container: C);
}
Expand description

Holds a list of allocated objects in a scalable pool. Previously allocated objects can be checked back in after use, to prevent immediate deallocation.

Required Methods§

source

fn check_out(&mut self) -> C

Get a value from the HeapPool.

source

fn check_in(&mut self, container: C)

Give a value back to the HeapPool.

Implementors§

source§

impl<T, F, W> HeapPool<Box<RefCell<T>>> for RefCellBox<T, F, W>where F: Emitter<T>, W: Handler<RefCell<T>>,