commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "C. Grobmeier" <>
Subject Re: [compress] Discussing compress
Date Tue, 14 Feb 2006 12:34:03 GMT
> I was thinking that something like
> Compress.getInstance(String compressorType);
> like Crypto would be nice.
> This way you can get a unique "entry point" for every compression algorithm 
> that can provide its own methods to compress/decompress/add files etc etc.

you are speaking of a factory method.
I allready thought about it. Besides:

Compress.getInstance(String compressorType);

there could be also a

Compress.getInstance(File compressedFile);

which loads a compressed file with the correct Compressor.
Returntype of getInstance could be Compressor, which is the interface of 
an concrete algorithm implementation.

- Chris

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message