Class Bzip2Rand
java.lang.Object
io.netty.handler.codec.compression.Bzip2Rand
Random numbers for decompress Bzip2 blocks.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final int[]
The Bzip2 specification originally included the optional addition of a slight pseudo-random perturbation to the input data, in order to work around the block sorting algorithm's non- optimal performance on some types of input. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) static int
rNums
(int i) Return the random number at a specific index.
-
Field Details
-
RNUMS
private static final int[] RNUMSThe Bzip2 specification originally included the optional addition of a slight pseudo-random perturbation to the input data, in order to work around the block sorting algorithm's non- optimal performance on some types of input. The current mainline bzip2 does not require this and will not create randomised blocks, but compatibility is still required for old data (and third party compressors that haven't caught up). When decompressing a randomised block, for each value N in this array, a 1 will be XOR'd onto the output of the Burrows-Wheeler transform stage after N bytes, then the next N taken from the following entry.
-
-
Constructor Details
-
Bzip2Rand
private Bzip2Rand()
-
-
Method Details
-
rNums
static int rNums(int i) Return the random number at a specific index.- Parameters:
i
- the index- Returns:
- the random number
-