Changeset 69e5760b


Ignore:
Timestamp:
Dec 13, 2011 6:56:44 PM (8 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
9e88fde
Parents:
5a715f3
Message:

javadoc clarifications

Location:
core/java/src/net/i2p/util
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • core/java/src/net/i2p/util/ReusableGZIPInputStream.java

    r5a715f3 r69e5760b  
    1010
    1111/**
    12  * Provide a cache of reusable GZIP streams, each handling up to 32KB without
    13  * expansion.
    14  *
     12 * Provide a cache of reusable GZIP unzipper streams.
     13 * This provides stream output only, and therefore can handle unlimited size.
    1514 */
    1615public class ReusableGZIPInputStream extends ResettableGZIPInputStream {
  • core/java/src/net/i2p/util/ReusableGZIPOutputStream.java

    r5a715f3 r69e5760b  
    1515 * This compresses to memory only. Retrieve the compressed data with getData().
    1616 * There is no facility to compress to an output stream.
     17 *
     18 * Do NOT use this for compression of unlimited-size data, as it will
     19 * expand, but never release, the BAOS memory buffer.
    1720 */
    1821public class ReusableGZIPOutputStream extends ResettableGZIPOutputStream {
     
    5255    }
    5356   
    54     private ByteArrayOutputStream _buffer = null;
     57    private final ByteArrayOutputStream _buffer;
    5558
    5659    private ReusableGZIPOutputStream() {
    57         super(new ByteArrayOutputStream(40*1024));
     60        super(new ByteArrayOutputStream(DataHelper.MAX_UNCOMPRESSED));
    5861        _buffer = (ByteArrayOutputStream)out;
    5962    }
Note: See TracChangeset for help on using the changeset viewer.