| Modifier and Type | Class and Description |
|---|---|
| public class | BandSet.BandAnalysisResults
Results obtained by trying different Codecs to encode a band |
| public class | BandSet.BandData
BandData represents information about a band, e.g. largest value etc and is used in the heuristics that calculate whether an alternative Codec could make the encoded band smaller. |
| Modifier and Type | Field and Description |
|---|---|
| private long[] | |
| private long[] | |
| pack-priv final int | |
| private static final int[] | |
| private static final byte[] | |
| protected final SegmentHeader |
| Access | Constructor and Description |
|---|---|
| public | BandSet(final int
- the packing effort to be used (must be 1-9) effort, final SegmentHeader - the segment header header)Constructs a new BandSet. |
| Modifier and Type | Method and Description |
|---|---|
| private BandSet. | |
| protected int[] | Returns: conversion result.conversion source. list)Converts a list of ConstantPoolEntrys to an int[] array of their indices |
| protected int[] | Returns: conversion result.conversion source. list)Converts a list of ConstantPoolEntrys or nulls to an int[] array of their indices +1 (or 0 for nulls) |
| public byte[] | Returns: the encoded band- name of the band (used for debugging) name, final int[] - the band ints, final BHSDCodec - the default Codec defaultCodec)Encode a band of integers. |
| protected byte[] | Returns: the encoded band- name of the band (for debugging purposes) name, final long[] - the band flags, final BHSDCodec - Codec for the low 32-bits band loCodec, final BHSDCodec - Codec for the high 32-bits band hiCodec, final boolean - ignores the high band if true as all values would be zero haveHiFlags)Encode a band of longs (values are split into their high and low 32 bits and then encoded as two separate bands |
| protected byte[] | encodeFlags(final String name, final long[][] flags, final BHSDCodec loCodec, final BHSDCodec hiCodec, final boolean haveHiFlags)
|
| public byte[] | Returns: the encoded value- the value to encode value, final BHSDCodec - Codec to use codec)Encode a single value with the given Codec |
| public byte[] | Returns: the encoded band- the band band, final BHSDCodec - the Codec to use codec)Encode a band without considering other Codecs |
| private void | encodeWithPopulationCodec(final String name, final int[] band, final BHSDCodec defaultCodec, final BandSet.
|
| private long[] | |
| protected int[] | Returns: conversion result.conversion source. integerList)Converts a list of Integers to an int[] array. |
| protected long[] | Returns: conversion result.conversion source. longList)Converts a list of Longs to an long[] array. |
| public abstract void | |
| private boolean | |
| private void |
| canonicalLargest | back to summary |
|---|---|
| private long[] canonicalLargest | |
| canonicalSmallest | back to summary |
|---|---|
| private long[] canonicalSmallest | |
| effort | back to summary |
|---|---|
| pack-priv final int effort | |
| effortThresholds | back to summary |
|---|---|
| private static final int[] effortThresholds | |
| EMPTY_BYTE_ARRAY | back to summary |
|---|---|
| private static final byte[] EMPTY_BYTE_ARRAY | |
| segmentHeader | back to summary |
|---|---|
| protected final SegmentHeader segmentHeader | |
| BandSet | back to summary |
|---|---|
| public BandSet(final int effort, final SegmentHeader header) Constructs a new BandSet.
| |
| analyseBand | back to summary |
|---|---|
| private BandSet. | |
| cpEntryListToArray | back to summary |
|---|---|
| protected int[] cpEntryListToArray(final List<? extends ConstantPoolEntry> list) Converts a list of ConstantPoolEntrys to an int[] array of their indices
| |
| cpEntryOrNullListToArray | back to summary |
|---|---|
| protected int[] cpEntryOrNullListToArray(final List<? extends ConstantPoolEntry> list) Converts a list of ConstantPoolEntrys or nulls to an int[] array of their indices +1 (or 0 for nulls)
| |
| encodeBandInt | back to summary |
|---|---|
| public byte[] encodeBandInt(final String name, final int[] ints, final BHSDCodec defaultCodec) throws Pack200Exception Encode a band of integers. The default codec may be used, but other Codecs are considered if effort is greater than 1.
| |
| encodeFlags | back to summary |
|---|---|
| protected byte[] encodeFlags(final String name, final long[] flags, final BHSDCodec loCodec, final BHSDCodec hiCodec, final boolean haveHiFlags) throws Pack200Exception Encode a band of longs (values are split into their high and low 32 bits and then encoded as two separate bands
| |
| encodeFlags | back to summary |
|---|---|
| protected byte[] encodeFlags(final String name, final long[][] flags, final BHSDCodec loCodec, final BHSDCodec hiCodec, final boolean haveHiFlags) throws Pack200Exception | |
| encodeScalar | back to summary |
|---|---|
| public byte[] encodeScalar(final int value, final BHSDCodec codec) throws Pack200Exception Encode a single value with the given Codec
| |
| encodeScalar | back to summary |
|---|---|
| public byte[] encodeScalar(final int[] band, final BHSDCodec codec) throws Pack200Exception Encode a band without considering other Codecs
| |
| encodeWithPopulationCodec | back to summary |
|---|---|
| private void encodeWithPopulationCodec(final String name, final int[] band, final BHSDCodec defaultCodec, final BandSet. | |
| flatten | back to summary |
|---|---|
| private long[] flatten(final long[][] flags) | |
| integerListToArray | back to summary |
|---|---|
| protected int[] integerListToArray(final List<Integer> integerList) Converts a list of Integers to an int[] array. | |
| longListToArray | back to summary |
|---|---|
| protected long[] longListToArray(final List<Long> longList) Converts a list of Longs to an long[] array. | |
| pack | back to summary |
|---|---|
| public abstract void pack(OutputStream out) throws IOException, Pack200Exception Write the packed set of bands to the given output stream
| |
| timeToStop | back to summary |
|---|---|
| private boolean timeToStop(final BandSet. | |
| tryCodecs | back to summary |
|---|---|
| private void tryCodecs(final String name, final int[] band, final BHSDCodec defaultCodec, final BandSet. | |
| Modifier and Type | Field and Description |
|---|---|
| private Codec | |
| private byte[] | |
| private int[] | |
| private int | |
| private int |
| Access | Constructor and Description |
|---|---|
| public |
| betterCodec | back to summary |
|---|---|
| private Codec betterCodec | |
| encodedBand | back to summary |
|---|---|
| private byte[] encodedBand | |
| extraMetadata | back to summary |
|---|---|
| private int[] extraMetadata | |
| numCodecsTried | back to summary |
|---|---|
| private int numCodecsTried | |
| saved | back to summary |
|---|---|
| private int saved | |
| BandAnalysisResults | back to summary |
|---|---|
| public BandAnalysisResults() | |
| Modifier and Type | Field and Description |
|---|---|
| private double | |
| private double | |
| private final int[] | |
| private int | |
| private Map | |
| private int | |
| private int | |
| private int | |
| private int | |
| private int |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | Returns: true if any band elements are negative.Returns true if any band elements are negative. |
| public boolean | Returns: true if the band deltas are mainly positive (heuristic).Returns true if the band deltas are mainly positive (heuristic). |
| public boolean | Returns: true if the deltas between adjacent band elements are mainly small (heuristic).Returns true if the deltas between adjacent band elements are mainly small (heuristic). |
| public int | Returns: the total number of distinct values found in the band.Returns the total number of distinct values found in the band. |
| public boolean | Returns: true if the band is well correlated (i.e. would be suitable for a delta encoding) (heuristic).Returns true if the band is well correlated (i.e. would be suitable for a delta encoding) (heuristic). |
| averageAbsoluteDelta | back to summary |
|---|---|
| private double averageAbsoluteDelta | |
| averageAbsoluteValue | back to summary |
|---|---|
| private double averageAbsoluteValue | |
| band | back to summary |
|---|---|
| private final int[] band | |
| deltaIsAscending | back to summary |
|---|---|
| private int deltaIsAscending | |
| distinctValues | back to summary |
|---|---|
| private Map<Integer, Integer> distinctValues | |
| largest | back to summary |
|---|---|
| private int largest | |
| largestDelta | back to summary |
|---|---|
| private int largestDelta | |
| smallDeltaCount | back to summary |
|---|---|
| private int smallDeltaCount | |
| smallest | back to summary |
|---|---|
| private int smallest | |
| smallestDelta | back to summary |
|---|---|
| private int smallestDelta | |
| BandData | back to summary |
|---|---|
| public BandData(final int[] band) Constructs a new instance of BandData. The band is then analysed.
| |
| anyNegatives | back to summary |
|---|---|
| public boolean anyNegatives() Returns true if any band elements are negative.
| |
| mainlyPositiveDeltas | back to summary |
|---|---|
| public boolean mainlyPositiveDeltas() Returns true if the band deltas are mainly positive (heuristic).
| |
| mainlySmallDeltas | back to summary |
|---|---|
| public boolean mainlySmallDeltas() Returns true if the deltas between adjacent band elements are mainly small (heuristic).
| |
| numDistinctValues | back to summary |
|---|---|
| public int numDistinctValues() Returns the total number of distinct values found in the band.
| |
| wellCorrelated | back to summary |
|---|---|
| public boolean wellCorrelated() Returns true if the band is well correlated (i.e. would be suitable for a delta encoding) (heuristic).
| |