Skip to main content

pco/
lib.rs

1#![doc = include_str!("../README.md")]
2//! # API Notes
3//!
4//! * In some places, Pco methods accept a destination (either `W: Write` or `&mut [T: Number]`).
5//! If Pco returns an error, it is possible both the destination and the struct
6//! have been modified.
7//! * Pco will always try to process all numbers, and it will fail if insufficient bytes are
8//! available. For instance, during decompression Pco will try to fill the entire `&mut [T]`
9//! passed in, returning an insufficient data error if the `&[u8]` passed in is not long enough.
10
11#![allow(clippy::uninit_vec)]
12#![allow(clippy::manual_non_exhaustive)] // sometimes we want to ban explicit construction within the crate too
13#![deny(clippy::unused_unit)]
14#![deny(dead_code)]
15
16#[doc = include_str!("../README.md")]
17#[cfg(doctest)]
18struct ReadmeDoctest;
19
20pub use chunk_config::{ChunkConfig, DeltaSpec, ModeSpec, PagingSpec};
21pub use constants::{DEFAULT_COMPRESSION_LEVEL, DEFAULT_MAX_PAGE_N, FULL_BATCH_N};
22pub use progress::Progress;
23
24pub mod data_types;
25/// for inspecting certain types of Pco metadata
26pub mod describers;
27pub mod errors;
28/// structs representing stored information about how compression was done
29pub mod metadata;
30/// for compressing/decompressing .pco files
31pub mod standalone;
32/// for compressing/decompressing as part of an outer, wrapping format
33pub mod wrapped;
34
35mod ans;
36mod bin_optimization;
37mod bit_reader;
38mod bit_writer;
39mod bits;
40mod chunk_config;
41mod chunk_latent_compressor;
42mod chunk_latent_decompressor;
43mod compression_intermediates;
44mod compression_table;
45mod constants;
46mod delta;
47mod dyn_slices;
48mod histograms;
49mod macros;
50mod mode;
51mod page_latent_decompressor;
52mod progress;
53mod read_write_uint;
54mod sampling;
55mod scratch_array;
56mod sort_utils;
57
58#[cfg(test)]
59mod tests;