Méthode | Description | |
---|---|---|
Deflate ( byte output ) : int |
Deflates the current input block with to the given array.
|
|
Deflate ( byte output, int offset, int length ) : int |
Deflates the current input block to the given array.
|
|
Deflater ( ) : System |
Creates a new deflater with default compression level.
|
|
Deflater ( int level ) : System |
Creates a new deflater with given compression level.
|
|
Deflater ( int level, bool noZlibHeaderOrFooter ) : System |
Creates a new deflater with given compression level.
|
|
Finish ( ) : void |
Finishes the deflater with the current input block. It is an error to give more input after this method was called. This method must be called to force all bytes to be flushed.
|
|
Flush ( ) : void |
Flushes the current input block. Further calls to deflate() will produce enough output to inflate everything in the current input block. This is not part of Sun's JDK so I have made it package private. It is used by DeflaterOutputStream to implement flush().
|
|
GetLevel ( ) : int |
Get current compression level
|
|
Reset ( ) : void |
Resets the deflater. The deflater acts afterwards as if it was just created with the same compression level and strategy as it had before.
|
|
SetDictionary ( byte dictionary ) : void |
Sets the dictionary which should be used in the deflate process. This call is equivalent to
|
|
SetDictionary ( byte dictionary, int index, int count ) : void |
Sets the dictionary which should be used in the deflate process. The dictionary is a byte array containing strings that are likely to occur in the data which should be compressed. The dictionary is not stored in the compressed output, only a checksum. To decompress the output you need to supply the same dictionary again.
|
|
SetInput ( byte input ) : void |
Sets the data which should be compressed next. This should be only called when needsInput indicates that more input is needed. If you call setInput when needsInput() returns false, the previous input that is still pending will be thrown away. The given byte array should not be changed, before needsInput() returns true again. This call is equivalent to
|
|
SetInput ( byte input, int offset, int count ) : void |
Sets the data which should be compressed next. This should be only called when needsInput indicates that more input is needed. The given byte array should not be changed, before needsInput() returns true again.
|
|
SetLevel ( int level ) : void |
Sets the compression level. There is no guarantee of the exact position of the change, but if you call this when needsInput is true the change of compression level will occur somewhere near before the end of the so far given input.
|
|
SetStrategy ( DeflateStrategy strategy ) : void |
Sets the compression strategy. Strategy is one of DEFAULT_STRATEGY, HUFFMAN_ONLY and FILTERED. For the exact position where the strategy is changed, the same as for SetLevel() applies.
|
public Deflate ( byte output ) : int | ||
output | byte | /// The buffer where compressed data is stored /// |
Résultat | int |
public Deflate ( byte output, int offset, int length ) : int | ||
output | byte | /// Buffer to store the compressed data. /// |
offset | int | /// Offset into the output array. /// |
length | int | /// The maximum number of bytes that may be stored. /// |
Résultat | int |
public Deflater ( int level ) : System | ||
level | int | /// the compression level, a value between NO_COMPRESSION /// and BEST_COMPRESSION, or DEFAULT_COMPRESSION. /// |
Résultat | System |
public Deflater ( int level, bool noZlibHeaderOrFooter ) : System | ||
level | int | /// the compression level, a value between NO_COMPRESSION /// and BEST_COMPRESSION. /// |
noZlibHeaderOrFooter | bool | /// true, if we should suppress the Zlib/RFC1950 header at the /// beginning and the adler checksum at the end of the output. This is /// useful for the GZIP/PKZIP formats. /// |
Résultat | System |
public SetDictionary ( byte dictionary ) : void | ||
dictionary | byte | /// the dictionary. /// |
Résultat | void |
public SetDictionary ( byte dictionary, int index, int count ) : void | ||
dictionary | byte | /// The dictionary data /// |
index | int | /// The index where dictionary information commences. /// |
count | int | /// The number of bytes in the dictionary. /// |
Résultat | void |
public SetInput ( byte input ) : void | ||
input | byte | /// the buffer containing the input data. /// |
Résultat | void |
public SetInput ( byte input, int offset, int count ) : void | ||
input | byte | /// the buffer containing the input data. /// |
offset | int | /// the start of the data. /// |
count | int | /// the number of data bytes of input. /// |
Résultat | void |
public SetLevel ( int level ) : void | ||
level | int | /// the new compression level. /// |
Résultat | void |
public SetStrategy ( DeflateStrategy strategy ) : void | ||
strategy | DeflateStrategy | /// The new compression strategy. /// |
Résultat | void |