Table of Contents

Class Bzip2Codec

Namespace
AvroSharp.Codecs
Assembly
AvroSharp.Codecs.dll

The bzip2 codec: each block is one bzip2 stream.

public sealed class Bzip2Codec : AvroCodec
Inheritance
Bzip2Codec
Inherited Members

Remarks

Uses the fully managed SharpZipLib library. Instances are thread-safe.

Constructors

Bzip2Codec(int)

Creates a bzip2 codec.

Fields

DefaultBlockSize

The default block size, 9 (900 KB), the same as Java's bzip2 codec.

Properties

BlockSize

Gets the bzip2 block size in units of 100 KB.

Default

Gets the codec with the DefaultBlockSize.

Name

Gets the name written to the file's avro.codec metadata entry, for example deflate.

Methods

Compress(ReadOnlyMemory<byte>, IBufferWriter<byte>)

Compresses one block.

Decompress(ReadOnlyMemory<byte>, IBufferWriter<byte>)

Decompresses one block. The destination refuses to grow past the reader's block limit, so an implementation needs no limit of its own; it should throw InvalidDataException for corrupt data.

ToString()

Returns a string that represents the current object.

See Also