snappy-c-0.1.0: Bindings to Google's Snappy: A fast compression library
Copyright(c) 2024 Finley McIlwaine
LicenseBSD-3-Clause (see LICENSE)
MaintainerFinley McIlwaine <finley@well-typed.com>
Safe HaskellNone
LanguageHaskell2010

Codec.Compression.SnappyC.Raw

Description

Raw format Snappy compression/decompression.

import Codec.Compression.SnappyC.Raw qualified as Snappy
Synopsis

Compression

compress :: ByteString -> ByteString Source #

Compress the input using Snappy.

The result is in Snappy raw format, not the framing format.

Decompression

decompress :: ByteString -> Maybe ByteString Source #

Decompress the input using Snappy.

Returns Nothing if the input is not in Snappy raw format or otherwise ill-formed.