home *** CD-ROM | disk | FTP | other *** search
/ Chip 2002 September / Chip_2002-09_cd1.bin / zkuste / vbasic / Data / Utils / XZipComp.exe / XceedCompression.Cab / F112859_Compress.h < prev    next >
Encoding:
C/C++ Source or Header  |  2001-05-11  |  2.0 KB  |  81 lines

  1. #ifndef __COMPRESS_H__
  2. #define __COMPRESS_H__
  3.  
  4. /* Xceed Streaming Compression Library - Compress Sample Application
  5.  * Copyright (c) 2001 Xceed Software Inc.
  6.  *
  7.  * [Compress.h]
  8.  *
  9.  * This console application shows how to compress a file, using different
  10.  * compression formats. It specifically demonstrates:
  11.  *  - The WriteFile and ProcessFile methods.
  12.  *  - The CompressionFormat properties.
  13.  *
  14.  * This file is part of the Xceed Streaming Compression Library sample 
  15.  * applications. The source code in this file is only intended as 
  16.  * a supplement to Xceed Streaming Compression Library's documentation, 
  17.  * and is provided "as is", without warranty of any kind, either 
  18.  * expressed or implied. 
  19.  */
  20.  
  21. //
  22. // The Visual C++ compiler will automatically generate wrapper classes 
  23. // around available interfaces found in this type library.
  24. //
  25.  
  26. #import "XceedSCO.dll" no_namespace named_guids
  27.  
  28. //
  29. // Enumerations
  30. //
  31.  
  32. // The different compression formats supported by the Xceed Streaming Compression
  33. // library.
  34. enum ECompressionFormat
  35. {
  36.   cfBZip2 = 0,
  37.   cfGZip = 1,
  38.   cfStandard = 2,
  39.   cfZip3 = 3,
  40.   cfZLib = 4,
  41.   // The next three items are not compression formats. They are compression methods.
  42.   // See the comments in the ExtractParameters function
  43.   cfBWT = 5,   //BurrowsWheeler
  44.   cfDeflate = 6,
  45.   cfStore = 7,
  46. };
  47.  
  48.  
  49. //
  50. // Constants
  51. //
  52.  
  53. #define BUFFER_SIZE   0x4000
  54.  
  55.  
  56. //
  57. // Data types
  58. //
  59.  
  60. // Structure for correspondence table between the possible compression format 
  61. // options passed on the command line and their equivalent compression format object.
  62. struct SCompressionFormat
  63. {
  64.   const char*         pszCommandLine;
  65.   ECompressionFormat  eFormat;
  66. };
  67.  
  68.  
  69. //
  70. // Prototypes
  71. //
  72.  
  73. void ShowHelp();
  74.  
  75. bool ExtractParameters( int argc, char* argv[],
  76.                         IXceedStreamingCompressionPtr piComp,
  77.                         _bstr_t& bstrInputFileName,
  78.                         _bstr_t& bstrOutputFileName );
  79.  
  80. #endif // __COMPRESS_H__
  81.