Boost logo

Boost :

From: Ehsan Akhgari (ehsan_at_[hidden])
Date: 2003-10-06 13:29:44

> 3 - A third suggestion was asking for user defined compression
> support (Ehsan Akhgari, Pavel Vozenilek ): basically, the wrapper is
> not designed
> for that right now. There are a few reasons for that, that could be
> discussed further:
> The zlib and bzip2 libraries have some intrisic
> differences: their
> constructor arguments, the number of configuration
> parameters, zlib can add
> a header, bzip2 not, etc... All these differences would make a common
> wrapper quite difficult to make. Anyway, all suggestions are welcome.

How about relying on a class like this for the

 // pseudo-code
 class Compression
  static Compression * createCompressor( ... );
  void initialize( ... );
  void compress( ... );
  void decompress( ... );
  // ...

And feed it through the streams using either compile time or runtime
polymorphism (whichever is appropriate.) The library itself can provide
zlibCompression and bzip2Compression, while user-defined extensions can
also handle other types of compression.

Does this fit in your model?

Ehsan Akhgari

List Owner: MSVC_at_[hidden]

[ Email: ehsan_at_[hidden] ]
[ WWW: ]

Boost list run by bdawes at, gregod at, cpdaniel at, john at