Table of Contents

CompressDeflate Method

Definition

Namespace
Cuemon.Extensions.IO
Assemblies
Cuemon.Extensions.IO.dll
Source
src/Cuemon.Extensions.IO/StreamExtensions.cs

CompressDeflate(Stream, Action<StreamCompressionOptions>)

Compresses the value using the DEFLATE algorithm.

public static Stream CompressDeflate(this Stream value, Action<StreamCompressionOptions> setup = null)

Parameters

value Stream

The Stream to extend.

setup Action<StreamCompressionOptions>

The StreamCompressionOptions which may be configured.

Returns

Stream

A DEFLATE compressed Stream of the value.

Exceptions

ArgumentNullException

value cannot be null.

ArgumentException

value does not support write operations such as compression.