Skip to main content

RegularFileSource

Trait RegularFileSource 

Source
pub trait RegularFileSource {
    // Required methods
    fn archive_path(&self) -> &str;
    fn file_data_size(&self) -> u64;
    fn mode(&self) -> u32;
    fn mtime(&self) -> u64;
    fn open(&self) -> Result<Box<dyn Read + '_>, ArchiveWriteError>;
}
Expand description

Re-openable source for one regular file written into an archive.

The writer may replan when options such as target volume sizing need another pass, so implementations must return a fresh reader from each open call.

Required Methods§

Source

fn archive_path(&self) -> &str

Source

fn file_data_size(&self) -> u64

Source

fn mode(&self) -> u32

Source

fn mtime(&self) -> u64

Source

fn open(&self) -> Result<Box<dyn Read + '_>, ArchiveWriteError>

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§