Menu

#59 Make compressors/decompressors instantiable

Version 2.0
closed
9
2012-11-01
2012-10-27
No

Currently for each compression algorithm there exists exactly one Compressor and one Decompressor. This will not do for multi-threaded code, where several threads may want to e.g. compress in parallel.

To solve this, the "getCompressor()" and "getDecompressor()" methods of CompressionAlgorithm shall become "createCompressor()" and "createDecompressor()" respectively, each returning a new instance on each call. Clients (e.g. CompressOutputStream) shall be updated accordingly, as well as unit tests.

Discussion

  • Andrei Kapustin

    Andrei Kapustin - 2012-11-01
    • milestone: --> Version 2.0
     
  • Andrei Kapustin

    Andrei Kapustin - 2012-11-01
    • priority: 7 --> 9
     
  • Andrei Kapustin

    Andrei Kapustin - 2012-11-01
    • status: open --> closed