flush_decompressor_buffer {zlib}R Documentation

Flush the internal buffer of the decompressor object.

Description

This function processes all pending input and returns the remaining uncompressed output. The function uses the provided initial buffer size and dynamically expands it as necessary to ensure all remaining data is decompressed. After calling this function, the decompress_chunk() method cannot be called again on the same object.

Usage

flush_decompressor_buffer(decompressorPtr, length = 256L)

Arguments

decompressorPtr

A SEXP pointer to an existing decompressor object.

length

An optional parameter that sets the initial size of the output buffer. Default is 256.

Value

A raw vector containing the remaining uncompressed output.

Examples

decompressor <- create_decompressor()
# ... (some decompression actions)
flushed_data <- flush_decompressor_buffer(decompressor)

[Package zlib version 1.0.3 Index]