[][src]Struct atm::storage::batch_tar_file::BatchTarFile

pub struct BatchTarFile { /* fields omitted */ }

Nested tar archive storage backend, where each entry in the archive is a gzip-compressed tar archive containing MIDI files. Use for the largest datasets where compression, or output file size, is of the utmost importance. Choosing a batch size (and compression level) such that each compressed tar archive aligns with 512 bytes will ensure that no space is wasted in the top-level archive. For example, if a batch size of 25 compresses to 515 bytes, then each entry will take 1,536 bytes (512 for header plus 1024 for data). However, if a batch compresses to 510 bytes, then each entry will take 1024 bytes, with only 2 bytes extra. Keep in mind that higher compression levels will reduce throughput of the program.

Implementations

impl BatchTarFile[src]

pub fn new<P: AsRef<Path>>(
    target_path: P,
    batch_size: u32,
    num_notes: u32,
    melody_length: u32,
    max_files: u32,
    partition_depth: u32,
    batch_compression: Option<Compression>,
    batch_mode: Option<u32>
) -> Result<Self, TarArchiveError>
[src]

Create new BatchTarFile instance

Trait Implementations

impl IntoInner for BatchTarFile[src]

type Inner = BufWriter<File>

Type of inner object

impl StorageBackend for BatchTarFile[src]

type Error = TarArchiveError

Error type for storage operations

Auto Trait Implementations

impl RefUnwindSafe for BatchTarFile

impl Send for BatchTarFile

impl Sync for BatchTarFile

impl Unpin for BatchTarFile

impl UnwindSafe for BatchTarFile

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.