]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - ITS/AliITSHuffman.h
ReadRaw(): TGraphs are created once per event (B.Polichtchouk)
[u/mrichter/AliRoot.git] / ITS / AliITSHuffman.h
index d3649ef6b3bd166be3e5c01caf0e185fc53b4fd1..b0948dc0ed04de593038dc4a9288ef32c1ba7f94 100644 (file)
 //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
 
 #include <TObject.h>
-#include <TObjArray.h>
 
 class AliITSInStream;
-
+class TObjectArray;
 class AliITSHNode: public TObject  {
 
- public:
-
-  UChar_t    fSymbol;        // comment to be written
-  ULong_t    fFrequency;     // comment to be written
-  AliITSHNode     *fLeft;    // comment to be written
-  AliITSHNode     *fRight;   // comment to be written
-  AliITSHNode     *fFather;  // not used
-  
  public:
   AliITSHNode();
   AliITSHNode(UChar_t symbol, ULong_t freq);
@@ -38,10 +29,18 @@ class AliITSHNode: public TObject  {
     // is sortable
     return kTRUE;
   }
-  Int_t Compare(TObject *obj);
+  Int_t Compare(const TObject *obj) const;
   
   ClassDef(AliITSHNode,1)     //HuffT node object for set:ITS
-    };
+
+ public:
+
+  UChar_t    fSymbol;        // comment to be written
+  ULong_t    fFrequency;     // comment to be written
+  AliITSHNode     *fLeft;    // comment to be written
+  AliITSHNode     *fRight;   // comment to be written
+  AliITSHNode     *fFather;  // not used
+};
 
 //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
 //  Attention! Next class has kept deliberaty in 
@@ -79,15 +78,15 @@ public:
   void BuildHTable();   
   Bool_t SpanTree(AliITSHNode*start, ULong_t code, UChar_t len);
   void ResetHNodes();
-  void Clear();
+  void ClearTable();
   
  protected:
 
   Int_t          fSize;     // size of the arrays
-  UChar_t       *fCodeLen;  //[fSize] number of bits array
-  ULong_t       *fCode;     //[fSize] coded symbols array
+  UChar_t       *fCodeLen;  //![fSize] number of bits array
+  ULong_t       *fCode;     //![fSize] coded symbols array
   
-  Short_t       *fSym;      //[fSize] array of input symbols
+  Short_t       *fSym;      //![fSize] array of input symbols
   TObjArray     *fHNodes;   // array of nodes
   Int_t          fNnodes;   // number of nodes