Simple DEFLATE implementation

Overview

This project is a simple and compliant implementation of DEFLATE in Java. Currently available is a DEFLATE decompressor and a GZIP decompressor. The implementation is less than 1000 lines of well-commented code.

The DEFLATE format is a compression standard specified in RFC 1951 (plain text or PDF) in year 1996. The format has widespread use, and can be found in protocols and file formats such as ZIP, GZIP, PNG, HTTP, and Git. The GZIP container format is specified in RFC 1952 (plain text or PDF).

Source code

Browse the project’s source code at GitHub: https://github.com/nayuki/DEFLATE

Or download a ZIP of all the files: https://github.com/nayuki/DEFLATE/archive/master.zip

The code is open source under the MIT License. See the readme file for details.

The project package includes these main items:

Notes

DEFLATE is popular enough that essentially every important programming language has a library for it. For example, Java has java.util.zip.Deflater, Python has zlib, and zlib is available for C. While this project provides a compliant implementation, my code runs slowly and might have bugs, so it should be used as an educational tool only.

Related

More info



Feedback

Question? Comment? Contact me

ProjectNayuki: Like, comment, follow updates on Facebook