You are viewing the documentation for a prerelease version. View Latest

Brotli

Read-only: Compress4J can extract this format but cannot create it.

Brotli decompression needs org.brotli:dec at runtime; see Additional Formats. Without it, building a BrotliDecompressor fails with a MissingArchiveDependencyException.

Example Usage

Brotli Decompression
try (BrotliDecompressor brotliDecompressor =
        BrotliDecompressor.builder(Path.of("example.br")).build()) {
    brotliDecompressor.write(Path.of("path/to/file.txt"));
}