Read and decompress data from the source stream.
Declaration Syntax
C# | C# | Visual Basic | Visual Basic | Visual C++ | Visual C++ | F# | F# |
public override int Read( byte[] buffer, int offset, int count )
public override int Read( byte[] buffer, int offset, int count )
Public Overrides Function Read ( buffer As Byte(), offset As Integer, count As Integer ) As Integer
Public Overrides Function Read ( buffer As Byte(), offset As Integer, count As Integer ) As Integer
public: virtual int Read( array<unsigned char>^ buffer, int offset, int count ) override
public: virtual int Read( array<unsigned char>^ buffer, int offset, int count ) override
abstract Read : buffer : byte[] * offset : int * count : int -> int override Read : buffer : byte[] * offset : int * count : int -> int
abstract Read : buffer : byte[] * offset : int * count : int -> int override Read : buffer : byte[] * offset : int * count : int -> int
Return Value
Int32
the number of bytes actually read
the number of bytes actually read
Remarks
With a GZipStream, decompression is done through reading.
Examples
Copy | |
---|---|
byte[] working = new byte[WORKING_BUFFER_SIZE]; using (System.IO.Stream input = System.IO.File.OpenRead(_CompressedFile)) { using (Stream decompressor= new Keyoti.RapidSpell.Compression.GZipStream(input, CompressionMode.Decompress, true)) { using (var output = System.IO.File.Create(_DecompressedFile)) { int n; while ((n= decompressor.Read(working, 0, working.Length)) !=0) { output.Write(working, 0, n); } } } } |
Assembly: Keyoti.RapidSpell.NET4 (Module: Keyoti.RapidSpell.NET4.dll) Version: 6.2.21.412