[GSoC] API for various compression codecs

First draft of API.
@trustin and @normanmaurer please review it.
Perhaps we don't need it because we can get the type of a codec by Java getClass()?