Deflater.setDictionary

D

Dr. Carsten Leue

I would like to initialize the java.util.zip.Deflater object with a
precalculated dictionary. The documentation is very sparse, it just tells to
pass in a byte array, but nothing about the content of this array. When I
use an arbitrary array I get an IllegalArgumentException. The documentation
says that this is due to an invalid dictionary format. But what is the
correct format?

Best regards
Carsten
 
C

Chris Uppal

*** NO! I WILL NOT! ***

I would like to initialize the java.util.zip.Deflater object with a
precalculated dictionary. The documentation is very sparse, it just tells
to pass in a byte array, but nothing about the content of this array.

You may find the documentation for the underlying ZLib implementation more
helpful -- or maybe not since it's still not ideally detailed. It's better
than the JavaDoc for the Java wrapper classes, anyway.

http://www.gzip.org/zlib/manual.html#deflateSetDictionary

HTH (at least a little).

-- chris
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,014
Latest member
BiancaFix3

Latest Threads

Top