Function encode

Source
pub fn encode<R: Read + Seek, W: Write>(
    dict: Option<&mut R>,
    output: &mut R,
    writer: &mut W,
    config: &EncoderConfig,
) -> Result<()>
Expand description

Encodes a delta file based on the given configuration and inputs.

§Arguments

  • dict - The source file to use as a dictionary. If None, the source file will not be used.
  • output - The target file to encode.
  • writer - The writer to write the encoded data to.
  • config - The configuration to use for the encoder.

§Errors

Returns an error if there was an issue reading the source or target files, or writing the encoded data.