protected void compress ( PlexusIoResource resource , OutputStream zOut ) throws IOException { InputStream in = Streams . bufferedInputStream ( resource . getContents ( ) ) ; try { compressFile ( in , zOut ) ; } finally { IOUtil . close ( in ) ; } }
compress a resource to an output stream