//////////////////////////////////////////////////////////////////////////////
-AliTPCHNode::AliTPCHNode(const AliTPCHNode &source){
+AliTPCHNode::AliTPCHNode(const AliTPCHNode &source)
+ :TObject(source){
//Copy Constructor
if(&source == this) return;
this->fSymbol = source.fSymbol;
//////////////////////////////////////////////////////////////////////////////
-AliTPCHTable::AliTPCHTable(const AliTPCHTable &source){
+AliTPCHTable::AliTPCHTable(const AliTPCHTable &source)
+ :TObject(source){
//Copy Constructor
if(&source == this) return;
this->fSize = source.fSize;
if (fCodeLen[i]){
cout.width(6);cout<<fSym[i];
cout.width(3);cout<<"|";
- cout.width(6);cout<<hex<<(ULong_t)fCode[i]<<dec;
+ cout.width(6);cout<<hex<<(UInt_t)fCode[i]<<dec;
cout.width(5);cout<<"|";
- cout.width(6);cout<<(ULong_t)fCodeLen[i]<<endl;
+ cout.width(6);cout<<(UInt_t)fCodeLen[i]<<endl;
}//end if
}//end for
}
//////////////////////////////////////////////////////////////////////////////
-Bool_t AliTPCHTable::SpanTree(AliTPCHNode *start, ULong_t code, UChar_t len){
+Bool_t AliTPCHTable::SpanTree(AliTPCHNode *start, UInt_t code, UChar_t len){
//Hoffman codes are generated spanning the Huffman tree
//In an Huffman tree any internal node has always two children
AliTPCHNode * visited;
Int_t AliTPCHTable::GetFrequencies(const char *fname){
//It fills the "fCode" array with the frequencies of the symbols read from the file
AliTPCBuffer160 buff(fname,0);
- ULong_t numberOfWords=0;
+ UInt_t numberOfWords=0;
Int_t val;
while((val=buff.GetNext())!=-1){
fCode[val]++;
return 0;
}
-Int_t AliTPCHTable::SetValFrequency(const Int_t Val,Double_t Value){
+Int_t AliTPCHTable::SetValFrequency(Int_t Val,Double_t Value){
//This method sets to "Value" the frequency of the symbol "Val"
fCode[Val]=Value;
fNum=1;
//////////////////////////////////////////////////////////////////////////////
-Int_t AliTPCHTable::SetFrequency(const Int_t Val){
+Int_t AliTPCHTable::SetFrequency(Int_t Val){
//It increments by one the frequency of the symbol "Val" whose frequency is
//stored in the fCode array
fCode[Val]++;
//According to the kind of table (0..4) it associates a dummy frequency (1) to
//every symbols whose real frequency is zero, in a given range 0..max
Int_t max;
- ULong_t val;
+ UInt_t val;
switch(k){
case 0:
max=fSize;