Struct simple_pool::ResourcePool[][src]

pub struct ResourcePool<T> { /* fields omitted */ }
Expand description

Versatile resource pool

Implementations

Create new resource pool

Create new resource pool with pre-allocated capacity

The size parameter is used to pre-allocate memory for the resource holder only

Append resource to the pool

Panics

This function might panic when called if the resource lock is already held by the current thread.

Get resource from the pool or wait until one is available

Trait Implementations

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.