*
* @throws IOException If there is an error decompressing the stream.
*/
public void decode( InputStream compressedData, OutputStream result, COSDictionary options ) throws IOException
{
ASCII85InputStream is = null;
try
{
is = new ASCII85InputStream(compressedData);
byte[] buffer = new byte[1024];
int amountRead = 0;
while( (amountRead = is.read( buffer, 0, 1024) ) != -1 )
{
result.write(buffer, 0, amountRead);
}
result.flush();
}
finally
{
if( is != null )
{
is.close();
}
}
}