Show / Hide Table of Contents

Class BZip2

An example class to demonstrate compression and decompression of BZip2 streams.

Inheritance
System.Object
BZip2
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: ICSharpCode.SharpZipLib.BZip2
Assembly: ICSharpCode.SharpZipLib.dll
Syntax
public static class BZip2

Methods

| Improve this Doc View Source

Compress(Stream, Stream, Boolean, Int32)

Compress the inStream sending result data to outStream

Declaration
public static void Compress(Stream inStream, Stream outStream, bool isStreamOwner, int level)
Parameters
Type Name Description
System.IO.Stream inStream

The readable stream to compress.

System.IO.Stream outStream

The output stream to receive the compressed data.

System.Boolean isStreamOwner

Both streams are closed on completion if true.

System.Int32 level

Block size acts as compression level (1 to 9) with 1 giving the lowest compression and 9 the highest.

| Improve this Doc View Source

Decompress(Stream, Stream, Boolean)

Decompress the inStream writing uncompressed data to the outStream

Declaration
public static void Decompress(Stream inStream, Stream outStream, bool isStreamOwner)
Parameters
Type Name Description
System.IO.Stream inStream

The readable stream containing data to decompress.

System.IO.Stream outStream

The output stream to receive the decompressed data.

System.Boolean isStreamOwner

Both streams are closed on completion if true.

  • Improve this Doc
  • View Source
In This Article
Back to top Copyright © 2000-2022 SharpZipLib Contributors