J D
J D

Reputation: 48687

Concurrently decompressing a stream

.NET allows a stream to be decompressed by wrapping it in another stream. However, I assume this is implemented serially. Is it possible to make this concurrent so the decompression of the last block can be done while the next block is being read?

Upvotes: 1

Views: 172

Answers (1)

Peter Ritchie
Peter Ritchie

Reputation: 35870

The built-in stream compression classes cannot be used that way. e.g. you can't break up the work involved in decompressing a stream that was compressed in one shot (i.e. wasn't broken up in to chunks of work).

This question was asked in MSDN magazine and was answered by Stephen Toub, who presents a solution. see http://msdn.microsoft.com/en-us/magazine/cc163290.aspx for more details

Upvotes: 3

Related Questions