C# Class TimeSeriesLibrary.LZFX

This static class is used to call the functions in lzfx.dll, which is coded in C and compiled for native Win32. LZFX is a fast-executing compression and decompression algorithm for byte arrays, although it does not achieve great compression ratios. The lzfx DLL is based on BSD-licensed source code from http://lzfx.googlecode.com.
显示文件 Open project: hydrologics/TimeSeriesLibrary Class Usage Examples

Public Methods

Method Description
Compress ( byte InputByteArray, byte &OutputByteArray ) : void

Assigns a compressed verion of InputByteArray to OutputByteArray

Decompress ( byte InputByteArray, byte OutputByteArray ) : void

Assigns a decompressed version of InputByteArray to OutputByteArray

Private Methods

Method Description
LZFX ( ) : System

static constructor

Method Details

Compress() public static method

Assigns a compressed verion of InputByteArray to OutputByteArray
public static Compress ( byte InputByteArray, byte &OutputByteArray ) : void
InputByteArray byte The byte array that is to be compressed
OutputByteArray byte The byte array into which the compressed data /// is to be written. This array must be allocated before calling the method, and /// it must be large enough to contain the compressed data. Note that if the data /// in InputByteArray is highly incompressible (floating point data that uses its /// full precision range is a known example), then OutputByteArray may need to be /// slightly larger than the InputByteArray. This method will resize OutputByteArray /// so that its allocated size is no larger than the data it contains.
return void

Decompress() public static method

Assigns a decompressed version of InputByteArray to OutputByteArray
public static Decompress ( byte InputByteArray, byte OutputByteArray ) : void
InputByteArray byte The byte array that is to be decompressed
OutputByteArray byte The byte array into which the decompressed data /// is to be written. This array must be allocated before calling the method, and /// it must have exactly the length that is needed to contain the decompressed data. /// If the decompressed data is found to be any larger or smaller than the length of /// OutputByteArray, then this method throws an exception.
return void