Skip to content
FutureBlitz

    Install

    Import std.compress.zstd

    ZstdDecompressor

    std.compress.zstd

    class

    Public Class ZstdDecompressor Implements Coder

    Zstd's bytes taken in turn, a frame after another: Add gives what the bytes it takes decompress to so far, and Finish what's left once they've all been added, and starts again. Each throws an IOError when the bytes aren't Zstd's or would come to more than the limit, and Finish when they end early.

    std/compress/zstd.fb, line 116

    • @PanicsAtCaller Public New(limit: Int = MOST_BYTES) constructor #

      A new ZstdDecompressor that gives at most limit bytes. Panics when the limit is negative.

    • Public Method Add(data: UInt8[]): UInt8[] Throws IOError method #

      Decompresses data, and gives the bytes it comes to so far. Throws an IOError when the bytes aren't Zstd's, or would come to more than the limit.

    • Public Method Finish(): UInt8[] Throws IOError method #

      The rest of the bytes, once every one is added, and starts again. Throws an IOError when the frame ended early.

    Report an issue with this page or with FutureBlitz on GitHub.