Struct ecpool::ErasureCoderPool[][src]

pub struct ErasureCoderPool<B> { /* fields omitted */ }

Thread pool for encoding and decoding data by using an ErasureCode implementation.

Internally, this uses fibers_tasque::DefaultCpuTaskQueue for realizing thread pool functionality.

Methods

impl<B: BuildCoder> ErasureCoderPool<B>
[src]

Makes a new ErasureCoderPool instance.

Encodes the given data to fragments asynchronously.

The encoding process will be executed on a thread in the pool.

The result vector contains N data fragments and M parity fragments (where N = self.data_fragments() and M = self.parity_fragments()).

Decodes the original data from the given fragments asynchronously.

The decoding process will be executed on a thread in the pool.

Note whether the correctness of the result data has been validated depends on the implementations.

Reconstructs the fragment specified by the given index from other fragments asynchronously.

The reconstruction process will be executed on a thread in the pool.

Trait Implementations

impl<B: Debug> Debug for ErasureCoderPool<B>
[src]

Formats the value using the given formatter. Read more

impl<B: Clone> Clone for ErasureCoderPool<B>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl<B> Send for ErasureCoderPool<B> where
    B: Send

impl<B> Sync for ErasureCoderPool<B> where
    B: Sync