Skip to main content

compress

Function compress 

Source
pub fn compress(input: &[u8], codec: Compression) -> Result<Vec<u8>, IoError>
Expand description

Compress a buffer according to the requested codec. Always returns a new Vec<u8> (per Parquet page convention).

§Arguments

  • input: Slice of bytes to compress.
  • codec: Compression algorithm to apply.

§Errors

Returns IoError::Compression if codec fails.