Struct autoreturn_pool::Pool
source · pub struct Pool<T: Send> { /* private fields */ }Implementations§
source§impl<T: Send + 'static> Pool<T>
impl<T: Send + 'static> Pool<T>
pub fn new<I>(items: I) -> Result<ArcPool<T>, Error>where
I: IntoIterator<Item = T>,
pub fn with_config<I>(config: Config, items: I) -> Result<ArcPool<T>, Error>where
I: IntoIterator<Item = T>,
pub fn take(&self) -> Result<Option<PoolObject<T>>, Error>
pub fn size(&self) -> Result<usize, Error>
Auto Trait Implementations§
impl<T> !Freeze for Pool<T>
impl<T> RefUnwindSafe for Pool<T>
impl<T> Send for Pool<T>
impl<T> Sync for Pool<T>
impl<T> Unpin for Pool<T>
impl<T> UnwindSafe for Pool<T>
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more