ByteBuffer outBuffer=uncompressedByteBuf.nioBuffer(0, uncompressedSize);
CompressionCodec c = getCodec(codecName);
//TODO: Create the decompressor only once at init time.
Class<?> cx = c.getClass();
DirectDecompressionCodec d=null;
DirectDecompressor decompr=null;
if (DirectDecompressionCodec.class.isAssignableFrom(cx)) {
d=(DirectDecompressionCodec)c;
}
if(d!=null) {
decompr = d.createDirectDecompressor();
}
if(d!=null && decompr!=null){
decompr.decompress(inpBuffer, outBuffer);
}else{