Package com.github.junrar.unpack.ppm
Class PPMContext
- java.lang.Object
-
- com.github.junrar.unpack.ppm.Pointer
-
- com.github.junrar.unpack.ppm.PPMContext
-
public class PPMContext extends Pointer
DOCUMENT ME- Version:
- $LastChangedRevision$
-
-
Field Summary
Fields Modifier and Type Field Description static int[]ExpEscapeprivate FreqDatafreqDataprivate intnumStatsprivate StateoneStateprivate int[]psstatic intsizeprivate intsuffixprivate PPMContexttempPPMContextprivate StatetempState1private StatetempState2private StatetempState3private StatetempState4private StatetempState5private static intunionSize
-
Constructor Summary
Constructors Constructor Description PPMContext(byte[] mem)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intcreateChild(ModelPPM model, State pStats, StateRef firstState)voiddecodeBinSymbol(ModelPPM model)booleandecodeSymbol1(ModelPPM model)booleandecodeSymbol2(ModelPPM model)private intgetArrayIndex(ModelPPM Model, State rs)FreqDatagetFreqData()intgetMean(int summ, int shift, int round)intgetNumStats()StategetOneState()intgetSuffix()private PPMContextgetTempPPMContext(byte[] mem)PPMContextinit(byte[] mem)private SEE2ContextmakeEscFreq2(ModelPPM model, int Diff)voidrescale(ModelPPM model)voidsetAddress(int pos)needs to set the fields of this object to the values in the byte[] at the given position.voidsetFreqData(FreqData freqData)voidsetNumStats(int numStats)voidsetOneState(StateRef oneState)voidsetSuffix(int suffix)voidsetSuffix(PPMContext suffix)java.lang.StringtoString()voidupdate1(ModelPPM model, int p)voidupdate2(ModelPPM model, int p)-
Methods inherited from class com.github.junrar.unpack.ppm.Pointer
getAddress
-
-
-
-
Field Detail
-
unionSize
private static final int unionSize
-
size
public static final int size
-
numStats
private int numStats
-
freqData
private final FreqData freqData
-
oneState
private final State oneState
-
suffix
private int suffix
-
ExpEscape
public static final int[] ExpEscape
-
tempState1
private final State tempState1
-
tempState2
private final State tempState2
-
tempState3
private final State tempState3
-
tempState4
private final State tempState4
-
tempState5
private final State tempState5
-
tempPPMContext
private PPMContext tempPPMContext
-
ps
private final int[] ps
-
-
Method Detail
-
init
public PPMContext init(byte[] mem)
-
getFreqData
public FreqData getFreqData()
-
setFreqData
public void setFreqData(FreqData freqData)
-
getNumStats
public final int getNumStats()
-
setNumStats
public final void setNumStats(int numStats)
-
getOneState
public State getOneState()
-
setOneState
public void setOneState(StateRef oneState)
-
getSuffix
public int getSuffix()
-
setSuffix
public void setSuffix(PPMContext suffix)
-
setSuffix
public void setSuffix(int suffix)
-
setAddress
public void setAddress(int pos)
Description copied from class:Pointerneeds to set the fields of this object to the values in the byte[] at the given position. be aware of the byte order- Overrides:
setAddressin classPointer- Parameters:
pos- the position this object should point to
-
getTempPPMContext
private PPMContext getTempPPMContext(byte[] mem)
-
rescale
public void rescale(ModelPPM model)
-
getMean
public int getMean(int summ, int shift, int round)
-
decodeBinSymbol
public void decodeBinSymbol(ModelPPM model)
-
update1
public void update1(ModelPPM model, int p)
-
decodeSymbol2
public boolean decodeSymbol2(ModelPPM model)
-
update2
public void update2(ModelPPM model, int p)
-
makeEscFreq2
private SEE2Context makeEscFreq2(ModelPPM model, int Diff)
-
decodeSymbol1
public boolean decodeSymbol1(ModelPPM model)
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-