Module utils

Module utils 

Source
Expand description

This module provides general-purpose utility modules for common functionality across the codebase. It includes:

  • compression: for handling tile compression and decompression.
  • csv: for lightweight CSV parsing utilities.
  • pretty_print (enabled with the cli feature): for formatted command-line output.
  • tile_hilbert_index: for Hilbert index calculations and spatial ordering of tiles.

Structs§

TargetCompression
Represents the target compression settings.

Traits§

HilbertIndex
Converts between 2‑D tile space and its position along a Hilbert space‑filling curve.

Functions§

compress
Compresses data based on the specified compression algorithm.
compress_brotli
Compresses data using Brotli.
compress_brotli_fast
Compresses data using Brotli with faster settings.
compress_gzip
Compresses data using Gzip.
decompress
Decompresses data based on the specified compression algorithm.
decompress_brotli
Decompresses data that was compressed using Brotli.
decompress_gzip
Decompresses data that was compressed using Gzip.
decompress_ref
Decompresses a data reference based on the specified compression algorithm.
optimize_compression
Optimizes the compression of a data blob based on the target compression settings.
read_csv_iter
High‑level CSV iterator enforcing a constant column count.
recompress
Recompresses a data blob from one compression algorithm to another.